use the new "stash" instead of the (anything but) "regular" cache

as this new cache category comes without side effects, we can
unconditionally create a cache whereever we are. this allows us to be
performant without explicit user action.

Task-number: QTBUG-31340
Change-Id: I6b88b20b61e8351aa8cbf94ad3eec65adac6e1d6
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
This commit is contained in:
Oswald Buddenhagen 2013-10-31 20:27:54 +01:00 committed by The Qt Project
parent ff31d87cc8
commit 53280989fb
2 changed files with 5 additions and 10 deletions

View File

@ -19,13 +19,8 @@ qt:!isEmpty(QT_CONFIG) {
contains(QT_CONFIG, static):contains(QT_CONFIG, c++11): CONFIG += c++11
}
isEmpty(_QMAKE_CACHE_) {
warning("No .qmake.cache is present. This significantly slows down qmake with this makespec.")
warning("Call 'cache()' in the top-level project file to rectify this problem.")
} else {
cache(QMAKE_XCODE_DEVELOPER_PATH)
cache(QMAKE_XCODE_VERSION)
}
cache(QMAKE_XCODE_DEVELOPER_PATH, stash)
cache(QMAKE_XCODE_VERSION, stash)
QMAKE_XCODE_LIBRARY_SUFFIX = $$qtPlatformTargetSuffix()

View File

@ -8,7 +8,7 @@ contains(QMAKE_MAC_SDK, .*/.*): \
isEmpty(QMAKE_MAC_SDK.$${QMAKE_MAC_SDK}.path) {
QMAKE_MAC_SDK_PATH = $$system("/usr/bin/xcodebuild -sdk $$QMAKE_MAC_SDK -version Path 2>/dev/null")
isEmpty(QMAKE_MAC_SDK_PATH): error("Could not resolve SDK path for \'$$QMAKE_MAC_SDK\'")
!isEmpty(_QMAKE_CACHE_): cache(QMAKE_MAC_SDK.$${QMAKE_MAC_SDK}.path, set, QMAKE_MAC_SDK_PATH)
cache(QMAKE_MAC_SDK.$${QMAKE_MAC_SDK}.path, set stash, QMAKE_MAC_SDK_PATH)
} else {
QMAKE_MAC_SDK_PATH = $$eval(QMAKE_MAC_SDK.$${QMAKE_MAC_SDK}.path)
}
@ -41,7 +41,7 @@ for(tool, $$list(QMAKE_CC QMAKE_CXX QMAKE_FIX_RPATH QMAKE_AR QMAKE_RANLIB QMAKE_
isEmpty(sysrooted): next()
$$tool = $$sysrooted $$member(value, 1, -1)
!isEmpty(_QMAKE_CACHE_): cache($$tool_variable, set, $$tool)
cache($$tool_variable, set stash, $$tool)
}
isEmpty(QMAKE_MAC_SDK.$${QMAKE_MAC_SDK}.platform_name) {
@ -52,7 +52,7 @@ isEmpty(QMAKE_MAC_SDK.$${QMAKE_MAC_SDK}.platform_name) {
"sed 's/.*Value: \\(.*\\)/\\1/'")
isEmpty(QMAKE_MAC_PLATFORM_NAME): error("Could not resolve platform name for SDK '$$QMAKE_MAC_SDK'")
!isEmpty(_QMAKE_CACHE_): cache(QMAKE_MAC_SDK.$${QMAKE_MAC_SDK}.platform_name, set, QMAKE_MAC_PLATFORM_NAME)
cache(QMAKE_MAC_SDK.$${QMAKE_MAC_SDK}.platform_name, set stash, QMAKE_MAC_PLATFORM_NAME)
} else {
QMAKE_MAC_PLATFORM_NAME = $$eval(QMAKE_MAC_SDK.$${QMAKE_MAC_SDK}.platform_name)
}