PDF4QT/Pdf4QtLib/Pdf4QtLib.pro

290 lines
11 KiB
Prolog
Raw Normal View History

2021-04-30 20:12:10 +02:00
# Copyright (C) 2018-2021 Jakub Melka
2018-11-17 16:48:30 +01:00
#
2021-08-10 19:22:56 +02:00
# This file is part of PDF4QT.
2018-11-17 16:48:30 +01:00
#
2021-08-10 19:22:56 +02:00
# PDF4QT is free software: you can redistribute it and/or modify
2018-11-17 16:48:30 +01:00
# it under the terms of the GNU Lesser General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
2021-04-30 20:12:10 +02:00
# with the written consent of the copyright owner, any later version.
2018-11-17 16:48:30 +01:00
#
2021-08-10 19:22:56 +02:00
# PDF4QT is distributed in the hope that it will be useful,
2018-11-17 16:48:30 +01:00
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Lesser General Public License for more details.
#
# You should have received a copy of the GNU Lesser General Public License
2021-08-10 19:22:56 +02:00
# along with PDF4QT. If not, see <https://www.gnu.org/licenses/>.
2018-11-17 16:48:30 +01:00
2019-01-27 17:55:22 +01:00
QT += gui widgets
2018-11-17 16:48:30 +01:00
2020-12-20 19:03:58 +01:00
TARGET = Pdf4QtLib
2018-11-17 16:48:30 +01:00
TEMPLATE = lib
2020-06-06 18:04:23 +02:00
win32:TARGET_EXT = .dll
VERSION = 1.0.0
QMAKE_TARGET_DESCRIPTION = "PDF rendering / editing library for Qt"
2021-04-30 20:12:10 +02:00
QMAKE_TARGET_COPYRIGHT = "(c) Jakub Melka 2018-2021"
2020-06-06 18:04:23 +02:00
2021-08-10 19:22:56 +02:00
DEFINES += PDF4QTLIB_LIBRARY
2018-11-17 16:48:30 +01:00
# The following define makes your compiler emit warnings if you use
# any feature of Qt which has been marked as deprecated (the exact warnings
# depend on your compiler). Please consult the documentation of the
# deprecated API in order to know how to port your code away from it.
DEFINES += QT_DEPRECATED_WARNINGS
# You can also make your code fail to compile if you use deprecated APIs.
# In order to do so, uncomment the following line.
# You can also select to disable deprecated APIs only up to a certain version of Qt.
#DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0x060000 # disables all the APIs deprecated before Qt 6.0.0
DESTDIR = $$OUT_PWD/..
SOURCES += \
2019-11-17 17:41:07 +01:00
sources/pdfaction.cpp \
sources/pdfadvancedtools.cpp \
2020-03-03 19:58:51 +01:00
sources/pdfannotation.cpp \
2019-09-29 15:44:35 +02:00
sources/pdfblendfunction.cpp \
2019-10-06 17:36:43 +02:00
sources/pdfccittfaxdecoder.cpp \
sources/pdfcms.cpp \
sources/pdfcompiler.cpp \
2020-03-08 17:06:43 +01:00
sources/pdfdocumentbuilder.cpp \
sources/pdfdocumentmanipulator.cpp \
2020-10-10 18:38:30 +02:00
sources/pdfdocumenttextflow.cpp \
2021-08-19 17:51:35 +02:00
sources/pdfdocumenttextfloweditormodel.cpp \
2020-03-22 15:30:34 +01:00
sources/pdfdocumentwriter.cpp \
2020-01-18 11:38:54 +01:00
sources/pdfexecutionpolicy.cpp \
2019-11-17 17:41:07 +01:00
sources/pdffile.cpp \
sources/pdfform.cpp \
2019-07-01 19:53:38 +02:00
sources/pdfitemmodels.cpp \
2020-10-04 16:56:55 +02:00
sources/pdfjavascriptscanner.cpp \
2019-10-20 17:41:36 +02:00
sources/pdfjbig2decoder.cpp \
2019-11-23 19:02:24 +01:00
sources/pdfmultimedia.cpp \
2018-11-17 16:48:30 +01:00
sources/pdfobject.cpp \
2020-11-25 18:57:02 +01:00
sources/pdfobjecteditormodel.cpp \
2020-11-27 19:53:37 +01:00
sources/pdfobjecteditorwidget.cpp \
2020-05-31 18:31:59 +02:00
sources/pdfobjectutils.cpp \
sources/pdfoptimizer.cpp \
2019-06-23 18:35:32 +02:00
sources/pdfoptionalcontent.cpp \
2019-11-17 17:41:07 +01:00
sources/pdfoutline.cpp \
2020-08-29 17:24:37 +02:00
sources/pdfpagenavigation.cpp \
2019-11-24 15:43:27 +01:00
sources/pdfpagetransition.cpp \
sources/pdfpainterutils.cpp \
2018-11-17 16:48:30 +01:00
sources/pdfparser.cpp \
sources/pdfdocument.cpp \
2018-11-21 19:30:15 +01:00
sources/pdfdocumentreader.cpp \
2019-08-25 18:16:37 +02:00
sources/pdfpattern.cpp \
2020-11-17 18:28:34 +01:00
sources/pdfplugin.cpp \
sources/pdfprogress.cpp \
2020-12-29 18:33:25 +01:00
sources/pdfredact.cpp \
2019-08-04 18:26:15 +02:00
sources/pdfsecurityhandler.cpp \
2020-12-30 17:06:13 +01:00
sources/pdfselectpagesdialog.cpp \
2020-06-13 18:51:06 +02:00
sources/pdfsignaturehandler.cpp \
2020-02-23 18:59:54 +01:00
sources/pdfsnapper.cpp \
2020-07-16 19:43:51 +02:00
sources/pdfstructuretree.cpp \
2019-12-28 19:21:29 +01:00
sources/pdftextlayout.cpp \
sources/pdftransparencyrenderer.cpp \
2019-05-10 19:48:52 +02:00
sources/pdfutils.cpp \
2020-01-12 18:46:59 +01:00
sources/pdfwidgettool.cpp \
2020-02-23 18:59:54 +01:00
sources/pdfwidgetutils.cpp \
2018-12-01 11:36:07 +01:00
sources/pdfxreftable.cpp \
2018-12-02 17:53:19 +01:00
sources/pdfvisitor.cpp \
2018-12-14 19:41:12 +01:00
sources/pdfencoding.cpp \
2018-12-26 18:00:17 +01:00
sources/pdfcatalog.cpp \
2018-12-29 18:22:13 +01:00
sources/pdfpage.cpp \
2019-01-20 17:55:06 +01:00
sources/pdfstreamfilters.cpp \
2019-01-27 17:55:22 +01:00
sources/pdfdrawspacecontroller.cpp \
2019-02-09 18:40:56 +01:00
sources/pdfdrawwidget.cpp \
sources/pdfcolorspaces.cpp \
2019-02-24 17:48:37 +01:00
sources/pdfrenderer.cpp \
sources/pdfpagecontentprocessor.cpp \
2019-02-24 19:42:00 +01:00
sources/pdfpainter.cpp \
2019-03-03 16:14:38 +01:00
sources/pdfrenderingerrorswidget.cpp \
2019-03-25 18:44:45 +01:00
sources/pdffunction.cpp \
sources/pdfnametounicode.cpp \
2019-05-07 18:21:22 +02:00
sources/pdffont.cpp \
sources/pdfimage.cpp
2018-11-17 16:48:30 +01:00
HEADERS += \
2019-11-17 17:41:07 +01:00
sources/pdfaction.h \
sources/pdfadvancedtools.h \
2020-03-03 19:58:51 +01:00
sources/pdfannotation.h \
2019-09-29 15:44:35 +02:00
sources/pdfblendfunction.h \
2019-10-06 17:36:43 +02:00
sources/pdfccittfaxdecoder.h \
sources/pdfcms.h \
sources/pdfcompiler.h \
2020-03-08 17:06:43 +01:00
sources/pdfdocumentbuilder.h \
2020-03-07 17:38:50 +01:00
sources/pdfdocumentdrawinterface.h \
sources/pdfdocumentmanipulator.h \
2020-10-10 18:38:30 +02:00
sources/pdfdocumenttextflow.h \
2021-08-19 17:51:35 +02:00
sources/pdfdocumenttextfloweditormodel.h \
2020-03-22 15:30:34 +01:00
sources/pdfdocumentwriter.h \
2020-01-18 11:38:54 +01:00
sources/pdfexecutionpolicy.h \
2019-11-17 17:41:07 +01:00
sources/pdffile.h \
sources/pdfform.h \
2019-07-01 19:53:38 +02:00
sources/pdfitemmodels.h \
2020-10-04 16:56:55 +02:00
sources/pdfjavascriptscanner.h \
2019-10-20 17:41:36 +02:00
sources/pdfjbig2decoder.h \
2019-09-28 18:26:31 +02:00
sources/pdfmeshqualitysettings.h \
2019-11-23 19:02:24 +01:00
sources/pdfmultimedia.h \
2019-11-30 16:26:32 +01:00
sources/pdfnametreeloader.h \
2018-11-17 16:48:30 +01:00
sources/pdfobject.h \
2020-11-25 18:57:02 +01:00
sources/pdfobjecteditormodel.h \
2020-11-27 19:53:37 +01:00
sources/pdfobjecteditorwidget.h \
2020-11-28 17:50:14 +01:00
sources/pdfobjecteditorwidget_impl.h \
2020-05-31 18:31:59 +02:00
sources/pdfobjectutils.h \
sources/pdfoptimizer.h \
2019-06-23 18:35:32 +02:00
sources/pdfoptionalcontent.h \
2019-11-17 17:41:07 +01:00
sources/pdfoutline.h \
2020-08-29 17:24:37 +02:00
sources/pdfpagenavigation.h \
2019-11-24 15:43:27 +01:00
sources/pdfpagetransition.h \
2020-04-23 19:25:57 +02:00
sources/pdfpainterutils.h \
2018-11-17 16:48:30 +01:00
sources/pdfparser.h \
sources/pdfglobal.h \
sources/pdfconstants.h \
sources/pdfdocument.h \
2018-11-21 19:30:15 +01:00
sources/pdfdocumentreader.h \
2019-08-25 18:16:37 +02:00
sources/pdfpattern.h \
2020-11-17 18:28:34 +01:00
sources/pdfplugin.h \
sources/pdfprogress.h \
2020-12-29 18:33:25 +01:00
sources/pdfredact.h \
2019-08-04 18:26:15 +02:00
sources/pdfsecurityhandler.h \
2020-12-30 17:06:13 +01:00
sources/pdfselectpagesdialog.h \
2020-06-13 18:51:06 +02:00
sources/pdfsignaturehandler.h \
sources/pdfsignaturehandler_impl.h \
2020-02-23 18:59:54 +01:00
sources/pdfsnapper.h \
2020-07-16 19:43:51 +02:00
sources/pdfstructuretree.h \
2019-12-28 19:21:29 +01:00
sources/pdftextlayout.h \
sources/pdftransparencyrenderer.h \
2020-01-12 18:46:59 +01:00
sources/pdfwidgettool.h \
2020-02-23 18:59:54 +01:00
sources/pdfwidgetutils.h \
sources/pdfxreftable.h \
2018-12-01 11:36:07 +01:00
sources/pdfflatmap.h \
2018-12-02 17:53:19 +01:00
sources/pdfvisitor.h \
2018-12-14 19:41:12 +01:00
sources/pdfencoding.h \
2018-12-24 17:09:23 +01:00
sources/pdfcatalog.h \
2018-12-26 18:00:17 +01:00
sources/pdfnumbertreeloader.h \
2018-12-29 18:22:13 +01:00
sources/pdfpage.h \
2019-01-20 17:55:06 +01:00
sources/pdfstreamfilters.h \
2019-01-27 17:55:22 +01:00
sources/pdfdrawspacecontroller.h \
2019-02-09 18:40:56 +01:00
sources/pdfdrawwidget.h \
sources/pdfflatarray.h \
sources/pdfcolorspaces.h \
2019-02-14 19:45:07 +01:00
sources/pdfrenderer.h \
2019-02-24 17:48:37 +01:00
sources/pdfpagecontentprocessor.h \
sources/pdfpainter.h \
2019-02-24 19:42:00 +01:00
sources/pdfutils.h \
2019-03-03 16:14:38 +01:00
sources/pdfrenderingerrorswidget.h \
2019-03-25 18:44:45 +01:00
sources/pdffunction.h \
sources/pdfnametounicode.h \
2019-04-29 17:03:19 +02:00
sources/pdffont.h \
2019-05-07 18:21:22 +02:00
sources/pdfexception.h \
sources/pdfimage.h
2018-11-17 16:48:30 +01:00
FORMS += \
2020-12-30 17:06:13 +01:00
sources/pdfrenderingerrorswidget.ui \
sources/pdfselectpagesdialog.ui
2018-11-25 14:48:08 +01:00
2020-11-07 17:44:03 +01:00
RESOURCES += cmaps.qrc
2021-07-05 14:57:32 +02:00
Pdf4Qt_DEPENDENCIES_PATH = $$absolute_path(../../PdfforQt-Dependencies, $$PWD)
Pdf4Qt_OPENSSL_PATH = $$absolute_path(../../Tools, $$[QT_INSTALL_PREFIX])
2020-11-07 14:42:24 +01:00
CONFIG(debug, debug|release) {
SUFFIX = d
}
2019-04-07 19:39:29 +02:00
# Link to freetype library
2020-12-20 19:03:58 +01:00
LIBS += -L$$Pdf4Qt_DEPENDENCIES_PATH/FreeType/ -lfreetype$${SUFFIX}
INCLUDEPATH += $$Pdf4Qt_DEPENDENCIES_PATH/FreeType/include
DEPENDPATH += $$Pdf4Qt_DEPENDENCIES_PATH/FreeType/include
2019-04-07 19:39:29 +02:00
2019-05-07 18:21:22 +02:00
# Link to OpenJPEG library
2020-12-20 19:03:58 +01:00
LIBS += -L$$Pdf4Qt_DEPENDENCIES_PATH/OpenJPEG/lib/ -lopenjp2$${SUFFIX}
INCLUDEPATH += $$Pdf4Qt_DEPENDENCIES_PATH/OpenJPEG/include/openjpeg-2.3
DEPENDPATH += $$Pdf4Qt_DEPENDENCIES_PATH/OpenJPEG/include/openjpeg-2.3
2020-11-07 17:25:16 +01:00
DEFINES += OPJ_STATIC
2019-05-07 18:21:22 +02:00
# Link to Independent JPEG Groups libjpeg
2020-12-20 19:03:58 +01:00
LIBS += -L$$Pdf4Qt_DEPENDENCIES_PATH/libjpeg/bin/ -ljpeg$${SUFFIX}
INCLUDEPATH += $$Pdf4Qt_DEPENDENCIES_PATH/libjpeg/include
DEPENDPATH += $$Pdf4Qt_DEPENDENCIES_PATH/libjpeg/include
# Link OpenSSL
2020-12-20 19:03:58 +01:00
LIBS += -L$$Pdf4Qt_OPENSSL_PATH/OpenSSL/Win_x64/bin -L$$Pdf4Qt_OPENSSL_PATH/OpenSSL/Win_x64/lib -llibcrypto -llibssl
INCLUDEPATH += $$Pdf4Qt_OPENSSL_PATH/OpenSSL/Win_x64/include
DEPENDPATH += $$Pdf4Qt_OPENSSL_PATH/OpenSSL/Win_x64/include
# Add OpenSSL to installations
2020-12-20 19:03:58 +01:00
openssl_lib.files = $$Pdf4Qt_OPENSSL_PATH/OpenSSL/Win_x64/bin/libcrypto-1_1-x64.dll $$Pdf4Qt_OPENSSL_PATH/OpenSSL/Win_x64/bin/libssl-1_1-x64.dll
openssl_lib.path = $$DESTDIR/install
INSTALLS += openssl_lib
2019-05-07 18:21:22 +02:00
# Link zlib
2020-12-20 19:03:58 +01:00
LIBS += -L$$Pdf4Qt_DEPENDENCIES_PATH/zlib/bin/ -lzlibstatic$${SUFFIX}
INCLUDEPATH += $$Pdf4Qt_DEPENDENCIES_PATH/zlib/include
DEPENDPATH += $$Pdf4Qt_DEPENDENCIES_PATH/zlib/include
# Link lcms2
2020-12-20 19:03:58 +01:00
LIBS += -L$$Pdf4Qt_DEPENDENCIES_PATH/lcms2/bin$${SUFFIX}/ -llcms2_static
INCLUDEPATH += $$Pdf4Qt_DEPENDENCIES_PATH/lcms2/include
DEPENDPATH += $$Pdf4Qt_DEPENDENCIES_PATH/lcms2/include
# ensure debug info even for RELEASE build
2018-11-25 14:48:08 +01:00
CONFIG += force_debug_info
2018-12-02 17:53:19 +01:00
QMAKE_CXXFLAGS += /std:c++latest /utf-8
2020-11-07 17:44:03 +01:00
QMAKE_RESOURCE_FLAGS += -threshold 0 -compress 9
2020-12-20 19:03:58 +01:00
PdfforQt_library.files = $$DESTDIR/Pdf4QtLib.dll
PdfforQt_library.path = $$DESTDIR/install
2021-08-08 16:52:10 +02:00
PdfforQt_library.CONFIG += no_check_exist
2020-12-20 19:03:58 +01:00
INSTALLS += PdfforQt_library
qt_libraries.files = $$[QT_INSTALL_BINS]/Qt?Widgets$${SUFFIX}.dll \
$$[QT_INSTALL_BINS]/Qt?Gui$${SUFFIX}.dll \
2019-12-01 13:02:25 +01:00
$$[QT_INSTALL_BINS]/Qt?Core$${SUFFIX}.dll \
$$[QT_INSTALL_BINS]/Qt?WinExtras$${SUFFIX}.dll \
2020-02-03 19:45:17 +01:00
$$[QT_INSTALL_BINS]/Qt?Svg$${SUFFIX}.dll \
2020-02-18 20:21:18 +01:00
$$[QT_INSTALL_BINS]/Qt?PrintSupport$${SUFFIX}.dll \
2020-06-28 18:55:09 +02:00
$$[QT_INSTALL_BINS]/Qt?TextToSpeech$${SUFFIX}.dll \
$$[QT_INSTALL_BINS]/Qt?Network$${SUFFIX}.dll \
$$[QT_INSTALL_BINS]/Qt?Xml$${SUFFIX}.dll
qt_libraries.path = $$DESTDIR/install
INSTALLS += qt_libraries
2020-01-25 17:36:25 +01:00
qt_plugin_platform.files = $$[QT_INSTALL_PLUGINS]/platforms/qwindows$${SUFFIX}.dll
qt_plugin_platform.path = $$DESTDIR/install/platforms
INSTALLS += qt_plugin_platform
qt_plugin_style.files = $$[QT_INSTALL_PLUGINS]/styles/qwindowsvistastyle$${SUFFIX}.dll
qt_plugin_style.path = $$DESTDIR/install/styles
INSTALLS += qt_plugin_style
2021-04-30 20:12:10 +02:00
qt_plugin_imageformat.files = $$[QT_INSTALL_PLUGINS]/imageformats/qgif$${SUFFIX}.dll \
$$[QT_INSTALL_PLUGINS]/imageformats/qicns$${SUFFIX}.dll \
$$[QT_INSTALL_PLUGINS]/imageformats/qico$${SUFFIX}.dll \
$$[QT_INSTALL_PLUGINS]/imageformats/qjpeg$${SUFFIX}.dll \
$$[QT_INSTALL_PLUGINS]/imageformats/qsvg$${SUFFIX}.dll \
$$[QT_INSTALL_PLUGINS]/imageformats/qtga$${SUFFIX}.dll \
$$[QT_INSTALL_PLUGINS]/imageformats/qtiff$${SUFFIX}.dll \
$$[QT_INSTALL_PLUGINS]/imageformats/qwbpm$${SUFFIX}.dll \
$$[QT_INSTALL_PLUGINS]/imageformats/qwebp$${SUFFIX}.dll
qt_plugin_imageformat.path = $$DESTDIR/install/imageformats
INSTALLS += qt_plugin_imageformat
2020-01-25 17:36:25 +01:00
qt_plugin_iconengine.files = $$[QT_INSTALL_PLUGINS]/iconengines/qsvgicon$${SUFFIX}.dll
qt_plugin_iconengine.path = $$DESTDIR/install/iconengines
INSTALLS += qt_plugin_iconengine
2020-02-03 19:45:17 +01:00
qt_plugin_printsupport.files = $$[QT_INSTALL_PLUGINS]/printsupport/windowsprintersupport$${SUFFIX}.dll
qt_plugin_printsupport.path = $$DESTDIR/install/printsupport
INSTALLS += qt_plugin_printsupport
2020-02-18 20:21:18 +01:00
qt_plugin_texttospeech.files = $$[QT_INSTALL_PLUGINS]/texttospeech/qtexttospeech_sapi$${SUFFIX}.dll
qt_plugin_texttospeech.path = $$DESTDIR/install/texttospeech
INSTALLS += qt_plugin_texttospeech