mirror of
https://github.com/YACReader/yacreader
synced 2025-07-17 20:44:32 -04:00
fixed Qt5 compilation for YACReaderLibrary in Linux
fixed management of special chars in CompressedArchive paths (only with Qt5, TODO: fix the issue in Qt4)
This commit is contained in:
@ -30,6 +30,7 @@ LIBS += -L/usr/lib -lpoppler-qt5
|
|||||||
else {
|
else {
|
||||||
INCLUDEPATH += /usr/include/poppler/qt4
|
INCLUDEPATH += /usr/include/poppler/qt4
|
||||||
LIBS += -L/usr/lib -lpoppler-qt4
|
LIBS += -L/usr/lib -lpoppler-qt4
|
||||||
|
|
||||||
}
|
}
|
||||||
LIBS += -lGLU
|
LIBS += -lGLU
|
||||||
}
|
}
|
||||||
|
@ -34,8 +34,15 @@ CONFIG -= embed_manifest_exe
|
|||||||
}
|
}
|
||||||
|
|
||||||
unix:!macx{
|
unix:!macx{
|
||||||
|
|
||||||
|
isEqual(QT_MAJOR_VERSION, 5) {
|
||||||
|
INCLUDEPATH += /usr/include/poppler/qt5
|
||||||
|
LIBS += -L/usr/lib -lpoppler-qt5
|
||||||
|
}
|
||||||
|
else {
|
||||||
INCLUDEPATH += /usr/include/poppler/qt4
|
INCLUDEPATH += /usr/include/poppler/qt4
|
||||||
LIBS += -L/usr/lib -lpoppler-qt4
|
LIBS += -L/usr/lib -lpoppler-qt4
|
||||||
|
}
|
||||||
LIBS += -lGLU
|
LIBS += -lGLU
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -97,7 +104,7 @@ HEADERS += comic_flow.h \
|
|||||||
comics_remover.h \
|
comics_remover.h \
|
||||||
../common/http_worker.h \
|
../common/http_worker.h \
|
||||||
yacreader_libraries.h \
|
yacreader_libraries.h \
|
||||||
../common/exit_check.cpp \
|
../common/exit_check.h \
|
||||||
|
|
||||||
SOURCES += comic_flow.cpp \
|
SOURCES += comic_flow.cpp \
|
||||||
create_library_dialog.cpp \
|
create_library_dialog.cpp \
|
||||||
|
@ -945,7 +945,7 @@ void LibraryWindow::loadCovers(const QModelIndex & mi)
|
|||||||
|
|
||||||
comicView->setModel(dmCV);
|
comicView->setModel(dmCV);
|
||||||
comicView->horizontalHeader()->setDefaultAlignment(Qt::AlignLeft);
|
comicView->horizontalHeader()->setDefaultAlignment(Qt::AlignLeft);
|
||||||
#if QT_VERSION >= 0x050100
|
#if QT_VERSION >= 0x050000
|
||||||
comicView->horizontalHeader()->setSectionsMovable(true);
|
comicView->horizontalHeader()->setSectionsMovable(true);
|
||||||
#else
|
#else
|
||||||
comicView->horizontalHeader()->setMovable(true);
|
comicView->horizontalHeader()->setMovable(true);
|
||||||
|
@ -107,8 +107,11 @@ CompressedArchive::CompressedArchive(const QString & filePath, QObject *parent)
|
|||||||
qDebug() << "wrong format";
|
qDebug() << "wrong format";
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
#ifdef UNICODE
|
||||||
if (!fileSpec->Open((LPCTSTR)filePath.toStdWString().data()))
|
if (!fileSpec->Open((LPCTSTR)filePath.toStdWString().data()))
|
||||||
|
#else
|
||||||
|
if (!fileSpec->Open((LPCTSTR)filePath.toStdString().data()))
|
||||||
|
#endif
|
||||||
{
|
{
|
||||||
qDebug() << "unable to load" + filePath;
|
qDebug() << "unable to load" + filePath;
|
||||||
continue;
|
continue;
|
||||||
@ -147,7 +150,11 @@ CompressedArchive::CompressedArchive(const QString & filePath, QObject *parent)
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifdef UNICODE
|
||||||
if (!fileSpec->Open((LPCTSTR)filePath.toStdWString().data()))
|
if (!fileSpec->Open((LPCTSTR)filePath.toStdWString().data()))
|
||||||
|
#else
|
||||||
|
if (!fileSpec->Open((LPCTSTR)filePath.toStdString().data()))
|
||||||
|
#endif
|
||||||
{
|
{
|
||||||
qDebug() << "Error opening rar file :" + filePath;
|
qDebug() << "Error opening rar file :" + filePath;
|
||||||
return;
|
return;
|
||||||
|
@ -54,7 +54,7 @@ DEFINES += UNICODE _UNICODE _FILE_OFFSET_BITS=64 _LARGEFILE_SOURCE \
|
|||||||
}
|
}
|
||||||
|
|
||||||
unix:!macx{
|
unix:!macx{
|
||||||
DEFINES += UNICODE _UNICODE _FILE_OFFSET_BITS=64 _LARGEFILE_SOURCE \
|
DEFINES += _FILE_OFFSET_BITS=64 _LARGEFILE_SOURCE \
|
||||||
NDEBUG _REENTRANT ENV_UNIX \
|
NDEBUG _REENTRANT ENV_UNIX \
|
||||||
_7ZIP_LARGE_PAGES
|
_7ZIP_LARGE_PAGES
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user