commit: 9841807aeb2ccd52836b79fb718a37ea20707ae2 Author: Andreas Sturmlechner <asturm <AT> gentoo <DOT> org> AuthorDate: Fri May 30 14:35:23 2025 +0000 Commit: Andreas Sturmlechner <asturm <AT> gentoo <DOT> org> CommitDate: Fri May 30 15:45:15 2025 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=9841807a
app-text/ebook-tools: Respin libzip-cmake.patch to not override cmake module Custom FindPackageHandleStandardArgs.cmake in CMAKE_MODULE_PATH = bad Closes: https://bugs.gentoo.org/956821 Signed-off-by: Andreas Sturmlechner <asturm <AT> gentoo.org> app-text/ebook-tools/ebook-tools-0.2.2-r3.ebuild | 2 +- .../files/ebook-tools-0.2.2-crashfix.patch | 11 +-- .../files/ebook-tools-0.2.2-libzip-cmake.patch | 78 ++++++++++++++++++++-- 3 files changed, 79 insertions(+), 12 deletions(-) diff --git a/app-text/ebook-tools/ebook-tools-0.2.2-r3.ebuild b/app-text/ebook-tools/ebook-tools-0.2.2-r3.ebuild index 179967bb922d..239539f53de4 100644 --- a/app-text/ebook-tools/ebook-tools-0.2.2-r3.ebuild +++ b/app-text/ebook-tools/ebook-tools-0.2.2-r3.ebuild @@ -19,7 +19,7 @@ DEPEND=" >=dev-libs/libzip-1.7.2:= " RDEPEND="${DEPEND} - lit2epub? ( app-text/convertlit ) + lit2epub? ( app-text/convertlit ) " PATCHES=( diff --git a/app-text/ebook-tools/files/ebook-tools-0.2.2-crashfix.patch b/app-text/ebook-tools/files/ebook-tools-0.2.2-crashfix.patch index 1ca8dd4902f2..12a1079a11fc 100644 --- a/app-text/ebook-tools/files/ebook-tools-0.2.2-crashfix.patch +++ b/app-text/ebook-tools/files/ebook-tools-0.2.2-crashfix.patch @@ -1,4 +1,4 @@ -From 93ebf942a90f9c95797838f9adab94bc0378671c Mon Sep 17 00:00:00 2001 +From ad006f1f843e4293b784f76b98185f2822bdaaca Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stefan=20Br=C3=BCns?= <[email protected]> Date: Tue, 30 Apr 2019 16:36:09 +0200 Subject: [PATCH] Avoid crash on toc.ncx navPoint without navLabel @@ -32,19 +32,20 @@ index d085503..a259d9d 100644 if (! tit->cache.label) tit->cache.label = (char *)ti->id; diff --git a/src/libepub/opf.c b/src/libepub/opf.c -index 6851db2..09bce9e 100644 +index 34145b9..ae41184 100644 --- a/src/libepub/opf.c +++ b/src/libepub/opf.c -@@ -398,6 +398,10 @@ void _opf_parse_navmap(struct opf *opf, xmlTextReaderPtr reader) { +@@ -394,6 +394,10 @@ void _opf_parse_navmap(struct opf *opf, xmlTextReaderPtr reader) { } else if (xmlTextReaderNodeType(reader) == 15) { if (item) { + if (! item->label) { -+ _epub_print_debug(opf->epub, DEBUG_WARNING, ++ _epub_print_debug(opf->epub, DEBUG_WARNING, + "- missing navlabel for nav point element"); + } _epub_print_debug(opf->epub, DEBUG_INFO, "adding nav point item->%s %s (d:%d,p:%d)", item->id, item->src, item->depth, item->playOrder); -- -2.21.0 +2.49.0 + diff --git a/app-text/ebook-tools/files/ebook-tools-0.2.2-libzip-cmake.patch b/app-text/ebook-tools/files/ebook-tools-0.2.2-libzip-cmake.patch index d1a560f1a5da..427483db9ed4 100644 --- a/app-text/ebook-tools/files/ebook-tools-0.2.2-libzip-cmake.patch +++ b/app-text/ebook-tools/files/ebook-tools-0.2.2-libzip-cmake.patch @@ -1,15 +1,17 @@ -From fa125b4223bc8995ed60befbed757ec23eed72e7 Mon Sep 17 00:00:00 2001 +From 0b33823e00e98fe905fcbc1b2a2fc4c8d521be2d Mon Sep 17 00:00:00 2001 From: Andreas Sturmlechner <[email protected]> Date: Thu, 22 Oct 2020 23:32:33 +0200 Subject: [PATCH] Use >=dev-libs/libzip-1.7.2 cmake config Signed-off-by: Andreas Sturmlechner <[email protected]> --- - CMakeLists.txt | 2 +- - cmake/FindLibZip.cmake | 36 ------------------------------------ - src/libepub/CMakeLists.txt | 2 +- - 3 files changed, 2 insertions(+), 38 deletions(-) + CMakeLists.txt | 2 +- + cmake/FindLibZip.cmake | 36 -------------- + cmake/FindPackageHandleStandardArgs.cmake | 58 ----------------------- + src/libepub/CMakeLists.txt | 2 +- + 4 files changed, 2 insertions(+), 96 deletions(-) delete mode 100644 cmake/FindLibZip.cmake + delete mode 100644 cmake/FindPackageHandleStandardArgs.cmake diff --git a/CMakeLists.txt b/CMakeLists.txt index fc141c2..691cf2b 100644 @@ -66,6 +68,70 @@ index c873092..0000000 -endif (LIBZIP_LIBRARY AND LIBZIP_INCLUDE_DIR) - -mark_as_advanced(LIBZIP_INCLUDE_DIR LIBZIP_LIBRARY) +diff --git a/cmake/FindPackageHandleStandardArgs.cmake b/cmake/FindPackageHandleStandardArgs.cmake +deleted file mode 100644 +index 151d812..0000000 +--- a/cmake/FindPackageHandleStandardArgs.cmake ++++ /dev/null +@@ -1,58 +0,0 @@ +-# FIND_PACKAGE_HANDLE_STANDARD_ARGS(NAME (DEFAULT_MSG|"Custom failure message") VAR1 ... ) +-# This macro is intended to be used in FindXXX.cmake modules files. +-# It handles the REQUIRED and QUIET argument to FIND_PACKAGE() and +-# it also sets the <UPPERCASED_NAME>_FOUND variable. +-# The package is found if all variables listed are TRUE. +-# Example: +-# +-# FIND_PACKAGE_HANDLE_STANDARD_ARGS(LibXml2 DEFAULT_MSG LIBXML2_LIBRARIES LIBXML2_INCLUDE_DIR) +-# +-# LibXml2 is considered to be found, if both LIBXML2_LIBRARIES and +-# LIBXML2_INCLUDE_DIR are valid. Then also LIBXML2_FOUND is set to TRUE. +-# If it is not found and REQUIRED was used, it fails with FATAL_ERROR, +-# independent whether QUIET was used or not. +-# If it is found, the location is reported using the VAR1 argument, so +-# here a message "Found LibXml2: /usr/lib/libxml2.so" will be printed out. +-# If the second argument is DEFAULT_MSG, the message in the failure case will +-# be "Could NOT find LibXml2", if you don't like this message you can specify +-# your own custom failure message there. +- +-MACRO(FIND_PACKAGE_HANDLE_STANDARD_ARGS _NAME _FAIL_MSG _VAR1 ) +- +- IF("${_FAIL_MSG}" STREQUAL "DEFAULT_MSG") +- IF (${_NAME}_FIND_REQUIRED) +- SET(_FAIL_MESSAGE "Could not find REQUIRED package ${_NAME}") +- ELSE (${_NAME}_FIND_REQUIRED) +- SET(_FAIL_MESSAGE "Could not find OPTIONAL package ${_NAME}") +- ENDIF (${_NAME}_FIND_REQUIRED) +- ELSE("${_FAIL_MSG}" STREQUAL "DEFAULT_MSG") +- SET(_FAIL_MESSAGE "${_FAIL_MSG}") +- ENDIF("${_FAIL_MSG}" STREQUAL "DEFAULT_MSG") +- +- STRING(TOUPPER ${_NAME} _NAME_UPPER) +- +- SET(${_NAME_UPPER}_FOUND TRUE) +- IF(NOT ${_VAR1}) +- SET(${_NAME_UPPER}_FOUND FALSE) +- ENDIF(NOT ${_VAR1}) +- +- FOREACH(_CURRENT_VAR ${ARGN}) +- IF(NOT ${_CURRENT_VAR}) +- SET(${_NAME_UPPER}_FOUND FALSE) +- ENDIF(NOT ${_CURRENT_VAR}) +- ENDFOREACH(_CURRENT_VAR) +- +- IF (${_NAME_UPPER}_FOUND) +- IF (NOT ${_NAME}_FIND_QUIETLY) +- MESSAGE(STATUS "Found ${_NAME}: ${${_VAR1}}") +- ENDIF (NOT ${_NAME}_FIND_QUIETLY) +- ELSE (${_NAME_UPPER}_FOUND) +- IF (${_NAME}_FIND_REQUIRED) +- MESSAGE(FATAL_ERROR "${_FAIL_MESSAGE}") +- ELSE (${_NAME}_FIND_REQUIRED) +- IF (NOT ${_NAME}_FIND_QUIETLY) +- MESSAGE(STATUS "${_FAIL_MESSAGE}") +- ENDIF (NOT ${_NAME}_FIND_QUIETLY) +- ENDIF (${_NAME}_FIND_REQUIRED) +- ENDIF (${_NAME_UPPER}_FOUND) +-ENDMACRO(FIND_PACKAGE_HANDLE_STANDARD_ARGS) diff --git a/src/libepub/CMakeLists.txt b/src/libepub/CMakeLists.txt index a3208b7..460270c 100644 --- a/src/libepub/CMakeLists.txt @@ -79,5 +145,5 @@ index a3208b7..460270c 100644 set_target_properties (epub PROPERTIES VERSION 0.2.1 SOVERSION 0) -- -2.29.0 +2.49.0
