@@ -1,31 +1,32 | |||
|
1 | 1 | !include(common.pri) { |
|
2 | 2 | error('missing common.pri') |
|
3 | 3 | } |
|
4 | 4 | |
|
5 | 5 | TEMPLATE = subdirs |
|
6 | 6 | SUBDIRS += src examples demos test qmlplugin |
|
7 | 7 | |
|
8 | 8 | integrated_build:{ |
|
9 | message('Configured for integrated build') | |
|
9 | message('Configured for integrated build against local libs...') | |
|
10 | 10 | } else { |
|
11 | message('Running build aginst system libs...') | |
|
11 | 12 | message('Please build example test and qmlplugin after installing library.') |
|
12 | 13 | } |
|
13 | 14 | |
|
14 | 15 | CONFIG += ordered |
|
15 | 16 | QMAKE_CXXFLAGS += -g -Wall |
|
16 | 17 | unix:QMAKE_DISTCLEAN += -r build bin include lib doc/html |
|
17 | 18 | win32:QMAKE_DISTCLEAN += /Q /s build bin include lib doc\\html |
|
18 | 19 | |
|
19 | 20 | # install feature file |
|
20 | 21 | feature.path = $$[QT_INSTALL_DATA]/mkspecs/features |
|
21 | 22 | feature.files = $$PWD/features/qtcommercialchart.prf |
|
22 | 23 | INSTALLS += feature |
|
23 | 24 | |
|
24 | 25 | doc.target = doc |
|
25 | 26 | win32:{ |
|
26 | 27 | doc.commands = qdoc3 $$CHART_BUILD_DOC_DIR\\qcharts.qdocconf |
|
27 | 28 | }else{ |
|
28 | 29 | doc.commands = qdoc3 $$CHART_BUILD_DOC_DIR/qcharts.qdocconf |
|
29 | 30 | } |
|
30 | 31 | doc.depends = FORCE |
|
31 | 32 | QMAKE_EXTRA_TARGETS += doc |
@@ -1,54 +1,49 | |||
|
1 | 1 | integrated_build:{ |
|
2 | message('Running integrated build against local libs...') | |
|
3 | 2 | INCLUDEPATH += $$CHART_BUILD_PUBLIC_HEADER_DIR |
|
4 | 3 | |
|
5 | 4 | !win32: { |
|
6 | 5 | LIBS += -L $$CHART_BUILD_LIB_DIR -Wl,-rpath,$$CHART_BUILD_LIB_DIR |
|
7 | 6 | }else{ |
|
8 | 7 | win32-msvc*: { |
|
9 | 8 | # hack fix for error: |
|
10 | 9 | # "LINK : fatal error LNK1146: no argument specified with option '/LIBPATH:'" |
|
11 | 10 | QMAKE_LIBDIR += $$CHART_BUILD_LIB_DIR |
|
12 | 11 | }else{ |
|
13 | 12 | LIBS += -L $$CHART_BUILD_LIB_DIR |
|
14 | 13 | } |
|
15 | 14 | } |
|
16 | 15 | |
|
17 | 16 | CONFIG(debug, debug|release) { |
|
18 | 17 | LIBS += -lQtCommercialChartd |
|
19 | 18 | #this is ugly hack to work around missing rpath, it simply copies lib |
|
20 | 19 | win32:{ |
|
21 | 20 | copylib.target = $$CHART_BUILD_BIN_DIR/QtCommercialChartd.dll |
|
22 | 21 | copylib.commands = $$QMAKE_COPY $$CHART_BUILD_LIB_DIR\\QtCommercialChartd.dll $$CHART_BUILD_BIN_DIR |
|
23 | 22 | copylib.depends = $$CHART_BUILD_LIB_DIR/QtCommercialChartd.dll |
|
24 | 23 | PRE_TARGETDEPS += $$CHART_BUILD_BIN_DIR/QtCommercialChartd.dll |
|
25 | 24 | QMAKE_EXTRA_TARGETS +=copylib |
|
26 | 25 | } |
|
27 | 26 | } else { |
|
28 | 27 | LIBS += -lQtCommercialChart |
|
29 | 28 | |
|
30 | 29 | #this is ugly hack to work around missing rpath, it simply copies lib |
|
31 | 30 | win32: { |
|
32 | 31 | copylib.target = $$CHART_BUILD_BIN_DIR/QtCommercialChart |
|
33 | 32 | copylib.commands = $$QMAKE_COPY $$CHART_BUILD_LIB_DIR\\QtCommercialChart.dll $$CHART_BUILD_BIN_DIR |
|
34 | 33 | copylib.depends = $$CHART_BUILD_LIB_DIR/QtCommercialChart.dll |
|
35 | 34 | PRE_TARGETDEPS += $$CHART_BUILD_BIN_DIR/QtCommercialChart |
|
36 | 35 | QMAKE_EXTRA_TARGETS +=copylib |
|
37 | 36 | } |
|
38 | 37 | } |
|
39 | 38 | |
|
40 | 39 | mac: { |
|
41 | 40 | # This is a hack to make binaries to use the internal version of the QtCommercial Charts library on OSX |
|
42 | QMAKE_POST_LINK += install_name_tool -change "libQtCommercialChartd.1.dylib" "@rpath/libQtCommercialChartd.dylib" $$CHART_BUILD_BIN_DIR/chartwidgettest.app/Contents/MacOS/chartwidgettest | |
|
43 |
QMAKE_POST_LINK |
|
|
44 | QMAKE_POST_LINK += && install_name_tool -change "libQtCommercialChartd.1.dylib" "@rpath/libQtCommercialChartd.dylib" $$CHART_BUILD_BIN_DIR/colorlineChart.app/Contents/MacOS/colorlineChart | |
|
45 | QMAKE_POST_LINK += && install_name_tool -change "libQtCommercialChartd.1.dylib" "@rpath/libQtCommercialChartd.dylib" $$CHART_BUILD_BIN_DIR/lineChart.app/Contents/MacOS/lineChart | |
|
46 | QMAKE_POST_LINK += && install_name_tool -change "libQtCommercialChartd.1.dylib" "@rpath/libQtCommercialChartd.dylib" $$CHART_BUILD_BIN_DIR/percentbarchart.app/Contents/MacOS/percentbarchart | |
|
47 | QMAKE_POST_LINK += && install_name_tool -change "libQtCommercialChartd.1.dylib" "@rpath/libQtCommercialChartd.dylib" $$CHART_BUILD_BIN_DIR/stackedbarchart.app/Contents/MacOS/stackedbarchart | |
|
48 | QMAKE_POST_LINK += && install_name_tool -change "libQtCommercialChartd.1.dylib" "@rpath/libQtCommercialChartd.dylib" $$CHART_BUILD_BIN_DIR/zoomLineChart.app/Contents/MacOS/zoomLineChart | |
|
41 | exists($$CHART_BUILD_BIN_DIR"/"$$TARGET".app/Contents/MacOS/"$$TARGET) { | |
|
42 | QMAKE_POST_LINK+=install_name_tool -change "libQtCommercialChartd.1.dylib" $$CHART_BUILD_LIB_DIR"/libQtCommercialChartd.dylib" $$CHART_BUILD_BIN_DIR"/"$$TARGET".app/Contents/MacOS/"$$TARGET | |
|
43 | message($$QMAKE_POST_LINK) | |
|
44 | } | |
|
49 | 45 | } |
|
50 | 46 | |
|
51 | 47 | } else { |
|
52 | message('Running build aginst system libs...') | |
|
53 | 48 | CONFIG+=qtcommercialchart |
|
54 | 49 | } |
General Comments 0
You need to be logged in to leave comments.
Login now