Commit Graph

6429 Commits

Author SHA1 Message Date
Brad King bbf8c03b4f InstallRequiredSystemLibraries: Fix ENV{ProgramFiles(x86)} reference
The fix in commit v3.1.0-rc1~544^2~5 (Windows: Avoid () in environment
variable references, 2014-05-02) introduced a set() command in the
middle of an argument list.  Move it to before the find_path() call.
2016-05-12 11:08:40 -04:00
Michał Górny 25845b10d8 CMakeParseImplicitLinkInfo: Exclude pathcc ldfe lines (#16100)
PathScale uses a wrapper around the linker.  The "ldfe" invocation in
the output is followed by a normal "ld" invocation.  Exclude the former
so we can reach and parse the latter correctly.
2016-05-11 15:06:59 -04:00
Brad King 1a02780483 Merge topic 'FindLua-homebrew'
25f34dea FindLua: Add library name for Lua 5.3 on homebrew
2016-05-10 14:40:47 -04:00
Brad King 3b3afefb90 Merge topic 'fix-hdf5-for-compiler-wrapers'
00405af0 HDF5: Refactor the use of compiler wrappers
2016-05-10 14:40:45 -04:00
Chuck Atkins 00405af0f1 HDF5: Refactor the use of compiler wrappers
* Make work with HDF5 compiler wrappers as the primary compiler (Cray)
 * Accept options used by compiler wrappers instead of just seeding
   search parameters
 * Only search for libraries if the first 2 fail
2016-05-09 10:20:39 -04:00
Brad King 0ac18d40c8 Remove `//------...` horizontal separator comments
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.
2016-05-09 09:41:43 -04:00
Anders Bakken 25f34deab6 FindLua: Add library name for Lua 5.3 on homebrew
Homebrew installs lua 5.3 like this:

    Cellar/lua53/5.3.2_2/lib/liblua.5.3.2.dylib
    Cellar/lua53/5.3.2_2/lib/liblua.5.3.dylib
    lib/liblua.5.3.2.dylib
    lib/liblua.5.3.dylib

Add the `liblua.{$VERSION}` naming scheme to our searched names.
2016-05-09 09:10:05 -04:00
Brad King afca373510 Help clang-format wrap after braces on long initializer lists
Add a long comment inside a few braced initializer lists in order to
convince clang-format to break after the opening brace and format the
list without indenting every value past the opening brace.
2016-05-06 15:54:32 -04:00
Brad King ac714a3839 Merge topic 'clang-cl-showincludes'
66de0866 Ninja: Fix clang-cl /showIncludes prefix detection
2016-05-04 10:08:38 -04:00
Brad King e053510efa Merge topic 'ExternalProject-git-recursive-init'
79410eeb ExternalProject: Initialize Git submodules recursively and on update (#16083)
2016-05-03 10:17:02 -04:00
Brad King c212b5b025 Merge topic 'FindBoost-no-system-env-paths'
5a9b2b3b FindBoost: Fix Boost_NO_SYSTEM_PATHS to not consider environment (#15702)
2016-05-03 10:16:57 -04:00
Ilya Kulakov 79410eeb1f ExternalProject: Initialize Git submodules recursively and on update (#16083) 2016-05-03 10:04:37 -04:00
Brad King 66de0866a3 Ninja: Fix clang-cl /showIncludes prefix detection
We run MSVC-like compilers with the `/showIncludes` option and match the
output to extract the corresponding message.  Fix the matching to
support compilers like `clang-cl` that print the message on the first
line such that it is not preceded by a newline.

LLVM-Issue: https://llvm.org/bugs/show_bug.cgi?id=27226
2016-05-03 08:43:13 -04:00
Brad King 5a9b2b3b11 FindBoost: Fix Boost_NO_SYSTEM_PATHS to not consider environment (#15702)
Previously we added only NO_CMAKE_SYSTEM_PATH to find command calls.
Add NO_SYSTEM_ENVIRONMENT_PATH too so that paths found from system
environment variables are not considered either.
2016-05-02 11:43:28 -04:00
FARBOS Arnaud 313676c9f0 FindHDF5: Add another debug suffix
HDF5 1.8.16 (and likely others) names its debug libraries with a
`_debug` suffix intsead of `d`.
2016-05-02 11:31:35 -04:00
Brad King 067b21b675 Merge topic 'clang-format-include-order'
e1c77472 Format include directive blocks and ordering with clang-format
180538c7 Source: Stabilize include order
0e7bca92 Utilities/Release: Stabilize include order in WiX custom action
eb817be0 Tests: Stabilize include order in MFC, VSXaml, and VSWinStorePhone
eda313b4 Tests: Stabilize include order in StringFileTest
7110b754 CursesDialog: add missing cmState include
d7a5f255 Modules: Remove unused CMakeTestWatcomVersion.c file
2016-05-02 09:24:21 -04:00
Brad King e1c7747253 Format include directive blocks and ordering with clang-format
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 <daniel@pfeifer-mail.de>
2016-04-29 13:58:54 -04:00
Brad King d7a5f25599 Modules: Remove unused CMakeTestWatcomVersion.c file
This file has not been used since commit v2.8.10~218^2~7^2 (Watcom:
Simplify compiler version detection, 2012-08-13).
2016-04-29 09:12:32 -04:00
Brad King d2a061596e Features: Record features for VS 2015 Update 2 2016-04-28 13:05:52 -04:00
Brad King 5b4f771fd7 Merge topic 'intel-compiler-features'
21b1fa5c Help: Add notes for topic 'intel-compiler-features'
9addce99 Features: Record standard flags for Intel C/C++ on Windows
15a6c950 WCDH: Add Intel to list of supported compilers
36f32ede Features: Record standards and features for Intel C on UNIX
d028b948 Features: Specify minimum version Intel C++ 12.1
be910f00 Features: Record standards and features for Intel C++ on UNIX
7f401ae4 Features: Detect C default dialect on MSVC-like compilers
2016-04-28 09:26:09 -04:00
Brad King 9addce99c2 Features: Record standard flags for Intel C/C++ on Windows
Select the `-std=` or `-Qstd=` flag based on whether Intel is GNU-like
or MSVC-like, respectively.
2016-04-28 09:16:36 -04:00
Robert Maynard 15a6c9502d WCDH: Add Intel to list of supported compilers 2016-04-28 09:16:36 -04:00
Robert Maynard 36f32ede8d Features: Record standards and features for Intel C on UNIX
Record features for Intel C 12.1 and above.  Skip this for now on
Windows (where Intel C simulates MSVC).
2016-04-28 09:16:35 -04:00
Robert Maynard d028b94872 Features: Specify minimum version Intel C++ 12.1
Versions below 12.1 do not provide enough information to properly detect
if compiling with c++98 or c++0x enabled so remove them from the
supported list.
2016-04-28 09:16:31 -04:00
Levi Morrison be910f00b5 Features: Record standards and features for Intel C++ on UNIX
Skip this for now on Windows (where Intel C++ simulates MSVC).
2016-04-28 09:15:25 -04:00
Brad King 7f401ae43f Features: Detect C default dialect on MSVC-like compilers
These compilers default to C 90 but do not define __STDC__.  While MSVC
itself has no option to change the dialect, compilers that document
compatibility with MSVC and define _MSC_VER may (e.g. Intel).
2016-04-28 09:08:35 -04:00
Brad King 7db9f3f294 ExternalProject: Add option to perform a shallow Git clone (#15291)
Inspired-by: Ilya Kulakov <kulakov.ilya@gmail.com>
2016-04-27 10:58:07 -04:00
Brad King f56a0ddd28 FindBISON: Fix BISON_TARGET macro for special characters in path (#16072)
Use the VERBATIM option to add_custom_command so that the command is
escaped correctly.
2016-04-20 13:19:31 -04:00
Brad King 3d13492eac FindFLEX: Fix FLEX_TARGET macro for special characters in path (#16072)
Use the VERBATIM option to add_custom_command so that the command is
escaped correctly.
2016-04-20 13:18:56 -04:00
Brad King 484958b781 Merge topic 'coverage_collect_delete'
5de122df CTestCoverageCollectGCOV: improve DELETE option
2016-04-20 09:52:41 -04:00
Brad King 0d4c75ecfb Merge topic 'boost-import-default'
2c1b720e FindBoost: Define Boost::boost for all boost versions
2016-04-20 09:52:38 -04:00
Roger Leigh 2c1b720e64 FindBoost: Define Boost::boost for all boost versions 2016-04-19 22:07:45 +01:00
Roman Wüger 26c92d50fd BundleUtilities: Add optional parameter to ignore specified files 2016-04-19 13:20:15 -04:00
Zack Galbreath 5de122dfa4 CTestCoverageCollectGCOV: improve DELETE option
The DELETE option to ctest_coverage_collect_gcov now properly
removes all the .gcov files that were created by this function.
Previously it left behind any files that were excluded by
CTEST_CUSTOM_COVERAGE_EXCLUDE.

This option now also deletes the following files/directory that
are created by ctest_coverage_collect_gcov:
  data.json
  coverage_file_list.txt
  the uncovered/ directory
2016-04-19 13:19:10 -04:00
Brad King 21fb50d512 Merge topic 'FindMPI-intel-compiler'
2a99fae1 FindMPI: Recognize `.lib` file names for specification of link libraries
c4417b09 FindMPI: Recognize /LIBPATH for specification of linker paths.
2016-04-18 08:57:25 -04:00
Frank Park 19e8752b86 FindGit: Add new 'GitHub for Windows' user directory
GitHub for Windows now installs in

    $ENV{LOCALAPPDATA}/Github/PortableGit*/cmd

instead of

    $ENV{LOCALAPPDATA}/Github/PortableGit*/bin

Search the new location first but keep the old one in case people have
older versions installed.
2016-04-15 14:59:06 -04:00
Dominic Meiser 2a99fae1cc FindMPI: Recognize `.lib` file names for specification of link libraries
The Intel MPI compiler wrappers link against static MPI libraries simply
by listing the libraries (no `-l`).
2016-04-15 13:42:05 -04:00
Dominic Meiser c4417b0927 FindMPI: Recognize /LIBPATH for specification of linker paths.
The Intel MPI wrappers use this form of -L to specify library locations.
2016-04-15 13:42:05 -04:00
Christoph Grüninger 875490545d FindMPI: Improve documentation formatting 2016-04-11 09:43:22 -04:00
Brad King 335b5430bf Merge topic 'GetPrerequisites-more-dumpbin-paths'
a1c40291 GetPrerequisites: Look for VS tools using environment variables
c79f88b0 GetPrerequisites: add path of VS 10,11,12,14 in order to find dumpbin.exe
2016-04-11 09:38:55 -04:00
Brad King a1c402910c GetPrerequisites: Look for VS tools using environment variables
The `VS*COMNTOOLS` environment variables specify locations of VS tools
and are set during the VS installation.  Use them in addition to the
hard-coded default install locations.
2016-04-08 08:48:20 -04:00
FARBOS Arnaud c79f88b019 GetPrerequisites: add path of VS 10,11,12,14 in order to find dumpbin.exe 2016-04-08 08:48:03 -04:00
Brad King e888af9719 MSVC: Drop space in `/DNDEBUG` flag for consistency (#16052)
We define `NDEBUG` without a space after the `-D` option for most
compilers.  Remove the space for MSVC (and Intel Fortran) for
consistency.  The MS compiler technically does not document that
the `-D` argument may be separated from its value, though every
version to date supports it.
2016-04-07 10:54:43 -04:00
Brad King 82c405c473 Merge topic 'branch_coverage_working_dir'
c5ff34cc CTestCoverageCollectGCOV: specify base dir for GLOB_RECURSE
2016-04-07 08:57:45 -04:00
Brad King 7d5a0f5f60 Merge topic 'branch_coverage_glob'
8ea1b0df CTestCoverageCollectGCOV: Improve documentation
425d7646 CTestCoverageCollectGCOV: Honor CTEST_EXTRA_COVERAGE_GLOB
2016-04-07 08:57:41 -04:00
Brad King cdce3cc902 Merge topic 'UseJava-cmake-command'
fa382ae8 UseJava: use CMAKE_COMMAND instead of direct cmake call
2016-04-07 08:57:35 -04:00
Brad King 47e358dcdb Merge topic 'ExternalProject-TLS_VERIFY-fixes'
4d8c988c ExternalProject: Fix file download script with CMAKE_TLS_{VERIFY,CAINFO}
23a71e4e ExternalProject: Tell Git not to verify certs only if TLS_VERIFY is OFF
2016-04-07 08:57:29 -04:00
Zack Galbreath 8ea1b0df58 CTestCoverageCollectGCOV: Improve documentation
Clean up prose and mention support for CTEST_EXTRA_COVERAGE_GLOB.
2016-04-07 08:53:30 -04:00
Zack Galbreath 425d764685 CTestCoverageCollectGCOV: Honor CTEST_EXTRA_COVERAGE_GLOB
Teach CTestCoverageCollectGCOV to honor the
CTEST_EXTRA_COVERAGE_GLOB variable.  When this variable is set,
this module will glob for matching source files that were not
covered and include them in the resulting tar file.
2016-04-07 08:53:30 -04:00
Brad King 4d8c988caa ExternalProject: Fix file download script with CMAKE_TLS_{VERIFY,CAINFO}
Avoid generating incorrect code such as

    set(CMAKE_TLS_VERIFY set(CMAKE_TLS_VERIFY 1))

when one of these variables is set in the calling project.
2016-04-06 16:49:13 -04:00