Commit Graph

28296 Commits

Author SHA1 Message Date
Joerg Bornemann
aebfbcaa46 AutoGen: Use depfiles for the XXX_autogen ninja targets
The XXX_autogen targets are implemented as utility commands, which
means they always run, even if there weren't any changes.

For the Ninja generator and Qt >= 5.15 we're taking a different
approach: This commit adds custom commands that create
XXX_autogen/timestamp files. Those custom commands have a depfile
assigned that is generated from the depfiles that were created by moc.

The XXX_autogen targets merely wrap the XXX_autogen/timestamp custom
commands.

Fixes: #18749
2020-01-28 11:16:11 -05:00
Joerg Bornemann
f765fdea03 AutoGen: Use moc's feature to output dependencies
In Qt version 5.15.0 moc learned to output the dependencies
of the generated file.

This commit enhances JobCompileMocT to read the dependency file
written by moc. The dependencies are stored in the same cache that's
used for the dependencies determined by dependency filters.

The dependency filter functionality is turned off if moc's dependency
output feature is used.

Fixes: #17750
Fixes: #19058
2020-01-28 11:16:11 -05:00
Joerg Bornemann
f8c505d4b3 Add a parser for GCC-style depfiles
Introduce the function cmReadGccDepfile that parses a GCC-style depfile
and returns its content. The implementation uses a lexer that is
modeled after the re2c implementation in Ninja.

The sample files of the autotest have been created with gcc 8.3.0.

This depfile reader is to be used by the Autogen facility to make use
of the depfiles that are generated by Qt's meta object compiler.
2020-01-28 11:16:11 -05:00
Brad King
7706b6a714 Merge topic 'xcode-top-level-only-with-object-library'
64304fe72b Xcode: Fix post build script for 'top level project only' opt

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4284
2020-01-28 11:05:17 -05:00
Brad King
ee5edfbda2 Merge topic 'dot-dir'
830a7d8803 cmArchiveWrite: Remove ./ suffix from zip archives

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4288
2020-01-28 11:04:30 -05:00
Brad King
cb8bd146c9 Merge topic 'modernize-memory-management'
b50b2755da cmComputeLinkInformation: modernize memory management

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4285
2020-01-28 11:03:34 -05:00
Brad King
193352e420 Merge topic 'clang-tidy-driver-mode'
f6f4eb0907 clang-tidy: Add driver mode argument

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4208
2020-01-28 11:01:19 -05:00
Brad King
e3be80f4fc Merge topic 'append-std-string'
1398517f31 AppendProperty: convert value param to std::string

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4282
2020-01-28 11:00:16 -05:00
Brad King
b6da71e299 Merge topic 'osx-version-flags'
6a84f0b791 macOS: Test OSX_COMPATIBILITY_VERSION and OSX_CURRENT_VERSION properties
4a62e3d97c macOS: Add OSX_COMPATIBILITY_VERSION and OSX_CURRENT_VERSION properties

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4274
2020-01-28 10:59:03 -05:00
Brad King
e4e41d33d6 Merge topic 'cmsting-stl-compatibility'
8f839d02e3 cm::String: enhance compatibility with STL

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4281
2020-01-28 10:58:11 -05:00
Brad King
571205fb6b Merge topic 'QNX_CMAKE_SYSROOT'
32a6ab1f3b QNX: Add support for CMAKE_SYSROOT

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4277
2020-01-28 10:56:41 -05:00
Masashi Fujita
7b6af980eb cmMakefile: Fix spelling typo in comment 2020-01-28 10:54:15 -05:00
Brad King
1f9321c683 Merge topic 'cuda_runtime_library_controls'
0d0145138f CUDA: Add abstraction for cuda runtime selection

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4178
2020-01-28 10:52:33 -05:00
Kitware Robot
03e2757c66 CMake Nightly Date Stamp 2020-01-28 00:01:07 -05:00
Yauheni Khnykin
64304fe72b Xcode: Fix post build script for 'top level project only' opt
When CMAKE_XCODE_GENERATE_TOP_LEVEL_PROJECT_ONLY is set on
Xcode generator created post build scripts which tried to call
XCODE_DEPEND_HELPER.make script in subproject.
But XCODE_DEPEND_HELPER.make don't exist in
subprojects when mentioned option is set on.

