summaryrefslogtreecommitdiff
path: root/Tests/RunCMake/export
Commit message (Collapse)AuthorAgeFilesLines
* Tests/RunCMake: Update cmake_minimum_required versionsBrad King2023-02-111-1/+1
| | | | | | | | For policy-specific tests, use the version before the policy was introduced. Otherwise, use 3.5 where possible. Also, remove `cmake_minimum_required()` and `project()` calls from individual cases where they are handled by `CMakeLists.txt`.
* Add deprecation warnings for policies CMP0108 and belowBrad King2022-10-121-0/+10
| | | | | | | The OLD behaviors of all policies are deprecated, but only by documentation. Add an explicit deprecation diagnostic for policies introduced in CMake 3.18 and below to encourage projects to port away from setting policies to OLD.
* cmGlobalGenerator: Only compute build files for all targetsKyle Edwards2022-07-132-0/+10
| | | | | | | | If we're creating generation objects for imported targets only, we don't need the export sets. Only compute build file generators if generating for all targets. Fixes: #23709
* export: Do not fail generation for separate namelink only caseDeniz Bahadir2020-12-012-0/+17
| | | | | | | | Update the change from commit 64690f6df0 (export: Do not fail generation for namelink-only case, 2020-10-09, v3.19.0-rc1~7^2) to also handle separate namelink-only and namelink-skip calls. Fixes: #21529
* export: Do not fail generation for namelink-only caseDeniz Bahadir2020-10-095-0/+18
|
* Tests/RunCMake: Update cmake_minimum_required versionsBrad King2020-06-181-1/+1
| | | | Use 3.3 or 2.8.12 where possible.
* Tests/RunCMake/export: handle collapsed newlinesBen Boeckel2020-05-221-2/+1
| | | | | When the build path is long with a space near the line length, a newline is lost.
* CUDA: Device linking use now link optionsMarc Chevrier2020-04-191-2/+2
| | | | | | | | | | properties LINK_OPTIONS and INTERFACE_LINK_OPTIONS are propagated to the device link step. To control which options are selected for normal link and device link steps, the $<DEVICE_LINK> and $<HOST_LINK> generator expressions can be used. Fixes: #18265
* export(): raise an error on multiple calls with same FILEMarc Chevrier2020-03-267-1/+52
| | | | Fixes: 20472
* export: Fix use-after-free on multiple calls overwriting same FILEBrad King2020-03-193-0/+8
| | | | | | | | | | | | | | | | | | | | | CMake 3.16 and below allow multiple `export()` calls with the same output file even without using `APPEND`. The implementation worked by accident by leaking memory. Refactoring in commit 5444a8095d (cmGlobalGenerator: modernize memrory managemenbt, 2019-12-29, v3.17.0-rc1~239^2) cleaned up that memory leak and converted it to a use-after-free instead. The problem is caused by using the `cmGlobalGenerator::BuildExportSets` map to own `cmExportBuildFileGenerator` instances. It can own only one instance per output FILE name at a time, so repeating use of the same file now frees the old `cmExportBuildFileGenerator` instance and leaves the pointer in the `cmMakefile::ExportBuildFileGenerators` vector dangling. Move ownership of the instances into `cmMakefile`'s vector since its entries are not replaced on a repeat output FILE. In future work we should introduce a policy to error out on this case. For now simply fix the use-after-free to restore CMake <= 3.16 behavior. Fixes: #20469
* Tests: add tests for export set error messagesBen Boeckel2019-06-277-0/+34
|
* export: Restore support for empty TARGETS listBrad King2019-06-252-0/+2
| | | | | | | | | Refactoring in commit f5acecaa6f (cmExportCommand: Port to cmArgumentParser, 2019-03-23, v3.15.0-rc1~270^2~3) broke the `export` command's support for specifying `TARGETS` with no entries. Fix it and add a test case. Fixes: #19415
* cmExportCommand: Port to cmArgumentParserRegina Pfeifer2019-04-042-3/+2
|
* EXPORT_PROPERTIES: Add test for an undefined propertyCraig Scott2018-08-162-0/+12
| | | | The added test verifies that a property listed in EXPORT_PROPERTIES can be undefined. It confirms the crash recorded in issue #18260.
* Export: allow exporting of additional propertiesWouter Klouwen2018-03-1611-0/+58
| | | | | | | | | This change introduces an additional property that may be set on a target to allow additional properties to be exported. Normally only a limited number of properties are exported. Additional properties may be exported by simply setting the `EXPORT_PROPERTIES` property on a target that is exported.
* export: Reject custom target exports earlier (#15657)Brad King2015-07-214-0/+8
| | | | | Diagnose and reject custom targets given to the export() command immediately. Previously we would generate an internal error later.
* Tests: Teach RunCMake.export to enable languages only when neededBrad King2015-07-215-3/+5
|
* export: Implement EXPORT subcommand (#9822)Stephen Kelly2013-12-2410-0/+39
| | | | | | Teach the export command to handle export sets defined by invocations of install(TARGETS ... EXPORT foo). This makes maintenance of targets exported to both the build tree and install tree trivial.
* export(): Check targets exist at configure-time (#14608)Stephen Kelly2013-12-045-0/+12
Commit 66b290e7 (export(): Process the export() command at generate time., 2012-10-06 ) refactored export() so that it could evaluate strings at generate-time. This was intended for evaluating target properties, but that commit also removed a check for target existence at configure-time. Restore that check and add a test for this case.