From 19410cd6e751d1ce5196e132b83025d937c5da4b Mon Sep 17 00:00:00 2001 From: Joan Karadimov Date: Sun, 31 Oct 2021 20:39:56 +0200 Subject: [PATCH] Enable the usage of pkg-config by MinGW builds --- compressed_archive/unarr/unarr-wrapper.pri | 2 +- dependencies/pdf_backend.pri | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/compressed_archive/unarr/unarr-wrapper.pri b/compressed_archive/unarr/unarr-wrapper.pri index 9e6a53b9..01152674 100644 --- a/compressed_archive/unarr/unarr-wrapper.pri +++ b/compressed_archive/unarr/unarr-wrapper.pri @@ -6,7 +6,7 @@ HEADERS += $$PWD/extract_delegate.h \ SOURCES += $$PWD/compressed_archive.cpp -unix:!macx:!contains(QT_CONFIG, no-pkg-config):packagesExist(libunarr) { +if(mingw|unix):!macx:!contains(QT_CONFIG, no-pkg-config):packagesExist(libunarr) { message(Using system provided unarr installation found by pkg-config.) CONFIG += link_pkgconfig PKGCONFIG += libunarr diff --git a/dependencies/pdf_backend.pri b/dependencies/pdf_backend.pri index 73add332..a14885bb 100644 --- a/dependencies/pdf_backend.pri +++ b/dependencies/pdf_backend.pri @@ -6,7 +6,7 @@ CONFIG(pdfium) { message(Using pdfium.) DEFINES += "USE_PDFIUM" SOURCES += ../common/pdf_comic.cpp - win32 { + msvc { INCLUDEPATH += $$PWD/pdfium/win/public contains(QMAKE_TARGET.arch, x86_64): { LIBS += -L$$PWD/pdfium/win/x64 -lpdfium @@ -14,7 +14,7 @@ CONFIG(pdfium) { LIBS += -L$$PWD/pdfium/win/x86 -lpdfium } } - unix { + unix|mingw { macx { LIBS += -L$$PWD/pdfium/macx/bin -lpdfium INCLUDEPATH += $$PWD/pdfium/macx/include @@ -43,7 +43,7 @@ CONFIG(pdfkit) { } CONFIG(poppler) { - win32 { + msvc { contains(QMAKE_TARGET.arch, x86_64): { error ("We currently don't ship precompiled poppler libraries for 64 bit builds on Windows") } @@ -54,7 +54,7 @@ CONFIG(poppler) { LIBS += -L$$PWD/poppler/bin LIBS += -L$$PWD/poppler/dependencies/bin } - unix:!macx { + if(unix|mingw):!macx { !contains(QT_CONFIG, no-pkg-config):packagesExist(poppler-qt5) { message("Using system provided installation of poppler-qt5 found by pkg-config.") CONFIG += link_pkgconfig