Add qt_common.prf and move some common definitions there

This file is now included by three types of Qt output: modules,
plugins (including QML plugins) and tools.

Change-Id: I5085f6ff37f70e9228303bf0520040adc2e2d7a5
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
This commit is contained in:
Thiago Macieira 2013-01-24 14:54:08 -08:00 committed by The Qt Project
parent 123ce761c0
commit bb6b2f4073
5 changed files with 24 additions and 11 deletions

View File

@ -50,6 +50,7 @@ INSTALLS += target
TARGET = $$qtLibraryTarget($$TARGET) TARGET = $$qtLibraryTarget($$TARGET)
load(qt_targets) load(qt_targets)
load(qt_common)
# plugins.qmltypes is used by Qt Creator for syntax highlighting and the QML code model. It needs # plugins.qmltypes is used by Qt Creator for syntax highlighting and the QML code model. It needs
# to be regenerated whenever the QML elements exported by the plugin change. This cannot be done # to be regenerated whenever the QML elements exported by the plugin change. This cannot be done

View File

@ -0,0 +1,20 @@
#
# W A R N I N G
# -------------
#
# This file is not part of the Qt API. It exists purely as an
# implementation detail. It may change from version to version
# without notice, or even be removed.
#
# We mean it.
#
contains(TEMPLATE, .*lib) {
# module and plugins
contains(QT_CONFIG, reduce_exports): CONFIG += hide_symbols
unix:contains(QT_CONFIG, reduce_relocations): CONFIG += bsymbolic_functions
contains(QT_CONFIG, largefile): CONFIG += largefile
contains(QT_CONFIG, separate_debug_info): CONFIG += separate_debug_info
contains(QT_CONFIG, separate_debug_info_nocopy): CONFIG += separate_debug_info_nocopy
contains(QT_CONFIG, c++11):CONFIG += c++11
}

View File

@ -73,13 +73,6 @@ contains(TARGET, QtAddOn.*): \
else: \ else: \
DEFINES += QT_BUILD_$${ucmodule}_LIB DEFINES += QT_BUILD_$${ucmodule}_LIB
contains(QT_CONFIG, reduce_exports):CONFIG += hide_symbols
unix:contains(QT_CONFIG, reduce_relocations):CONFIG += bsymbolic_functions
contains(QT_CONFIG, largefile):CONFIG += largefile
contains(QT_CONFIG, separate_debug_info):CONFIG += separate_debug_info
contains(QT_CONFIG, separate_debug_info_nocopy):CONFIG += separate_debug_info_nocopy
contains(QT_CONFIG, c++11):CONFIG += c++11
#mac frameworks #mac frameworks
mac:CONFIG(shared, static|shared):contains(QT_CONFIG, qt_framework) { mac:CONFIG(shared, static|shared):contains(QT_CONFIG, qt_framework) {
#QMAKE_FRAMEWORK_VERSION = 4.0 #QMAKE_FRAMEWORK_VERSION = 4.0
@ -168,6 +161,7 @@ win32 {
TARGET = $$qtLibraryTarget($$TARGET$$QT_LIBINFIX) #do this towards the end TARGET = $$qtLibraryTarget($$TARGET$$QT_LIBINFIX) #do this towards the end
load(qt_targets) load(qt_targets)
load(qt_common)
win32:DEFINES+=_USE_MATH_DEFINES win32:DEFINES+=_USE_MATH_DEFINES

View File

@ -23,10 +23,6 @@ tool_plugin {
contains(QT_CONFIG, debug_and_release):CONFIG += debug_and_release contains(QT_CONFIG, debug_and_release):CONFIG += debug_and_release
contains(QT_CONFIG, build_all):CONFIG += build_all contains(QT_CONFIG, build_all):CONFIG += build_all
} }
contains(QT_CONFIG, reduce_exports):CONFIG += hide_symbols
contains(QT_CONFIG, separate_debug_info):CONFIG += separate_debug_info
contains(QT_CONFIG, separate_debug_info_nocopy):CONFIG += separate_debug_info_nocopy
contains(QT_CONFIG, c++11):CONFIG += c++11
CONFIG(static, static|shared) { CONFIG(static, static|shared) {
isEmpty(MODULE): MODULE = $$basename(TARGET) isEmpty(MODULE): MODULE = $$basename(TARGET)
@ -52,6 +48,7 @@ INSTALLS += target
TARGET = $$qtLibraryTarget($$TARGET) TARGET = $$qtLibraryTarget($$TARGET)
load(qt_targets) load(qt_targets)
load(qt_common)
wince*:LIBS += $$QMAKE_LIBS_GUI wince*:LIBS += $$QMAKE_LIBS_GUI
QMAKE_LFLAGS += $$QMAKE_LFLAGS_NOUNDEF QMAKE_LFLAGS += $$QMAKE_LFLAGS_NOUNDEF

View File

@ -28,6 +28,7 @@ host_build {
INSTALLS += target INSTALLS += target
load(qt_targets) load(qt_targets)
load(qt_common)
# If we are doing a prefix build, create a "module" pri which enables # If we are doing a prefix build, create a "module" pri which enables
# qtPrepareTool() to work with the non-installed build. # qtPrepareTool() to work with the non-installed build.