##// END OF EJS Templates
Adds release debug direcotires to bin lib
Michal Klocek -
r1978:1592e9b9bba3
parent child
Show More
@@ -1,102 +1,118
1 ##################### LIB #################################################
1 ##################### LIB #################################################
2
2
3 LIBRARY_NAME = QtCommercialChart
3 LIBRARY_NAME = QtCommercialChart
4 CONFIG(debug, debug|release) {
4 CONFIG(debug, debug|release) {
5 mac: LIBRARY_NAME = $$join(LIBRARY_NAME,,,_debug)
5 mac: LIBRARY_NAME = $$join(LIBRARY_NAME,,,_debug)
6 win32: LIBRARY_NAME = $$join(LIBRARY_NAME,,,d)
6 win32: LIBRARY_NAME = $$join(LIBRARY_NAME,,,d)
7 }
7 }
8
8
9 LIBS += -l$$LIBRARY_NAME
9 LIBS += -l$$LIBRARY_NAME
10
10
11 # This will undefine Q_DECL_EXPORT/Q_DECL_IMPORT at qchartglobal.h
11 # This will undefine Q_DECL_EXPORT/Q_DECL_IMPORT at qchartglobal.h
12 # They should not be used for staticlib builds.
12 # They should not be used for staticlib builds.
13 staticlib:DEFINES+=QTCOMMERCIALCHART_STATICLIB
13 staticlib:DEFINES+=QTCOMMERCIALCHART_STATICLIB
14
14
15 ##################### SHADOW CONFIG #################################################
15 ##################### SHADOW CONFIG #################################################
16
16
17 !contains($${PWD}, $${OUT_PWD}){
17 !contains($${PWD}, $${OUT_PWD}){
18 search = "$$PWD:::"
18 search = "$$PWD:::"
19 temp = $$split(search,"/")
19 temp = $$split(search,"/")
20 temp = $$last(temp)
20 temp = $$last(temp)
21 path = $$replace(search,$$temp,'')
21 path = $$replace(search,$$temp,'')
22 temp = $$split(OUT_PWD,$$path)
22 temp = $$split(OUT_PWD,$$path)
23 temp = $$split(temp,'/')
23 temp = $$split(temp,'/')
24 temp = $$first(temp)
24 temp = $$first(temp)
25 path = "$${path}$${temp}"
25 path = "$${path}$${temp}"
26 SHADOW=$$path
26 SHADOW=$$path
27 }else{
27 }else{
28 SHADOW=$$PWD
28 SHADOW=$$PWD
29 CONFIG-=development_build
29 CONFIG-=development_build
30 }
30 }
31
31
32 ##################### BUILD PATHS ##################################################
32 ##################### BUILD PATHS ##################################################
33
33
34 CHART_BUILD_PUBLIC_HEADER_DIR = $$SHADOW/include
34 CHART_BUILD_PUBLIC_HEADER_DIR = $$SHADOW/include
35 CHART_BUILD_PRIVATE_HEADER_DIR = $$CHART_BUILD_PUBLIC_HEADER_DIR/private
35 CHART_BUILD_PRIVATE_HEADER_DIR = $$CHART_BUILD_PUBLIC_HEADER_DIR/private
36 CHART_BUILD_LIB_DIR = $$SHADOW/lib
36 CHART_BUILD_LIB_DIR = $$SHADOW/lib
37 CHART_BUILD_DIR = $$SHADOW/build
37 CHART_BUILD_DIR = $$SHADOW/build
38 CHART_BUILD_BIN_DIR = $$SHADOW/bin
38 CHART_BUILD_BIN_DIR = $$SHADOW/bin
39 CHART_BUILD_PLUGIN_DIR = $$CHART_BUILD_BIN_DIR/QtCommercial/Chart
39 CHART_BUILD_QML_PLUGIN_DIR = $$CHART_BUILD_BIN_DIR
40 CHART_BUILD_DESIGNER_PLUGIN_DIR = $$CHART_BUILD_LIB_DIR
40 CHART_BUILD_DOC_DIR = $$SHADOW/doc
41 CHART_BUILD_DOC_DIR = $$SHADOW/doc
41
42
43 CONFIG(release,debug|release){
44 CHART_BUILD_LIB_DIR = $$CHART_BUILD_LIB_DIR/release
45 CHART_BUILD_BIN_DIR = $$CHART_BUILD_BIN_DIR/release
46 CHART_BUILD_QML_PLUGIN_DIR = $$CHART_BUILD_QML_PLUGIN_DIR/release/QtCommercial/Chart
47 CHART_BUILD_DESIGNER_PLUGIN_DIR = $$CHART_BUILD_LIB_DIR
48 }
49
50
51 CONFIG(debug,debug|release){
52 CHART_BUILD_LIB_DIR = $$CHART_BUILD_LIB_DIR/debug
53 CHART_BUILD_BIN_DIR = $$CHART_BUILD_BIN_DIR/debug
54 CHART_BUILD_QML_PLUGIN_DIR = $$CHART_BUILD_QML_PLUGIN_DIR/debug/QtCommercial/Chart
55 CHART_BUILD_DESIGNER_PLUGIN_DIR = $$CHART_BUILD_LIB_DIR
56 }
42 # Use own folders for debug and release builds
57 # Use own folders for debug and release builds
43
58
44 CONFIG(debug, debug|release):CHART_BUILD_DIR = $$join(CHART_BUILD_DIR,,,/debug)
59 CONFIG(debug, debug|release):CHART_BUILD_DIR = $$join(CHART_BUILD_DIR,,,/debug)
45 CONFIG(release, debug|release): CHART_BUILD_DIR = $$join(CHART_BUILD_DIR,,,/release)
60 CONFIG(release, debug|release): CHART_BUILD_DIR = $$join(CHART_BUILD_DIR,,,/release)
46
61
47
62
48 win32:{
63 win32:{
49 CHART_BUILD_PUBLIC_HEADER_DIR = $$replace(CHART_BUILD_PUBLIC_HEADER_DIR, "/","\\")
64 CHART_BUILD_PUBLIC_HEADER_DIR = $$replace(CHART_BUILD_PUBLIC_HEADER_DIR, "/","\\")
50 CHART_BUILD_PRIVATE_HEADER_DIR = $$replace(CHART_BUILD_PRIVATE_HEADER_DIR, "/","\\")
65 CHART_BUILD_PRIVATE_HEADER_DIR = $$replace(CHART_BUILD_PRIVATE_HEADER_DIR, "/","\\")
51 CHART_BUILD_BUILD_DIR = $$replace(CHART_BUILD_BUILD_DIR, "/","\\")
66 CHART_BUILD_BUILD_DIR = $$replace(CHART_BUILD_BUILD_DIR, "/","\\")
52 CHART_BUILD_BIN_DIR = $$replace(CHART_BUILD_BIN_DIR, "/","\\")
67 CHART_BUILD_BIN_DIR = $$replace(CHART_BUILD_BIN_DIR, "/","\\")
53 CHART_BUILD_PLUGIN_DIR = $$replace(CHART_BUILD_PLUGIN_DIR, "/","\\")
68 CHART_BUILD_QML_PLUGIN_DIR = $$replace(CHART_BUILD_QML_PLUGIN_DIR, "/","\\")
69 CHART_BUILD_DESIGNER_PLUGIN_DIR = $$replace(CHART_BUILD_DESIGNER_PLUGIN_DIR, "/","\\")
54 CHART_BUILD_DOC_DIR = $$replace(CHART_BUILD_DOC_DIR, "/","\\")
70 CHART_BUILD_DOC_DIR = $$replace(CHART_BUILD_DOC_DIR, "/","\\")
55 CHART_BUILD_LIB_DIR = $$replace(CHART_BUILD_LIB_DIR, "/","\\")
71 CHART_BUILD_LIB_DIR = $$replace(CHART_BUILD_LIB_DIR, "/","\\")
56 }
72 }
57
73
58 mac: {
74 mac: {
59 # Some Qt versions use an incompatible configuration on OSX which makes the build fail.
75 # Some Qt versions use an incompatible configuration on OSX which makes the build fail.
60 # As a work-around, set the minimum OSX version to 10.5.
76 # As a work-around, set the minimum OSX version to 10.5.
61 QMAKE_CXXFLAGS *= -mmacosx-version-min=10.5
77 QMAKE_CXXFLAGS *= -mmacosx-version-min=10.5
62 QMAKE_LFLAGS *= -mmacosx-version-min=10.5
78 QMAKE_LFLAGS *= -mmacosx-version-min=10.5
63 }
79 }
64
80
65 linux-arm*: {
81 linux-arm*: {
66 DEFINES+=QT_ON_ARM
82 DEFINES+=QT_ON_ARM
67 }
83 }
68
84
69 ##################### INCLUDES ############################################################
85 ##################### INCLUDES ############################################################
70
86
71
87
72 INCLUDEPATH += $$CHART_BUILD_PUBLIC_HEADER_DIR
88 INCLUDEPATH += $$CHART_BUILD_PUBLIC_HEADER_DIR
73
89
74 !win32: {
90 !win32: {
75 LIBS += -L$$CHART_BUILD_LIB_DIR -Wl,-rpath,$$CHART_BUILD_LIB_DIR
91 LIBS += -L$$CHART_BUILD_LIB_DIR -Wl,-rpath,$$CHART_BUILD_LIB_DIR
76 } else {
92 } else {
77 win32-msvc*: {
93 win32-msvc*: {
78 # hack fix for error:
94 # hack fix for error:
79 # "LINK : fatal error LNK1146: no argument specified with option '/LIBPATH:'"
95 # "LINK : fatal error LNK1146: no argument specified with option '/LIBPATH:'"
80 QMAKE_LIBDIR += $$CHART_BUILD_LIB_DIR
96 QMAKE_LIBDIR += $$CHART_BUILD_LIB_DIR
81 } else {
97 } else {
82 LIBS += -L$$CHART_BUILD_LIB_DIR
98 LIBS += -L$$CHART_BUILD_LIB_DIR
83 }
99 }
84 }
100 }
85
101
86 ##################### DEVELOPMENT BUILD ###################################################
102 ##################### DEVELOPMENT BUILD ###################################################
87
103
88 development_build: {
104 development_build: {
89 DEFINES+=DEVELOPMENT_BUILD
105 DEFINES+=DEVELOPMENT_BUILD
90 CONFIG+=debug_and_release
106 CONFIG+=debug_and_release
91 CONFIG+=build_all
107 CONFIG+=build_all
92 }
108 }
93
109
94 #################### COVERAGE #################################################################
110 #################### COVERAGE #################################################################
95 coverage: CONFIG += debug
111 coverage: CONFIG += debug
96
112
97 ##################### UNIT TESTS ##############################################################
113 ##################### UNIT TESTS ##############################################################
98
114
99 CONFIG(debug, debug|release) {
115 CONFIG(debug, debug|release) {
100 DEFINES+=BUILD_PRIVATE_UNIT_TESTS
116 DEFINES+=BUILD_PRIVATE_UNIT_TESTS
101 }
117 }
102
118
@@ -1,49 +1,50
1 TARGET = qtcommercialchartqml
2 QT += declarative
3
4 !include( ../plugins.pri ) {
1 !include( ../plugins.pri ) {
5 error( "Couldn't find the plugins.pri file!" )
2 error( "Couldn't find the plugins.pri file!" )
6 }
3 }
4
5 TARGET = qtcommercialchartqml
6 QT += declarative
7 DESTDIR = $$CHART_BUILD_QML_PLUGIN_DIR
7 INCLUDEPATH += $$CHART_BUILD_PRIVATE_HEADER_DIR
8 INCLUDEPATH += $$CHART_BUILD_PRIVATE_HEADER_DIR
8
9
9 CONFIG(debug, debug|release) {
10 CONFIG(debug, debug|release) {
10 mac: TARGET = $$join(TARGET,,,_debug)
11 mac: TARGET = $$join(TARGET,,,_debug)
11 win32: TARGET = $$join(TARGET,,,d)
12 win32: TARGET = $$join(TARGET,,,d)
12 }
13 }
13
14
14 SOURCES += \
15 SOURCES += \
15 plugin.cpp \
16 plugin.cpp \
16 declarativechart.cpp \
17 declarativechart.cpp \
17 declarativexypoint.cpp \
18 declarativexypoint.cpp \
18 declarativexyseries.cpp \
19 declarativexyseries.cpp \
19 declarativelineseries.cpp \
20 declarativelineseries.cpp \
20 declarativesplineseries.cpp \
21 declarativesplineseries.cpp \
21 declarativeareaseries.cpp \
22 declarativeareaseries.cpp \
22 declarativescatterseries.cpp \
23 declarativescatterseries.cpp \
23 declarativepieseries.cpp \
24 declarativepieseries.cpp \
24 declarativebarseries.cpp \
25 declarativebarseries.cpp \
25 declarativecategoryaxis.cpp \
26 declarativecategoryaxis.cpp \
26 declarativemargins.cpp
27 declarativemargins.cpp
27
28
28 HEADERS += \
29 HEADERS += \
29 declarativechart.h \
30 declarativechart.h \
30 declarativexypoint.h \
31 declarativexypoint.h \
31 declarativexyseries.h \
32 declarativexyseries.h \
32 declarativelineseries.h \
33 declarativelineseries.h \
33 declarativesplineseries.h \
34 declarativesplineseries.h \
34 declarativeareaseries.h \
35 declarativeareaseries.h \
35 declarativescatterseries.h \
36 declarativescatterseries.h \
36 declarativepieseries.h \
37 declarativepieseries.h \
37 declarativebarseries.h \
38 declarativebarseries.h \
38 declarativecategoryaxis.h \
39 declarativecategoryaxis.h \
39 declarativemargins.h
40 declarativemargins.h
40
41
41 TARGETPATH = QtCommercial/Chart
42 TARGETPATH = QtCommercial/Chart
42 target.path = $$[QT_INSTALL_IMPORTS]/$$TARGETPATH
43 target.path = $$[QT_INSTALL_IMPORTS]/$$TARGETPATH
43 qmldir.files += $$PWD/qmldir
44 qmldir.files += $$PWD/qmldir
44 qmldir.path += $$[QT_INSTALL_IMPORTS]/$$TARGETPATH
45 qmldir.path += $$[QT_INSTALL_IMPORTS]/$$TARGETPATH
45 INSTALLS += target qmldir
46 INSTALLS += target qmldir
46
47
47 FILE = $$PWD/qmldir
48 FILE = $$PWD/qmldir
48 win32:{FILE = $$replace(FILE, "/","\\")}
49 win32:{FILE = $$replace(FILE, "/","\\")}
49 QMAKE_POST_LINK += $$QMAKE_COPY $$FILE $$CHART_BUILD_PLUGIN_DIR
50 QMAKE_POST_LINK += $$QMAKE_COPY $$FILE $$CHART_BUILD_QML_PLUGIN_DIR
@@ -1,13 +1,13
1 TARGET=qtcommercialchartdesigner
2
3 !include( ../plugins.pri ) {
1 !include( ../plugins.pri ) {
4 error( "Couldn't find the plugins.pri file!" )
2 error( "Couldn't find the plugins.pri file!" )
5 }
3 }
6
4
5 TARGET=qtcommercialchartdesigner
6 DESTDIR = $$CHART_BUILD_DESIGNER_PLUGIN_DIR
7 CONFIG += designer
7 CONFIG += designer
8 HEADERS = qchartsplugin.h
8 HEADERS = qchartsplugin.h
9 SOURCES = qchartsplugin.cpp
9 SOURCES = qchartsplugin.cpp
10 RESOURCES = qchartsplugin.qrc
10 RESOURCES = qchartsplugin.qrc
11
11
12 target.path = $$[QT_INSTALL_PLUGINS]/designer
12 target.path = $$[QT_INSTALL_PLUGINS]/designer
13 INSTALLS += target No newline at end of file
13 INSTALLS += target
@@ -1,16 +1,14
1 !include( ../config.pri ) {
1 !include( ../config.pri ) {
2 error( "Couldn't find the config.pri file!" )
2 error( "Couldn't find the config.pri file!" )
3 }
3 }
4
4
5 TEMPLATE = lib
5 TEMPLATE = lib
6
6
7 CONFIG+= plugin
7 CONFIG+= plugin
8
9 DESTDIR = $$CHART_BUILD_PLUGIN_DIR
10 OBJECTS_DIR = $$CHART_BUILD_DIR/plugins/$$TARGET
8 OBJECTS_DIR = $$CHART_BUILD_DIR/plugins/$$TARGET
11 MOC_DIR = $$CHART_BUILD_DIR/plugins/$$TARGET
9 MOC_DIR = $$CHART_BUILD_DIR/plugins/$$TARGET
12 UI_DIR = $$CHART_BUILD_DIR/plugins/$$TARGET
10 UI_DIR = $$CHART_BUILD_DIR/plugins/$$TARGET
13 RCC_DIR = $$CHART_BUILD_DIR/plugins/$$TARGET
11 RCC_DIR = $$CHART_BUILD_DIR/plugins/$$TARGET
14
12
15 # staticlib config causes problems when building executables
13 # staticlib config causes problems when building executables
16 staticlib: CONFIG-=staticlib
14 staticlib: CONFIG-=staticlib
General Comments 0
You need to be logged in to leave comments. Login now