1. 24 Jul, 2019 1 commit
    • Sebastian Holtermann's avatar
      cmMakefile: Let AddDefinition accept a value as cm::string_view · e91bfe44
      Sebastian Holtermann authored
      This changes `cmMakefile::AddDefinition` to take a `cm::string_view` as value
      argument instead of a `const char *`.
      
      Benefits are:
      - `std::string` can be passed to `cmMakefile::AddDefinition` directly without
        the `c_str()` plus string length recomputation fallback.
      - Lengths of literals passed to `cmMakefile::AddDefinition` can be computed at
        compile time.
      
      In various sources uses of `cmMakefile::AddDefinition` are adapted to avoid
      `std::string::c_str` calls and the `std::string` is passed directly.
      Uses of `cmMakefile::AddDefinition`, where a `nullptr` `const char*` might
      be passed to `cmMakefile::AddDefinition` are extended with `nullptr` checks.
      e91bfe44
  2. 19 May, 2019 1 commit
  3. 20 Feb, 2019 2 commits
  4. 20 Jan, 2019 1 commit
  5. 11 Jan, 2019 1 commit
  6. 01 Jun, 2018 1 commit
    • Kitware Robot's avatar
      Revise C++ coding style using clang-format-6.0 · d7204e64
      Kitware Robot authored
      Run the `clang-format.bash` script to update all our C and C++ code to a
      new style defined by `.clang-format`.  Use `clang-format` version 6.0.
      
      * If you reached this commit for a line in `git blame`, re-run the blame
        operation starting at the parent of this commit to see older history
        for the content.
      
      * See the parent commit for instructions to rebase a change across this
        style transition commit.
      d7204e64
  7. 31 Jan, 2018 1 commit
    • Pavel Solodovnikov's avatar
      Reduce raw string pointers usage. · 653b8946
      Pavel Solodovnikov authored
      * Change some functions to take `std::string` instead of
        `const char*` in the following classes: `cmMakeFile`, `cmake`,
        `cmCoreTryCompile`, `cmSystemTools`,  `cmState`, `cmLocalGenerator`
        and a few others.
      * Greatly reduce using of `const char*` overloads for
        `cmSystemTools::MakeDirectory` and `cmSystemTools::RelativePath`.
      * Remove many redundant `c_str()` conversions throughout the code.
      653b8946
  8. 12 Sep, 2017 1 commit
  9. 24 Aug, 2017 1 commit
  10. 11 Apr, 2017 1 commit
    • Daniel Pfeifer's avatar
      Use quotes for non-system includes · 1d829c86
      Daniel Pfeifer authored
      Automate with:
      
      git grep -l '#include <cm_' -- Source \
        | xargs sed -i 's/#include <\(cm_.*\)>/#include "\1"/g'
      
      git grep -l '#include <cmsys/' -- Source \
        | xargs sed -i 's/#include <\(cmsys\/.*\)>/#include "\1"/g'
      
      git grep -l '#include <cm[A-Z]' -- Source \
        | xargs sed -i 's/#include <\(cm[A-Z].*\)>/#include "\1"/g'
      1d829c86
  11. 14 Nov, 2016 2 commits
  12. 26 Oct, 2016 1 commit
  13. 27 Sep, 2016 1 commit
    • Brad King's avatar
      Simplify CMake per-source license notices · 86578ecc
      Brad King authored
      Per-source copyright/license notice headers that spell out copyright holder
      names and years are hard to maintain and often out-of-date or plain wrong.
      Precise contributor information is already maintained automatically by the
      version control tool.  Ultimately it is the receiver of a file who is
      responsible for determining its licensing status, and per-source notices are
      merely a convenience.  Therefore it is simpler and more accurate for
      each source to have a generic notice of the license name and references to
      more detailed information on copyright holders and full license terms.
      
      Our `Copyright.txt` file now contains a list of Contributors whose names
      appeared source-level copyright notices.  It also references version control
      history for more precise information.  Therefore we no longer need to spell
      out the list of Contributors in each source file notice.
      
      Replace CMake per-source copyright/license notice headers with a short
      description of the license and links to `Copyright.txt` and online information
      available from "https://cmake.org/licensing".  The online URL also handles
      cases of modules being copied out of our source into other projects, so we
      can drop our notices about replacing links with full license text.
      
      Run the `Utilities/Scripts/filter-notices.bash` script to perform the majority
      of the replacements mechanically.  Manually fix up shebang lines and trailing
      newlines in a few files.  Manually update the notices in a few files that the
      script does not handle.
      86578ecc
  14. 15 Sep, 2016 1 commit
  15. 28 Jun, 2016 1 commit
  16. 16 May, 2016 1 commit
    • Kitware Robot's avatar
      Revise C++ coding style using clang-format · d9fd2f54
      Kitware Robot authored
      Run the `Utilities/Scripts/clang-format.bash` script to update
      all our C++ code to a new style defined by `.clang-format`.
      Use `clang-format` version 3.8.
      
      * If you reached this commit for a line in `git blame`, re-run the blame
        operation starting at the parent of this commit to see older history
        for the content.
      
      * See the parent commit for instructions to rebase a change across this
        style transition commit.
      d9fd2f54
  17. 29 Apr, 2016 1 commit
    • Brad King's avatar
      Source: Stabilize include order · 180538c7
      Brad King authored
      Each source file has a logical first include file.  Include it in an
      isolated block so that tools that sort includes do not move them.
      180538c7
  18. 15 Jun, 2015 1 commit
  19. 18 Jan, 2015 2 commits
  20. 11 Mar, 2014 1 commit
    • Stephen Kelly's avatar
      Remove some c_str() calls. · 21c573f6
      Stephen Kelly authored
      Use the clang RemoveCStrCalls tool to automatically migrate the
      code. This was only run on linux, so does not have any positive or
      negative effect on other platforms.
      21c573f6
  21. 19 Oct, 2013 1 commit
    • Brad King's avatar
      exec_program: Re-implement using KWSys Process · 52b80b26
      Brad King authored
      Drop use of cmSystemTools::RunCommand.  It used popen on UNIX
      (equivalent to /bin/sh -c "$command") and direct CreateProcess calls on
      Windows.  Implement equivalent behavior using the KWSys Process library.
      Copy windows shortpath conversion logic from cmSystemTools::RunCommand.
      52b80b26
  22. 13 Aug, 2012 1 commit
    • Kitware Robot's avatar
      Remove trailing whitespace from most CMake and C/C++ code · 7bbaa428
      Kitware Robot authored
      Our Git commit hooks disallow modification or addition of lines with
      trailing whitespace.  Wipe out all remnants of trailing whitespace
      everywhere except third-party code.
      
      Run the following shell code:
      
      git ls-files -z -- \
       bootstrap doxygen.config '*.readme' \
       '*.c' '*.cmake' '*.cpp' '*.cxx' \
       '*.el' '*.f' '*.f90' '*.h' '*.in' '*.in.l' '*.java' \
       '*.mm' '*.pike' '*.py' '*.txt' '*.vim' |
      egrep -z -v '^(Utilities/cm|Source/(kwsys|CursesDialog/form)/)' |
      egrep -z -v '^(Modules/CPack\..*\.in)' |
      xargs -0 sed -i 's/ \+$//'
      7bbaa428
  23. 01 Oct, 2009 1 commit
  24. 28 Sep, 2009 1 commit
    • Brad King's avatar
      Convert CMake to OSI-approved BSD License · 96afb120
      Brad King authored
      This converts the CMake license to a pure 3-clause OSI-approved BSD
      License.  We drop the previous license clause requiring modified
      versions to be plainly marked.  We also update the CMake copyright to
      cover the full development time range.
      96afb120
  25. 23 Jan, 2008 1 commit
  26. 10 May, 2006 1 commit
  27. 15 Mar, 2006 1 commit
  28. 24 Jun, 2004 1 commit
  29. 23 Jun, 2004 1 commit
  30. 08 Nov, 2002 1 commit
  31. 23 Oct, 2002 2 commits
  32. 08 Oct, 2002 1 commit
  33. 15 Sep, 2002 1 commit
  34. 08 Aug, 2002 2 commits
  35. 08 Apr, 2002 1 commit