1. 08 Nov, 2016 1 commit
  2. 26 Oct, 2016 1 commit
  3. 21 Oct, 2016 1 commit
  4. 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
  5. 28 Jun, 2016 1 commit
  6. 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
  7. 09 May, 2016 1 commit
    • Brad King's avatar
      Remove `//------...` horizontal separator comments · 0ac18d40
      Brad King authored
      Modern editors provide plenty of ways to visually separate functions.
      Drop the explicit comments that previously served this purpose.
      Use the following command to automate the change:
      
          $ git ls-files -z -- \
              "*.c" "*.cc" "*.cpp" "*.cxx" "*.h" "*.hh" "*.hpp" "*.hxx" |
            egrep -z -v "^Source/cmCommandArgumentLexer\." |
            egrep -z -v "^Source/cmCommandArgumentParser(\.y|\.cxx|Tokens\.h)" |
            egrep -z -v "^Source/cmDependsJavaLexer\." |
            egrep -z -v "^Source/cmDependsJavaParser(\.y|\.cxx|Tokens\.h)" |
            egrep -z -v "^Source/cmExprLexer\." |
            egrep -z -v "^Source/cmExprParser(\.y|\.cxx|Tokens\.h)" |
            egrep -z -v "^Source/cmFortranLexer\." |
            egrep -z -v "^Source/cmFortranParser(\.y|\.cxx|Tokens\.h)" |
            egrep -z -v "^Source/cmListFileLexer\." |
            egrep -z -v "^Source/cm_sha2" |
            egrep -z -v "^Source/(kwsys|CursesDialog/form)/" |
            egrep -z -v "^Utilities/(KW|cm).*/" |
            xargs -0 sed -i '/^\(\/\/---*\|\/\*---*\*\/\)$/ {d;}'
      
      This avoids modifying third-party sources and generated sources.
      0ac18d40
  8. 29 Apr, 2016 2 commits
    • Brad King's avatar
      Format include directive blocks and ordering with clang-format · e1c77472
      Brad King authored
      Sort include directives within each block (separated by a blank line) in
      lexicographic order (except to prioritize `sys/types.h` first).  First
      run `clang-format` with the config file:
      
          ---
          SortIncludes: false
          ...
      
      Commit the result temporarily.  Then run `clang-format` again with:
      
          ---
          SortIncludes: true
          IncludeCategories:
            - Regex:    'sys/types.h'
              Priority: -1
          ...
      
      Commit the result temporarily.  Start a new branch and cherry-pick the
      second commit.  Manually resolve conflicts to preserve indentation of
      re-ordered includes.  This cleans up the include ordering without
      changing any other style.
      
      Use the following command to run `clang-format`:
      
          $ git ls-files -z -- \
              '*.c' '*.cc' '*.cpp' '*.cxx' '*.h' '*.hh' '*.hpp' '*.hxx' |
            egrep -z -v '(Lexer|Parser|ParserHelper)\.' |
            egrep -z -v '^Source/cm_sha2' |
            egrep -z -v '^Source/(kwsys|CursesDialog/form)/' |
            egrep -z -v '^Utilities/(KW|cm).*/' |
            egrep -z -v '^Tests/Module/GenerateExportHeader' |
            egrep -z -v '^Tests/RunCMake/CommandLine/cmake_depends/test_UTF-16LE.h' |
            xargs -0 clang-format -i
      
      This selects source files that do not come from a third-party.
      Inspired-by: Daniel Pfeifer's avatarDaniel Pfeifer <daniel@pfeifer-mail.de>
      e1c77472
    • 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
  9. 12 Nov, 2014 1 commit
    • Chuck Atkins's avatar
      Use containers of labeled search paths instead of individual members · 1abd7cd9
      Chuck Atkins authored
      Manage classes of search paths in labeled containers.  This removes the
      need to have a seperate member variable for each type of search path, but
      also allows path types to be grouped togethor in various different ways
      and manipulated as subsets of the full set of search paths.
      1abd7cd9
  10. 11 Nov, 2014 2 commits
  11. 15 Oct, 2014 1 commit
  12. 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
  13. 08 Mar, 2014 1 commit
  14. 21 Nov, 2013 1 commit
    • Stephen Kelly's avatar
      Introduce CMAKE_STAGING_PREFIX variable. · 7521da28
      Stephen Kelly authored
      This variable can be useful in cross-compiling contexts where the
      sysroot is read-only or where the sysroot should otherwise remain
      pristine.
      
      If the new CMAKE_STAGING_PREFIX variable is set, it is used instead
      of CMAKE_INSTALL_PREFIX when generating the installation rules in
      cmake_install.cmake.
      
      This way, the CMAKE_INSTALL_PREFIX variable
      always refers to the installation prefix on the target device, regardless
      of whether host==target.
      
      If any -rpath paths passed to the linker contain the CMAKE_STAGING_PREFIX,
      the matching path fragments are replaced with the CMAKE_INSTALL_PREFIX.
      Matching paths in the -rpath-link are not transformed.
      
      The cross-prefix usr-move workaround is assumed not to require extension
      regarding CMAKE_STAGING_PREFIX. The staging area is a single prefix, so
      there is no scope for cross-prefix symlinks. The CMAKE_INSTALL_PREFIX
      is still used to determine the workaround path, and that variable
      remains the relevant one even if CMAKE_STAGING_PREFIX is used. If the
      generated export files are deployed to the target, the workaround
      will still be in place, and still be employed if required.
      7521da28
  15. 19 Nov, 2013 1 commit
    • Stephen Kelly's avatar
      Add CMAKE_SYSROOT variable to set --sysroot when cross compiling. · 7cd65c97
      Stephen Kelly authored
      As CMAKE_ROOT_FIND_PATH can be a list, a new CMAKE_SYSROOT is
      introduced, which is never a list.
      
      The contents of this variable is passed to supporting compilers
      as --sysroot. It is also accounted for when processing implicit
      link directories reported by the compiler, and when generating
      RPATH information.
      7cd65c97
  16. 02 Nov, 2013 1 commit
    • Brad King's avatar
      cmFindCommon: Revert accidental change · 13aea6d1
      Brad King authored
      In commit c4373b33 (cmTarget: Make GetProperty() const, 2013-10-29)
      we accidentally changed the cmFindCommon.cxx logic in a way that
      looks like a local experiment leftover that went unnoticed due to
      the size of the other changes in the commit.  Revert it.
      13aea6d1
  17. 31 Oct, 2013 1 commit
    • Stephen Kelly's avatar
      cmTarget: Make GetProperty() const. · c4373b33
      Stephen Kelly authored
      This has follow-on effects for other methods and classes. Further
      work on making the use of const cmTarget pointers common can be
      done, particularly with a view to generate-time methods.
      c4373b33
  18. 16 Oct, 2013 1 commit
    • Brad King's avatar
      Drop builtin command documentation · e33d8d2d
      Brad King authored
      Drop all GetTerseDocumentation and GetFullDocumentation methods from
      commands.  The command documentation is now in Help/command/*.rst files.
      e33d8d2d
  19. 12 Jul, 2013 1 commit
  20. 07 Jun, 2013 1 commit
    • Stephen Kelly's avatar
      Use --sysroot when cross compiling. · de4da665
      Stephen Kelly authored
      As CMAKE_ROOT_FIND_PATH can be a list, a new CMAKE_SYSROOT is
      introduced, which is never a list.
      
      The contents of this variable is passed to supporting compilers
      as --sysroot. It is also accounted for when processing implicit
      link directories reported by the compiler, and when generating
      RPATH information.
      de4da665
  21. 23 Sep, 2011 1 commit
    • Brad King's avatar
      Refactor find_* command final path list computation · b0cd6305
      Brad King authored
      All find_* commands re-root the list of paths and then add trailing
      slashes.  Factor this pair of calls out into a dedicated method.  The
      new method would be the only caller to AddTrailingSlashes, so subsume
      that method into it.
      b0cd6305
  22. 12 Nov, 2010 1 commit
  23. 13 Aug, 2010 1 commit
    • Todd Gamblin's avatar
      Teach find_* commands to ignore some paths · 1221581a
      Todd Gamblin authored
      Add platform configuration variable CMAKE_SYSTEM_IGNORE_PATH and user
      configuration variable CMAKE_IGNORE_PATH.  These specify a set of
      directories that will be ignored by all the find commands.  Update
      FindPackageTest so that several cases will fail without a functioning
      CMAKE_IGNORE_PATH.
      1221581a
  24. 01 May, 2010 1 commit
  25. 01 Oct, 2009 1 commit
  26. 30 Sep, 2009 1 commit
  27. 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
  28. 03 Sep, 2009 1 commit
  29. 03 Oct, 2008 1 commit
  30. 02 Oct, 2008 1 commit
  31. 09 Jun, 2008 2 commits
  32. 05 Jun, 2008 1 commit
    • Brad King's avatar
      ENH: Refactor cmFindCommon, cmFindBase, and cmFindPackageCommand · 789c167b
      Brad King authored
        - Add each part of the search order in a separate method.
        - Collect added paths in an ivar in cmFindCommon.
        - Move user path storage up to cmFindCommon and share
          between cmFindBase and cmFindPackageCommand.
        - Expand user path registry values up in cmFindCommon
          - Enables 32-/64-bit registry view for find_package
          - Disables registry expansion for paths not specified
            with the PATHS argument, which is not expected.
      789c167b
  33. 17 Jan, 2008 1 commit
    • Brad King's avatar
      ENH: Major improvements to the FIND_PACKAGE command. See bug #3659. · b424df91
      Brad King authored
        - Use CMAKE_PREFIX_PATH and CMAKE_SYSTEM_PREFIX_PATH among other means
          to locate package configuration files.
        - Create cmFindCommon as base for cmFindBase and cmFindPackageCommand
        - Move common functionality up to cmFindCommon
        - Improve documentation of FIND_* commands.
        - Fix FIND_* commands to not add framework/app paths in wrong place.
      b424df91