centralize detection of prefix builds
this makes the use sites more expressive Change-Id: Ib879de65d1cc26462fa61f5339e951f294515faf Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
This commit is contained in:
parent
8f61befb53
commit
f75e897519
@ -25,7 +25,7 @@ qml1_target: \
|
||||
else: \
|
||||
instbase = $$[QT_INSTALL_QML]
|
||||
|
||||
exists($$[QT_HOST_PREFIX]/.qmake.cache) {
|
||||
!prefix_build {
|
||||
# These bizarre rules copy the files to the qtbase build directory
|
||||
|
||||
defineReplace(qmlModStripSrcDir) {
|
||||
|
@ -20,7 +20,10 @@
|
||||
debug(1, "Not loading qmodule.pri twice")
|
||||
}
|
||||
|
||||
!build_pass:!isEmpty(_QMAKE_SUPER_CACHE_):!exists($$[QT_HOST_DATA]/.qmake.cache) {
|
||||
!exists($$[QT_HOST_DATA]/.qmake.cache): \
|
||||
CONFIG += prefix_build
|
||||
|
||||
!build_pass:!isEmpty(_QMAKE_SUPER_CACHE_):prefix_build {
|
||||
# When doing a -prefix build of top-level qt5/qt.pro, we need to announce
|
||||
# this repo's module pris' location to the other repos.
|
||||
isEmpty(MODULE_QMAKE_OUTDIR): MODULE_QMAKE_OUTDIR = $$shadowed($$dirname(_QMAKE_CONF_))
|
||||
|
@ -16,8 +16,8 @@ isEmpty(MODULE_BASE_DIR): MODULE_BASE_DIR = $$MODULE_PROFILE_DIR
|
||||
isEmpty(MODULE_BASE_OUTDIR): MODULE_BASE_OUTDIR = $$shadowed($$MODULE_BASE_DIR)
|
||||
isEmpty(MODULE_QMAKE_OUTDIR): MODULE_QMAKE_OUTDIR = $$MODULE_BASE_OUTDIR
|
||||
|
||||
QTDIR = $$[QT_HOST_PREFIX]
|
||||
exists($$QTDIR/.qmake.cache) {
|
||||
!prefix_build {
|
||||
QTDIR = $$[QT_HOST_PREFIX]
|
||||
# Permit modules to enforce being built outside QTDIR ...
|
||||
!force_independent: MODULE_BASE_OUTDIR = $$QTDIR
|
||||
# ... though this sort of breaks the idea.
|
||||
|
@ -112,7 +112,7 @@ INCLUDEPATH *= $$eval(QT.$${MODULE}.includes) $$eval(QT.$${MODULE}.private_inclu
|
||||
#other
|
||||
TEMPLATE = lib
|
||||
DESTDIR = $$eval(QT.$${MODULE}.libs)
|
||||
win32:!wince*:exists($$[QT_INSTALL_PREFIX]/.qmake.cache): DLLDESTDIR = $$eval(QT.$${MODULE}.bins)
|
||||
win32:!wince*:!prefix_build: DLLDESTDIR = $$eval(QT.$${MODULE}.bins)
|
||||
|
||||
CONFIG += qmake_cache target_qt
|
||||
|
||||
|
@ -31,7 +31,7 @@ load(qt_targets)
|
||||
|
||||
# If we are doing a prefix build, create a "module" pri which enables
|
||||
# qtPrepareTool() to work with the non-installed build.
|
||||
!build_pass:!exists($$[QT_INSTALL_PREFIX]/.qmake.cache) {
|
||||
!build_pass:prefix_build {
|
||||
|
||||
isEmpty(MODULE):MODULE = $$TARGET
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user