Fixed build on linux
This commit is contained in:
@@ -37,8 +37,30 @@ FORMS += mainwindow.ui \
|
||||
logindialog.ui
|
||||
|
||||
|
||||
unix{
|
||||
ARCH_TYPE = unix
|
||||
macx{
|
||||
ARCH_TYPE = macx
|
||||
}
|
||||
linux{
|
||||
!contains(QT_ARCH, x86_64){
|
||||
ARCH_TYPE = linux32
|
||||
}else{
|
||||
ARCH_TYPE = linux64
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
unix {
|
||||
QMAKE_CXXFLAGS += -Wno-unknown-pragmas
|
||||
|
||||
CONFIG(debug, debug|release) {
|
||||
LIBS += -L$$PWD/../../LimeReport/build/$${QT_VERSION}/$${ARCH_TYPE}/debug/lib/ -llimereport -lQtZint
|
||||
#QMAKE_CXXFLAGS += -Wl,-rpath-link,$$PWD/../../LimeReport/build/$${QT_VERSION}/$${ARCH_TYPE}/debug/lib/
|
||||
} else {
|
||||
LIBS += -L$$PWD/../../LimeReport/build/$${QT_VERSION}/$${ARCH_TYPE}/release/lib/ -llimereport -lQtZint
|
||||
#QMAKE_CXXFLAGS += -Wl,-rpath-link,$$PWD/../../LimeReport/build/$${QT_VERSION}/$${ARCH_TYPE}/release/lib/
|
||||
}
|
||||
}
|
||||
|
||||
win32 {
|
||||
|
||||
@@ -28,7 +28,8 @@ void ReportViewer::setReport(ReportPtr report)
|
||||
QFile file(reportPath);
|
||||
file.open(QFile::ReadOnly);
|
||||
|
||||
m_report->loadFromByteArray(&file.readAll());
|
||||
QByteArray data = file.readAll();
|
||||
m_report->loadFromByteArray(&data);
|
||||
m_report->setReportFileName(reportPath);
|
||||
m_report->dataManager()->setReportVariable("dbPath", Context::instance().settings()->value("db/path", "").toString());
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user