mirror of
https://github.com/fralx/LimeReport.git
synced 2024-12-23 16:22:58 +03:00
Simplify .pro/.pri
This commit is contained in:
parent
d56fb6150c
commit
e96e1a9adc
@ -1,13 +1,13 @@
|
||||
DEFINES += NO_PNG
|
||||
TEMPLATE = lib
|
||||
|
||||
contains(CONFIG, static_build){
|
||||
CONFIG(static_build) {
|
||||
message(Static Build)
|
||||
CONFIG += staticlib
|
||||
DEFINES += QZINT_STATIC_BUILD
|
||||
}
|
||||
|
||||
!contains(CONFIG, staticlib){
|
||||
!CONFIG(staticlib) {
|
||||
CONFIG += dll
|
||||
DEFINES += QZINT_LIBRARY
|
||||
}
|
||||
|
52
common.pri
52
common.pri
@ -1,34 +1,44 @@
|
||||
# uncomment to disable translations
|
||||
#CONFIG += no_build_translations
|
||||
|
||||
# uncomment to disable zint
|
||||
#CONFIG += no_zint
|
||||
|
||||
# uncomment to disable svg
|
||||
#CONFIG += no_svg
|
||||
|
||||
# uncomment to enable easy_profiler
|
||||
#CONFIG *= easy_profiler
|
||||
|
||||
isEmpty(BINARY_RESULT_DIR) {
|
||||
BINARY_RESULT_DIR = $${PWD}
|
||||
}
|
||||
|
||||
!contains(CONFIG, no_build_translations){
|
||||
CONFIG += build_translations
|
||||
!CONFIG(no_build_translations) {
|
||||
CONFIG *= build_translations
|
||||
}
|
||||
#CONFIG *= easy_profiler
|
||||
|
||||
!contains(CONFIG, no_zint){
|
||||
!CONFIG(no_zint) {
|
||||
CONFIG *= zint
|
||||
}
|
||||
|
||||
!contains(CONFIG, no_svg) {
|
||||
!CONFIG(no_svg) {
|
||||
QT *= svg
|
||||
CONFIG *= svg
|
||||
DEFINES += HAVE_SVG
|
||||
DEFINES *= HAVE_SVG
|
||||
}
|
||||
|
||||
INCLUDEPATH += $$PWD/3rdparty/easyprofiler/easy_profiler_core/include
|
||||
DEPENDPATH += $$PWD/3rdparty/easyprofiler/easy_profiler_core/include
|
||||
|
||||
contains(CONFIG, easy_profiler){
|
||||
CONFIG(easy_profiler) {
|
||||
message(EasyProfiler)
|
||||
unix|win32: LIBS += -L$$PWD/3rdparty/easyprofiler/build/bin/ -leasy_profiler
|
||||
INCLUDEPATH *= $$PWD/3rdparty/easyprofiler/easy_profiler_core/include
|
||||
DEPENDPATH *= $$PWD/3rdparty/easyprofiler/easy_profiler_core/include
|
||||
unix|win32: LIBS *= -L$$PWD/3rdparty/easyprofiler/build/bin/ -leasy_profiler
|
||||
greaterThan(QT_MAJOR_VERSION, 4) {
|
||||
DEFINES += BUILD_WITH_EASY_PROFILER
|
||||
DEFINES *= BUILD_WITH_EASY_PROFILER
|
||||
}
|
||||
}
|
||||
|
||||
!contains(CONFIG, qtscriptengine){
|
||||
!CONFIG(qtscriptengine) {
|
||||
greaterThan(QT_MAJOR_VERSION, 4) {
|
||||
greaterThan(QT_MINOR_VERSION, 5) {
|
||||
CONFIG *= qjsengine
|
||||
@ -42,25 +52,25 @@ lessThan(QT_MAJOR_VERSION, 5){
|
||||
}
|
||||
}
|
||||
|
||||
contains(CONFIG, qtscriptengine){
|
||||
CONFIG(qtscriptengine) {
|
||||
CONFIG -= qjsengine
|
||||
QT *= script
|
||||
DEFINES *= USE_QTSCRIPTENGINE
|
||||
message(qtscriptengine)
|
||||
}
|
||||
|
||||
!contains(CONFIG, no_formdesigner){
|
||||
!CONFIG(no_formdesigner) {
|
||||
CONFIG *= dialogdesigner
|
||||
}
|
||||
|
||||
!contains(CONFIG, no_embedded_designer){
|
||||
!CONFIG(no_embedded_designer) {
|
||||
CONFIG *= embedded_designer
|
||||
DEFINES += HAVE_REPORT_DESIGNER
|
||||
DEFINES *= HAVE_REPORT_DESIGNER
|
||||
message(embedded designer)
|
||||
}
|
||||
|
||||
ZINT_PATH = $$PWD/3rdparty/zint-2.6.1
|
||||
contains(CONFIG,zint){
|
||||
CONFIG(zint) {
|
||||
DEFINES *= HAVE_ZINT
|
||||
}
|
||||
|
||||
@ -83,13 +93,16 @@ CONFIG(release, debug|release){
|
||||
BUILD_DIR = $${BINARY_RESULT_DIR}/build/$${QT_VERSION}
|
||||
|
||||
DEST_INCLUDE_DIR = $$PWD/include
|
||||
|
||||
unix{
|
||||
ARCH_DIR = $${OUT_PWD}/unix
|
||||
ARCH_TYPE = unix
|
||||
|
||||
macx{
|
||||
ARCH_DIR = $${OUT_PWD}/macx
|
||||
ARCH_TYPE = macx
|
||||
}
|
||||
|
||||
linux{
|
||||
!contains(QT_ARCH, x86_64) {
|
||||
message("Compiling for 32bit system")
|
||||
@ -102,6 +115,7 @@ unix{
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
win32 {
|
||||
!contains(QT_ARCH, x86_64) {
|
||||
message("Compiling for 32bit system")
|
||||
@ -143,7 +157,7 @@ greaterThan(QT_MAJOR_VERSION, 4) {
|
||||
message(uitools)
|
||||
DEFINES *= HAVE_UI_LOADER
|
||||
}
|
||||
contains(CONFIG, qjsengine){
|
||||
CONFIG(qjsengine) {
|
||||
message(qjsengine)
|
||||
DEFINES *= USE_QJSENGINE
|
||||
QT *= qml
|
||||
|
@ -23,8 +23,8 @@ CONFIG(debug, debug|release) {
|
||||
} else {
|
||||
LIBS += -llimereport
|
||||
}
|
||||
!contains(CONFIG, static_build){
|
||||
contains(CONFIG,zint){
|
||||
|
||||
!CONFIG(static_build) : CONFIG(zint) {
|
||||
LIBS += -L$${DEST_LIBS}
|
||||
CONFIG(debug, debug|release) {
|
||||
LIBS += -lQtZintd
|
||||
@ -32,4 +32,3 @@ CONFIG(debug, debug|release) {
|
||||
LIBS += -lQtZint
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -67,8 +67,7 @@ CONFIG(debug, debug|release) {
|
||||
}
|
||||
message($$LIBS)
|
||||
|
||||
!contains(CONFIG, static_build){
|
||||
contains(CONFIG,zint){
|
||||
!CONFIG(static_build) : CONFIG(zint) {
|
||||
LIBS += -L$${DEST_LIBS}
|
||||
CONFIG(debug, debug|release) {
|
||||
LIBS += -lQtZintd
|
||||
@ -76,4 +75,3 @@ message($$LIBS)
|
||||
LIBS += -lQtZint
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -65,8 +65,7 @@ CONFIG(debug, debug|release) {
|
||||
LIBS += -llimereport
|
||||
}
|
||||
|
||||
!contains(CONFIG, static_build){
|
||||
contains(CONFIG,zint){
|
||||
!CONFIG(static_build) : CONFIG(zint) {
|
||||
LIBS += -L$${DEST_LIBS}
|
||||
CONFIG(debug, debug|release) {
|
||||
LIBS += -lQtZintd
|
||||
@ -74,4 +73,3 @@ CONFIG(debug, debug|release) {
|
||||
LIBS += -lQtZint
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -1,11 +1,12 @@
|
||||
include(../common.pri)
|
||||
QT += core gui
|
||||
|
||||
contains(CONFIG,release) {
|
||||
CONFIG(release) {
|
||||
TARGET = LRDesigner
|
||||
} else {
|
||||
TARGET = LRDesignerd
|
||||
}
|
||||
|
||||
TEMPLATE = app
|
||||
|
||||
HEADERS += \
|
||||
@ -56,12 +57,10 @@ CONFIG(debug, debug|release) {
|
||||
LIBS += -llimereport
|
||||
}
|
||||
|
||||
!contains(CONFIG, static_build){
|
||||
contains(CONFIG,zint){
|
||||
!CONFIG(static_build) : CONFIG(zint) {
|
||||
CONFIG(debug, debug|release) {
|
||||
LIBS += -L$${DEST_LIBS} -lQtZintd
|
||||
} else {
|
||||
LIBS += -L$${DEST_LIBS} -lQtZint
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -4,7 +4,7 @@ include(../common.pri)
|
||||
include(../limereport/limereport.pri)
|
||||
include(../limereport/designer.pri)
|
||||
|
||||
contains(CONFIG,release) {
|
||||
CONFIG(release) {
|
||||
TARGET = designer_plugin
|
||||
} else {
|
||||
TARGET = designer_plugind
|
||||
@ -33,7 +33,7 @@ unix {
|
||||
}
|
||||
|
||||
|
||||
contains(CONFIG,zint){
|
||||
CONFIG(zint) {
|
||||
message(zint)
|
||||
INCLUDEPATH += $$ZINT_PATH/backend $$ZINT_PATH/backend_qt
|
||||
DEPENDPATH += $$ZINT_PATH/backend $$ZINT_PATH/backend_qt
|
||||
|
@ -1,31 +1,23 @@
|
||||
TEMPLATE = subdirs
|
||||
|
||||
!contains(CONFIG, no_zint){
|
||||
CONFIG += zint
|
||||
}
|
||||
|
||||
include(common.pri)
|
||||
contains(CONFIG, zint){
|
||||
|
||||
CONFIG += ordered
|
||||
|
||||
CONFIG(zint) {
|
||||
SUBDIRS += 3rdparty
|
||||
}
|
||||
|
||||
export($$CONFIG)
|
||||
|
||||
CONFIG += ordered
|
||||
SUBDIRS += \
|
||||
limereport \
|
||||
demo_r1 \
|
||||
demo_r2 \
|
||||
designer
|
||||
|
||||
greaterThan(QT_MAJOR_VERSION, 4){
|
||||
greaterThan(QT_MINOR_VERSION, 1){
|
||||
greaterThan(QT_MAJOR_VERSION, 4) : greaterThan(QT_MINOR_VERSION, 1) {
|
||||
SUBDIRS += console
|
||||
}
|
||||
}
|
||||
|
||||
!contains(CONFIG, embedded_designer){
|
||||
!contains(CONFIG, static_build){
|
||||
!CONFIG(embedded_designer) : !CONFIG(static_build) {
|
||||
SUBDIRS += designer_plugin
|
||||
}
|
||||
}
|
||||
|
@ -1,7 +1,8 @@
|
||||
include(../common.pri)
|
||||
|
||||
DEFINES += HAVE_REPORT_DESIGNER
|
||||
|
||||
contains(CONFIG,dialogdesigner){
|
||||
CONFIG(dialogdesigner) {
|
||||
include($$REPORT_PATH/dialogdesigner/dialogdesigner.pri)
|
||||
}
|
||||
|
||||
@ -51,7 +52,7 @@ SOURCES += \
|
||||
$$REPORT_PATH/lrreportdesignwidget.cpp \
|
||||
$$REPORT_PATH/lrreportdesignwindow.cpp
|
||||
|
||||
contains(CONFIG, svg){
|
||||
CONFIG(svg) {
|
||||
SOURCES += \
|
||||
$$REPORT_PATH/objectinspector/editors/lrsvgeditor.cpp \
|
||||
$$REPORT_PATH/objectinspector/propertyItems/lrsvgpropitem.cpp
|
||||
|
@ -1,20 +1,18 @@
|
||||
include(../../common.pri)
|
||||
include($$PWD/3rdparty/qtcreator/designerintegrationv2/designerintegration.pri)
|
||||
|
||||
INCLUDEPATH *= $$PWD/3rdparty/designer
|
||||
greaterThan(QT_MAJOR_VERSION, 4) {
|
||||
contains(QT,uitools){
|
||||
|
||||
greaterThan(QT_MAJOR_VERSION, 4) : contains(QT, uitools) {
|
||||
DEFINES += HAVE_QTDESIGNER_INTEGRATION
|
||||
}
|
||||
}
|
||||
lessThan(QT_MAJOR_VERSION, 5){
|
||||
contains(CONFIG,uitools){
|
||||
|
||||
lessThan(QT_MAJOR_VERSION, 5) : CONFIG(uitools) {
|
||||
DEFINES += HAVE_QTDESIGNER_INTEGRATION
|
||||
}
|
||||
}
|
||||
|
||||
greaterThan(QT_MAJOR_VERSION, 4) {
|
||||
QT *= designer designercomponents-private
|
||||
|
||||
} else {
|
||||
CONFIG *= designer
|
||||
qtAddLibrary(QtDesignerComponents)
|
||||
|
@ -76,16 +76,15 @@ SOURCES += \
|
||||
$$REPORT_PATH/exporters/lrpdfexporter.cpp \
|
||||
$$REPORT_PATH/lrpreparedpages.cpp
|
||||
|
||||
|
||||
contains(CONFIG, staticlib){
|
||||
CONFIG(staticlib) {
|
||||
SOURCES += $$REPORT_PATH/lrfactoryinitializer.cpp
|
||||
}
|
||||
|
||||
contains(CONFIG, zint){
|
||||
CONFIG(zint) {
|
||||
SOURCES += $$REPORT_PATH/items/lrbarcodeitem.cpp
|
||||
}
|
||||
|
||||
contains(CONFIG, svg){
|
||||
CONFIG(svg) {
|
||||
SOURCES += $$REPORT_PATH/items/lrsvgitem.cpp \
|
||||
}
|
||||
|
||||
@ -171,15 +170,15 @@ HEADERS += \
|
||||
$$REPORT_PATH/lrpreparedpages.h \
|
||||
$$REPORT_PATH/lrpreparedpagesintf.h
|
||||
|
||||
contains(CONFIG, staticlib){
|
||||
CONFIG(staticlib) {
|
||||
HEADERS += $$REPORT_PATH/lrfactoryinitializer.h
|
||||
}
|
||||
|
||||
contains(CONFIG,zint){
|
||||
CONFIG(zint) {
|
||||
HEADERS += $$REPORT_PATH/items/lrbarcodeitem.h
|
||||
}
|
||||
|
||||
contains(CONFIG, svg){
|
||||
CONFIG(svg) {
|
||||
HEADERS += $$REPORT_PATH/items/lrsvgitem.h
|
||||
}
|
||||
|
||||
@ -196,4 +195,3 @@ FORMS += \
|
||||
RESOURCES += \
|
||||
$$REPORT_PATH/report.qrc \
|
||||
$$REPORT_PATH/items/items.qrc
|
||||
|
||||
|
@ -6,11 +6,11 @@ CONFIG(debug, debug|release){
|
||||
|
||||
TEMPLATE = lib
|
||||
|
||||
contains(CONFIG, static_build){
|
||||
CONFIG(static_build) {
|
||||
CONFIG += staticlib
|
||||
}
|
||||
|
||||
!contains(CONFIG, staticlib){
|
||||
!CONFIG(staticlib) {
|
||||
CONFIG += lib
|
||||
CONFIG += dll
|
||||
}
|
||||
@ -26,7 +26,7 @@ macx{
|
||||
|
||||
DEFINES += LIMEREPORT_EXPORTS
|
||||
|
||||
contains(CONFIG, staticlib){
|
||||
CONFIG(staticlib) {
|
||||
DEFINES += HAVE_STATIC_BUILD
|
||||
DEFINES += QZINT_STATIC_BUILD
|
||||
message(STATIC_BUILD)
|
||||
@ -85,7 +85,7 @@ win32 {
|
||||
}
|
||||
}
|
||||
|
||||
contains(CONFIG,zint){
|
||||
CONFIG(zint) {
|
||||
message(zint)
|
||||
INCLUDEPATH += $$ZINT_PATH/backend $$ZINT_PATH/backend_qt
|
||||
DEPENDPATH += $$ZINT_PATH/backend $$ZINT_PATH/backend_qt
|
||||
@ -112,7 +112,7 @@ INSTALLS += target
|
||||
|
||||
####Automatically build required translation files (*.qm)
|
||||
|
||||
contains(CONFIG,build_translations){
|
||||
CONFIG(build_translations) {
|
||||
LANGUAGES = ru es ar fr zh pl
|
||||
|
||||
defineReplace(prependAll) {
|
||||
@ -139,5 +139,3 @@ contains(CONFIG,build_translations){
|
||||
}
|
||||
|
||||
#### EN AUTOMATIC TRANSLATIONS
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user