I have succesfully run qtRPT report with barcode in linux, both as library and with static linking.
For win it crashes the program no matter if I add RPT as static or dynamic library.
I tried both approaches - compiling the code under windows and usinc MXE cross compiling under linux.
Both solutions fail.
It seams like the zint library loads fine beause if I delete the dll windows complains on program startup.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
one more lessons - in case somebody has simillar problem.
Even though I selecter QtRPT to be compiled as library it seames it's liked statically . The reason for windows version crashing was the qtrpt.dll file. WHen I deleted that it no longer crashes.
Still the crosscompiled qtzint.dll is there but no barcode on the preview
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Further updates. with dynamically linked Qt and compilation inside Windows all works ok.
Somehow the crosscompiled (MXE) library - qtZint.dll is crashing the whole app on loading in windows.
When I run the program under wine I can find some trace
I added some debug messages in BarCode::BarCode
and I can see them after trying to generate the report
"BARCODE constructed
qtzint loaded"
but then I get
QGuiApplication::font(): no QGuiApplication instance and no application font set.
and a crash
The error happens in BarCode::drawBarcode
at
bc->render(*painter,QRectF(x,y,width,height), Zint::QZint::KeepAspectRatio);
Last edit: polpol 2023-02-28
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I have succesfully run qtRPT report with barcode in linux, both as library and with static linking.
For win it crashes the program no matter if I add RPT as static or dynamic library.
I tried both approaches - compiling the code under windows and usinc MXE cross compiling under linux.
Both solutions fail.
It seams like the zint library loads fine beause if I delete the dll windows complains on program startup.
one more lessons - in case somebody has simillar problem.
Even though I selecter QtRPT to be compiled as library it seames it's liked statically . The reason for windows version crashing was the qtrpt.dll file. WHen I deleted that it no longer crashes.
Still the crosscompiled qtzint.dll is there but no barcode on the preview
Further updates. with dynamically linked Qt and compilation inside Windows all works ok.
Somehow the crosscompiled (MXE) library - qtZint.dll is crashing the whole app on loading in windows.
When I run the program under wine I can find some trace
I added some debug messages in BarCode::BarCode
and I can see them after trying to generate the report
"BARCODE constructed
qtzint loaded"
but then I get
QGuiApplication::font(): no QGuiApplication instance and no application font set.
and a crash
The error happens in BarCode::drawBarcode
at
bc->render(*painter,QRectF(x,y,width,height), Zint::QZint::KeepAspectRatio);
Last edit: polpol 2023-02-28