diff --git a/libcddb-no-examples.patch b/libcddb-no-examples.patch index f38d386..d94c440 100644 --- a/libcddb-no-examples.patch +++ b/libcddb-no-examples.patch @@ -1,7 +1,9 @@ -Index: Makefile.am -=================================================================== ---- Makefile.am.orig 2003-05-28 17:55:14.000000000 +0200 -+++ Makefile.am 2007-10-09 08:08:47.000000000 +0200 +--- + Makefile.am | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +--- a/Makefile.am ++++ b/Makefile.am @@ -1,5 +1,5 @@ -SUBDIRS = include lib examples tests diff --git a/libcddb.changes b/libcddb.changes index 3da994f..7fcb876 100644 --- a/libcddb.changes +++ b/libcddb.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Fri Mar 22 19:04:27 UTC 2024 - Matej Cepl + +- Add pointer-types.patch to fix compilation error with GCC 14 + (bsc#1221698). + ------------------------------------------------------------------- Thu Feb 29 15:42:19 UTC 2024 - pgajdos@suse.com diff --git a/libcddb.spec b/libcddb.spec index 0880886..13ba289 100644 --- a/libcddb.spec +++ b/libcddb.spec @@ -34,6 +34,9 @@ URL: https://libcddb.sourceforge.net/ Source: http://downloads.sourceforge.net/project/%{_name}/%{_name}/%{version}/%{_name}-%{version}.tar.bz2 Source2: baselibs.conf Patch0: libcddb-no-examples.patch +# PATCH-FIX-UPSTREAM pointer-types.patch bsc#1221698 mcepl@suse.com +# Patch from https://src.fedoraproject.org/rpms/libcddb/raw/rawhide/f/pointer-types.patch +Patch1: pointer-types.patch BuildRequires: libtool BuildRequires: pkgconfig %if %{BUILD_UTILS} @@ -75,10 +78,11 @@ tries to be as cross-platform as possible. %prep %setup -q -n %{_name}-%{version} %if !%{BUILD_UTILS} -%patch -P 0 +%patch -p1 -P 0 %else sed -i 's:\(\.\.\|\$(top_builddir)\)/[^/]*/lib\([^ ]*\)\.la:-l\2:g' */Makefile.am %endif +%patch -p1 -P 1 %build autoreconf -f -i diff --git a/pointer-types.patch b/pointer-types.patch new file mode 100644 index 0000000..a2dce8c --- /dev/null +++ b/pointer-types.patch @@ -0,0 +1,15 @@ +--- + lib/cddb_net.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +--- a/lib/cddb_net.c ++++ b/lib/cddb_net.c +@@ -325,7 +325,7 @@ int timeout_connect(int sockfd, const st + default: + /* we got connected, check error condition */ + l = sizeof(rv); +- getsockopt(sockfd, SOL_SOCKET, SO_ERROR, &rv, &l); ++ getsockopt(sockfd, SOL_SOCKET, SO_ERROR, &rv, (socklen_t * restrict)&l); + if (rv) { + /* something went wrong, simulate normal connect behaviour */ + errno = rv;