diff options
author | Allan Sandfeld Jensen <allan.jensen@theqtcompany.com> | 2015-10-14 12:29:28 +0200 |
---|---|---|
committer | Allan Sandfeld Jensen <allan.jensen@theqtcompany.com> | 2015-10-14 12:29:54 +0200 |
commit | 9be23eb946580519b2b0600cc854ec8050b90659 (patch) | |
tree | 63ccf0e565f346a0788d937b004e01d2ec029b5e /tools/qmake/mkspecs/features/functions.prf | |
parent | 4f2e66f9d898e9c11a7ad6e552d0d47bb15d4051 (diff) | |
parent | 981e38d2dc82c047c6ad8ec19427d3ac7434dc3c (diff) |
Merge remote-tracking branch 'origin/5.6' into devwip/47-based
Change-Id: I0569b04ced3456a1d5d91e02e117963115fcf1b2
Diffstat (limited to 'tools/qmake/mkspecs/features/functions.prf')
-rw-r--r-- | tools/qmake/mkspecs/features/functions.prf | 22 |
1 files changed, 17 insertions, 5 deletions
diff --git a/tools/qmake/mkspecs/features/functions.prf b/tools/qmake/mkspecs/features/functions.prf index c0e1f90bb..99f60d0e5 100644 --- a/tools/qmake/mkspecs/features/functions.prf +++ b/tools/qmake/mkspecs/features/functions.prf @@ -22,11 +22,18 @@ defineTest(isPlatformSupported) { } defineTest(isPythonVersionSupported) { - python_major_version = $$system('python -c "import sys; print sys.version_info.major"') - python_minor_version = $$system('python -c "import sys; print sys.version_info.minor"') - lessThan(python_major_version, 3): greaterThan(python_major_version, 1): greaterThan(python_minor_version, 6): return(true) - skipBuild("Using Python version "$$python_major_version"."$$python_minor_version", but Python version 2 (2.7 or later) is required to build Qt WebEngine.") - return(false) + python_error_msg = "Python version 2 (2.7 or later) is required to build Qt WebEngine." + python_major_version = $$system('python -c "import sys; print(sys.version_info[0])"') + greaterThan(python_major_version, 2) { + skipBuild("Python version 3 is not supported by Chromium.") + skipBuild($$python_error_msg) + return(false) + } + python_minor_version = $$system('python -c "import sys; print(sys.version_info[1])"') + greaterThan(python_major_version, 1): greaterThan(python_minor_version, 6): return(true) + skipBuild("Using Python version "$$python_major_version"."$$python_minor_version".") + skipBuild($$python_error_msg) + return(false) } defineTest(isGCCVersionSupported) { @@ -142,6 +149,11 @@ defineReplace(which) { return($$out) } +defineTest(use?) { + contains(WEBENGINE_CONFIG, use_$$lower($$1)): return(true) + return(false) +} + defineReplace(findOrBuildNinja) { # If NINJA_PATH env var is set, prefer that. # Fallback to locating our own bootstrapped ninja. |