summaryrefslogtreecommitdiffstats
path: root/Tests/RunCMake/add_subdirectory
Commit message (Collapse)AuthorAgeFilesLines
* Tests/RunCMake: Update cmake_minimum_required versions to 3.10Brad King2024-10-031-1/+1
| | | | | For policy-specific tests, use the version before the policy was introduced. Otherwise, use 3.10 where possible.
* Tests: Simplify tests for Visual Studio generatorsBrad King2024-08-281-1/+1
| | | | | | Since commit 03c31b0395 (Drop Visual Studio 9 2008 generator, 2024-05-06, v3.30.0-rc1~134^2), some tests do not need to be version-dependent.
* Ninja Multi-Config: Fix crash if config list is changed in subdirectoryBrad King2024-06-213-0/+6
| | | | | | | Look up the value of `CMAKE_CONFIGURATION_TYPES` only in the top level directory. Fixes: #26064
* NVHPC: Support nvfortran versions that don't support isystemRobert Maynard2023-06-235-0/+11
| | | | Fixes: #25019
* 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_subdirectory: Add SYSTEM optionDa Quexian2022-09-2614-0/+46
| | | | | Fixes: #22401 Signed-off-by: Da Quexian <daquexian566@gmail.com>
* Merge topic 'ci-fixups'Brad King2021-07-0614-14/+28
|\ | | | | | | | | | | | | | | 46c89c77de gitlab-ci: Rename CI config variable to avoid conflict with CMAKE_BUILD_TYPE 3ede66e17a Tests: Fix newline matching in several RunCMake.* cases Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !6298
| * Tests: Fix newline matching in several RunCMake.* casesBrad King2021-07-0214-14/+28
| | | | | | | | | | | | | | | | The RunCMake infrastructure's `*-stdout.txt` expected output files interpret `\n` as a `\` and `n` rather than a newline. Use a literal newline instead. Otherwise the cases that were trying to match any configuration name via `[^\n]*` would fail on `RelWithDebInfo` because it contains the letter `n`.
* | Add deprecation warnings for policies CMP0088 and belowBrad King2021-06-301-0/+8
|/ | | | | | | The OLD behaviors of all policies are deprecated, but only by documentation. Add an explicit deprecation diagnostic for policies introduced in CMake 3.14 and below to encourage projects to port away from setting policies to OLD.
* CMP0082: Check EXCLUDE_FROM_ALL property at generate timeKyle Edwards2021-05-244-3/+4
| | | | Fixes: #22234
* Tests: Cover EXCLUDE_FROM_ALL OFF on sub/sub/tgt in sub/allBrad King2019-09-304-0/+5
| | | | Issue: #19753
* Ninja,Makefile: Fix subdir "all" with nested EXCLUDE_FROM_ALL subdirBrad King2019-09-306-0/+10
| | | | | | | | | | The "all" target defined for a subdirectory (e.g. `cd sub; make` or `ninja sub/all`) should not include the "all" targets from nested subdirectories (e.g. `sub/sub`) that are marked as `EXCLUDE_FROM_ALL`. Fix this and add a test case. Issue: #19753 Co-Author: Sebastian Holtermann <sebholt@xwmw.org>
* Restore "all" target in subdirectories marked EXCLUDE_FROM_ALLBrad King2019-09-307-2/+68
| | | | | | | | | | | | | The "all" target in each directory is supposed to have targets from that directory even if the directory itself is marked `EXCLUDE_FROM_ALL` in its parent. This was broken by commit dc6888573d (Pass EXCLUDE_FROM_ALL from directory to targets, 2019-01-15, v3.14.0-rc1~83^2) which made the participation of a target in "all" independent of context. Revert much of the logic change from that commit to restore the old behavior. Then re-implement the behavior intended by the commit to keep its test working. Extend the test to cover the old behavior too. Fixes: #19753
* Tests: Clarify target names in RunCMake.add_subdirectory ExcludeFromAllBrad King2019-09-264-6/+9
| | | | | Rename the `baz` target to `subinc` to clarify that its role is to be included even though it is in an otherwise excluded subdirectory.
* Tests: Revise RunCMake.add_subdirectory ExcludeFromAll to avoid globbingBrad King2019-09-264-61/+43
| | | | Also simplify the clean step.
* Pass EXCLUDE_FROM_ALL from directory to targetsZack Galbreath2019-01-213-0/+61
| | | | | | When a target is created it now inherits the EXCLUDE_FROM_ALL property from its directory. This change makes it possible to include a target in "all", even if its directory has been marked as EXCLUDE_FROM_ALL.
* Testing: Add test for CMP0082Kyle Edwards2018-10-1035-2/+119
|
* Xcode: Add targets marked as EXCLUDE_FROM_ALL to project (#16101)Gregor Jasny2016-08-317-0/+36
|
* Tests: Add case for add_subdirectory inside a functionBrad King2015-11-234-0/+33
|
* add_subdirectory: Fix error message on missing CMakeLists.txt (#15680)Brad King2015-08-049-0/+24
Refactoring in commit v3.3.0-rc1~76^2 (cmMakefile: Handle CMP0014 before configuring the generator, 2015-05-14) accidentally left the file name "/CMakeLists.txt" in the error message. Remove it and add a test case.