Commit Graph

43923 Commits

Author SHA1 Message Date
Brad King
d7df3cd73f FindBoost: Remove incorrect 1.70 timer dependency
Running `Utilities/Scripts/BoostScanDeps.cmake` with the Boost 1.70.0
sources shows that the `timer` component no longer depends on `system`.
This is consistent with upstream Boost Timer commit `43eecbd071`.
2019-08-30 14:51:03 -04:00
Brad King
8ff43de1a5 FindBoost: Simplify conditional block for last known version
A version newer than we know about will be large enough to enter the
block for the last known version so we can put the warning there.
2019-08-30 14:51:03 -04:00
Brad King
40bbe50e23 CMake 3.15.2 v3.15.2 2019-08-07 12:44:19 -04:00
Brad King
dfac85bb11 Merge branch 'doc-relnotes-3.15' into release-3.15
Merge-request: !3664
2019-08-07 12:42:56 -04:00
Brad King
18ce372e0f Help: Add 3.15.2 release notes 2019-08-07 12:41:27 -04:00
Brad King
1c7a4f93dd Merge branch 'FindGLEW-macOS' into release-3.15
Merge-request: !3656
2019-08-06 09:53:42 -04:00
Claudio Fantacci
feeb0381bc FindGLEW: Fix typo in verbose log message 2019-08-06 09:49:03 -04:00
Claudio Fantacci
ab822a9b48 FindGLEW: Add required OpenGL dependency in macOS
macOS requires OpenGL as INTERFACE_LINK_LIBRARIES dependency
in the GLEW targets. This commit fixes this issue.
2019-08-06 09:49:03 -04:00
Claudio Fantacci
a8a3efa3be FindGLEW: Fix macOS library suffix selection
Fix logic added by commit a7d853868b (FindGLEW: Update implementation,
2019-03-13, v3.15.0-rc1~375^2~1) on macOS.  macOS is recognized as both
UNIX and APPLE.  Consequently, the library suffix for shared and static
library was set, respectively, as `.so` and `.a`, just like UNIX systems.
Fix this by properly checking the OS type.

Fixes: #19542
2019-08-06 09:47:35 -04:00
Brad King
9a384e7304 Merge branch 'find_package-prefer-config-not-found' into release-3.15
Merge-request: !3653
2019-08-06 09:43:25 -04:00
Cristian Adam
8ed868606d find_package: Fix prefer-config mode to not fail on missing optional package
When `CMAKE_FIND_PACKAGE_PREFER_CONFIG` mode was set to `ON`, failure to
find a package was fatal even if it was not `REQUIRED`.  Fix this and
add a test case.

Fixes: #19557
2019-08-06 09:36:36 -04:00
Brad King
1c3404a301 Merge branch 'clang-frontend-variant' into release-3.15
Merge-request: !3650
2019-08-05 10:28:29 -04:00
Brad King
a245479372 clang: Work around toolchain file use of internal CMake variables
Since commit d44c0db0b2 (clang: setup correct configuration in gnu mode,
2019-02-20, v3.15.0-rc1~41^2~5) our Clang compiler information modules
need the `CMAKE_<LANG>_COMPILER_FRONTEND_VARIANT` variable that we
compute during compiler detection.  However, some existing toolchain
files set our internal `CMAKE_<LANG>_COMPILER_ID_RUN` variables and
block that detection, but do not set the new frontend variant variable.
Help them out by setting `CMAKE_<LANG>_COMPILER_FRONTEND_VARIANT` anyway.

Fixes: #19515, #19539
2019-08-05 09:43:00 -04:00
Brad King
edca8d5c3a Merge branch 'fileapi-install-generators' into release-3.15
Merge-request: !3639
2019-08-02 11:06:22 -04:00
Brad King
d70a0f8681 fileapi: Fix codemodel target install destination for cross-dir rules
Since commit e89ad0f94e (install: Allow installing targets created in
another directory, 2018-06-18, v3.13.0-rc1~407^2) we support calling
`install(TARGETS)` for targets created in another directory.  However,
install generators are associated with the directory in which the call
to `install()` appears.  This may not be the same directory in which the
target is defined.  Record in each target the list of install generators
it has.

