path: root/config.tests
diff options
authorGirish Ramakrishnan <>2012-03-20 21:01:20 -0700
committerQt by Nokia <>2012-03-22 20:59:27 +0100
commit4cc9523a3153a0e7b012de3919e0c4f4ccb96265 (patch)
treec4d5733084b4c51340c9491f186501035d3ec4ed /config.tests
parent31f9df520527be3f7a0f45092dbb5bc9ed1700ff (diff)
Make architecture detection more robust.
Any message/error in mkspecs or qmake feature files ends up confusing the current arch detection logic. Instead, search for "Project MESSAGE: .* Architecture: <arch>". Change-Id: I308932a5b75f3a1fcbc4fe30c74faf2e83b2d752 Reviewed-by: Oswald Buddenhagen <>
Diffstat (limited to 'config.tests')
2 files changed, 15 insertions, 15 deletions
diff --git a/config.tests/arch/arch.cpp b/config.tests/arch/arch.cpp
index f942d0adc7..1a96fb982f 100644
--- a/config.tests/arch/arch.cpp
+++ b/config.tests/arch/arch.cpp
@@ -55,29 +55,29 @@
#undef sparc
#undef unknown
#if defined(Q_PROCESSOR_ALPHA)
+Architecture: alpha
#elif defined(Q_PROCESSOR_ARM)
+Architecture: arm
#elif defined(Q_PROCESSOR_AVR32)
+Architecture: avr32
+Architecture: bfin
#elif defined(Q_PROCESSOR_X86_32)
+Architecture: i386
#elif defined(Q_PROCESSOR_X86_64)
+Architecture: x86_64
#elif defined(Q_PROCESSOR_IA64)
+Architecture: ia64
#elif defined(Q_PROCESSOR_MIPS)
+Architecture: mips
#elif defined(Q_PROCESSOR_POWER)
+Architecture: power
#elif defined(Q_PROCESSOR_S390)
+Architecture: s390
#elif defined(Q_PROCESSOR_SH)
+Architecture: sh
#elif defined(Q_PROCESSOR_SPARC)
+Architecture: sparc
+Architecture: unknown
diff --git a/config.tests/arch/ b/config.tests/arch/
index 108f262a55..ea85a52b97 100644
--- a/config.tests/arch/
+++ b/config.tests/arch/
@@ -1,7 +1,7 @@
CONFIG -= qt debug_and_release
# Detect target by preprocessing a file that uses Q_PROCESSOR_* macros from qprocessordetection.h
-# 'false' as second argument to system() prevents qmake from stripping newlines
-COMPILER_ARCH = $$system($$COMMAND, false)
+# system function converts newline in output into spaces
# Message back to configure so that it can set QT_ARCH and QT_HOST_ARCH