summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAllan Sandfeld Jensen <allan.jensen@theqtcompany.com>2015-07-14 14:03:53 +0200
committerAllan Sandfeld Jensen <allan.jensen@theqtcompany.com>2015-07-27 12:31:47 +0000
commit94b550ebee2858756a293aacf7e78e7ce11bb9c9 (patch)
tree9d277093ee65674368590fba9e2f716c99976837
parent8b6bd564eddafe9b3fd42e19367c0f94e860ceed (diff)
Add post configure step and make using system ICU an option
Adds a post configure step to test qmake arguments, summerize options, and make it possible to enable using system ICU, but leaving it default off for now. Also summerizes the proprietary codec configuration. Change-Id: I620a69dcdbb14b49143770d38eecb5aeab48ad05 Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
-rw-r--r--src/core/config/desktop_linux.pri2
-rw-r--r--src/core/config/embedded_linux.pri3
-rw-r--r--src/core/gyp_run.pro2
-rw-r--r--tools/qmake/mkspecs/features/configure.prf22
-rw-r--r--tools/qmake/mkspecs/features/default_post.prf3
-rw-r--r--tools/qmake/mkspecs/features/default_pre.prf4
6 files changed, 33 insertions, 3 deletions
diff --git a/src/core/config/desktop_linux.pri b/src/core/config/desktop_linux.pri
index d9ce4f721..fc965f363 100644
--- a/src/core/config/desktop_linux.pri
+++ b/src/core/config/desktop_linux.pri
@@ -30,4 +30,6 @@ config_system_opus: GYP_CONFIG += use_system_opus=1
config_system_speex: GYP_CONFIG += use_system_speex=1
config_system_vpx: GYP_CONFIG += use_system_libvpx=1
+contains(WEBENGINE_CONFIG, use_system_icu): GYP_CONFIG += use_system_icu=1
+
!contains(QT_CONFIG, pulseaudio): GYP_CONFIG += use_pulseaudio=0
diff --git a/src/core/config/embedded_linux.pri b/src/core/config/embedded_linux.pri
index b645caa90..ffe530bc9 100644
--- a/src/core/config/embedded_linux.pri
+++ b/src/core/config/embedded_linux.pri
@@ -43,7 +43,6 @@ GYP_CONFIG += \
use_ozone=1 \
use_pango=0 \
use_system_fontconfig=1 \
- use_system_icu=1 \
icu_use_data_file_flag=0 \
use_x11=0 \
v8_use_snapshot=false \
@@ -62,3 +61,5 @@ config_system_jsoncpp: GYP_CONFIG += use_system_jsoncpp=1
config_system_opus: GYP_CONFIG += use_system_opus=1
config_system_speex: GYP_CONFIG += use_system_speex=1
config_system_vpx: GYP_CONFIG += use_system_libvpx=1
+
+contains(WEBENGINE_CONFIG, use_system_icu): GYP_CONFIG += use_system_icu=1
diff --git a/src/core/gyp_run.pro b/src/core/gyp_run.pro
index 3f631302c..bb19a679d 100644
--- a/src/core/gyp_run.pro
+++ b/src/core/gyp_run.pro
@@ -85,7 +85,7 @@ cross_compile {
contains(QT_ARCH, "x86_64"): GYP_ARGS += "-D target_arch=x64"
contains(QT_ARCH, "i386"): GYP_ARGS += "-D target_arch=ia32"
-contains(WEBENGINE_CONFIG, proprietary_codecs): GYP_ARGS += "-Dproprietary_codecs=1 -Dffmpeg_branding=Chrome -Duse_system_ffmpeg=0"
+contains(WEBENGINE_CONFIG, use_proprietary_codecs): GYP_ARGS += "-Dproprietary_codecs=1 -Dffmpeg_branding=Chrome -Duse_system_ffmpeg=0"
!contains(QT_CONFIG, qt_framework): contains(QT_CONFIG, private_tests) {
GYP_ARGS += "-D qt_install_data=\"$$[QT_INSTALL_DATA/get]\""
diff --git a/tools/qmake/mkspecs/features/configure.prf b/tools/qmake/mkspecs/features/configure.prf
index 85c3d4634..d7add261b 100644
--- a/tools/qmake/mkspecs/features/configure.prf
+++ b/tools/qmake/mkspecs/features/configure.prf
@@ -51,3 +51,25 @@ defineTest(runConfigure) {
}
}
+# This is called from default_post, at which point we've also parsed
+# command line options
+defineTest(finalizeConfigure) {
+ linux {
+ contains(WEBENGINE_CONFIG, use_system_icu) {
+ packagesExist("icu-uc icu-i18n") {
+ log("ICU............................... Using system version$${EOL}")
+ } else {
+ log("ICU............................... System ICU not found$${EOL}")
+ skipBuild("Unmet dependencies: icu-uc, icu-i18n")
+ }
+ } else {
+ log("ICU............................... Using internal copy (Default, force system ICU with WEBENGINE_CONFIG += use_system_icu)$${EOL}")
+ }
+ }
+ contains(WEBENGINE_CONFIG, use_proprietary_codecs) {
+ log("Proprietary codecs (H264, MP3).... Enabled$${EOL}")
+ } else {
+ log("Proprietary codecs (H264, MP3).... Not enabled (Default, enable with WEBENGINE_CONFIG += use_proprietary_codecs)$${EOL}")
+ }
+}
+
diff --git a/tools/qmake/mkspecs/features/default_post.prf b/tools/qmake/mkspecs/features/default_post.prf
index d09ba05fd..64e8cb1fe 100644
--- a/tools/qmake/mkspecs/features/default_post.prf
+++ b/tools/qmake/mkspecs/features/default_post.prf
@@ -1,4 +1,7 @@
load(default_post)
+load(functions)
+
+root_project_file:isPlatformSupported(): finalizeConfigure()
!isEmpty(skipBuildReason) {
SUBDIRS =
diff --git a/tools/qmake/mkspecs/features/default_pre.prf b/tools/qmake/mkspecs/features/default_pre.prf
index 2e556c2a6..6506e67ad 100644
--- a/tools/qmake/mkspecs/features/default_pre.prf
+++ b/tools/qmake/mkspecs/features/default_pre.prf
@@ -16,7 +16,9 @@ load(default_pre)
load(functions)
# Check platform support and run config tests early enough to bail
-equals(_PRO_FILE_, "$$QTWEBENGINE_ROOT/qtwebengine.pro"): isPlatformSupported() {
+equals(_PRO_FILE_, "$$QTWEBENGINE_ROOT/qtwebengine.pro"): CONFIG += root_project_file
+
+root_project_file:isPlatformSupported() {
load(configure)
runConfigure()
}