1. 08 Nov, 2016 1 commit
  2. 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
  3. 19 Sep, 2016 4 commits
  4. 03 Sep, 2016 1 commit
  5. 27 Aug, 2016 1 commit
  6. 28 Jun, 2016 1 commit
  7. 10 Jun, 2016 1 commit
  8. 06 Jun, 2016 1 commit
  9. 02 Jun, 2016 1 commit
    • Daniel Pfeifer's avatar
      Simplify boolean expressions · 7f6b8d33
      Daniel Pfeifer authored
      Use clang-tidy's readability-simplify-boolean-expr checker.
      After applying the fix-its, revise all changes *very* carefully.
      Be aware of false positives and invalid changes.
      7f6b8d33
  10. 25 May, 2016 1 commit
    • Daniel Pfeifer's avatar
      Use enums defined in cmOutputConverter using their fully qualified name. · 25d1ef64
      Daniel Pfeifer authored
      Mostly automated:
      
      values=("RelativeRoot" "NONE" "FULL" "HOME" "START" "HOME_OUTPUT" "START_OUTPUT"
              "OutputFormat" "UNCHANGED" "MAKERULE" "SHELL" "WATCOMQUOTE" "RESPONSE"
              "FortranFormat" "FortranFormatNone" "FortranFormatFixed" "FortranFormatFree")
      for i in "${values[@]}"; do git grep -l cmLocalGenerator::$i | xargs sed -i "s|cmLocalGenerator::$i|cmOutputConverter::$i|g"; done
      25d1ef64
  11. 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
  12. 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
  13. 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
  14. 03 Apr, 2015 1 commit
  15. 10 Mar, 2015 1 commit
  16. 18 Jan, 2015 1 commit
  17. 13 Jan, 2015 1 commit
  18. 11 Jan, 2015 1 commit
  19. 22 Jul, 2014 2 commits
    • Brad King's avatar
      cmDepends: Refactor object file path conversion · 85cea8a7
      Brad King authored
      Delay conversion of the path to object files (on the left-hand side
      of dependencies) until just before they are written.  Also do not
      convert the format of paths written to the 'depend.internal' file.
      This is consistent with the way the right-hand side of dependencies
      are already handled.
      85cea8a7
    • Brad King's avatar
      cmLocalGenerator: Rename 'MAKEFILE' to 'MAKERULE' · 9f92a78b
      Brad King authored
      Rename the internal enumeration value for converting paths destined
      for use in Makefile rule syntax.
      9f92a78b
  20. 11 Mar, 2014 2 commits
  21. 08 Mar, 2014 2 commits
    • Ben Boeckel's avatar
      strings: Remove cmStdString references · 270eb96d
      Ben Boeckel authored
      Casts from std::string -> cmStdString were high on the list of things
      taking up time. Avoid such implicit casts across function calls by just
      using std::string everywhere.
      
      The comment that the symbol name is too long is no longer relevant since
      modern debuggers alias the templates anyways and the size is a
      non-issue since the underlying methods are generated since it's
      inherited.
      270eb96d
    • Ben Boeckel's avatar
      stringapi: Use strings for the languages · ce511435
      Ben Boeckel authored
      ce511435
  22. 07 Jan, 2014 1 commit
  23. 26 Jun, 2013 1 commit
  24. 06 Nov, 2012 2 commits
    • Alexander Neundorf's avatar
      cmDepends: allow multiple dependees per depender · e74ff7c2
      Alexander Neundorf authored
      
      
      This patch is heavily inspired by Michael Wild.
      
      The interfaces cmDepends::Write and cmDepends::WriteDependencies where
      extended to allow multiple dependees (sources) per depender (object).
      cmDepends::Write first collect all dependencies into a std::set before
      passing it to cmDepends::WriteDependencies.
      
      cmDependsC::WriteDependencies also first collects all explicit and
      implicit dependencies into a std::set and only then writes
      depend.{internal,make}. The implementation of cmDependsFortran simply
      loops over all sources and proceeds as before, whereas the cmDependsJava
      implementation is as trivial as before.
      
      This is for preventing exponential growth of depend.{internal,make} in
      the next commit which fixes dependency-vector erasure in
      cmDepends::CheckDependencies.
      Inspired-by: default avatarMichael Wild <themiwi@users.sourceforge.net>
      e74ff7c2
    • Alexander Neundorf's avatar
      cmDependsC: fix indentation · ecc77d09
      Alexander Neundorf authored
      This is intentionally a separate commit, so the parent commit which
      changes the logic is small and not mixed with formatting (indentation)
      changes.  So, this patch here does not change any logic.
      
      Alex
      ecc77d09
  25. 03 Nov, 2012 1 commit
    • Alexander Neundorf's avatar
      cmDependsC: remove code duplication · 3e7d97d4
      Alexander Neundorf authored
      
      
      This patch reduces a bit code duplication by changing the way how the
      case that we already have valid dependencies for a file is handled.
      Instead of having the code for writing the depend-files twice,
      we now fill the existing dependencies into the same set and then
      write it out once at the end of cmDependsC::WriteDependencies()
      
      Alex
      Inspired-by: default avatarMichael Wild <themiwi@users.sourceforge.net>
      3e7d97d4
  26. 18 Dec, 2011 2 commits
  27. 17 Jan, 2011 1 commit
    • Brad King's avatar
      Normalize slashes in scanned #include lines (#10281) · 8dc7501d
      Brad King authored
      On Windows platforms source files may contain '\' in include directives:
      
        #include "a\b.h"
      
      Normalize these while scanning to use forward slashes.  CMake will
      convert from forward slashes to the direction preferred by the native
      build tools when writing the path to 'depend.make' files.
      8dc7501d
  28. 09 Oct, 2009 1 commit
  29. 06 Oct, 2009 1 commit
    • Alexander Neundorf's avatar
      speedup C dependency scanning even more · 8a5ae4c1
      Alexander Neundorf authored
      Scanning the dependencies for kdelibs/khtml/ (when all files are scanned) is
      now down to 4.6 s from 6.3 s before this change (without the
      headerLocationCache it takes about 14 s here).
      It doesn't really make sense to include the complete include path as part
      of the key for the map, since the include path will be the same for
      all files in a project, so it doesn't add anything.
      
      Alex
      8a5ae4c1
  30. 01 Oct, 2009 1 commit
  31. 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
  32. 23 Sep, 2009 1 commit
    • Alexander Neundorf's avatar
      Major optimization of C/C++ dependency scanning. · 39383ef8
      Alexander Neundorf authored
      Now only the dependencies for the file where the dependencies actually may
      have changed are rescanned, before that this was done for all source files
      even if only one source file had changed.
      This reduces e.g. on my machine the time for scanning the dependencies
      of kdelibs/khtml/ when only one file (khtml_global.cpp) has changed from
      around 7.5 seconds to 1.2 seconds.
      
      The tests succeed, it does what I expected it to do on kdelibs, and Brad
      also reviewed the patch, so I think it should be ok.
      
      Alex
      39383ef8