Fixes: #19546
2019-07-31 19:32:55 -04:00
Brad King
1ea751c8d1 Merge branch 'clang-cl-non-windows' into release-3.15
Merge-request: !3634
2019-07-31 13:04:03 -04:00
Brad King
863f7eb6d7 clang: Restore support for clang-cl on non-Windows hosts
The frontend variant detection logic added by commit 53fbe23f3f (clang:
introduce CMAKE_<lang>_COMPILER_FRONTEND_VARIANT, 2019-02-20,
v3.15.0-rc1~41^2~8) assumes that `clang-cl` only runs on a Windows host.
It is also available on non-Windows hosts.  Fix the condition.

Fixes: #19544
2019-07-31 12:52:35 -04:00
Brad King
7d98cd0442 Merge branch 'source_group-tree-files' into release-3.15
Merge-request: !3630
2019-07-30 11:31:15 -04:00
Brad King
93af8a2583 source_group: Fix regression in relative FILES
Fix the check added in commit 8d93815d20 (source_group command ensures
that FILES arguments are actually files, 2019-04-25, v3.15.0-rc1~195^2)
to convert to an absolute path before checking for existence.

Also simplify the conversion to an absolute path.

Fixes: #19454
2019-07-30 11:29:58 -04:00
Brad King
4053d5737d Merge branch 'vs-spectre-off' into release-3.15
Merge-request: !3629
2019-07-30 11:20:59 -04:00
Brad King
f9b7c660d7 VS: Fix mapping of -Qspectre- flag
The mapping for this flag was added by commit 43aa632f57 (VS: Populate
`-Qspectre-` flag table entry for v142, 2019-01-24, v3.14.0-rc1~74^2~7).
However, it did not do anything because the special logic added by
commit bb60ed6e72 (VS: Add flag table entry for -Qspectre, 2018-10-08,
v3.13.0-rc1~4^2) to move the `SpectreMitigation` element from
`ClCompile` to the top level only handled the presence of the setting
and not its value.  Extend the special logic to carry the value too.

Fixes: #19535
2019-07-30 11:17:28 -04:00
Brad King
055a782b8a Merge branch 'swift-with-interface-libs' into release-3.15
Merge-request: !3624
2019-07-29 15:34:19 -04:00
Brad King
601fe84bd1 Swift: Restore support for enabling with INTERFACE libraries
The check added in commit b06f4c8a74 (Swift: disallow WIN32_EXECUTABLE
properties, 2019-05-31, v3.15.0-rc1~9^2) makes sense only for
executables because the `WIN32_EXECUTABLE` property is defined only for
them.  Running the check on other target types, particularly those that
do not link such as INTERFACE libraries, violates internal assumptions.
In particular, `GetLinkerLanguage` should not be called on such targets.

Fixes: #19528
2019-07-29 15:24:29 -04:00
Brad King
f43a7d76c7 CMake 3.15.1 v3.15.1 2019-07-26 07:50:55 -04:00
Brad King
838278f4ba Merge branch 'doc-relnotes-3.15' into release-3.15
Merge-request: !3608
2019-07-26 07:25:33 -04:00
Brad King
3b113cc131 Help: Add 3.15.1 release notes 2019-07-26 07:18:09 -04:00
Brad King
693a9b382a Merge branch 'FindMPI-link-flags' into release-3.15
Merge-request: !3605
2019-07-25 13:09:25 -04:00
Robert Maynard
cf04da7e70 FindMPI: make sure computed link flags are not de-duplicated
In commit f7eaa342de (FindMPI: Store imported target link flags as a
list instead of a string, 2019-06-14, v3.15.0-rc2~2^2) we used
`separate_arguments` to parse the extracted link flags and add them to
`INTERFACE_LINK_LIBRARIES`.  That property is not meant for link flags
and CMake may de-duplicate them.  This is particularly problematic for
flags like `-Wl,-rpath -Wl,/path1 -Wl,-rpath -Wl,/path2`.

