summaryrefslogtreecommitdiffstats
path: root/Source/cmPolicies.h
diff options
context:
space:
mode:
authorRalf Habacker <ralf.habacker@freenet.de>2023-11-02 16:48:15 (GMT)
committerBrad King <brad.king@kitware.com>2023-12-19 15:00:55 (GMT)
commitca5a300d7fee308a0f32bf677e4bb5d74ebbd0cc (patch)
tree47870643781ec741b668a8dd0403e0d2d34dba31 /Source/cmPolicies.h
parentdaf8da8c8007229490dbdf0b2cd32f0b575f3c00 (diff)
downloadCMake-ca5a300d7fee308a0f32bf677e4bb5d74ebbd0cc.zip
CMake-ca5a300d7fee308a0f32bf677e4bb5d74ebbd0cc.tar.gz
CMake-ca5a300d7fee308a0f32bf677e4bb5d74ebbd0cc.tar.bz2
add_test: Honor CROSSCOMPILING_EMULATOR only when cross-compiling
Add policy CMP0158 to provide compatibility for existing projects. Fixes: #23672
Diffstat (limited to 'Source/cmPolicies.h')
-rw-r--r--Source/cmPolicies.h6
1 files changed, 5 insertions, 1 deletions
diff --git a/Source/cmPolicies.h b/Source/cmPolicies.h
index 7964f32..f038c6b 100644
--- a/Source/cmPolicies.h
+++ b/Source/cmPolicies.h
@@ -480,7 +480,11 @@ class cmMakefile;
29, 0, cmPolicies::WARN) \
SELECT(POLICY, CMP0157, \
"Swift compilation mode selected by an abstraction.", 3, 29, 0, \
- cmPolicies::WARN)
+ cmPolicies::WARN) \
+ SELECT(POLICY, CMP0158, \
+ "add_test() honors CMAKE_CROSSCOMPILING_EMULATOR only when " \
+ "cross-compiling.", \
+ 3, 28, 0, cmPolicies::WARN)
#define CM_SELECT_ID(F, A1, A2, A3, A4, A5, A6) F(A1)
#define CM_FOR_EACH_POLICY_ID(POLICY) \