Fixes: #20262
2020-01-27 16:14:19 -05:00
Robert Maynard
0d0145138f CUDA: Add abstraction for cuda runtime selection
Fixes #17559
Replace our hard-coded default of cudart=static with a first-class abstraction to select the runtime library from an enumeration of logical names.
2020-01-27 16:02:26 -05:00
Brad King
ccaa0bccc4 Ninja: Do not clean metadata when re-generating inside a running build
When `ninja` re-runs CMake to re-generate the build system, do not try
to use the ninja tools to update metadata on Windows.  The outer ninja
process is already holding the files open.

Issue: #20274
2020-01-27 15:39:04 -05:00
Brad King
657820a00b Ninja: Track when running to re-generate during a build
Tell CMake explicitly when it is re-running inside a `ninja` invocation
to re-generate the build system.
2020-01-27 15:39:04 -05:00
Brad King
b12b013028 Ninja: Factor metadata cleanup into dedicated method 2020-01-27 15:39:04 -05:00
Brad King
5d92e60d81 Ninja: Skip cleandead and recompact if build.ninja is missing
In error cases the `build.ninja` file may not exist.  Skip running ninja
tools that require it so that we do not generate additional errors.
2020-01-27 15:09:18 -05:00
Brad King
dd0a4718fd Ninja: Fix CMAKE_NINJA_OUTPUT_PATH_PREFIX with Ninja 1.10
The ninja 1.10 tools we use since commit fb18215904 (Ninja: clean ninja
metadata once generated, 2019-05-13) expect `build.ninja` to be
available and loadable.  In commit 6cc74b6140 (cmGlobalNinjaGenerator:
avoid cleandead and recompact in Ninja-Multi, 2020-01-22) we added a
condition to exclude the tools in a case where `build.ninja` is not
available.  Generalize that condition using a local variable and extend
it for the case that `build.ninja` is not loadable in the current
directory because it is meant to be a sub-ninja for a higher directory.
2020-01-27 15:09:18 -05:00
Stephen Kelly
32a6ab1f3b QNX: Add support for CMAKE_SYSROOT
QCC is a wrapper around GCC, but it is not a fully transparent wrapper.
Some compile options need to be passed to GCC using a `-Wc` option.

QCC does not support --sysroot, so setting CMAKE_SYSROOT in a toolchain
file currently does not work.  This means that it is likely that no one
is setting CMAKE_SYSROOT in existing QNC toolchain files.  Override the
GCC option for sysroot in the QCC.cmake file with -Wc,-isysroot.

This exposes a further issue in that the QNX SDK does not follow the
same architectural folder structure as linux uses.  That is, on linux
systems, architecture-specific libraries might be in

    <sysroot>/usr/lib/<arch>

such as

    /usr/lib/x86_64-linux-gnu/libcurl.so

CMake models this by suffixing the <arch> onto lib directories when
searching for libraries.

The QNX SDK is structured differently such that the <arch> should be
used as a prefix:

    <sysroot>/<arch>/usr/lib

such as

    <sysroot>/x86_64/usr/lib/libcurl.so

Add a variable for platform configuration to set whether to prefix or
suffix the <arch> and set that in the QCC.cmake.

Use the directory structure of the QNX SDK to compute the <arch> from
the implicit library directories.  The assumption is that the arch will
be a single directory directly below the CMAKE_SYSROOT, below which the
usr/ prefix occurs.

It would not be appropriate to instruct users to make the <arch> part of
the sysroot when specified in the toolchain file because:

1.  That would be non-DRY - The QCC wrapper already determines the <arch>
    by the -V argument passed to the compiler, specified in the toolchain
    file as the CMAKE_C_COMPILER_TARGET variable.
2.  The includes in the QNX SDK are not below the <arch> directory.

So, the location of the <arch> in the full path is different on QNX
compared to, say an embedded linux platform, but the intent is the same.

Add documentation to recommend the use of CMAKE_SYSROOT in a QNX
toolchain file.

As the CMAKE_SYSROOT is always the same for QNX, it would be possible to
simply set it in QCC.cmake.  However, that would change behavior for
existing users as when CMAKE_SYSROOT is set, files/paths outside of the
CMAKE_SYSROOT do not get found.

