mirror of
https://github.com/fralx/LimeReport.git
synced 2024-12-23 16:22:58 +03:00
Fix build on Qt 4
This commit is contained in:
parent
0550654b04
commit
372c677f6f
@ -1,3 +1,4 @@
|
||||
#CONFIG += build_translations
|
||||
CONFIG += zint
|
||||
ZINT_PATH = $$PWD/3rdparty/zint-2.4.4
|
||||
|
||||
@ -11,6 +12,7 @@ DEFINES += LIMEREPORT_VERSION=$${LIMEREPORT_VERSION}
|
||||
|
||||
QT += script xml sql
|
||||
REPORT_PATH = $$PWD/limereport
|
||||
TRANSLATIONS_PATH = $$PWD/translations
|
||||
|
||||
greaterThan(QT_MAJOR_VERSION, 4) {
|
||||
DEFINES+=HAVE_QT5
|
||||
|
@ -70,28 +70,33 @@ contains(CONFIG,zint){
|
||||
#######
|
||||
####Automatically build required translation files (*.qm)
|
||||
|
||||
contains(CONFIG,build_translations){
|
||||
LANGUAGES = ru es_ES
|
||||
|
||||
LANGUAGES = ru es_ES
|
||||
defineReplace(prependAll) {
|
||||
for(a,$$1):result += $$2$${a}$$3
|
||||
return($$result)
|
||||
}
|
||||
|
||||
defineReplace(prependAll) {
|
||||
for(a,$$1):result += $$2$${a}$$3
|
||||
return($$result)
|
||||
TRANSLATIONS = $$prependAll(LANGUAGES, $$TRANSLATIONS_PATH/limereport_,.ts)
|
||||
qtPrepareTool(LUPDATE, lupdate)
|
||||
ts.commands = $$LUPDATE $$PWD -ts $$TRANSLATIONS
|
||||
|
||||
TRANSLATIONS_FILES =
|
||||
qtPrepareTool(LRELEASE, lrelease)
|
||||
for(tsfile, TRANSLATIONS) {
|
||||
qmfile = $$tsfile
|
||||
qmfile ~= s,.ts$,.qm,
|
||||
qm.commands += $$LRELEASE -removeidentical $$tsfile -qm $$qmfile $$escape_expand(\\n\\t)
|
||||
tmp_command = $$LRELEASE -removeidentical $$tsfile -qm $$qmfile $$escape_expand(\\n\\t)
|
||||
TRANSLATIONS_FILES += $$qmfile
|
||||
}
|
||||
qm.depends = ts
|
||||
|
||||
QMAKE_EXTRA_TARGETS += qm ts
|
||||
POST_TARGETDEPS += qm
|
||||
}
|
||||
|
||||
TRANSLATIONS_PATH = $$PWD/../translations
|
||||
TRANSLATIONS = $$prependAll(LANGUAGES, $$TRANSLATIONS_PATH/limereport_,.ts)
|
||||
|
||||
qtPrepareTool(LUPDATE, lupdate)
|
||||
ts.commands = $$LUPDATE $$_PRO_FILE_
|
||||
|
||||
qtPrepareTool(LRELEASE, lrelease)
|
||||
qm.commands = $$LRELEASE $$_PRO_FILE_
|
||||
qm.depends = ts
|
||||
|
||||
QMAKE_EXTRA_TARGETS += qm ts
|
||||
POST_TARGETDEPS += qm ts
|
||||
|
||||
|
||||
#### EN AUTOMATIC TRANSLATIONS
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user