CMake merge requestshttps://gitlab.kitware.com/cmake/cmake/-/merge_requests2019-03-11T13:02:39-04:00https://gitlab.kitware.com/cmake/cmake/-/merge_requests/3044VS: Update for VS 2019 preview 42019-03-11T13:02:39-04:00Brad KingVS: Update for VS 2019 preview 4A temporary workaround added by !2856 for VS 2019 preview 2 and 3 is no longer needed as of VS 2019 preview 4.
Also update the release note to mention that support is based on preview 4.
Fixes: #18898A temporary workaround added by !2856 for VS 2019 preview 2 and 3 is no longer needed as of VS 2019 preview 4.
Also update the release note to mention that support is based on preview 4.
Fixes: #188983.14.0Brad KingBrad Kinghttps://gitlab.kitware.com/cmake/cmake/-/merge_requests/3024VS: Fix detection of clang-cl with -T llvm2019-02-27T08:19:22-05:00Brad KingVS: Fix detection of clang-cl with -T llvmWhen using a VS generator with `-T llvm`, MSBuild relies on the "LLVM
Compiler Toolchain" VS Extension. This does not put `clang-cl` in the
`PATH` inside the build, and LLVM no longer provides a `cl` replacement
either. Therefore we ne...When using a VS generator with `-T llvm`, MSBuild relies on the "LLVM
Compiler Toolchain" VS Extension. This does not put `clang-cl` in the
`PATH` inside the build, and LLVM no longer provides a `cl` replacement
either. Therefore we need another way to extract the path to the
`CMAKE_{C,CXX}_COMPILER`. Fortunately the LLVM VS integration provides
a `$(ClangClExecutable)` macro we can reference to get the path.
Fixes: #189833.14.0Brad KingBrad Kinghttps://gitlab.kitware.com/cmake/cmake/-/merge_requests/3016Add ASM Compiler detection for QCC2019-02-26T10:45:28-05:00MvdHurkAdd ASM Compiler detection for QCCThis will allow you to do `set(CMAKE_ASM_COMPILER_TARGET ${COMPILER_TARGET})`. Much appreciated if this could still be part of 3.14.This will allow you to do `set(CMAKE_ASM_COMPILER_TARGET ${COMPILER_TARGET})`. Much appreciated if this could still be part of 3.14.3.14.0Brad KingBrad Kinghttps://gitlab.kitware.com/cmake/cmake/-/merge_requests/2989VS: Tell VS 2019 to use Windows SDK 8.1 explicitly when needed2020-10-12T15:17:17-04:00Brad KingVS: Tell VS 2019 to use Windows SDK 8.1 explicitly when neededVS 2019 does not default to the 8.1 SDK as VS 2017 and VS 2015 did. When `CMAKE_SYSTEM_VERSION` is 8.1 or lower, select the 8.1 SDK explicitly.
Fixes: #18927VS 2019 does not default to the 8.1 SDK as VS 2017 and VS 2015 did. When `CMAKE_SYSTEM_VERSION` is 8.1 or lower, select the 8.1 SDK explicitly.
Fixes: #189273.14.0Brad KingBrad Kinghttps://gitlab.kitware.com/cmake/cmake/-/merge_requests/2984Use -? instead of /? to test compiler for MSVC-like command-line support2019-02-20T08:57:13-05:00Brad KingUse -? instead of /? to test compiler for MSVC-like command-line supportMS-style command-line tools accept either `/` or `-` for command-line
options. Prefer `-` over `/` so that non-MS tools do not treat it as a
path.
Fixes: #18941MS-style command-line tools accept either `/` or `-` for command-line
options. Prefer `-` over `/` so that non-MS tools do not treat it as a
path.
Fixes: #189413.14.0Brad KingBrad Kinghttps://gitlab.kitware.com/cmake/cmake/-/merge_requests/2921XLClang: Create compiler id for Clang-based XL2019-06-06T10:16:39-04:00Chuck AtkinsXLClang: Create compiler id for Clang-based XLThis created a new XLClang compiler ID to distinguish between the older AIX and Linux BigEndian XL compilers and the newer clang-based AIX and Linux LittleEndian XL compilers.
Fixes: #18460
Fixes: #18835
This created a new XLClang compiler ID to distinguish between the older AIX and Linux BigEndian XL compilers and the newer clang-based AIX and Linux LittleEndian XL compilers.
Fixes: #18460
Fixes: #18835
3.15.0Chuck AtkinsChuck Atkinshttps://gitlab.kitware.com/cmake/cmake/-/merge_requests/2912Xcode: Update default Swift language version for Xcode 10.22019-02-05T07:30:08-05:00Brad KingXcode: Update default Swift language version for Xcode 10.2Xcode 10.2 no longer supports Swift language versions before 4.0.
Fixes: #18871Xcode 10.2 no longer supports Swift language versions before 4.0.
Fixes: #188713.14.0Brad KingBrad Kinghttps://gitlab.kitware.com/cmake/cmake/-/merge_requests/2867FindDoxygen: Escape backslashes in default values2019-01-28T08:30:10-05:00Craig ScottFindDoxygen: Escape backslashes in default valuesDoxygen 1.8.15 added a new LATEX_MAKEINDEX_CMD config
item and it has a default value that contains a backslash on
some installations.
Fixes: #18738Doxygen 1.8.15 added a new LATEX_MAKEINDEX_CMD config
item and it has a default value that contains a backslash on
some installations.
Fixes: #187383.13.4Craig ScottCraig Scotthttps://gitlab.kitware.com/cmake/cmake/-/merge_requests/2862Intel: Record support for relaxed constexpr by version 18.0.52019-01-28T08:04:02-05:00Brad KingIntel: Record support for relaxed constexpr by version 18.0.5Update the special case added by !2133 to record that 18.0.5 fixed the regression.Update the special case added by !2133 to record that 18.0.5 fixed the regression.3.13.4Brad KingBrad Kinghttps://gitlab.kitware.com/cmake/cmake/-/merge_requests/2789VS: Add Visual Studio 16 2019 generator2019-03-14T13:23:20-04:00Brad KingVS: Add Visual Studio 16 2019 generatorAdd this generator *without* support for specifying the target architecture in the generator name. cmake-gui will be taught to provide a field for this, and command-line builds can use -A.
Also, teach this generator to select a default...Add this generator *without* support for specifying the target architecture in the generator name. cmake-gui will be taught to provide a field for this, and command-line builds can use -A.
Also, teach this generator to select a default target architecture based on the host architecture.
Fixes: #18689
Supersedes: !27113.14.0Brad KingBrad Kinghttps://gitlab.kitware.com/cmake/cmake/-/merge_requests/2775VS: Exclude VS 2019 instances when using VS 2017 generator2019-05-06T10:53:37-04:00Brad KingVS: Exclude VS 2019 instances when using VS 2017 generatorFilter instances reported by the VS Installer to consider only VS 2017
instances for the "Visual Studio 15 2017" generator.
Fixes: #18721Filter instances reported by the VS Installer to consider only VS 2017
instances for the "Visual Studio 15 2017" generator.
Fixes: #187213.13.3Brad KingBrad Kinghttps://gitlab.kitware.com/cmake/cmake/-/merge_requests/2724CUDA: Add CUDA 10 (Turing) detection2018-12-10T09:23:22-05:00Brad KingCUDA: Add CUDA 10 (Turing) detectionBackport !2702 to `release` for 3.13 since this is an environmental regression.Backport !2702 to `release` for 3.13 since this is an environmental regression.3.13.2Brad KingBrad Kinghttps://gitlab.kitware.com/cmake/cmake/-/merge_requests/2637IRSL: Detect versioned Windows Universal CRT directories2018-11-20T09:30:44-05:00Brad KingIRSL: Detect versioned Windows Universal CRT directoriesWindows SDK version 10.0.17763.0 now places the uCRT libraries in a
versioned directory.
Fixes: #18603Windows SDK version 10.0.17763.0 now places the uCRT libraries in a
versioned directory.
Fixes: #186033.13.0Brad KingBrad Kinghttps://gitlab.kitware.com/cmake/cmake/-/merge_requests/2635configure_file: canonicalize input and output path in dependencies2018-11-19T10:47:09-05:00Brad Kingconfigure_file: canonicalize input and output path in dependenciesRepresent the input file path internally in canonical form. Otherwise
multiple `configure_file` calls that share the same input file but specify
it relative to different directories (e.g. via `../`) result in multiple
copies of the depe...Represent the input file path internally in canonical form. Otherwise
multiple `configure_file` calls that share the same input file but specify
it relative to different directories (e.g. via `../`) result in multiple
copies of the dependency on the rule to re-run CMake. This causes the
Ninja generator to emit duplicate phony build statements for these
dependencies, which generates an error with `-w dupbuild=err`, which
will be default in Ninja 1.9.
Also canonicalize the output path for consistency.
Add a test case.
Fixes: #185843.13.0Brad KingBrad Kinghttps://gitlab.kitware.com/cmake/cmake/-/merge_requests/2601FindBoost: Additional fixes for 1.692018-11-13T10:38:57-05:00Roger LeighFindBoost: Additional fixes for 1.69Fixes some bits from commit 364fb69adc8 in !2522
- Add version numbers
- Add correct Python package names
- Update BoostScanDeps to emit correct Python package names
- Remove `SYNC` component. No matching headers in FindBoost, and...Fixes some bits from commit 364fb69adc8 in !2522
- Add version numbers
- Add correct Python package names
- Update BoostScanDeps to emit correct Python package names
- Remove `SYNC` component. No matching headers in FindBoost, and no headers in Boost that I can see (BoostScanDeps doesn't pick it up). Maybe this is a 1.70 component which isn't needed yet?
@mloskot Are these changes OK with you?
Topic-rename: FindBoost-1.69
3.13.0Brad KingBrad Kinghttps://gitlab.kitware.com/cmake/cmake/-/merge_requests/2579FindBoost: Improve compiler prefix detection for GCC 5+ and clang 4+2019-04-01T11:22:18-04:00Mateusz ĹoskotFindBoost: Improve compiler prefix detection for GCC 5+ and clang 4+FindBoost: Improve compiler prefix detection for GCC 5+ and clang 4+
Add recognition of compiler version and prefix for clang.
Accommodate [changes to version numbering scheme for GCC 5+](https://gcc.gnu.org/develop.html) and clang...FindBoost: Improve compiler prefix detection for GCC 5+ and clang 4+
Add recognition of compiler version and prefix for clang.
Accommodate [changes to version numbering scheme for GCC 5+](https://gcc.gnu.org/develop.html) and clang 4+
- Minor number becomes patch, so excluded it from compiler prefix.
- Improves searching for Boost 1.69+ libraries built with GCC 5+ and
clang 4+, where library names are generated with compiler tag based on
major version only eg. -gcc5 for GC 5.5.0 or -clang6 for clang 6.0.0
- Follows up related changes in upcoming Boost 1.69
https://github.com/boostorg/build/pull/349
Dump detected compiler version in Boost_DEBUG message.
Replace use of CMAKE_COMPILER_IS_GNUCXX with CMAKE_CXX_COMPILER_ID.
-----
## Problem Example
Let's consider building Boost 1.69+ (current master or later) with GCC 5.5.0 and clang 6.0.0 on Linux:
```shell
b2 toolset=gcc variant=debug,release address-model=64 --layout=versioned --with-system stage
b2 toolset=clang variant=debug,release address-model=64 --layout=versioned --with-system stage
```
This will generate the following libraries:
```shell
$ ls -1 libboost_system*
libboost_system-clang6-mt-d-x64-1_69.a
libboost_system-clang6-mt-d-x64-1_69.so
libboost_system-clang6-mt-d-x64-1_69.so.1.69.0
libboost_system-clang6-mt-x64-1_69.a
libboost_system-clang6-mt-x64-1_69.so
libboost_system-clang6-mt-x64-1_69.so.1.69.0
libboost_system-gcc5-mt-d-x64-1_69.a
libboost_system-gcc5-mt-d-x64-1_69.so
libboost_system-gcc5-mt-d-x64-1_69.so.1.69.0
libboost_system-gcc5-mt-x64-1_69.a
libboost_system-gcc5-mt-x64-1_69.so
libboost_system-gcc5-mt-x64-1_69.so.1.69.0
```
Now, we run CMake for a project that `find_package` for Boost:
```shell
cmake -DBOOST_ROOT=/mnt/d/boost.wsl -DBoost_ARCHITECTURE=-x64 ..
```
This will fail because `Boost_COMPILER` is guessed as `-gcc55`.
Obvious but inconvenient workaround is to fix the compiler tag manually:
```shell
cmake -DBOOST_ROOT=/mnt/d/boost.wsl -DBoost_ARCHITECTURE=-x64 -DBoost_COMPILER=-gcc5 ..
```
The changes propose in this MR improve the lookup and free users from manually specifying the compiler tag.
Topic-rename: FindBoost-compiler-guess-update
3.13.0Roger LeighRoger Leighhttps://gitlab.kitware.com/cmake/cmake/-/merge_requests/2568FindBoost: Add explicit Boost_ARCHITECTURE option2020-04-15T11:49:37-04:00Brad KingFindBoost: Add explicit Boost_ARCHITECTURE optionBoost 1.66 and above built with `--layout=versioned` add an architecture
tag to the library file names. We already try to compute this tag
automatically when `CMAKE_CXX_COMPILER_ARCHITECTURE_ID` is available,
but that is currently not c...Boost 1.66 and above built with `--layout=versioned` add an architecture
tag to the library file names. We already try to compute this tag
automatically when `CMAKE_CXX_COMPILER_ARCHITECTURE_ID` is available,
but that is currently not computed everywhere. Add an explicit
`Boost_ARCHITECTURE` option that a user can set to specify the
architecture tag.
Issue: #177013.13.0Roger LeighRoger Leighhttps://gitlab.kitware.com/cmake/cmake/-/merge_requests/2551FindProtobuf: Add missing link dependencies on threads2020-09-22T08:28:17-04:00Brad KingFindProtobuf: Add missing link dependencies on threadsProtobuf headers have dependencies on threads. On UNIX platforms this
requires linking to a threads library. We've long done this in the
`Protobuf_LIBRARIES` result variable. However, the imported targets
added by !861 and !876 were m...Protobuf headers have dependencies on threads. On UNIX platforms this
requires linking to a threads library. We've long done this in the
`Protobuf_LIBRARIES` result variable. However, the imported targets
added by !861 and !876 were missing a dependency on threads.
Add the dependency to the imported targets, and to the variables
`Protobuf_LITE_LIBRARIES` and `Protobuf_PROTOC_LIBRARIES`. While this
did not seem to matter in practice for a long time, protobuf 3.6 throws
exceptions in some cases when threads are missing.
Fixes: #185333.13.0Brad KingBrad Kinghttps://gitlab.kitware.com/cmake/cmake/-/merge_requests/2547FindPostgreSQL: Search for version 112018-10-31T09:34:48-04:00Sylvain JoubertFindPostgreSQL: Search for version 11Topic-rename: FindPostgreSQL-11
Topic-rename: FindPostgreSQL-11
3.13.0Brad KingBrad Kinghttps://gitlab.kitware.com/cmake/cmake/-/merge_requests/2545Flang: Fix command-line used to preprocess sources2018-10-30T11:06:50-04:00Brad KingFlang: Fix command-line used to preprocess sourcesRunning flang with `-E` now ignores any `-o` option and always prints
preprocessed output to stdout. Use shell redirection to place it in a
file instead.
Fixes: #18497Running flang with `-E` now ignores any `-o` option and always prints
preprocessed output to stdout. Use shell redirection to place it in a
file instead.
Fixes: #184973.13.0Brad KingBrad King