The <arch> prefixing is only enabled in cmSearchPath.cxx if
CMAKE_SYSROOT is set.  This ensures that the user gets consistency in
the current state without CMAKE_SYSROOT, and gets better consistency
when using CMAKE_SYSROOT.
2020-01-27 14:04:56 -05:00
Hanjiang Yu
f6f4eb0907 clang-tidy: Add driver mode argument
`clang-tidy` does not infer driver mode if it is not provided with a
JSON compilation database.  This is exactly the way cmake launches it.
Hence clang-tidy will only use the default driver mode.  Add an explicit
driver mode argument to avoid this.
2020-01-27 13:59:05 -05:00
Cristian Adam
830a7d8803 cmArchiveWrite: Remove ./ suffix from zip archives
Fixes: #20238
2020-01-27 16:53:46 +01:00
Brad King
f624b44524 Merge topic 'fix-ninja-multi-framework-header'
63c9cd2088 Ninja Multi-Config: Fix bug with MacOS frameworks

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4279
2020-01-27 10:06:53 -05:00
Brad King
306328ace8 Merge topic 'depend-on-target-real-name'
08699cec68 add_custom_command: Fix dependency on macOS framework target

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4273
2020-01-27 10:04:08 -05:00
Brad King
0bf9589bf1 Merge topic 'csharp-no-valued-macros'
effd4d0569 CSharp: Do not pass definitions with values

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4267
2020-01-27 10:03:26 -05:00
Brad King
6f7f293562 Merge topic 'cpack-dmg-breaklongline'
4a3a7d5f5d CPack/DragNDrop: Fix word corruption in BreakLongLines

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4275
2020-01-27 09:33:45 -05:00
Brad King
d5f5496783 Merge topic 'cpack-dmg-rtf-for-sla'
9571929701 CPack/DragNDrop: Support RTF licenses

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4270
2020-01-27 09:32:51 -05:00
Brad King
a9a1a7a325 Merge topic 'makefiles-suppress-vcs-implicit-rules'
879e56f336 makefiles: suppress RCS and SCCS implicit rules

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4264
2020-01-27 09:29:58 -05:00
Kitware Robot
ee4299ce46 CMake Nightly Date Stamp 2020-01-27 00:01:05 -05:00
Marc Chevrier
b50b2755da cmComputeLinkInformation: modernize memory management 2020-01-26 14:01:45 +01:00
Kitware Robot
55ea8f6b1b CMake Nightly Date Stamp 2020-01-26 00:01:13 -05:00
Marc Chevrier
8f839d02e3 cm::String: enhance compatibility with STL 2020-01-25 18:16:16 +01:00
Vitaly Stakhovsky
1398517f31 AppendProperty: convert value param to std::string 2020-01-25 10:37:00 -05:00
Kitware Robot
33e7bd66c0 CMake Nightly Date Stamp 2020-01-25 00:01:08 -05:00
Kyle Edwards
63c9cd2088 Ninja Multi-Config: Fix bug with MacOS frameworks 2020-01-24 17:16:25 -05:00
Brad King
072a95350c Merge topic 'ninja-multi-cross-configs'
b7a2baf38c Ninja Multi-Config: Add variable to control configs used in cross-config build

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4269
2020-01-24 15:02:20 -05:00
Sumit Bhardwaj
effd4d0569 CSharp: Do not pass definitions with values
The Microsoft C# tooling does not accept definitions with values.
Filter them out.

Fixes: #19817
2020-01-24 14:43:37 -05:00
Isuru Fernando
4a62e3d97c macOS: Add OSX_COMPATIBILITY_VERSION and OSX_CURRENT_VERSION properties
Fixes: #17652
2020-01-24 14:13:41 -05:00
Koray Kilinc
4a3a7d5f5d CPack/DragNDrop: Fix word corruption in BreakLongLines
When the lines are wrapped the leading characters of the next word were being lost
2020-01-24 09:17:12 -08:00
Brad King
08699cec68 add_custom_command: Fix dependency on macOS framework target
When the `DEPENDS` option names a logical target name, convert to the
"real" path of that target rather than any of the symlink-provided
alternative file names.  This makes the dependencies consistent with the
outputs named by link rules producing the target artifacts.

