Commit Graph

9538 Commits

Author SHA1 Message Date
Brad King
d71591dfd5 Merge branch 'FindBLAS-OpenBLAS-thread' into release-3.15
Merge-request: !4134
2019-12-12 12:13:10 -05:00
Brad King
d1e111d166 FindBLAS: Consider OpenBLAS with thread libraries only with C or CXX
The check added by commit 276b56f01c (FindBLAS: Add second try for
OpenBLAS with thread libraries., 2019-06-07, v3.15.0-rc2~5^2) can
work only when C or CXX is enabled.

Fixes: #20092
2019-12-12 12:10:47 -05:00
Brad King
b3a536e726 Merge branch 'backport-3.15-vs-v142-version' into release-3.15
Merge-request: !4133
2019-12-12 11:38:15 -05:00
Brad King
07612646fe VS: Fix support for v142 toolset minor versions in VS 16.5+
The fix in commit 5117389931 (VS: Fix support for v142 toolset minor
versions, 2019-10-01, v3.15.5~6^2) worked around a bug in VS's placement
of toolset files.   VS 16.5 will fix that bug and restore the original
pattern for locations of toolset files.  Update our logic to look for
both possibilities.

Issue: #19779
2019-12-12 11:25:42 -05:00
Brad King
3d1a939af1 Merge branch 'backport-3.15-FindGTK2-harfbuzz' into release-3.15
Merge-request: !3877
2019-12-09 13:23:38 -05:00
Markus Mittendrein
e4b1b79abb FindGTK2: Add harfbuzz to GTK2_INCLUDE_DIRS
Fixes: #19531
2019-12-09 12:04:33 -05:00
Brad King
4e4327ee3c Merge branch 'backport-implicit-includes-extra-CR' into release-3.15
Merge-request: !4088
2019-11-26 09:03:14 -05:00
Brad King
4b46523d90 CMakeParseImplicitIncludeInfo: Remove all CR chars from compiler output
With Clang/LLVM on MinGW, lines ending in `\r\r\n` have been observed.
Filter out all `\r` characters from these line endings.

Fixes: #20021
2019-11-25 14:32:02 -05:00
Brad King
61ce9d1769 Merge branch 'backport-FindBoost-meta-component-ALL' into release-3.15
Merge-request: !4008
2019-11-07 09:31:59 -05:00
Deniz Bahadir
0faeb6a428 FindBoost: Prevent warning due to new meta-component "ALL" of Boost 1.73 2019-11-07 09:29:54 -05:00
Brad King
4011b1be41 Merge branch 'backport-findpostgres-10-and-older' into release-3.15
Merge-request: !4007
2019-11-07 09:29:20 -05:00
Ben Boeckel
aeae4182cb FindPostgreSQL: support version encoding used in pre-10 releases
With the 10.x release, PostgreSQL upstream started encoding the version
as `MMmmmm` where `M` is major and `m` is minor. Prior to that, `MMmmPP`
was used where `P` was the patch number. Detect this difference and
decode it based on the used encoding.

Fixes: #19912
2019-11-07 09:24:12 -05:00
Brad King
83dbef1135 Merge branch 'InstallRequiredSystemLibraries-redist' into release-3.15
Merge-request: !3909
2019-10-11 12:08:27 -04:00
Brad King
ecbf6546d7 IRSL: Install vcruntime140_1.dll if available
VS 2019 now distributes this additional runtime DLL with its `14.2x`
toolsets.

Fixes: #19829
2019-10-11 12:05:51 -04:00
Brad King
2eecd1c3bc IRSL: Prefer MSVC runtime libraries from newest toolset first 2019-10-11 11:57:39 -04:00
Brad King
5117389931 VS: Fix support for v142 toolset minor versions
When using `-T v142,version=14.22` the `.props` file location is
different starting with version `14.20` than it was in `14.16` and
below.  Adapt the path based on the version.

Fixes: #19779
2019-10-01 11:39:38 -04:00
Brad King
7a8bd12926 Merge branch 'FindBoost-1.71' into release-3.15
Merge-request: !3780
2019-09-04 09:10:57 -04:00
Brad King
907d3ed824 FindBoost: Tolerate future Boost INTERFACE libraries
Since commit 0dd6772a89 (FindBoost: Add legacy variables and targets for
compatibility, 2019-06-14, v3.15.0-rc2~3^2~1) we query imported targets
provided by `BoostConfig.cmake` for their `IMPORTED_LOCATION_<cfg>`.
Querying this property is not allowed on INTERFACE libraries, so add a
condition to avoid doing so in case Boost adds one in the future.

