diff --git a/CMakeLists.txt b/CMakeLists.txt index 1359c56..78d0a7b 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -79,19 +79,11 @@ include(CMakePackageConfigHelpers) set(INCLUDE_INSTALL_DIR ${CMAKE_INSTALL_INCLUDEDIR}/deepin-pdfium) set(LIB_INSTALL_DIR ${CMAKE_INSTALL_LIBDIR}) -# 创建Qt5版本库 -if(Qt5_FOUND) - message(STATUS ">>> Enable Qt5 version of the library") - set(QT_DESIRED_VERSION 5) - set(TARGET_NAME ${PROJECT_NAME}5) - include(target.cmake) -endif() - -# 创建Qt6版本库 if(Qt6_FOUND) - message(STATUS ">>> Enable Qt6 version of the library") - # keep the same project name for Qt6 in order to compability with other applications, ie. DFM set(QT_DESIRED_VERSION 6) - set(TARGET_NAME ${PROJECT_NAME}) - include(target.cmake) +else() + set(QT_DESIRED_VERSION 5) endif() + +set(TARGET_NAME ${PROJECT_NAME}) +include(target.cmake) diff --git a/debian/control b/debian/control index de1944d..0e6c0f5 100644 --- a/debian/control +++ b/debian/control @@ -4,10 +4,8 @@ Priority: optional Maintainer: deepin Build-Depends: debhelper (>= 11), cmake, - qt6-base-dev, - qt6-tools-dev-tools, - qtbase5-dev, - qttools5-dev-tools, + qt6-base-dev | qtbase5-dev, + qt6-tools-dev-tools | qttools5-dev-tools, pkg-config, libjpeg-dev, libicu-dev, @@ -23,23 +21,11 @@ Standards-Version: 4.3.0 Package: libdeepin-pdfium Architecture: any Depends: ${shlibs:Depends}, ${misc:Depends} -Description: A libaray about PDF base on Qt6. - A library for parsing and editing and displaying PDF. - -Package: libdeepin-pdfium5 -Architecture: any -Depends: ${shlibs:Depends}, ${misc:Depends} -Description: A libaray about PDF base on Qt5. +Description: A libaray about PDF. A library for parsing and editing and displaying PDF. Package: libdeepin-pdfium-dev Architecture: any Depends: ${shlibs:Depends}, ${misc:Depends}, libdeepin-pdfium -Description: A libaray about PDF dev base on Qt6. +Description: A libaray about PDF dev. A libaray that provides for parsing and editing and displaying PDF interface dev. - -Package: libdeepin-pdfium5-dev -Architecture: any -Depends: ${shlibs:Depends}, ${misc:Depends}, libdeepin-pdfium5 -Description: A libaray about PDF dev base on Qt5. - A libaray that provides for parsing and editing and displaying PDF interface dev. \ No newline at end of file diff --git a/debian/libdeepin-pdfium5-dev.install b/debian/libdeepin-pdfium5-dev.install deleted file mode 100644 index 43e6504..0000000 --- a/debian/libdeepin-pdfium5-dev.install +++ /dev/null @@ -1,3 +0,0 @@ -/usr/include/deepin-pdfium5/* -/usr/lib/*/pkgconfig/deepin-pdfium5.pc -/usr/lib/*/cmake/deepin-pdfium5/* diff --git a/debian/libdeepin-pdfium5.install b/debian/libdeepin-pdfium5.install deleted file mode 100644 index 266a782..0000000 --- a/debian/libdeepin-pdfium5.install +++ /dev/null @@ -1 +0,0 @@ -/usr/lib/*/libdeepin-pdfium5.so* \ No newline at end of file diff --git a/include/dpdfglobal.h b/include/dpdfglobal.h index 7d37fe1..5c8f8a4 100755 --- a/include/dpdfglobal.h +++ b/include/dpdfglobal.h @@ -11,7 +11,9 @@ #include #include #include +#if QT_VERSION >= QT_VERSION_CHECK(6, 0, 0) #include +#endif #ifndef BUILD_DEEPDF_STATIC # if defined(BUILD_DEEPDF_LIB)