Fixes: #20264
2020-01-24 11:29:45 -05:00
Brad King
786b56942b Merge topic 'vs-dotnet-standard-core'
ae1e1909a1 VS: Add support for .NET Standard and .NET Core

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4240
2020-01-24 10:55:26 -05:00
Andrew Fuller
9571929701 CPack/DragNDrop: Support RTF licenses 2020-01-24 07:48:52 -08:00
Brad King
816bbf227f Merge topic 'trace_json_timestamp'
c829f0cfca trace: Add time and stack level to JSON output format

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Volo Zyko <volo.zyko@gmail.com>
Merge-request: !4242
2020-01-24 09:19:55 -05:00
Brad King
89a93348d5 Merge topic 'multi-ninja-no-cleandead'
6cc74b6140 cmGlobalNinjaGenerator: avoid cleandead and recompact in Ninja-Multi

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4261
2020-01-24 09:17:07 -05:00
Joerg Bornemann
ae1e1909a1 VS: Add support for .NET Standard and .NET Core
Fixes: #20105
2020-01-24 09:11:05 -05:00
Ben Boeckel
879e56f336 makefiles: suppress RCS and SCCS implicit rules
These are not suffix rules and are not suppressed by the empty
`.SUFFIXES` recipe. Additionally, the old `SUFFIXES =` code didn't
actually accomplish this, so remove it.
2020-01-24 09:06:25 -05:00
Kitware Robot
55921df313 CMake Nightly Date Stamp 2020-01-24 00:01:06 -05:00
Kyle Edwards
b7a2baf38c Ninja Multi-Config: Add variable to control configs used in cross-config build 2020-01-23 15:47:12 -05:00
Kyle Edwards
ab2fc91821 Merge topic 'organize_makefile_help_output'
7c1470f146 Makefiles: Organize help output to group 'like' targets

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4260
2020-01-23 10:43:03 -05:00
Brad King
f0f7ea2bf5 Merge topic 'get-runtime-dependencies-keyword-args'
3573f62a16 Merge branch 'backport-get-runtime-dependencies-keyword-args'
c998c8d560 file(GET_RUNTIME_DEPENDENCIES): Tolerate empty list arguments
4c8a917a87 file(GET_RUNTIME_DEPENDENCIES): Tolerate empty list arguments

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4262
2020-01-23 10:02:45 -05:00
Brad King
9771d231aa Merge topic 'ninja-multi-default-build-alias'
8337ed0d73 Ninja Multi-Config: Add variable to control aliases in build.ninja
110037369d Refactor: Split Ninja files into impl-<Config>.ninja and build-<Config>.ninja
e62a3414f7 Refactor: Move common.ninja into CMakeFiles

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4238
2020-01-23 10:01:14 -05:00
Ben Boeckel
6cc74b6140 cmGlobalNinjaGenerator: avoid cleandead and recompact in Ninja-Multi
Fixes: #20247
2020-01-23 09:24:46 -05:00
Kitware Robot
9c87d051ad CMake Nightly Date Stamp 2020-01-23 00:01:09 -05:00
Kyle Edwards
c998c8d560 file(GET_RUNTIME_DEPENDENCIES): Tolerate empty list arguments
Also list all keywords that were missing values instead of only the
first one.
2020-01-22 14:34:33 -05:00
Robert Maynard
7c1470f146 Makefiles: Organize help output to group 'like' targets 2020-01-22 13:21:12 -05:00
Kyle Edwards
8337ed0d73 Ninja Multi-Config: Add variable to control aliases in build.ninja 2020-01-22 10:26:21 -05:00
Kyle Edwards
110037369d Refactor: Split Ninja files into impl-<Config>.ninja and build-<Config>.ninja 2020-01-22 10:26:21 -05:00
Kyle Edwards
e62a3414f7 Refactor: Move common.ninja into CMakeFiles 2020-01-22 10:25:35 -05:00
Kyle Edwards
593d0f3a57 Merge topic 'ninja-restat-just-build.ninja'
eb2da206d9 cmGlobalNinjaGenerator: only restat build.ninja

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4245
2020-01-22 10:25:06 -05:00
Frank Winklmeier
c829f0cfca trace: Add time and stack level to JSON output format
Add the timestamp and stack depth of the function call to the JSON trace
output format. This information can be useful for cmake profiling and
call stack inspection (see e.g. https://github.com/volo-zyko/cmake-profile-stats).

Improve unit test to allow for varying set of keys to check in trace lines.
2020-01-22 09:58:52 -05:00
Brad King
15c573df41 Merge topic 'mark_as_advanced-without-cache'
3ec82b713e cmMarkAsAdvancedCommand: ignore variables which don't exist in the cache
701a5c60e0 cmake: avoid marking local or unused variables as advanced
af158149e7 FindOpenSSL: do not mark a local variable as advanced
74f659f1f2 FindCurses: only mark CURSES_EXTRA_LIBRARY when it is used
7e2ae4e96d FindOpenGL: only mark declared cache variables as advanced
7cc02a0c29 FindLua: only mark LUA_MATH_LIBRARY as advanced if required
85cd26b8a6 FindBoost: only mark Boost_DIR as advanced if defined
338c7916ba CTest: avoid marking undeclared cache variables as advanced
...

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4150
2020-01-22 09:50:49 -05:00
Brad King
39695f6fb3 Merge topic 'modernize-memory-management'
edab5add57 cmMakefileTargetGenerator: modernize memory management

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4250
2020-01-22 09:49:30 -05:00
Brad King
3be2abd889 Merge topic 'install-std-string'
5e54b0cf2f cmInstallGenerator: std::string params

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4255
2020-01-22 09:40:32 -05:00
Brad King
3f601ebb0a Merge topic 'vs-std-string'
2e768924f3 cmLocalVisualStudio7Generator: clean up c_str()

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4249
2020-01-22 09:24:57 -05:00
Kitware Robot
0877438599 CMake Nightly Date Stamp 2020-01-22 00:01:07 -05:00
Vitaly Stakhovsky
5e54b0cf2f cmInstallGenerator: std::string params
Several construction parameters converted to std::string
Also made a few class members const
2020-01-21 11:09:35 -05:00
Brad King
21e60da5bb CMake 3.16.3 2020-01-21 10:17:47 -05:00
Brad King
7a89e3c36c Merge topic 'install-std-string'
9db532f44d cmInstall*Generator: std::string params

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4241
2020-01-21 09:21:51 -05:00
Vitaly Stakhovsky
9db532f44d cmInstall*Generator: std::string params
Several construction parameters converted to std::string
Also made a few class members const
2020-01-21 09:19:13 -05:00
Ben Boeckel
eb2da206d9 cmGlobalNinjaGenerator: only restat build.ninja
This reduces the work that ninja needs to do on a CMake reconfigure.
2020-01-21 08:57:51 -05:00
Marc Chevrier
edab5add57 cmMakefileTargetGenerator: modernize memory management 2020-01-21 12:52:05 +01:00
Kitware Robot
2f7e76efa4 CMake Nightly Date Stamp 2020-01-21 00:01:16 -05:00
Ben Boeckel
3ec82b713e cmMarkAsAdvancedCommand: ignore variables which don't exist in the cache
Fixes: #18331
2020-01-20 15:49:29 -05:00
Vitaly Stakhovsky
2e768924f3 cmLocalVisualStudio7Generator: clean up c_str() 2020-01-20 15:44:07 -05:00
Brad King
941c09616b Merge topic 'multi-ninja-pch'
a55df20499 Multi-Ninja: Add precompile headers support

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4201
2020-01-20 11:59:28 -05:00
Brad King
56a3e84a67 Merge topic 'realpath-cache'
9d5a554cc9 cmGlobalGenerator: Add cache for realpath() results

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4220
2020-01-20 11:55:04 -05:00
Brad King
b168d8e855 Merge topic 'autogen_rcc_skip_unity' into release-3.16
086d9b2bab Autogen: Enable SKIP_UNITY_BUILD_INCLUSION on AUTORCC generated files

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Cristian Adam <cristian.adam@gmail.com>
Merge-request: !4237
2020-01-20 11:54:13 -05:00
Brad King
6a5a23ea92 Merge topic 'autogen_rcc_skip_unity'
086d9b2bab Autogen: Enable SKIP_UNITY_BUILD_INCLUSION on AUTORCC generated files

Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Cristian Adam <cristian.adam@gmail.com>
Merge-request: !4237
2020-01-20 11:54:13 -05:00
Brad King
9b9dfacaa5 Merge topic 'acc-fix-in-source-depends-path'
ba3a417dce Tests/CustomCommand: add a test for depending on a `./path`
e23475dc73 Tests/CustomCommand: fix custom command line to actually make its output
db4780d584 cmGeneratorTarget: search for relative paths to the binary directory
ec479f101f cmLocalGenerator: collapse the path after construction
fd0ba705ce add_custom_command: check if a relative path should be an in-source path
fd84f510f8 cmLocalGenerator: simplify the current source dir query

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4195
2020-01-20 11:52:00 -05:00
Kitware Robot
5e38b8f608 CMake Nightly Date Stamp 2020-01-20 00:01:13 -05:00
Craig Scott
582cc710c2 Merge topic 'pch-msvc-no-path-repetition' into release-3.16
07fe1bcd4e PCH: No repeated path for internal generated PCH files (MSVC case)

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4236
2020-01-19 15:10:17 -05:00
Craig Scott
6bd07b9de1 Merge topic 'pch-msvc-no-path-repetition'
07fe1bcd4e PCH: No repeated path for internal generated PCH files (MSVC case)

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4236
2020-01-19 15:10:17 -05:00
Kitware Robot
cd08cb7b8c CMake Nightly Date Stamp 2020-01-19 00:01:08 -05:00
Kitware Robot
5b4b808cb4 CMake Nightly Date Stamp 2020-01-18 00:01:15 -05:00
Cristian Adam
a55df20499 Multi-Ninja: Add precompile headers support
Fixes: #19789
2020-01-17 23:17:35 +01:00
Sebastian Holtermann
086d9b2bab Autogen: Enable SKIP_UNITY_BUILD_INCLUSION on AUTORCC generated files
`rcc` generated files are not compatible with unity builds, because they
contain classes in anonymous namespaces and static data with identical names.

This patch sets the source file property `SKIP_UNITY_BUILD_INCLUSION` to `On`
on all `AUTORCC` generated files to exclude them from unity build files.

Fixes: #20191 "QT5: Exclude resource files from unity build"
2020-01-17 09:48:35 -05:00
Brad King
a7fca06c46 Merge topic 'out-of-dir-link-list'
f0e67da061 target_link_libraries: Fix out-of-dir linking of a list of targets
acee629103 cmTargetLinkLibrariesCommand: Move HandleLibrary to helper struct
ba675f1ecc Tests: Enable CMP0022 in ExportImport out-of-dir linking case

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4226
2020-01-17 09:41:10 -05:00
Brad King
cd6f6b2a9f Merge topic 'cmake-ctest-arguments'
4153d8445b Add CMAKE_CTEST_ARGUMENTS variable to pass command-line arguments to ctest

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4168
2020-01-17 09:40:23 -05:00
Brad King
796d66438b Merge topic 'rename-cross-config-variable'
310b58e961 Ninja Multi-Config: Rename variable to be more consistent

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4234
2020-01-17 09:39:32 -05:00
Brad King
85e959b727 Merge topic 'feature/cmSourceFile-avoid-unnecessary-copy'
5da3d01fd1 cmSourceFile: avoid unnnecessary copies

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4233
2020-01-17 09:38:45 -05:00
Craig Scott
808888aa47 Merge topic 'cpack-custom-dmg-names'
6d6f4b9316 CPack/DragNDrop: Support CPACK_DMG_<component>_FILE_NAME
b53230fbee Tests: Add DragNDrop as a testable CPack generator

Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !4227
2020-01-17 08:33:01 -05:00
Kitware Robot
c9836f8a88 CMake Nightly Date Stamp 2020-01-17 00:01:14 -05:00
Ben Boeckel
db4780d584 cmGeneratorTarget: search for relative paths to the binary directory
Dependencies in the form `./somepath.txt` are not found otherwise
because we only match on last-path-component searches and `.` never
shows up in a full path as a full component.
2020-01-16 13:56:30 -05:00
Ben Boeckel
ec479f101f cmLocalGenerator: collapse the path after construction
The path may contain `..` or `.` components naïvely, so compute them out
before letting the generator handle them.
2020-01-16 13:56:30 -05:00
Ben Boeckel
fd0ba705ce add_custom_command: check if a relative path should be an in-source path
This still is broken for dependencies on generated paths where they get
generated to the source directory rather than the build directory
however, but there's no way to determine that is the case.

Fixes: #20194
2020-01-16 13:54:26 -05:00
Ben Boeckel
fd84f510f8 cmLocalGenerator: simplify the current source dir query 2020-01-16 13:54:25 -05:00
Brad King
f0e67da061 target_link_libraries: Fix out-of-dir linking of a list of targets
In a case like

    target_link_libraries(targetInOtherDir PUBLIC "$<1:a;b>")

then all entries in the list need to be looked up in the caller's
scope.  Previously our `::@(directory-id)` suffix would apply only
to the last entry.  Instead surround the entire entry by a pair
`::@(directory-id);...;::@` so that the `::@` syntax can encode
a directory lookup scope change evaluated as the list is processed.

Fixes: #20204
2020-01-16 13:24:27 -05:00
Brad King
acee629103 cmTargetLinkLibrariesCommand: Move HandleLibrary to helper struct 2020-01-16 11:53:52 -05:00