In commit 39c572c9c9 (FindMPI: Updated to use INTERFACE_LINK_OPTIONS,
2019-06-24) we moved the parsed flags over to `INTERFACE_LINK_OPTIONS`,
but that may still perform de-duplication.  Avoid the parsing and
de-duplication of flags by passing the original string via `SHELL:`
instead.

Fixes: #19516
2019-07-25 12:59:21 -04:00
Brad King
070a5e3835 Merge branch 'makefile-depend-relative-include' into release-3.15
Merge-request: !3599
2019-07-25 07:15:42 -04:00
Brad King
d46bac5d38 Makefile: Fix regression in dependencies on relative includes
Since commit a13a5c948e (Replace use of CollapseCombinedPath with
CollapseFullPath, 2019-03-19, v3.15.0-rc1~361^2~1), one code path now
calls `CollapseFullPath` with a base path that may be relative.
Backport KWSys commit c6f8e24a3 (SystemTools: Fix CollapseFullPath with
relative base path, 2019-07-24) to handle such base paths.

This case occurs when a build tree is placed in a directory inside a
source tree such that CMake is willing to generate a relative path from
the build tree to the source tree.  Add a test covering this case.

Fixes: #19507
2019-07-24 11:37:31 -04:00
Brad King
420073e536 Merge branch 'backport-clang-gnulike-support' into release-3.15
Merge-request: !3592
2019-07-24 08:12:51 -04:00
Brad King
4f15a6a5c2 Tests: Revert "require C++14 for the Tutorial"
Revert commit a2a90f41e3 (Tests: require C++14 for the Tutorial,
2019-03-21, v3.15.0-rc1~41^2~2).  In commit d50b31be35 (Clang: For MSVC
ABI do not use modes older than C++14, 2019-07-23) we fixed the C++
standard selection for GNU-like Clang with the MSVC ABI so the test code
itself no longer needs to do it.  In particular, changing the tests in
this way broke the tutorial's narrative.
2019-07-24 08:02:37 -04:00
Brad King
d50b31be35 Clang: For MSVC ABI do not use modes older than C++14
Since commit d44c0db0b2 (clang: setup correct configuration in gnu mode,
2019-02-20, v3.15.0-rc1~41^2~5) we support the GNU-like Clang that
targets the MSVC ABI.  However, Clang cannot compile with the MSVC
standard library unless it runs in a mode aware of C++14 (since MSVC
itself does not even have a lower mode).  When `CMAKE_CXX_STANDARD` is
set to 98 or 11, use C++14 anyway.

Since Clang's default mode is aware of C++14, another option is to not
add any flags for 98 or 11.  However, if a future Clang version ever
defaults to a higher C++ standard, setting the standard to 98 or 11
should at least not use a mode higher than 14.

Also revert test updates from commit 4819ff9647 (Tests: fix failures
with gnu mode clang on windows, 2019-03-21, v3.15.0-rc1~41^2~3) that
were meant to work around the standard selection problem.

Fixes: #19496
2019-07-24 07:40:30 -04:00
Brad King
07b93cb185 Merge branch 'fix-emulator-arguments' into release-3.15
Merge-request: !3591
2019-07-23 08:38:57 -04:00
Marek Antoniak
bf6f5467a0 Fix allocation in CROSSCOMPILING_EMULATOR evaluation
In commit fec441ec17 (Teach CROSSCOMPILING_EMULATOR to support
arguments, 2019-05-30, v3.15.0-rc1~6^2) the new member
`cmCustomCommandGenerator::EmulatorsWithArguments` was not initialized
to the proper size.  Fix this and add a test case covering the crash
that could occur with multiple commands where an emulator appears only
in a later command.

