Commit Graph

8157 Commits

Author SHA1 Message Date
Brad King
a363c9356d Merge topic 'findmpi-builtin-fix'
d1d8719f FindMPI: Fix various legacy problems

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !1569
2017-12-13 07:52:54 -05:00
Brad King
f0b3fab179 Merge topic 'irsl-msvc-omp-fix'
4dae55fb IRSL: Fix MSVC variable deferencing

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !1588
2017-12-13 07:50:52 -05:00
Brad King
95e86eafd7 Merge topic 'FindPerlLibs-MacOS-failure'
a6005371 FindPerlLibs: Add support for MSYS and CYGWIN
362a1f33 FindPerlLibs: refactoring
c365a078 FindPerlLibs: fix MacOS failure

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !1586
2017-12-13 07:50:02 -05:00
Christian Pfeiffer
4dae55fb70 IRSL: Fix MSVC variable deferencing
Fixes: #17529
2017-12-12 15:16:38 +01:00
Christian Pfeiffer
d1d8719f62 FindMPI: Fix various legacy problems
This MR fixes a number of bugs stemming from legacy variable handling,
partially introduced by commit v3.10.0-rc1~103^2 (FindMPI: Add support
for FreeBSD and SLES, 2017-08-09).

* `MPI_COMPILE_OPTIONS` and `MPI_COMPILE_DEFINITIONS` legacy hints were not passed correctly.
* Legacy variables could be parsed after they were set by `FindMPI` cause erroneous hinting on subsequent runs.
* In the case of the compiler supporting MPI implicitly:
	* not all consumption variables would be correctly reset.
	* `MPI_<LANG>_HEADER_DIR` would be set unintentionally.
	* `MPI_<LANG>_LIB_NAMES` appeared in cache despite being ignored.
	* on subsequent passes, `MPI_<LANG>_COMPILER` could be corrupted.
* the C-to-CXX copy logic would take place even if `MPI_SKIP_GUESSING` was turned on
* if only some language compilers were given, inconsistent search behavior could be observed

Issue: #17538
2017-12-12 14:20:02 +01:00
Brad King
77aab3e515 Merge topic 'FindPkgConfig_doc_cleanup'
adf49137 FindPkgConfig: Cleanup docs

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !1584
2017-12-12 08:03:57 -05:00
Brad King
57199deafa Merge topic 'fix-iar-binutils-for-cxx'
e4707048 IAR: FindBinUtils should work for CXX as well as C

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !1572
2017-12-12 08:02:55 -05:00
Brad King
e2303b257c Merge branch 'fix-iar-binutils-for-cxx' into release-3.10
Merge-request: !1572
2017-12-12 08:00:44 -05:00
Islam Amer
e4707048c0 IAR: FindBinUtils should work for CXX as well as C
The IAR compiler test works when a project specifies LANGUAGES C CXX
but fails if CXX comes before C. This change makes it work regardless
of the order.
2017-12-12 08:00:16 -05:00
Marc Chevrier
a6005371b0 FindPerlLibs: Add support for MSYS and CYGWIN 2017-12-12 11:42:28 +01:00
Marc Chevrier
362a1f336d FindPerlLibs: refactoring
Use a dedicated function (perl_get_info) to retrieve various configuration information
2017-12-12 09:41:16 +01:00
Marc Chevrier
c365a07870 FindPerlLibs: fix MacOS failure
Fix library paths computation on MacOS

