Brad King
0dcbf4ab58
cmGeneratorTarget: Record when imported target link iface libs are done
...
`GetImportLinkInterface` populates the link interface from properties
of imported targets. Make it more closely match the link interface
of in-project targets by recording the `LibrariesDone` field.
2021-12-16 10:39:41 -05:00
Brad King
1d709ea2f5
cmGeneratorTarget: Propagate backtraces from INTERFACE_LINK_LIBRARIES
2021-12-15 12:29:47 -05:00
Brad King
9f5e0629df
Merge topic 'link-iface-usage-reqs-only'
...
1e49880472 cmGeneratorTarget: Avoid boolean trap in usage requirement lookup
Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !6796
2021-12-10 09:14:53 -05:00
Brad King
1e49880472
cmGeneratorTarget: Avoid boolean trap in usage requirement lookup
...
Replace `bool usage_requirements_only` arguments with a proper
enumeration to clarify meaning at call sites.
2021-12-09 11:00:23 -05:00
Brad King
c749982c13
cmTargetPropertyComputer: Simplify by restoring use of cmMakefile
...
Logically revert commit 390a7d8647 (cmTargetPropertyComputer: Implement
GetProperty without cmMakefile, 2016-10-13, v3.8.0-rc1~445^2~9).
It relied on using `cmListFileBacktrace` to get a scope in which to
look up policies.
This does remove a backtrace from `LOCATION` property errors at generate
time, but the backtrace we reported before was incorrect. It pointed at
the addition of a target, not to the reference to the property.
2021-12-08 10:03:48 -05:00
Brad King
4e84a4763d
Merge topic 'support_nvcc_native_flag'
...
14d8a2768d CUDA: Support nvcc 11.5 new -arch=all|all-major flags
Acked-by: Kitware Robot <kwrobot@kitware.com>
Reviewed-by: Raul Tambre <raul@tambre.ee>
Merge-request: !6652
2021-11-02 08:55:13 -04:00
Robert Maynard
14d8a2768d
CUDA: Support nvcc 11.5 new -arch=all|all-major flags
2021-11-01 14:57:58 -04:00
Kyle Edwards
8a09723bff
cmGeneratorTarget: Integrate file sets into calculated sources
2021-10-27 15:17:23 -04:00
Sean McBride
1cf14f8c03
Source: fix many -Wmissing-prototypes warnings by marking functions static
2021-10-25 12:27:09 -04:00
Brad King
7df0541055
Add property to mark IMPORTED targets as not SYSTEM
...
Add an `IMPORTED_NO_SYSTEM` target property to specify this. When
enabled, do not treat the `INTERFACE_INCLUDE_DIRECTORIES` of an imported
target as `SYSTEM` include directories.
This is similar to the existing `NO_SYSTEM_FROM_IMPORTED` property, but
works from the consumed target rather than the consumer.
Fixes : #17364
2021-10-14 13:15:48 -04:00
Sean McBride
37859e3244
Source: Fix clang -Wimplicit-fallthrough warnings
2021-09-28 10:53:54 -04:00
Marc Chevrier
cc56dc7468
Rename cmProp in cmValue
2021-09-21 17:14:04 +02:00
Brad King
62834c0760
Merge topic 'macos-cache-rpath-install-namedir'
...
2266e223c5 macOS: Speed up rpath install name dir lookup with a cache
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6543
2021-09-21 11:06:25 -04:00
Lukas Böger
2266e223c5
macOS: Speed up rpath install name dir lookup with a cache
...
Fixes : #20602
2021-09-20 11:15:25 -04:00
Marc Chevrier
3a1e6f5f59
remove cmToCStr function
2021-09-19 19:11:07 +02:00
Brad King
69c0a5daf9
Merge topic 'pch-xcode-multiple-languages'
...
bbcdac4e5d PCH: Fix all-language precompile header support in Xcode
Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !6435
2021-09-14 09:48:00 -04:00
Cristian Adam
bbcdac4e5d
PCH: Fix all-language precompile header support in Xcode
...
Fixes : #22384
2021-09-13 08:12:11 -07:00
Kyle Edwards
ab94c369c9
Refactor: Convert parallel string/backtrace vectors to BT vectors
2021-09-03 09:52:14 -04:00
Marc Chevrier
5a2a275bb4
Refactor: reduce cmToCStr usage
2021-08-19 10:49:30 +02:00
Marc Chevrier
e542116814
Refactor: cmGeneratorTarget::GetSourcesProperty returns cmProp
2021-08-09 16:56:41 +02:00
Marc Chevrier
e5cd39ca80
cmProp: refactoring: transform alias in class
...
To handle safely the values used by CMake variables and properties,
introduce the class cmProp as a replacement from the simple pointer
to std::string instance.
2021-08-08 16:19:08 +02:00
Brad King
d9e4b47432
cmGeneratorTarget: Clarify logic recognizing explicit link interface
2021-07-13 11:53:00 -04:00
Brad King
ff97944806
cmGeneratorTarget: Clarify cmLinkImplItem constructor call
2021-07-13 11:52:59 -04:00
Brad King
8112480921
cmGeneratorTarget: Clarify ExpandLinkItems local variable role
2021-07-13 11:52:58 -04:00
Brad King
33f0505f01
cmGeneratorTarget: Simplify ExpandLinkItems signature
2021-07-13 11:31:16 -04:00
Marc Chevrier
8a93de080c
cmGeneratorTarget: Add method for LINKER: prefix translation
2021-07-08 13:48:42 +02:00
Brad King
85fe60ef03
Merge topic 'tll-out-of-dir'
...
e27a76f131 target_link_libraries: Restore transitive out-of-dir linking
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6285
2021-06-30 07:27:49 -04:00
Brad King
e27a76f131
target_link_libraries: Restore transitive out-of-dir linking
...
Refactoring in commit 7f506b95a7 (cmGeneratorTarget: Refactor link item
lookup, 2021-05-26, v3.21.0-rc1~103^2~4) accidentally dropped the
persistent lookup scope tracking across multiple items that was added by
commit f0e67da061 (target_link_libraries: Fix out-of-dir linking of a
list of targets, 2020-01-14, v3.17.0-rc1~149^2). This broke a
transitive out-of-dir linking case not covered by our test suite.
Restore the scope tracking and add a test case.
Fixes : #22363
2021-06-29 16:52:12 -04:00
Brad King
a6b075c3f8
Merge topic 'import-elf'
...
115ff6a347 cmELF: Include the ELF parsing code unconditionally
5dfa3ddbe5 cmELF: Allow building without system ELF headers
0da1540aaa cmELF: Fix check for TagMipsRldMapRel
e21188df8b cmELF: Open file explicitly in binary mode
70cdb36d25 Merge branch 'upstream-elf' into import-elf
7a0a37ca41 elf 2021-06-23 (f13da247)
18038042ed cmelf: Add script to import the FreeBSD ELF headers
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !6240
2021-06-25 07:26:35 -04:00
Alex Richardson
115ff6a347
cmELF: Include the ELF parsing code unconditionally
...
Now that the ELF definitions are provided on all platforms there is no
need to keep the CMake_USE_ELF_PARSER option.
2021-06-24 10:57:51 -04:00
Isuru Fernando
fe3f846e1b
Makefiles: Add support for building Fortran intrinsics
...
Fixes : #21463
2021-06-24 08:39:47 -04:00
Zack Galbreath
8514ee9b31
HIP: analyze output of hipcc
to determine default GPU architecture
2021-06-07 19:25:34 +00:00
Robert Maynard
947dbed0aa
HIP: Automatically inject the hip::device
runtime target
...
Any target that might need to link to hip code needs the `hip::device`
target
2021-06-07 19:25:33 +00:00
Robert Maynard
b50bfc8913
HIP: Add language to CMake
2021-06-07 19:25:33 +00:00
Brad King
ed3aad97e3
cmGeneratorTarget: Clear cached link implementation when a source is added
...
Adding a source file at generate time can cause the linker language or
other settings to change that affect `GetLinkImplementationLibraries`
and friends.
2021-06-04 12:14:04 -04:00
Brad King
3941555d93
target_link_libraries: Place $<TARGET_OBJECTS> before libraries
...
Linkers always use object files explicitly specified on the command line
regardless of where they appear. Move them to the front of the list of
linked libraries in so that symbols required by the object files can be
resolved by any library.
Issue: #22149
2021-05-29 09:28:36 -04:00
Brad King
7f506b95a7
cmGeneratorTarget: Refactor link item lookup
...
Look up items individually so the call sites can do something with the
result besides appending to a vector.
2021-05-28 14:27:38 -04:00
Brad King
96809a8541
cmGeneratorTarget: Give temporary link impl item an explicit name
2021-05-28 14:27:38 -04:00
Brad King
2ae72ef74b
Xcode: Enable multi-arch TARGET_OBJECTS genex in [INTERFACE_]LINK_LIBRARIES
...
This was an oversight in the original implementation.
2021-05-26 15:43:38 -04:00
Kyle Edwards
820d3afb28
Framework: Fix $<TARGET_SONAME_FILE:...> for imported frameworks
2021-05-20 15:00:22 -04:00
Vitaly Stakhovsky
ce97b7909b
Source: Remove unnecessary comparisons to nullptr
2021-05-10 11:44:53 -04:00
Brad King
b362c0bb26
Merge topic 'CUDA-device-link'
...
bb96984ec9 CUDA Device link: Ensure all link options are correctly formatted
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !5962
2021-04-01 10:21:11 -04:00
Marc Chevrier
bb96984ec9
CUDA Device link: Ensure all link options are correctly formatted
...
Fixes : #21994
2021-03-31 12:05:23 +02:00
Kyle Edwards
d34d28e688
Genex: Add TARGET_RUNTIME_DLLS genex
...
Co-Authored-by: Brad King <brad.king@kitware.com>
2021-02-24 14:55:17 -05:00
Marc Chevrier
b722eea925
Genex: LINK_LANGUAGE respects LINKER_LANGUAGE property
...
If target property LINKER_LANGUAGE is set, LINK_LANGUAGE generator
expression evaluation must be always successful.
This fix can be helpful to elaborate a solution for issue #21818 .
2021-02-23 08:14:14 -05:00
Brad King
e017ba046c
AIX: Enable XCOFF editing to replace RPATH on installation
...
Avoid relinking before installation.
2021-02-03 12:26:58 -05:00
Brad King
d8f3e68ca9
Ninja Multi-Config: Enable relink diagnostic message
...
We already have a message for the "Ninja" generator, but it applies
to the "Ninja Multi-Config" generator too.
2021-02-03 11:35:31 -05:00
Brad King
b6071c93f5
Rename CMAKE_USE_ELF_PARSER to CMake_USE_ELF_PARSER
...
We use the `CMake_` prefix for options affecting CMake itself.
2021-02-03 11:35:31 -05:00
Brad King
9b96fbc358
Merge topic 'clang-tidy-fixes'
...
ef935b17ab clang-tidy: fix `readability-use-anyofallof` warnings
9ac8dbbb94 clang-tidy: fix `readability-simplify-boolean-expr` warnings
ca505718f4 clang-tidy: fix `readability-redundant-string-init` warnings
b3b6ede6a1 clang-tidy: fix `readability-redundant-access-specifiers` warnings
cdfc4e3195 clang-tidy: fix `readability-qualified-auto` warnings
808b17b120 clang-tidy: fix `readability-make-member-function-const` warnings
4470eb5179 clang-tidy: fix `performance-trivially-destructible` warnings
4f396e6528 clang-tidy: fix `performance-no-automatic-move` warnings
...
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !5731
2021-01-27 09:52:18 -05:00
Ben Boeckel
cdfc4e3195
clang-tidy: fix readability-qualified-auto
warnings
2021-01-27 08:45:45 -05:00