Turn on PCH on mac os x.
--HG-- branch : develop
This commit is contained in:
parent
dc0344bbea
commit
7038c25c39
29
common.pri
29
common.pri
|
@ -13,6 +13,11 @@ win32{
|
|||
QMAKE_INSTALL_PROGRAM = xcopy /y
|
||||
}
|
||||
|
||||
macx{
|
||||
# QTBUG-31034 qmake doesn't allow override QMAKE_CXX
|
||||
CONFIG+=no_ccache
|
||||
}
|
||||
|
||||
CONFIG(release, debug|release){
|
||||
!noDebugSymbols:win32:!win32-msvc*{
|
||||
unset(QMAKE_STRIP)
|
||||
|
@ -100,20 +105,16 @@ defineTest(forceCopyToDestdir) {
|
|||
|
||||
# We use precompiled headers for more fast compilation source code.
|
||||
defineReplace(set_PCH){
|
||||
unix:no_ccache|win32{
|
||||
macx:clang*{
|
||||
# Precompiled headers don't work with clang on macx.
|
||||
} else {
|
||||
CONFIG += precompile_header # Turn on creation precompiled headers (PCH).
|
||||
export(CONFIG) # export value to global variable.
|
||||
no_ccache{
|
||||
CONFIG += precompile_header # Turn on creation precompiled headers (PCH).
|
||||
export(CONFIG) # export value to global variable.
|
||||
|
||||
PRECOMPILED_HEADER = stable.h # Header file with all all static headers: libraries, static local headers.
|
||||
export(PRECOMPILED_HEADER) # export value to global variable
|
||||
PRECOMPILED_HEADER = stable.h # Header file with all all static headers: libraries, static local headers.
|
||||
export(PRECOMPILED_HEADER) # export value to global variable
|
||||
|
||||
win32-msvc* {
|
||||
PRECOMPILED_SOURCE = stable.cpp # MSVC need also cpp file.
|
||||
export(PRECOMPILED_SOURCE) # export value to global variable.
|
||||
}
|
||||
win32-msvc* {
|
||||
PRECOMPILED_SOURCE = stable.cpp # MSVC need also cpp file.
|
||||
export(PRECOMPILED_SOURCE) # export value to global variable.
|
||||
}
|
||||
}
|
||||
return(true)
|
||||
|
@ -121,7 +122,7 @@ defineReplace(set_PCH){
|
|||
|
||||
defineReplace(enable_ccache){
|
||||
no_ccache{ # For enable run qmake with CONFIG+=no_ccache
|
||||
# do nothing
|
||||
$$set_PCH()
|
||||
} else {
|
||||
# ccache support only Unix systems.
|
||||
unix:{
|
||||
|
@ -140,6 +141,8 @@ defineReplace(enable_ccache){
|
|||
QMAKE_CXX = ccache clang++
|
||||
export(QMAKE_CXX) # export value to global variable.
|
||||
}
|
||||
} else {
|
||||
$$set_PCH()
|
||||
}
|
||||
}
|
||||
return(true)
|
||||
|
|
|
@ -59,16 +59,7 @@ OTHER_FILES += \
|
|||
$$DATA_RESOURCE
|
||||
|
||||
# Set using ccache. Function enable_ccache() defined in common.pri.
|
||||
macx {
|
||||
CONFIG(debug, debug|release){
|
||||
$$enable_ccache()# Use only in debug mode on Mac
|
||||
}
|
||||
} else {
|
||||
$$enable_ccache()
|
||||
}
|
||||
|
||||
# Set precompiled headers. Function set_PCH() defined in common.pri.
|
||||
$$set_PCH()
|
||||
$$enable_ccache()
|
||||
|
||||
CONFIG(debug, debug|release){
|
||||
# Debug mode
|
||||
|
|
|
@ -57,16 +57,8 @@ OTHER_FILES += \
|
|||
share/resources/icon/64x64/icon64x64.ico # Valentina's logo.
|
||||
|
||||
# Set using ccache. Function enable_ccache() defined in common.pri.
|
||||
macx {
|
||||
CONFIG(debug, debug|release){
|
||||
$$enable_ccache()# Use only in debug mode on Mac
|
||||
}
|
||||
} else {
|
||||
$$enable_ccache()
|
||||
}
|
||||
$$enable_ccache()
|
||||
|
||||
# Set precompiled headers. Function set_PCH() defined in common.pri.
|
||||
$$set_PCH()
|
||||
|
||||
CONFIG(debug, debug|release){
|
||||
# Debug mode
|
||||
|
|
|
@ -53,9 +53,6 @@ RESOURCES += \
|
|||
# Set using ccache. Function enable_ccache() defined in common.pri.
|
||||
$$enable_ccache()
|
||||
|
||||
# Set precompiled headers. Function set_PCH() defined in common.pri.
|
||||
$$set_PCH()
|
||||
|
||||
CONFIG(debug, debug|release){
|
||||
# Debug mode
|
||||
unix {
|
||||
|
|
|
@ -62,9 +62,6 @@ unix:!macx{
|
|||
# Set using ccache. Function enable_ccache() defined in common.pri.
|
||||
$$enable_ccache()
|
||||
|
||||
# Set precompiled headers. Function set_PCH() defined in common.pri.
|
||||
$$set_PCH()
|
||||
|
||||
CONFIG(debug, debug|release){
|
||||
# Debug mode
|
||||
unix {
|
||||
|
|
|
@ -40,9 +40,6 @@ OBJECTS_DIR = obj
|
|||
# Set using ccache. Function enable_ccache() defined in common.pri.
|
||||
$$enable_ccache()
|
||||
|
||||
# Set precompiled headers. Function set_PCH() defined in common.pri.
|
||||
$$set_PCH()
|
||||
|
||||
CONFIG(debug, debug|release){
|
||||
# Debug mode
|
||||
unix {
|
||||
|
|
|
@ -46,9 +46,6 @@ OBJECTS_DIR = obj
|
|||
# Set using ccache. Function enable_ccache() defined in common.pri.
|
||||
$$enable_ccache()
|
||||
|
||||
# Set precompiled headers. Function set_PCH() defined in common.pri.
|
||||
$$set_PCH()
|
||||
|
||||
CONFIG(debug, debug|release){
|
||||
# Debug mode
|
||||
unix {
|
||||
|
|
|
@ -40,9 +40,6 @@ OBJECTS_DIR = obj
|
|||
# Set using ccache. Function enable_ccache() defined in common.pri.
|
||||
$$enable_ccache()
|
||||
|
||||
# Set precompiled headers. Function set_PCH() defined in common.pri.
|
||||
$$set_PCH()
|
||||
|
||||
CONFIG(debug, debug|release){
|
||||
# Debug mode
|
||||
unix {
|
||||
|
|
|
@ -45,9 +45,6 @@ RCC_DIR = rcc
|
|||
# Set using ccache. Function enable_ccache() defined in common.pri.
|
||||
$$enable_ccache()
|
||||
|
||||
# Set precompiled headers. Function set_PCH() defined in common.pri.
|
||||
$$set_PCH()
|
||||
|
||||
CONFIG(debug, debug|release){
|
||||
# Debug mode
|
||||
unix {
|
||||
|
|
|
@ -48,9 +48,6 @@ OBJECTS_DIR = obj
|
|||
# Set using ccache. Function enable_ccache() defined in common.pri.
|
||||
$$enable_ccache()
|
||||
|
||||
# Set precompiled headers. Function set_PCH() defined in common.pri.
|
||||
$$set_PCH()
|
||||
|
||||
CONFIG(debug, debug|release){
|
||||
# Debug mode
|
||||
unix {
|
||||
|
|
|
@ -40,9 +40,6 @@ OBJECTS_DIR = obj
|
|||
# Set using ccache. Function enable_ccache() defined in common.pri.
|
||||
$$enable_ccache()
|
||||
|
||||
# Set precompiled headers. Function set_PCH() defined in common.pri.
|
||||
$$set_PCH()
|
||||
|
||||
CONFIG(debug, debug|release){
|
||||
# Debug mode
|
||||
unix {
|
||||
|
|
|
@ -43,9 +43,6 @@ OBJECTS_DIR = obj
|
|||
# Set using ccache. Function enable_ccache() defined in common.pri.
|
||||
$$enable_ccache()
|
||||
|
||||
# Set precompiled headers. Function set_PCH() defined in common.pri.
|
||||
$$set_PCH()
|
||||
|
||||
CONFIG(debug, debug|release){
|
||||
# Debug mode
|
||||
unix {
|
||||
|
|
|
@ -60,9 +60,6 @@ unix:!macx{
|
|||
# Set using ccache. Function enable_ccache() defined in common.pri.
|
||||
$$enable_ccache()
|
||||
|
||||
# Set precompiled headers. Function set_PCH() defined in common.pri.
|
||||
$$set_PCH()
|
||||
|
||||
CONFIG(debug, debug|release){
|
||||
# Debug mode
|
||||
unix {
|
||||
|
|
|
@ -48,9 +48,6 @@ UI_DIR = uic
|
|||
# Set using ccache. Function enable_ccache() defined in common.pri.
|
||||
$$enable_ccache()
|
||||
|
||||
# Set precompiled headers. Function set_PCH() defined in common.pri.
|
||||
$$set_PCH()
|
||||
|
||||
INCLUDEPATH += $$PWD/../vpatterndb
|
||||
|
||||
CONFIG(debug, debug|release){
|
||||
|
|
|
@ -42,9 +42,6 @@ OBJECTS_DIR = obj
|
|||
# Set using ccache. Function enable_ccache() defined in common.pri.
|
||||
$$enable_ccache()
|
||||
|
||||
# Set precompiled headers. Function set_PCH() defined in common.pri.
|
||||
$$set_PCH()
|
||||
|
||||
CONFIG(debug, debug|release){
|
||||
# Debug mode
|
||||
unix {
|
||||
|
|
|
@ -48,9 +48,6 @@ SOURCES += \
|
|||
# Set using ccache. Function enable_ccache() defined in common.pri.
|
||||
$$enable_ccache()
|
||||
|
||||
# Set precompiled headers. Function set_PCH() defined in common.pri.
|
||||
$$set_PCH()
|
||||
|
||||
CONFIG(debug, debug|release){
|
||||
# Debug mode
|
||||
unix {
|
||||
|
|
|
@ -75,9 +75,6 @@ HEADERS += \
|
|||
# Set using ccache. Function enable_ccache() defined in common.pri.
|
||||
$$enable_ccache()
|
||||
|
||||
# Set precompiled headers. Function set_PCH() defined in common.pri.
|
||||
$$set_PCH()
|
||||
|
||||
CONFIG(debug, debug|release){
|
||||
# Debug mode
|
||||
unix {
|
||||
|
|
Loading…
Reference in New Issue
Block a user