[neon/extras/peruse/Neon/unstable] debian: update the patches

Pino Toscano null at kde.org
Fri Jul 29 14:41:07 BST 2022


Git commit 88629393fa5579c29fece45cb3c726b5d62f7aca by Pino Toscano.
Committed on 16/08/2021 at 18:09.
Pushed by jriddell into branch 'Neon/unstable'.

update the patches

- make-acbf-static.patch: update
- remove-rar-support.patch: update/rewrite

M  +3    -0    debian/changelog
M  +27   -9    debian/patches/make-acbf-static.patch
M  +59   -28   debian/patches/remove-rar-support.patch

https://invent.kde.org/neon/extras/peruse/commit/88629393fa5579c29fece45cb3c726b5d62f7aca

diff --git a/debian/changelog b/debian/changelog
index 983cdb2..254e07e 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -7,6 +7,9 @@ peruse (1.80+dfsg-0r1) UNRELEASED; urgency=medium
     - stop passing --fail-missing to dh_missing, as it is the default behaviour
   * Remove the explicit as-needed linking, as it is done by binutils now.
   * Bump Standards-Version to 4.5.1, no changes required.
+  * Update the patches:
+    - make-acbf-static.patch: update
+    - remove-rar-support.patch: update/rewrite
 
  -- Debian KDE Extras Team <debian-qt-kde at lists.debian.org>  Mon, 16 Aug 2021 19:18:36 +0200
 
diff --git a/debian/patches/make-acbf-static.patch b/debian/patches/make-acbf-static.patch
index 3c5b9d7..8595bf4 100644
--- a/debian/patches/make-acbf-static.patch
+++ b/debian/patches/make-acbf-static.patch
@@ -1,19 +1,37 @@
 Description: This patch makes libacbf static so it isn't a public library.
+ Also, disable the installation of the related development bits.
 Author: Simon Quigley <tsimonq2 at ubuntu.com>
+Author: Pino Toscano <pino at debian.org>
+Last-Update: 2021-08-16
 --- a/src/acbf/CMakeLists.txt
 +++ b/src/acbf/CMakeLists.txt
