Unable to compile Zint.pro
-
Guys
Downloaded the latest source package. Tried to compile it for Linux Mint 20.1. First Mint responded qmake not found. Finally loaded QT4 packages and got qmake to work. Then I got the following errors on trying to get qmake to make the makefile:
Zint.pro:16 INCPATH is depricated use INCLUDEPATH instead
Zint.pro:142 Parse Failure 'First:All'
What should I do to fix this?
Thanks,
Marty -
Hi and welcome to devnet,
Based on the error message, you seem to have loaded a very old project.
You should either update the .pro file to match current standards or regenerate one from scratch and update it with relevant values from this one.
Note that Qt 4 has reach end of life quite a long time ago. You should port that project to Qt 5 or even better Qt 6.
-
Thanks for your response. Downloaded QtRptProject 3.0.0.zip from Sourceforge. That file was dated 2022-01-05. That seemed to be current release. Is there another source for the source code? The binaries for linux did not work.
Suggested fix from the forum was to download the source and compile.
The Zint version was 2.4.4 distributed in the zip file stated above.I downloaded a more current version of Zint (3.0). Should I compile this with cmake as instructed then try to complie QtRpt.
I have no idea how to modify the .pro file or port it to Qt5. So bearing in mind I'm not a Qt programmer and want to run it Mint Linux I would need some further guidance.
Thanks,
Marty -
What would be nice is for you to post where you are getting these projects from.
You were talking about Zint and now are adding QRpt in the mix which makes things less clear.
-
Sorry for the confusion. In order to compile QtRptProject, the install file says to compile Zint - backend-qt4 first then compile QtRptProject.. The errors occur when I try to compile Zint qtbackend.
Downloaded QtRptProject 3.0.0.zip from Sourceforge. That file was dated 2022-01-05. That was the latest current release. The Zint version was 2.4.4 distributed in the zip file stated above.
The intent is to get QtRptProject running under Linux Mint 20.1.
This is the install.txt file found in the zip. file download.
Compile Zint:
cd 3rdparty/zint-2.4.4/backend_qt4
qmake -o Makefile Zint.pro
make
Compile designer and library:
cd ../../../QtRptDesigner
qmake
make clean
make
Compile the demo program:
cd ../QtRptDemo
qmake
make clean
make
Execute the demo program:
cd ../bin/release
export
LD_LIBRARY_PATH=$LD_LIBRARY_PATH:~/PATH_TO_WHERE_IT_IS/QtRptProject/bin/release/lib
./QtRptDemo &The Zint qtbackend .pro File:
DEFINES += NO_PNG
TEMPLATE = lib
CONFIG += dllmacx{
CONFIG -= dll
CONFIG += lib_bundle
CONFIG += plugin
}unix{
CONFIG += plugin
}#VERSION = 2.4.4
INCLUDEPATH += ../backend
DEFINES += _CRT_SECURE_NO_WARNINGS _CRT_NONSTDC_NO_WARNINGS ZINT_VERSION=\"$$VERSION\"
DEFINES += QZINT_LIBRARY
TARGET = QtZint#!contains(DEFINES, NO_PNG) {
SOURCES += ../backend/png.c
LIBS += -lpng
#}
win32-msvc* {
DEFINES += _CRT_SECURE_NO_WARNINGS
#QMAKE_CFLAGS += /TP /wd4018 /wd4244 /wd4305
#QMAKE_CXXFLAGS += /TP /wd4018 /wd4244 /wd4305
}include($$PWD/../../../QtRPT/config.pri) #Loading config file to get path where place ready library
!exists($$PWD/../../../QtRPT/config.pri) {
message("not found config.pri")
}INCLUDEPATH += zint zint/backend zint/backend_qt4
DLLDESTDIR = $${DEST_DIRECTORY}
DESTDIR = $${DEST_DIRECTORY}/libHEADERS +=
qzint.h
qzint_global.h
../backend/aztec.h
../backend/code1.h
../backend/code49.h
../backend/common.h
../backend/composite.h
../backend/dmatrix.h
../backend/font.h
../backend/gb2312.h
../backend/gridmtx.h
../backend/gs1.h
../backend/large.h
../backend/maxicode.h
../backend/maxipng.h
../backend/ms_stdint.h
../backend/pdf417.h
../backend/qr.h
../backend/reedsol.h
../backend/rss.h
../backend/sjis.h
../backend/zint.hSOURCES +=
$$PWD/qzint.cpp
../backend/2of5.c
../backend/auspost.c
../backend/aztec.c
../backend/code.c
../backend/code1.c
../backend/code16k.c
../backend/code49.c
../backend/code128.c
../backend/common.c
../backend/composite.c
../backend/dllversion.c
../backend/dmatrix.c
../backend/gridmtx.c
../backend/gs1.c
../backend/imail.c
../backend/large.c
../backend/library.c
../backend/maxicode.c
../backend/medical.c
../backend/pdf417.c
../backend/plessey.c
../backend/png.c
../backend/postal.c
../backend/ps.c
../backend/qr.c
../backend/reedsol.c
../backend/render.c
../backend/rss.c
../backend/svg.c
../backend/telepen.c
../backend/upcean.cwin32 {
MOC_DIR = tmp-win32
UI_DIR = tmp-win32
UI_HEADERS_DIR = tmp-win32
UI_SOURCES_DIR = tmp-win32
OBJECTS_DIR = tmp-win32
RCC_DIR = tmp-win32
}linux {
MOC_DIR = tmp-lin64
UI_DIR = tmp-lin64
UI_HEADERS_DIR = tmp-lin64
UI_SOURCES_DIR = tmp-lin64
OBJECTS_DIR = tmp-lin64
RCC_DIR = tmp-lin64
}CONFIG -= debug_and_release debug_and_release_target
#DESTDIR = .
#include.path = $$[ZINT_INSTALL_HEADERS]
#include.files = ../backend/zint.h qzint.h#target.path = $$[ZINT_INSTALL_LIBS]
#INSTALLS += target include
Hope this information helps.
Thanks, Marty
-
@ham13 said in Unable to compile Zint.pro:
QtRptProject
In a word, I don't know why you selected this particular project/report writer. But if that requires Qt4 (for "Zint" or whatever) I would (strongly) suggest it is the wrong choice and outdated. I think you will strongly regret picking something requiring Qt4 nowadays. Find another report writer which uses Qt5 or Qt6.
-
Okay. Which one would you suggest? I'll take a look at those using QT5 - 6. The latest version of QtRptProject 3.0.0 states it uses QT - 6 on their Facebook page.
However the Install text with the "new" version is still the same as in earlier versions and still uses QT4.I will see what happens when I compile the latest version. (just for fun). Thanks for your advice. I will search the net again to see what reporting software is out there using QR5-6 and will run on Linux.
Marty