1. 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
  2. 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
  3. 29 Apr, 2016 1 commit
    • 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
  4. 09 Mar, 2016 1 commit
    • Brad King's avatar
      Drop Visual Studio 6 generator · b42866a3
      Brad King authored
      This generator has been deprecated since CMake 3.3.  Remove it.
      Update documentation, modules, and tests to drop content specific
      to this generator.
      b42866a3
  5. 25 Jan, 2015 1 commit
    • Brad King's avatar
      Tests: Shorten paths in CompileDefinitions · 494f6e8d
      Brad King authored
      Shorten the add_definitions command test directory and target names to
      avoid creating really long paths that fail with some tools on Windows.
      While at it, remove unnecessary project() command calls.
      494f6e8d
  6. 06 Aug, 2014 1 commit
    • Brad King's avatar
      Genex: Do not consider 'head' when evaluating build properties · 3f476bea
      Brad King authored
      When $<TARGET_PROPERTY> names a build property like COMPILE_DEFINITIONS
      but not the usage requirement (INTERFACE_) version of it, the value
      should be that used to build the target.  It should not be influenced by
      a dependent 'head' target like usage requirements are.
      
      Extend the CompileDefinitions test with a case covering the corrected
      behavior.
      Reviewed-by: Stephen Kelly's avatarStephen Kelly <steveire@gmail.com>
      3f476bea
  7. 08 Jan, 2014 1 commit
  8. 24 Jul, 2013 1 commit
    • Stephen Kelly's avatar
      Remove the LINK_LANGUAGE generator expression. · 4f6bd702
      Stephen Kelly authored
      It accepted an optional argument to test for equality, but no way
      to get the linker language of a particular target.
      
      TARGET_PROPERTY provides this flexibility and STREQUAL provides
      the necessary API for equality test.
      
      Extend the CompileDefinitions test to cover accessing the
      property of another target.
      4f6bd702
  9. 24 May, 2013 2 commits
    • Stephen Kelly's avatar
      Tests/CompileDefinitions: Avoid spaces in defines on VS 6 · 015309fc
      Stephen Kelly authored
      The VS 6 IDE does not like spaces in definition values so CMake drops
      them and warns.  The Tests/CompileDefinitions test C code that looks for
      the dropped definitions already knows to skip them, but CMake still
      warns.  Silence the warnings by avoiding such values in the first place
      on VS 6.
      015309fc
    • Stephen Kelly's avatar
      Add $<LINK_LANGUAGE> generator expression · 32410140
      Stephen Kelly authored
      They can't be used when evaluating link libraries, but they can be
      used for include directories and compile definitions. Later they can
      be used for compile options.
      32410140
  10. 16 May, 2013 1 commit
    • Stephen Kelly's avatar
      Add the JOIN generator expression. · a7ba4520
      Stephen Kelly authored
      This generator expression joins a list with a separator. The separator
      may contain arbitrary content, such as commas, which is ordinarily a
      delimiter in the generator expression syntax.
      a7ba4520
  11. 25 Mar, 2013 1 commit
  12. 17 Oct, 2012 1 commit
  13. 28 Sep, 2012 1 commit
  14. 22 Aug, 2012 1 commit
  15. 21 Aug, 2012 2 commits
  16. 20 Aug, 2012 1 commit
    • Stephen Kelly's avatar
      Don't duplicate -D defines sent to the compiler. · 3dae652b
      Stephen Kelly authored
      There is no need to do so. Be consistent with include directories and
      ensure uniqueness.
      
      This requires changing the API of the cmLocalGenerator::AppendDefines
      method, and changing the generators to match.
      
      The test unfortunately can't test for uniqueness, but it at least verifies
      that nothing gets lost.
      3dae652b