-@@ -31,7 +31,7 @@ ecm_qt_declare_logging_category(acbf_SRC
-     DEFAULT_SEVERITY Warning
+@@ -63,7 +63,7 @@ ecm_qt_declare_logging_category(acbf_SRC
+     EXPORT AdvancedComicBookFormat
  )
  
 -add_library(acbf SHARED ${acbf_SRCS})
 +add_library(acbf STATIC ${acbf_SRCS})
- generate_export_header(acbf BASE_NAME acbf)
- 
- target_link_libraries(acbf
-@@ -45,4 +45,4 @@ set_target_properties(acbf PROPERTIES
-    EXPORT_NAME AdvancedComicBookFormat
+ include(ECMGenerateExportHeader)
+ ecm_generate_export_header(acbf
+     EXPORT_FILE_NAME acbf_export.h
+@@ -133,20 +133,6 @@ configure_package_config_file(
+     INSTALL_DESTINATION "${CMAKECONFIG_INSTALL_DIR}"
  )
  
--install(TARGETS acbf ${KF5_INSTALL_TARGETS_DEFAULT_ARGS})
-+#install(TARGETS acbf ${KF5_INSTALL_TARGETS_DEFAULT_ARGS})
+-install(FILES
+-    "${CMAKE_CURRENT_BINARY_DIR}/AdvancedComicBookFormatConfig.cmake"
+-    "${CMAKE_CURRENT_BINARY_DIR}/AdvancedComicBookFormatConfigVersion.cmake"
+-    DESTINATION "${CMAKECONFIG_INSTALL_DIR}"
+-    COMPONENT Devel
+-)
+-install(FILES
+-    ${acbf_HEADERS}
+-    ${CMAKE_CURRENT_BINARY_DIR}/acbf_version.h
+-    DESTINATION "${KDE_INSTALL_INCLUDEDIR_KF5}/AdvancedComicBookFormat" COMPONENT Devel
+-)
+-
+-install(TARGETS acbf EXPORT AdvancedComicBookFormatTargets ${KF5_INSTALL_TARGETS_DEFAULT_ARGS})
+-install(EXPORT AdvancedComicBookFormatTargets DESTINATION "${CMAKECONFIG_INSTALL_DIR}" FILE AdvancedComicBookFormatTargets.cmake )
+ ecm_qt_install_logging_categories(
+     EXPORT AdvancedComicBookFormat
+     FILE AdvancedComicBookFormat.categories
diff --git a/debian/patches/remove-rar-support.patch b/debian/patches/remove-rar-support.patch
index 67d7032..65e5349 100644
--- a/debian/patches/remove-rar-support.patch
+++ b/debian/patches/remove-rar-support.patch
@@ -2,18 +2,18 @@ Description: Remove RAR support
  The embedded RAR support cannot be distributed as-is, so don't build it.
 Author: Simon Quigley <tsimonq2 at ubuntu.com>
 Forwarded: not-needed
-Last-Update: 2018-03-20
+Last-Update: 2021-08-16
 --- a/src/qtquick/ArchiveBookModel.cpp
 +++ b/src/qtquick/ArchiveBookModel.cpp
-@@ -41,7 +41,6 @@
- #include <KFileMetaData/UserMetaData>
+@@ -45,7 +45,6 @@
+ #include <KLocalizedString>
  #include <karchive.h>
  #include <kzip.h>
 -#include "KRar.h" // "" because it's a custom thing for now
  
  #include <qtquick_debug.h>
- 
-@@ -179,10 +178,6 @@ void ArchiveBookModel::setFilename(QStri
+ #include <AcbfData.h>
+@@ -210,10 +209,6 @@ void ArchiveBookModel::setFilename(QStri
      {
          d->archive = new KZip(newFilename);
      }
@@ -31,39 +31,70 @@ Last-Update: 2018-03-20
  #include "ComicCoverImageProvider.h"
  
 -#include <KRar.h>
+ #include <KZip>
  #include <karchive.h>
  #include <karchivefile.h>
- 
-@@ -85,9 +84,6 @@ QImage ComicCoverImageProvider::requestI
-     QMimeDatabase db;
-     db.mimeTypeForFile(id, QMimeDatabase::MatchContent);
-     const QMimeType mime = db.mimeTypeForFile(id, QMimeDatabase::MatchContent);
--    if(mime.inherits("application/x-cbr") || mime.inherits("application/x-rar")) {
--        archive = new KRar(id);
--    }
-     // FIXME: This goes elsewhere - see below
-     // If this code seems familiar, it is adapted from kio-extras/thumbnail/comiccreator.cpp
-     // The reason being that this code should be removed once our karchive-rar functionality is merged into
+@@ -172,9 +171,7 @@ void ComicCoverRunnable::run()
+         QMimeDatabase db;
+         db.mimeTypeForFile(d->id, QMimeDatabase::MatchContent);
+         const QMimeType mime = db.mimeTypeForFile(d->id, QMimeDatabase::MatchContent);
+-        if(!d->isAborted() && (mime.inherits("application/x-cbr") || mime.inherits("application/x-rar"))) {
+-            archive = new KRar(d->id);
+-        } else if(!d->isAborted() && (mime.inherits("application/x-cbz") || mime.inherits("application/zip"))) {
++        if(!d->isAborted() && (mime.inherits("application/x-cbz") || mime.inherits("application/zip"))) {
+             archive = new KZip(d->id);
+         }
+         // FIXME: This goes elsewhere - see below
 --- a/src/qtquick/CMakeLists.txt
 +++ b/src/qtquick/CMakeLists.txt
-@@ -1,4 +1,4 @@
+@@ -1,5 +1,3 @@
 -add_subdirectory(karchive-rar)
-+#add_subdirectory(karchive-rar)
- 
+-
  set(qmlplugin_SRCS
      qmlplugin.cpp
-@@ -39,12 +39,12 @@ target_compile_definitions(peruseqmlplug
+     ArchiveBookModel.cpp
+@@ -18,11 +16,6 @@ set(qmlplugin_SRCS
+     TextViewerItem.cpp
+ )
+ 
+-set(karchive_rar_SRCS
+-    karchive-rar/KRar.cpp
+-    karchive-rar/KRarFileEntry.cpp
+-)
+-
+ if(USE_PERUSE_PDFTHUMBNAILER)
+     set(qmlplugin_SRCS
+         ${qmlplugin_SRCS}
+@@ -37,7 +30,7 @@ ecm_qt_declare_logging_category(qmlplugi
+     DEFAULT_SEVERITY Warning
+ )
+ 
+-add_library (peruseqmlplugin SHARED ${qmlplugin_SRCS} ${karchive_rar_SRCS} $<TARGET_OBJECTS:karchive-c-unarr>)
++add_library (peruseqmlplugin SHARED ${qmlplugin_SRCS})
+ if(USE_PERUSE_PDFTHUMBNAILER)
+ target_compile_definitions(peruseqmlplugin
+     PRIVATE
+@@ -46,8 +39,6 @@ target_compile_definitions(peruseqmlplug
  endif()
  target_include_directories(peruseqmlplugin
      PRIVATE
 -    karchive-rar
-+#    karchive-rar
+-    karchive-rar/unarr
      acbf
+     ${Qt5Quick_PRIVATE_INCLUDE_DIRS}
  )
- target_link_libraries (peruseqmlplugin
-     acbf
--    karchive-rar
-+#    karchive-rar
-     Qt5::Core
-     Qt5::Qml
-     Qt5::Quick
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -78,12 +78,6 @@ set_package_properties(KF5Kirigami2 PROP
+     TYPE RUNTIME
+ )
+ 
+-find_package(ZLIB)
+-set_package_properties(ZLIB PROPERTIES
+-    PURPOSE "Required for the unarr based rar support used for reading books in the CBR format"
+-    TYPE REQUIRED
+-)
+-
+ # The following checks for the QQuickTextNode private header
+ # The original checking code can be found in QtWebKit
+ include(CheckCXXSourceCompiles)



More information about the Neon-commits mailing list