pkgsrc-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

CVS commit: pkgsrc/multimedia/gerbera



Module Name:    pkgsrc
Committed By:   nros
Date:           Thu Oct  6 08:41:04 UTC 2022

Modified Files:
        pkgsrc/multimedia/gerbera: distinfo
Added Files:
        pkgsrc/multimedia/gerbera/patches: patch-CMakeLists.txt
            patch-src_util_string__converter.cc

Log Message:
gerbera: fix build on systems that use const in second argument to iconv


To generate a diff of this commit:
cvs rdiff -u -r1.2 -r1.3 pkgsrc/multimedia/gerbera/distinfo
cvs rdiff -u -r0 -r1.1 pkgsrc/multimedia/gerbera/patches/patch-CMakeLists.txt
cvs rdiff -u -r0 -r1.3 \
    pkgsrc/multimedia/gerbera/patches/patch-src_util_string__converter.cc

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: pkgsrc/multimedia/gerbera/distinfo
diff -u pkgsrc/multimedia/gerbera/distinfo:1.2 pkgsrc/multimedia/gerbera/distinfo:1.3
--- pkgsrc/multimedia/gerbera/distinfo:1.2      Mon Jul 11 11:49:48 2022
+++ pkgsrc/multimedia/gerbera/distinfo  Thu Oct  6 08:41:03 2022
@@ -1,6 +1,8 @@
-$NetBSD: distinfo,v 1.2 2022/07/11 11:49:48 adam Exp $
+$NetBSD: distinfo,v 1.3 2022/10/06 08:41:03 nros Exp $
 
 BLAKE2s (gerbera-1.11.0.tar.gz) = b5262860214cd153029adb3895f4c6d332a3ebd40d38f45728af001b80a71eaa
 SHA512 (gerbera-1.11.0.tar.gz) = ae2b3342b3b57ce6d656d0ebadfd73b5f2764f2164314f6b0deac170a82e6861349c37732e6914454918112124038b221dbd4882001b5de51a49326432ccd70f
 Size (gerbera-1.11.0.tar.gz) = 4115178 bytes
+SHA1 (patch-CMakeLists.txt) = 97f56d9c927c40ad8179d80f97f338441fae142f
 SHA1 (patch-src_main.cc) = b7b59975bc477141c8a92af9200ba2b301e55926
+SHA1 (patch-src_util_string__converter.cc) = f60a91b8ccdb851c5e939254e429ac08f5715196

Added files:

Index: pkgsrc/multimedia/gerbera/patches/patch-CMakeLists.txt
diff -u /dev/null pkgsrc/multimedia/gerbera/patches/patch-CMakeLists.txt:1.1
--- /dev/null   Thu Oct  6 08:41:04 2022
+++ pkgsrc/multimedia/gerbera/patches/patch-CMakeLists.txt      Thu Oct  6 08:41:03 2022
@@ -0,0 +1,23 @@
+$NetBSD: patch-CMakeLists.txt,v 1.1 2022/10/06 08:41:03 nros Exp $
+
+* fix build on systems that have const in second argument to iconv
+
+--- CMakeLists.txt.orig        2022-05-03 17:39:25.000000000 +0000
++++ CMakeLists.txt
+@@ -326,6 +326,16 @@ target_link_libraries(libgerbera PUBLIC 
+ 
+ find_package(Iconv REQUIRED)
+ target_link_libraries(libgerbera PUBLIC Iconv::Iconv)
++include(CheckPrototypeDefinition)
++set(CMAKE_REQUIRED_LIBRARIES Iconv::Iconv)
++check_prototype_definition(iconv
++  "size_t iconv(iconv_t cd, const char ** src, size_t * srcl, char ** dst, size_t * dstl)"
++  0 "iconv.h" ICONV_CONST)
++if(ICONV_CONST)
++    target_compile_definitions(libgerbera PRIVATE ICONV_CONST)
++endif()
++unset(CMAKE_REQUIRED_LIBRARIES)
++
+ 
+ find_package(UUID REQUIRED)
+ target_link_libraries(libgerbera PUBLIC UUID::UUID)

Index: pkgsrc/multimedia/gerbera/patches/patch-src_util_string__converter.cc
diff -u /dev/null pkgsrc/multimedia/gerbera/patches/patch-src_util_string__converter.cc:1.3
--- /dev/null   Thu Oct  6 08:41:04 2022
+++ pkgsrc/multimedia/gerbera/patches/patch-src_util_string__converter.cc       Thu Oct  6 08:41:03 2022
@@ -0,0 +1,17 @@
+$NetBSD: patch-src_util_string__converter.cc,v 1.3 2022/10/06 08:41:03 nros Exp $
+
+* fix build on systems that have const in second argument to iconv
+
+--- src/util/string_converter.cc.orig  2022-10-06 08:09:22.564707578 +0000
++++ src/util/string_converter.cc
+@@ -122,8 +122,8 @@ std::string StringConverter::_convert(co
+     // log_debug(("iconv: BEFORE: input bytes left: {}  output bytes left: {}",
+     //        input_bytes, output_bytes));
+ #if defined(ICONV_CONST) || defined(SOLARIS)
+-    int ret = iconv(cd, inputPtr, &input_bytes,
+-        output_ptr, &output_bytes);
++    int ret = iconv(cd, inputPtr, &inputBytes,
++        outputPtr, &outputBytes);
+ #else
+     int ret = iconv(cd, const_cast<char**>(inputPtr), &inputBytes,
+         outputPtr, &outputBytes);



Home | Main Index | Thread Index | Old Index