Commit Graph

12497 Commits

Author SHA1 Message Date
Craig Scott
b4db306aff ExternalProject: Remove unused property docs
BRIEF_DOCS and FULL_DOCS became optional as of edb5059216
(define_property(): Make BRIEF_DOCS and FULL_DOCS optional,
2022-01-18). Remove these options from the define_property()
calls, since they served no useful purpose. The canonical
documentation of those properties is in the RST docs at the top of
the file.
2022-05-23 07:36:15 +10:00
Craig Scott
5c021c8355 ExternalProject: Replace SEND_ERROR with FATAL_ERROR
The one remaining SEND_ERROR is still needed because further messages
must be written before a final FATAL_ERROR on that code path.
2022-05-23 07:36:04 +10:00
Brad King
92c7c2c39a Merge topic 'findvulkan-improvements'
7974fcd1a7 FindVulkan: remove noop on CMAKE_MODULE_PATH in tests
acdb5fe0e8 FindVulkan: Add component for `glslc` and `glslangValidator`
998ee49779 FindVulkan: ensure policy CMP0057 is NEW to use `IN_LIST` with `if()`
9f8720e74c FindVulkan: Add component for `glslang`
8d133f49e3 FindVulkan: Add component for `SPIRV-Tools`
6e4d20921d FindVulkan: Add component for `shaderc_combined`
2f46b8d723 FindVulkan: Move `mark_as_advanced` right after `find_*` calls.
08a420af4a FindVulkan: Factorize code for library/executable search

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7225
2022-05-20 09:08:44 -04:00
Brad King
48a303e6f4 Merge topic 'cpack-nuget-components-on-windows'
066ff258db CPack/NuGet: Restore component packaging on Windows

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7280
2022-05-19 09:39:59 -04:00
MACHIZAUD Andréa
acdb5fe0e8 FindVulkan: Add component for glslc and glslangValidator
For backward compatibility with previous CMake versions they are implicitly added to the list of components
2022-05-18 23:16:11 +02:00
MACHIZAUD Andréa
998ee49779 FindVulkan: ensure policy CMP0057 is NEW to use IN_LIST with if() 2022-05-18 23:16:11 +02:00
MACHIZAUD Andréa
9f8720e74c FindVulkan: Add component for glslang 2022-05-18 23:16:09 +02:00
MACHIZAUD Andréa
8d133f49e3 FindVulkan: Add component for SPIRV-Tools 2022-05-18 23:15:50 +02:00
MACHIZAUD Andréa
6e4d20921d FindVulkan: Add component for shaderc_combined 2022-05-18 23:15:48 +02:00
Alex Turbov
066ff258db CPack/NuGet: Restore component packaging on Windows
The change from `\` to `/` in commit dade75509f (CPack/NuGet: Fix nuspec
file generation for UNIX-style OS, 2020-12-21, v3.20.0-rc1~243^2) does
not work on Windows.  Use `cmake_path` to form a path to an image
directory with preinstalled files.

Fixes: #22489
2022-05-18 11:12:02 -04:00
Brad King
59b3e97720 Merge topic 'clang-imsvc'
faed1562fb Merge branch 'backport-3.23-clang-imsvc' into clang-imsvc
23a52561c7 Clang: Use -imsvc flag without space to support Clang tools

Acked-by: Kitware Robot <kwrobot@kitware.com>
Reviewed-by: Raul Tambre <raul@tambre.ee>
Acked-by: hihig2001 <hihig@bluehole.net>
Merge-request: !7274
2022-05-18 08:02:10 -04:00
Brad King
6daf38dec6 Merge topic 'FindGLUT-remove-undocumented-vars'
6c053e68df FindGLUT: Remove undocumented variables GLUT_INCLUDE_PATH and GLUT_LIBRARY

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7273
2022-05-18 08:00:48 -04:00
Brad King
334f7ac87f Merge topic 'fetchcontent-subbuild-config-type-fix'
82f3ceb26b FetchContent: Use Debug rather than Release for sub-build

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7272
2022-05-18 07:58:50 -04:00
Brad King
faed1562fb Merge branch 'backport-3.23-clang-imsvc' into clang-imsvc 2022-05-17 11:20:15 -04:00
Brad King
23a52561c7 Clang: Use -imsvc flag without space to support Clang tools
Since commit bb61c2d024 (Clang: use -imsvc for system include dirs when
running on Windows, 2020-09-16, v3.19.0-rc1~162^2) we use the `-imsvc`
flag followed by the include directory as a separate argument.  Some
versions of `clang-tidy` do not support the flag unless the include
directory is attached to it, so use that form instead.

A similar fix was made by commit 3a8b6653dc (MSVC: Use -external:I flag
without space to support Clang tools, 2022-01-11, v3.22.2~8^2).

Fixes: #23517
2022-05-17 11:09:15 -04:00
Letu Ren
6c053e68df FindGLUT: Remove undocumented variables GLUT_INCLUDE_PATH and GLUT_LIBRARY
Fixes: #23370
2022-05-17 09:08:12 -04:00
Brad King
e561e29e04 Merge topic 'findzlib-static'
3f0b9663a4 FindZLIB: fix ZLIB_USE_STATIC_LIBS on Windows

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7262
2022-05-17 08:52:09 -04:00
Brad King
2ef9865f09 Merge topic 'FortranCInterface-gcc12'
cb616d43d6 FortranCInterface: Fix failure with gfortran 12 and Clang

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7266
2022-05-17 08:47:31 -04:00
Brad King
e05a476700 Merge topic 'FortranCInterface-gcc12' into release-3.23
cb616d43d6 FortranCInterface: Fix failure with gfortran 12 and Clang

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7266
2022-05-17 08:47:30 -04:00
Craig Scott
82f3ceb26b FetchContent: Use Debug rather than Release for sub-build
The config used can be part of the path to the sub-build. On some
platforms, there are restrictions on the length of paths or file names.
Use Debug rather than Release because the former is shorter.
When CMAKE_CONFIGURATION_TYPES is left at its default, this also
makes the path the same as the previous default before 10865c8e5f
(FetchContent: Hard-code a config for the sub-build, 2022-05-01) .
2022-05-17 14:42:31 +10:00
Brad King
cb616d43d6 FortranCInterface: Fix failure with gfortran 12 and Clang
The C flags added by commit 6a0ce19ce1 (FortranCInterface: Fix
compatibility with GCC gfortran 12 LTO, 2022-01-19, v3.22.2~5^2)
should only be added for the GNU C compiler.

Fixes: #23500
Issue: #23123
2022-05-16 11:18:00 -04:00
Brad King
c4ed5341c4 Merge topic 'CMAKE_PROJECT_TOP_LEVEL_INCLUDES'
a6c34b0353 project(): Add new CMAKE_PROJECT_TOP_LEVEL_INCLUDES file injection point
8aa29a1793 CMakeDetermineSystem: Remove unreachable code

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !7250
2022-05-16 09:26:59 -04:00
Craig Scott
7a390edefb Merge topic 'fetchcontent-subbuild-config-type'
10865c8e5f FetchContent: Hard-code a config for the sub-build

Acked-by: Kitware Robot <kwrobot@kitware.com>
Tested-by: buildbot <buildbot@kitware.com>
Merge-request: !7228
2022-05-16 07:33:35 -04:00
MACHIZAUD Andréa
2f46b8d723 FindVulkan: Move mark_as_advanced right after find_* calls. 2022-05-13 23:12:29 +02:00
MACHIZAUD Andréa
08a420af4a FindVulkan: Factorize code for library/executable search 2022-05-13 23:09:05 +02:00
Peter Würth
3f0b9663a4 FindZLIB: fix ZLIB_USE_STATIC_LIBS on Windows
- on Windows, the ZLIB_USE_STATIC_LIBS options requires a reordering of
  the search names in order to prefer the static library, since in most
  cases both static and shared libraries are built
- add zlibwapi[d] library name for the contrib/vstudio builds
- add lib prefix and .dll.a suffix for the win32/Makefile.gcc build

Fixes #23140
2022-05-13 18:26:27 +02:00
Brad King
ef7c0cb885 Merge topic 'FindGLUT-system-include-dirs'
8041ca5df0 FindGLUT: Fix GLUT_INCLUDE_DIRS with pkg-config and /usr/include

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7252
2022-05-13 08:52:04 -04:00
Brad King
300c91fecd Merge topic 'externalproject-uses-terminal-flags'
b1c2cb0436 ExternalProject: Make SVN interactive with USES_TERMINAL_{DOWNLOAD,UPDATE}

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7248
2022-05-13 08:51:09 -04:00
Brad King
9529863f2a Merge topic 'FindPkgConfig-LIBRARY_PATH'
11c8da94d4 FindPkgConfig: Fix preservation of ENV{PKG_CONFIG_ALLOW_SYSTEM_LIBS}

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !7258
2022-05-13 08:42:49 -04:00
Brad King
165208c784 Merge topic 'FindPkgConfig-LIBRARY_PATH' into release-3.23
11c8da94d4 FindPkgConfig: Fix preservation of ENV{PKG_CONFIG_ALLOW_SYSTEM_LIBS}

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !7258
2022-05-13 08:42:48 -04:00
Brad King
968b5200a5 Merge topic 'FindPython-3.12'
ca2877c039 FindPython: add support for Python 3.12

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7255
2022-05-13 08:41:56 -04:00
Craig Scott
10865c8e5f FetchContent: Hard-code a config for the sub-build
If the main project overrides CMAKE_CONFIGURATION_TYPES such
that there is no Debug configuration, some multi-config generators
can fail because they might assume Debug by default (Visual Studio
might do this). Always specify the configuration for multi-config
generators so that we don't rely on any such defaults.

Fixes: #23177
2022-05-13 15:56:17 +10:00
Brad King
11c8da94d4 FindPkgConfig: Fix preservation of ENV{PKG_CONFIG_ALLOW_SYSTEM_LIBS}
Fix the ENV save/restore added by commit 36979f5b43 (FindPkgConfig:
Tolerate PKG_CONFIG_SYSTEM_LIBRARY_PATH in environment, 2021-07-13,
v3.22.0-rc1~407^2) to unset the variable if it was originally not set.

While at it, clarify the value to which we temporarily set it. The
`pkg-config` and `pkgconf` tools only check that the variable is set,
and do not care about the value.  Set it to a more true-looking value.

Issue: #22148
2022-05-12 13:18:24 -04:00
Letu Ren
8041ca5df0 FindGLUT: Fix GLUT_INCLUDE_DIRS with pkg-config and /usr/include
Fixes: #23474
2022-05-12 12:58:09 -04:00
Michael Hirsch
ca2877c039 FindPython: add support for Python 3.12 2022-05-12 10:55:11 -04:00
Michael Durso Jr
b1c2cb0436 ExternalProject: Make SVN interactive with USES_TERMINAL_{DOWNLOAD,UPDATE}
ExternalProject_Add() supports USES_TERMINAL_* flags to enable user
input for different steps.  The Subversion download options ignored
these flags when checking out or updated a Subversion repo.

Fixes: #23348
2022-05-12 10:40:35 -04:00
Brad King
c67f0cd592 Merge topic 'doc-package-compatibility-mode'
a82163839a CMakePackageConfigHelpers: Fix note about version files supporting ranges

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7254
2022-05-12 09:28:16 -04:00
friendlyanon
a82163839a CMakePackageConfigHelpers: Fix note about version files supporting ranges
In commit 55c3b6a77e (CMakePackageConfigHelpers: Relax restrictions on
version range, 2019-05-30, v3.20.0-rc1~295^2~1) the documentation for
write_basic_package_version_file documented the support of version
ranges by the generated version files, however the note wrongly
specifies a COMPATIBILITY_MODE argument, instead of COMPATIBILITY.
2022-05-11 14:00:38 -04:00
Dmitry Kushpet
587d1942b5 FindOpenCL: Add support for version 3.0 2022-05-11 21:00:24 +03:00
Brad King
66aa34e529 Merge topic 'FindOpenSSL-qnx7.0'
e6656381aa FindOpenSSL: Support version 1.1.1 under QNX 7.0

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !7232
2022-05-10 10:37:58 -04:00
Brad King
79b64690d9 Merge topic 'werror-property'
76a08cd253 COMPILE_WARNING_AS_ERROR: Add options to treat warnings as errors

Acked-by: Kitware Robot <kwrobot@kitware.com>
Tested-by: buildbot <buildbot@kitware.com>
Acked-by: Michael Hirsch <michael@scivision.dev>
Merge-request: !7187
2022-05-10 10:30:42 -04:00
Craig Scott
8aa29a1793 CMakeDetermineSystem: Remove unreachable code 2022-05-08 18:54:35 +10:00
Georg Lutz
e6656381aa FindOpenSSL: Support version 1.1.1 under QNX 7.0
QNX 7.0 allows parallel installation of OpenSSL 1.0.2 and OpenSSL 1.1.1. The
1.1.1 version has "1_1" appended to the include dir and library names.
2022-05-06 22:07:07 +02:00
Martin Duffy
76a08cd253 COMPILE_WARNING_AS_ERROR: Add options to treat warnings as errors
Add `COMPILE_WARNING_AS_ERROR` target property and supporting
`CMAKE_COMPILE_WARNING_AS_ERROR` variable.

`COMPILE_WARNING_AS_ERROR` is initialized by
`CMAKE_COMPILE_WARNING_AS_ERROR`. It is a boolean variable. If it is
true, it expands to a different flag depending on the compiler such that
any warnings at compile will be treated as errors.

Supports compiler ids that I could find a relevant flag for.
2022-05-06 12:14:37 -04:00
Cameron Cawley
6a2b016bbd OpenWatcom: Support CMAKE_WATCOM_RUNTIME_LIBRARY with Linux and OS/2 builds 2022-05-06 10:40:59 -04:00
Cameron Cawley
33da5824ac OpenWatcom: Allow specifying the runtime library
Add a `CMAKE_WATCOM_RUNTIME_LIBRARY` variable to control the
runtime library selection.  Add policy CMP0136 to switch to
in place of the old hard-coded default flags.

Fixes: #23178
2022-05-06 10:40:58 -04:00
Brad King
78b7046a32 Merge topic 'Java-version-handling'
c80763c701 Merge branch 'backport-3.23-Java-version-handling' into Java-version-handling
93e18a4eb6 FindJava, FindJNI: ensure correct handling of versions on Windows

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7241
2022-05-06 08:57:25 -04:00
Brad King
cc207014cf Merge topic 'Java-version-handling' into release-3.23
93e18a4eb6 FindJava, FindJNI: ensure correct handling of versions on Windows

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7241
2022-05-06 08:57:24 -04:00
Craig Scott
c5dff5ace2 Merge topic 'FetchContent_find_package_integration'
29e31e2825 Packages: Integrate FetchContent and find_package()

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Acked-by: huangqinjin <huangqinjin@gmail.com>
Merge-request: !5688
2022-05-06 08:33:38 -04:00
Brad King
cd20592c6d Merge topic 'ExternalProject-no-extract-timestamp'
a283e58b51 ExternalProject: Add DOWNLOAD_EXTRACT_TIMESTAMP option and policy

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !7137
2022-05-05 09:20:41 -04:00