summaryrefslogtreecommitdiffstats
path: root/configure.cmake
diff options
context:
space:
mode:
authorJoerg Bornemann <joerg.bornemann@qt.io>2020-08-19 16:49:13 +0200
committerJoerg Bornemann <joerg.bornemann@qt.io>2020-08-20 17:07:46 +0200
commitdf28355981e14c90dc0f214ceeba40be77401fb4 (patch)
treea2eb561965f1d77a68310b1635a910f71347ffa6 /configure.cmake
parent45d3c75ab6f29e88637363869a3b0be8df731dec (diff)
CMake: Support configure tests of type 'compilerSupportsFlag'
Task-number: QTBUG-86155 Change-Id: Iaa5c48b6508870a0f6afdf9df66cd2e634fe19b3 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
Diffstat (limited to 'configure.cmake')
-rw-r--r--configure.cmake26
1 files changed, 23 insertions, 3 deletions
diff --git a/configure.cmake b/configure.cmake
index f56047b14c..0fb01ef4fb 100644
--- a/configure.cmake
+++ b/configure.cmake
@@ -110,6 +110,26 @@ int main(int argc, char **argv)
"# FIXME: qmake: ['CONFIG += precompile_header', 'PRECOMPILED_DIR = .pch', 'PRECOMPILED_HEADER = header.h']
)
+qt_config_compiler_supports_flag_test(use_bfd_linker
+ LABEL "bfd linker"
+ FLAG "-fuse-ld=bfd"
+)
+
+qt_config_compiler_supports_flag_test(use_gold_linker
+ LABEL "gold linker"
+ FLAG "-fuse-ld=gold"
+)
+
+qt_config_compiler_supports_flag_test(use_lld_linker
+ LABEL "lld linker"
+ FLAG "-fuse-ld=lld"
+)
+
+qt_config_compiler_supports_flag_test(optimize_debug
+ LABEL "-Og support"
+ FLAG "-Og"
+)
+
# reduce_relocations
qt_config_compile_test(reduce_relocations
LABEL "-Bsymbolic-functions support"
@@ -364,19 +384,19 @@ qt_feature("gc_binaries" PRIVATE
qt_feature("use_bfd_linker"
LABEL "bfd"
AUTODETECT false
- CONDITION NOT WIN32 AND NOT INTEGRITY AND NOT WASM AND tests.use_bfd_linker OR FIXME
+ CONDITION NOT WIN32 AND NOT INTEGRITY AND NOT WASM AND TEST_use_bfd_linker
ENABLE INPUT_linker STREQUAL 'bfd'
DISABLE INPUT_linker STREQUAL 'gold' OR INPUT_linker STREQUAL 'lld'
)
qt_feature_config("use_bfd_linker" QMAKE_PRIVATE_CONFIG)
qt_feature("use_gold_linker_alias"
AUTODETECT false
- CONDITION NOT WIN32 AND NOT INTEGRITY AND NOT WASM AND tests.use_gold_linker OR FIXME
+ CONDITION NOT WIN32 AND NOT INTEGRITY AND NOT WASM AND TEST_use_gold_linker
)
qt_feature("use_lld_linker"
LABEL "lld"
AUTODETECT false
- CONDITION NOT WIN32 AND NOT INTEGRITY AND NOT WASM AND tests.use_lld_linker OR FIXME
+ CONDITION NOT WIN32 AND NOT INTEGRITY AND NOT WASM AND TEST_use_lld_linker
ENABLE INPUT_linker STREQUAL 'lld'
DISABLE INPUT_linker STREQUAL 'bfd' OR INPUT_linker STREQUAL 'gold'
)