Suggested-by: Alexander Grund <alexander.grund@tu-dresden.de>
Issue: #19656, #19402
2019-09-04 09:09:31 -04:00
Brad King
2d357b7a68 FindBoost: Clarify role of legacy variables in warning message
Revise the wording of the warning added by commit 0dd6772a89 (FindBoost:
Add legacy variables and targets for compatibility, 2019-06-14,
v3.15.0-rc2~3^2~1) to refer to the old variables as "legacy" rather
than "standard".

Suggested-by: Alexander Grund <alexander.grund@tu-dresden.de>
Issue: #19402
2019-09-04 09:09:31 -04:00
Brad King
3b8fa496e7 Merge branch 'FindBoost-1.71' into release-3.15
Merge-request: !3763
2019-08-30 14:54:30 -04:00
Brad King
7828577065 FindBoost: Add support for Boost 1.71
Run `Utilities/Scripts/BoostScanDeps.cmake` with the Boost 1.71.0
sources to compute dependencies.  They are the same as Boost 1.70.

Fixes: #19658
2019-08-30 14:51:20 -04:00
Brad King
cf29fa18c8 FindBoost: Unwrap compatibility INTERFACE targets for legacy variables
Since commit 0dd6772a89 (FindBoost: Add legacy variables and targets for
compatibility, 2019-06-14, v3.15.0-rc2~3^2~1) we extract information
from imported targets provided by upstream `BoostConfig.cmake` files.
However, upstream Boost 1.71 provides some imported targets only for
compatibility.  They are just INTERFACE libraries that wrap around the
real target named by `INTERFACE_LINK_LIBRARIES`.  Unwrap this layer so
we can extract the real imported location.

Fixes: #19656
2019-08-30 14:51:03 -04:00
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
d911f8fc12 Merge branch 'CrayPrgEnv-update-link-type-detection' into release-3.15
Merge-request: !3716
2019-08-22 12:27:08 -04:00
Chuck Atkins
971c778213 CrayPrgEnv: Change default linking mode based on PE version
Beginning with the 19.06 release of the Cray Programming Environment, the
default linking mode on XC Cray systems is dynamic instead of static.
This updates the CrayPrgEnv compiler wrappers to detect the PE version
being used and behave accordingly.
2019-08-22 12:26:06 -04:00
Brad King
9182b3ce53 Merge branch 'FindMPI-restore-flag-vars' into release-3.15
Merge-request: !3710
2019-08-21 10:10:52 -04:00
Robert Maynard
31b8b28fed FindMPI: Restore MPI_<LANG>_COMPILE_FLAGS and MPI_<LANG>_COMPILE_OPTIONS
In commit e374b9f1eb (FindMPI: Restore MPI_<LANG>_COMPILE_FLAGS as a
command-line string, 2018-09-10, v3.12.3~6^2) we tried to restore the
compile flags but accidentally inverted the arguments to `list(JOIN)`
causing both `MPI_<LANG>_COMPILE_FLAGS` and `MPI_<LANG>_COMPILE_OPTIONS`
to be empty.

Issue: #18349
2019-08-21 10:08:12 -04:00
Brad King
ea0294c281 Flang: Implement MSVC runtime library abstraction
In commit fb3370b6a1 (MSVC: Add abstraction for runtime library
selection, 2019-04-10, v3.15.0-rc1~229^2) we overlooked updating flags
for Flang on Windows.  Add them now and update the MSVCRuntimeLibrary
Fortran test to work with Flang.  Base the flags on those we already
use for the GNU-like Clang targeting the MSVC ABI.

Fixes: #19583
2019-08-09 10:18:54 -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
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
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
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
420073e536 Merge branch 'backport-clang-gnulike-support' into release-3.15
Merge-request: !3592
2019-07-24 08:12:51 -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
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
1a2d260634 Merge branch 'backport-swift-improvements' into release-3.15
Merge-request: !3568
2019-07-18 07:47:05 -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
Saleem Abdulrasool
be0d404208 Support per-language library link flags
This changes the behaviour of the generators to use a per-language
library search path flag.  This is needed for multi-language projects
with different compilers (e.g. cl + gfortran).  Since the adjusted
variable has been part of the user settings, we control this based on a
policy.

Fixes: #19307
2019-07-17 20:44:58 -07:00
Brad King
7242d81269 Merge branch 'FindBISON-CMP0088-SourcePath' into release-3.15
Merge-request: !3549
2019-07-12 16:21:26 -04:00
Brad King
3af48083a2 Merge branch 'FindBISON-CMP0088-SourcePath' into release-3.14
Merge-request: !3549
2019-07-12 16:21:12 -04:00