Fixes: #19500
Co-Author: Brad King <brad.king@kitware.com>
2019-07-23 08:33:31 -04:00
Brad King
4cac01c63a Merge branch 'InstallRequiredSystemLibraries-redist' into release-3.15
Merge-request: !3585
2019-07-22 10:20:06 -04:00
James Butler
13c3ec545b IRSL: Fix discovery of VS 2019 v141 toolset redistributables
Since VS 2019, the v141 toolset redistributables can be found in
either the VS 2019 or VS 2017 install directory. Update the logic
to search multiple versions of VS.

Fixes: #19488
2019-07-22 10:06:45 -04:00
James Butler
0484165da0 IRSL: Fix typo in v143 toolset version check
Fix the toolset v143 check from commit 33ee779330 (IRSL: Fix discovery
of VS 2019 v142 toolset redistributables, 2019-04-03, v3.14.2~6^2) to
check the correct variable.
2019-07-22 10:06:44 -04:00
Brad King
fc2a7c8b3f Merge branch 'ctest-done-hash' into release-3.15
Merge-request: !3563
2019-07-19 12:01:04 -04:00
Betsy McPhail
da79075c4d CTest: Generate Done.xml before calculating its hash
Fixes: #19489
2019-07-19 12:00:30 -04:00
Brad King
8d22999753 Merge branch 'msvc-runtime-library-doc' into release-3.15
Merge-request: !3573
2019-07-19 11:18:44 -04:00
Brad King
282d9f3168 MSVC: Document behavior when MSVC_RUNTIME_LIBRARY is not set
By default `CMAKE_MSVC_RUNTIME_LIBRARY` is not set.  Document the
default runtime library selection in that case.  We already test it.
2019-07-19 11:17:32 -04:00
Brad King
d96bc3cf04 Merge branch 'vs-asmlist-dir' into release-3.15
Merge-request: !3569
2019-07-18 11:41:49 -04:00
Brad King
c1fc6c80c7 VS: Place intermediate files in the "ASM List Location" next to objects
The `AssemblerListingLocation` setting in VS project files is meant for
intermediate files created during the build much like object files.
When the VS 7 generator was first under development, commit 49aebe6c99
(new arch, 2002-09-04) placed both object files and the ASM list
location in the same directory.  Later commit f9aef0e422 (Generator now
creates a separate intermediate files directory for each target,
2005-07-27) moved the object files to a per-target directory but the
ASM list location was not moved with them.  Move it now.

Fixes: #19480
2019-07-18 11:40:58 -04:00
Brad King
1a2d260634 Merge branch 'backport-swift-improvements' into release-3.15
Merge-request: !3568
2019-07-18 07:47:05 -04:00
Brad King
c79032438c Merge branch 'FindPython-interpreter-crosscompiling' into release-3.15
Merge-request: !3564
2019-07-18 07:14:55 -04:00
Marc Chevrier
696d0f9caf FindPython: ensure interpreter is founded when cross-compiling
Fixes: #19473
2019-07-18 07:13:20 -04:00
Saleem Abdulrasool
5803a8a2f7 Swift: support SONAME on ELFish targets
We should enable the soname to be setup for ELF shared libraries.
Failure to do so generates binaries with incorrect names which prevents
loading.
2019-07-17 20:46:25 -07:00
Saleem Abdulrasool
47e28cbe1f Swift: support multithreaded compilation
Query the number of logical CPUs available to enable parallel
compilation for Swift.
2019-07-17 20:46:08 -07:00
Saleem Abdulrasool
6814567e8c Swift: add rules for static linking
The Swift driver recently learnt how to generate static libraries using
the `-static` flag.  This enables us to generate proper static libraries
with dependency tracking with Swift as well.
2019-07-17 20:45:54 -07:00