From 2438a5ad48014ca0828ee417616358ea171826aa Mon Sep 17 00:00:00 2001 From: Kent Hansen Date: Thu, 1 Sep 2011 16:13:29 +0200 Subject: Try to ensure that QT_ARCH is always set when configuring v8 This is a workaround for QTBUG-21224. For v8 we want to use QT_ARCH as the primary variable for detecting the target platform. Unfortunately, QT_ARCH isn't set when v8.pro is parsed using fromfile() from within another .pro file (namely src/src.pro). qt_config seems to be the bare minimum that's needed to get qconfig.pri (which sets QT_ARCH and friends) loaded. Change-Id: Ideb713724b98dd100560eaf6d7be39df9a22a71e Reviewed-on: http://codereview.qt.nokia.com/4094 Reviewed-by: Qt Sanity Bot Reviewed-by: Oswald Buddenhagen Reviewed-by: Marius Storm-Olsen --- src/v8/v8.pri | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'src/v8/v8.pri') diff --git a/src/v8/v8.pri b/src/v8/v8.pri index 4d55bbfd5a..dde953ca0d 100644 --- a/src/v8/v8.pri +++ b/src/v8/v8.pri @@ -1,3 +1,10 @@ +isEmpty(QT_ARCH) { + # We're most likely being parsed in a fromfile() call, in which case the + # QMake environment isn't complete. Load qt_config in an attempt to set + # the variables we need (QT_ARCH and CONFIG, in particular). + load(qt_config) +} + equals(QT_ARCH, x86_64)|contains(CONFIG, x86_64):CONFIG += arch_x86_64 else:equals(QT_ARCH, "i386"):CONFIG += arch_i386 else:equals(QT_ARCH, "arm"):CONFIG += arch_arm -- cgit v1.2.3