Fixes: #12544
2017-12-12 09:38:39 +01:00
Craig Scott
adf4913795 FindPkgConfig: Cleanup docs
- Moved block of misplaced comments to correct section
- Improved grammar, readability and consistency
- Updated to conform to style guidelines
2017-12-10 22:50:39 +11:00
Domen Vrankar
93d5f464cc CPack: enable all CMake policies for generator scripts 2017-12-09 12:50:28 +01:00
Brad King
3efc6ad2a2 Merge branch 'cuda_darwin_proper_install_names_flags' into release-3.10
Merge-request: !1570
2017-12-08 09:54:31 -05:00
Brad King
e81b7a2075 Merge topic 'cuda_darwin_proper_install_names_flags'
ce3874b3 CUDA: Shared libraries on Darwin properly setup @rpath install_names

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !1570
2017-12-08 09:53:33 -05:00
Robert Maynard
ce3874b303 CUDA: Shared libraries on Darwin properly setup @rpath install_names
Shared libraries linked with CUDA now properly setup booth the correct
install_name but also specify headerpad_max_install_names so that the names
can be changed post build.
2017-12-07 11:31:03 -05:00
Brad King
e016d6d255 Merge topic 'cpack-rpm-check-executable-flags'
a2031d3a CPack/RPM: check executable flags for debuginfo packages

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !1565
2017-12-07 08:28:31 -05:00
Brad King
e1a09cfbd1 Merge topic 'externalproject_download_dir'
b8b87489 ExternalProject: Support substituting <DOWNLOAD_DIR>

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !1537
2017-12-07 08:14:34 -05:00
Brad King
79fde6a324 Merge topic 'FindOpenCL-amd-sdk'
f313541a FindOpenCL: Add support for AMD OpenCL SDK Light

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !1562
2017-12-07 08:13:37 -05:00
Brad King
ea63c522ef Merge topic 'gtest-discovery-timeout'
935848a8 GoogleTest: Add test for missing test executable
29731d89 GoogleTest: Add timeout to discovery
e99e3982 GoogleTest: Improve gtest_discover_tests messages

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !1534
2017-12-07 08:06:27 -05:00
Brad King
afae027d63 Merge branch 'gtest-discovery-timeout' into release-3.10
Merge-request: !1534
2017-12-07 08:03:11 -05:00
Craig Scott
b8b8748977 ExternalProject: Support substituting <DOWNLOAD_DIR> 2017-12-07 07:22:02 +11:00
Domen Vrankar
a2031d3a3a CPack/RPM: check executable flags for debuginfo packages
Debuginfo packages can not be created from programs and
shared libraries that do not have execute permissions.
2017-12-06 21:04:20 +01:00
Harry Mallon
f313541adb FindOpenCL: Add support for AMD OpenCL SDK Light 2017-12-06 15:03:34 +00:00
Brad King
22f440ae69 Merge topic 'findmpi-notfound-spam'
bde7513d FindMPI: Correct legacy variable handling

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !1557
2017-12-06 08:00:46 -05:00
Brad King
b6dd3969e8 Merge topic 'findmpi-found-cond'
2047eb36 FindMPI: Fix multiple configure runs

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !1556
2017-12-06 08:00:07 -05:00
Matthew Woehlke
29731d8919 GoogleTest: Add timeout to discovery
Add a TIMEOUT option to gtest_discover_tests. This provides a
work-around in case a test goes out to lunch, rather than causing the
build to simply hang. (Although this is still a problem with the user's
project, hanging the build is not cool, especially in the case of
automatically running CI builds. It is much preferred that the build
should actively fail in this case, and it is trivially easy for us to
implement that.)
2017-12-06 07:37:48 -05:00
Brad King
0418e91f7d Merge branch 'findmpi-notfound-spam' into release-3.10
Merge-request: !1557
2017-12-05 08:37:10 -05:00
Brad King
64184762f4 Merge branch 'findmpi-found-cond' into release-3.10
Merge-request: !1556
2017-12-05 08:36:52 -05:00
Christian Pfeiffer
2047eb360d FindMPI: Fix multiple configure runs
Due to a erroneous logical dependency on a temporary variable, FindMPI
would depend its FOUND status on the set of flags needed to support
compiler-implicit MPI support after the first configure run.

This behavior is especially causing a misreported NOT FOUND status after
the first run on MPI implementations without MPI compiler like MS-MPI or
MPICH2 on Windows.
2017-12-05 14:17:27 +01:00
Christian Pfeiffer
bde7513d2f FindMPI: Correct legacy variable handling
Due to a minor logic error, MPI_LIBRARY, MPI_EXTRA_LIBRARY and
MPI_<LANG>_LIBRARIES hints are currently not correctly handled and
discarded.

Additionally, if either C or CXX aren't enabled, there subsequent calls
to FindMPI will cause cache variables of the sort "MPI_MPI_EXTRA_LIBRARY-NOTFOUND"
to appear due to an error in the compatibility handling. (Doesn't affect
functionality)
2017-12-05 14:14:40 +01:00
Brad King
d5681e353a Merge topic 'pragma-once'
4d611868 Check*: Added include guards

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !1327
2017-12-04 10:52:47 -05:00
Cristian Adam
4d611868df Check*: Added include guards 2017-12-01 13:05:02 +02:00
Matthew Woehlke
e99e39829b GoogleTest: Improve gtest_discover_tests messages
Adjust the formatting of error messages produced when test discovery
goes wrong, in order to avoid spurious line breaking.
2017-11-30 15:07:52 -05:00
Brad King
c2ea729c87 Merge topic 'CMakeFindBinUtils-improve-switch'
acb4cb95 CMakeFindBinUtils: Improve switch between MSVC- and GNU-like tools

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !1533
2017-11-30 07:58:15 -05:00
Brad King
21806e6f5f Merge topic 'findcuda-separable-compilation-fix'
3726ded1 FindCUDA: Add cublas device library to separable compilation

