summaryrefslogtreecommitdiffstats
path: root/mkspecs
diff options
context:
space:
mode:
Diffstat (limited to 'mkspecs')
-rw-r--r--mkspecs/features/configure_base.prf8
-rw-r--r--mkspecs/features/qt_configure.prf10
2 files changed, 11 insertions, 7 deletions
diff --git a/mkspecs/features/configure_base.prf b/mkspecs/features/configure_base.prf
index f62142f84d..08edba4b1c 100644
--- a/mkspecs/features/configure_base.prf
+++ b/mkspecs/features/configure_base.prf
@@ -26,14 +26,18 @@ isEmpty(QMAKE_CONFIG_VERBOSE): QMAKE_CONFIG_VERBOSE = false
defineTest(qtLog) {
write_file($$QMAKE_CONFIG_LOG, 1, append)
- $$QMAKE_CONFIG_VERBOSE: log("$$1$$escape_expand(\\n)")
+ $$QMAKE_CONFIG_VERBOSE: for (l, 1): log("$$l$$escape_expand(\\n)")
}
defineTest(qtRunLoggedCommand) {
qtLog("+ $$1")
- output = $$system("( $$1 ) 2>&1", blob, result)
+ output = $$system("( $$1 ) 2>&1", lines, result)
qtLog($$output)
+ !isEmpty(2) {
+ $$2 = $$output
+ export($$2)
+ }
!equals(result, 0): return(false)
return(true)
diff --git a/mkspecs/features/qt_configure.prf b/mkspecs/features/qt_configure.prf
index 7a289f7b94..a0e5b1a772 100644
--- a/mkspecs/features/qt_configure.prf
+++ b/mkspecs/features/qt_configure.prf
@@ -331,13 +331,13 @@ defineTest(qtConfTest_pkgConfig) {
!qtConfPkgConfigPackageExists($$pkg_config, $$args): \
return(false)
- $${1}.libs = $$system("$$pkg_config --libs $$args", lines)
- $${1}.cflags = $$system("$$pkg_config --cflags $$args", lines)
- includes = $$system("$$pkg_config --cflags-only-I $$args", lines)
+ qtRunLoggedCommand("$$pkg_config --modversion $$args", version)|return(false)
+ qtRunLoggedCommand("$$pkg_config --libs $$args", $${1}.libs)|return(false)
+ qtRunLoggedCommand("$$pkg_config --cflags $$args", $${1}.cflags)|return(false)
+ qtRunLoggedCommand("$$pkg_config --cflags-only-I $$args", includes)|return(false)
eval(includes = $$includes)
includes ~= s/^-I//g
$${1}.includedir = "$$val_escape(includes)"
- version = $$system("$$pkg_config --modversion $$args")
$${1}.version = $$first(version)
export($${1}.libs)
export($${1}.cflags)
@@ -356,7 +356,7 @@ defineTest(qtConfTest_getPkgConfigVariable) {
return(false)
variable = $$eval($${1}.pkg-config-variable)
- $${1}.value = $$system("$$pkg_config --variable=$$variable $$args")
+ qtRunLoggedCommand("$$pkg_config --variable=$$variable $$args", $${1}.value)|return(false)
export($${1}.value)
return(true)
}