Acked-by: Kitware Robot <kwrobot@kitware.com>
Reviewed-by: Robert Maynard <robert.maynard@kitware.com>
Merge-request: !1446
2017-11-30 07:55:59 -05:00
Brad King
eee4124f3a Merge topic 'findiconv-module'
95646591 FindIconv: Add the FindIconv module.

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !1530
2017-11-30 07:55:24 -05:00
Brad King
c5fdd66252 Merge topic 'CheckIncludeFiles-fix-src-name'
3eee3301 CheckIncludeFiles: Fix name of source file used for check

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !1538
2017-11-30 07:42:45 -05:00
Brad King
3eee33012e CheckIncludeFiles: Fix name of source file used for check
In commit 7669695a74 (CheckIncludeFiles: extend to allow a LANGUAGE
argument, 2017-11-08) the file name used for the check was accidentally
left as `${var}.c`, where `var` is not a variable we define.  It was
passing tests by accidentally using just `.c` as the file name, but can
break in real projects that may leave `var` defined to something else.
The reference was taken from similar code in CheckTypeSize where the
variable names are different.  Fix our reference to be `${VARIABLE}`.
2017-11-30 07:37:35 -05:00
Jamil Appa
3726ded116 FindCUDA: Add cublas device library to separable compilation
Add cublas libraries to separable compilation device link line to
resolve missing symbols when using cublas device library.
2017-11-29 11:44:42 -05:00
Christian Pfeiffer
95646591d6 FindIconv: Add the FindIconv module.
This module provides abstraction over the various ways POSIX platforms
handle the iconv calls defined in POSIX.1-2001 and later versions.
2017-11-29 14:51:32 +01:00
Brad King
c07b18d883 Merge topic 'CodeBlocks-custom-compiler-id'
e04f1d1b CodeBlocks: add option for the CB compiler ID

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !1512
2017-11-29 08:32:26 -05:00
Brad King
d5cad74078 Merge topic 'clang-cl-fix'
f969f1a9 Clang: Do not mistake clang-cl 6.0 for GNU-like clang

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !1522
2017-11-29 08:29:36 -05:00
Brad King
caffddd620 Merge topic 'CheckIncludeFiles-language-CXX'
b31d5e1d CheckIncludeFiles: improve warning for missing argument
1f1c2a9f CheckIncludeFiles: clean up documentation of new features
c8609992 Help: Add notes for topic 'CheckIncludeFiles-language-CXX'
ea1bb902 CheckIncludeFiles: add unit tests
7669695a CheckIncludeFiles: extend to allow a LANGUAGE argument

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !1464
2017-11-29 08:26:05 -05:00
Brad King
9e961930ee Merge topic 'win-clang-debug'
458c589f FindBoost: Add Windows ABI tag for Clang debug
00e39a4a FindBoost: Use CMAKE_CXX_COMPILER_ID for Intel compiler

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !1529
2017-11-29 08:23:11 -05:00
Brad King
d4805dd47b Merge topic 'cuda-implicit-include-dirs'
2f72573a CUDA: Treat /usr/include as an implicit include directory

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !1528
2017-11-29 08:20:45 -05:00
Brad King
79ad921a38 Merge branch 'clang-cl-fix' into release-3.10
Merge-request: !1522
2017-11-28 11:09:53 -05:00
İsmail Dönmez
f969f1a9ce Clang: Do not mistake clang-cl 6.0 for GNU-like clang
The check added by commit v3.10.0-rc2~2^2 (Clang: Diagnose unsupported
GNU-like clang targeting MSVC ABI, 2017-10-10) is incorrectly detecting
clang-cl 6.0 as GNU-like.  Currently cmake is testing if the clang
compiler accepts `--version` to see if it accepts GNU style flags.
However, with the latest llvm snapshot this also works for clang-cl:

    > clang-cl --version
    clang version 6.0.0 (trunk)
    Target: x86_64-pc-windows-msvc
    Thread model: posix
    InstalledDir: C:\Program Files\LLVM\bin

So instead we should use the `/?` flag which fails with clang but
works with clang-cl:

    > clang-cl /? &> /dev/null; echo $?
    0
    > clang /? &> /dev/null; echo $?
    1

Fixes: #17518
2017-11-28 17:08:33 +01:00
Brad King
acb4cb9500 CMakeFindBinUtils: Improve switch between MSVC- and GNU-like tools
The switch was not considering some languages, such as `ASM`.
Instead of memorizing the list of languages in the condition,
use a language specified by the includer.

Fixes: #17510
2017-11-28 07:57:58 -05:00