cdparanoia-32: fix build

This commit is contained in:
Danny Rawlins 2021-12-21 20:13:03 +11:00
parent b599535ec3
commit dfe57d55b8
10 changed files with 718 additions and 611 deletions

View File

@ -3,8 +3,10 @@ drwxr-xr-x root/root usr/lib32/
-rw-r--r-- root/root usr/lib32/libcdda_interface.a
lrwxrwxrwx root/root usr/lib32/libcdda_interface.so -> libcdda_interface.so.0.10.2
lrwxrwxrwx root/root usr/lib32/libcdda_interface.so.0 -> libcdda_interface.so.0.10.2
-rw-r--r-- root/root usr/lib32/libcdda_interface.so.0.10.2
-rwxr-xr-x root/root usr/lib32/libcdda_interface.so.0.10.2
-rw-r--r-- root/root usr/lib32/libcdda_paranoia.a
lrwxrwxrwx root/root usr/lib32/libcdda_paranoia.so -> libcdda_paranoia.so.0.10.2
lrwxrwxrwx root/root usr/lib32/libcdda_paranoia.so.0 -> libcdda_paranoia.so.0.10.2
-rw-r--r-- root/root usr/lib32/libcdda_paranoia.so.0.10.2
-rwxr-xr-x root/root usr/lib32/libcdda_paranoia.so.0.10.2
drwxr-xr-x root/root usr/lib32/pkgconfig/
-rw-r--r-- root/root usr/lib32/pkgconfig/cdparanoia-3.pc

View File

@ -1,7 +1,12 @@
untrusted comment: verify with /etc/ports/compat-32.pub
RWSwxGo/zH7eXW5dNxANj0kai3n88A4jldkOeObhbOmEmIA5kDi1/h8GoT4vp9LADGYNuiW2BJIn0wlk+KdqQMFwL3CaRY1B/wo=
SHA256 (Pkgfile) = 4a3e6cb2d67b655a1ed08ff09546426aabcff6c0b7fd04491845337256f84277
SHA256 (.footprint) = c6b28ac040cba3e244417b0e477c037b9a077586edf2509fffd25f91deb9b7a5
RWSwxGo/zH7eXVidHZmZiRgZLYvkZcdeUTUVVZgZFLlnxi63SRX4m/Chh08rFYAkUnPDJB9nhPEgomA7hJwJ7l+dBnMUq4cimgg=
SHA256 (Pkgfile) = 1004fd79b809ea4b2e8894246f0bee435039d318e20bba3fc5dbda9eeb38703b
SHA256 (.footprint) = ec2dacfb229d2e3580d3dc27f399aa41e47962d7cca61c17ba41ef502c1c3102
SHA256 (cdparanoia-III-10.2.src.tgz) = 005db45ef4ee017f5c32ec124f913a0546e77014266c6a1c50df902a55fe64df
SHA256 (cdparanoia-10.2-gcc43.patch) = d055d86056809dee6e861af77d766fb0f17084bb19e44d9d99be8a0c11892a18
SHA256 (cdparanoia-10.2-ldflags.patch) = 11db67bf65f4cb1e6bb33e5166ef081ac0e57bed9703149135a5c83a55481f9f
SHA256 (cdparanoia-10.2-463009.patch) = bb7d0256b57b2ae630bfb9f78be7bda6e1abaed809f0238112b850fb9ca3e7ef
SHA256 (cdparanoia-10.2-endian.patch) = da764568a0466cd856c8e4dac09be2be4e7a2104125db4b60de873217a0dece8
SHA256 (cdparanoia-10.2-install.patch) = 807c72330ebde3fc0c26a10ed7236870f49ae11df75dd8bd2be9c593e774806a
SHA256 (cdparanoia-10.2-format-security.patch) = a6f80215c801190dfcade6751d12235a1878ab6b5762260086e7f0ce1296bef4
SHA256 (cdparanoia-use-proper-gnu-config-files.patch) = dc4b2540552f53a563c1f2ba6e279c70049fdd13e066d87e126370e54148e30d
SHA256 (cdparanoia-10.2-ldflags.patch) = 9b352a93ebedc7c523c76213756f98139ea3912162ee719ab0c5cc6648f94fe2
SHA256 (cdparanoia-10.2-add-pkgconfig.patch) = f8e09fd0a05723ae8f16ab186394d807d5ec61dfcdcf815accd7aae755182dee

View File

@ -5,25 +5,34 @@
name=cdparanoia-32
version=10.2
release=2
release=3
source=(https://downloads.xiph.org/releases/cdparanoia/cdparanoia-III-$version.src.tgz
cdparanoia-$version-gcc43.patch
cdparanoia-$version-ldflags.patch)
cdparanoia-10.2-463009.patch
cdparanoia-10.2-endian.patch
cdparanoia-10.2-install.patch
cdparanoia-10.2-format-security.patch
cdparanoia-use-proper-gnu-config-files.patch
cdparanoia-10.2-ldflags.patch
cdparanoia-10.2-add-pkgconfig.patch)
build() {
cd cdparanoia-III-$version
patch -p 0 -i $SRC/cdparanoia-$version-gcc43.patch
patch -p 1 -i $SRC/cdparanoia-$version-ldflags.patch
autoreconf
patch -p3 -i $SRC/cdparanoia-10.2-463009.patch
patch -p1 -i $SRC/cdparanoia-10.2-endian.patch
patch -p1 -i $SRC/cdparanoia-10.2-install.patch
patch -p1 -i $SRC/cdparanoia-10.2-format-security.patch
patch -p1 -i $SRC/cdparanoia-use-proper-gnu-config-files.patch
patch -p1 -i $SRC/cdparanoia-10.2-ldflags.patch
patch -p1 -i $SRC/cdparanoia-10.2-add-pkgconfig.patch
autoreconf -ifv
./configure \
--prefix=/usr \
--mandir=$PKG/usr/man \
--libdir=$PKG/usr/lib32 \
--libdir=/usr/lib32 \
--host=i686-pc-linux-gnu
make -j 1
make prefix=$PKG/usr install
make -j1
make DESTDIR=$PKG install
rm -rf $PKG/{etc,var} $PKG/usr/{bin,etc,include,man,sbin,share}
rm -r $PKG/usr/{bin,include,share}
}

View File

@ -0,0 +1,91 @@
From 5beb3983942ce92ea18a2a0f2e15f84fb25c27d8 Mon Sep 17 00:00:00 2001
From: xiphmont <xiphmont@0101bb08-14d6-0310-b084-bc0e0c8e3800>
Date: Fri, 11 Jun 2010 15:42:00 +0000
Subject: [PATCH] Add pkgconfig file to cdparanoia; closes Trac #1706
git-svn-id: https://svn.xiph.org/trunk/cdparanoia@17289 0101bb08-14d6-0310-b084-bc0e0c8e3800
---
Makefile.in | 7 +++++--
cdparanoia-3.pc.in | 12 ++++++++++++
configure.in | 5 ++++-
3 files changed, 21 insertions(+), 3 deletions(-)
create mode 100644 cdparanoia-3.pc.in
diff --git a/Makefile.in b/Makefile.in
index 25c91ce..bfef153 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -3,7 +3,7 @@
# DO NOT EDIT BELOW! ##########################################################
# (unless, of course, you know what you are doing :) ##########################
-VERSION=10.2
+VERSION=@VERSION@
VPATH=@srcdir@
srcdir=@srcdir@
@@ -23,6 +23,7 @@ BINDIR=@bindir@
MANDIR=@mandir@
INCLUDEDIR=@includedir@
LIBDIR=@libdir@
+PKGCONFIGDIR=@libdir@/pkgconfig
PWD = $(shell pwd)
OFILES = main.o report.o header.o buffering_write.o cachetest.o
@@ -85,6 +86,8 @@ install:
$(DESTDIR)$(LIBDIR)/libcdda_paranoia.so.0
ln -fs libcdda_paranoia.so.0.$(VERSION) \
$(DESTDIR)$(LIBDIR)/libcdda_paranoia.so
+ $(INSTALL) -d -m 0755 $(DESTDIR)$(PKGCONFIGDIR)
+ $(INSTALL) -m 0644 $(srcdir)/cdparanoia-3.pc $(DESTDIR)$(PKGCONFIGDIR)
cdparanoia: $(OFILES) $(LIBDEP)
$(LD) $(CFLAGS) $(LDFLAGS) $(OFILES) \
@@ -104,6 +107,6 @@ distclean:
cd interface && $(MAKE) distclean
cd paranoia && $(MAKE) distclean
-rm -f cdparanoia *~ config.* *.o *.wav *.aifc *.raw test.file \
- Makefile verify_test core gmon.out
+ Makefile verify_test core gmon.out cdparanoia-3.pc
.PHONY: all debug test lib slib install clean distclean
diff --git a/cdparanoia-3.pc.in b/cdparanoia-3.pc.in
new file mode 100644
index 0000000..3a15099
--- /dev/null
+++ b/cdparanoia-3.pc.in
@@ -0,0 +1,12 @@
+prefix=@prefix@
+exec_prefix=@exec_prefix@
+libdir=@libdir@
+includedir=@includedir@
+
+Name: Cdparanoia III
+Description: Compact Disc Digital Audio (CDDA) Digital Audio Extraction (DAE) library
+Requires:
+Version: @VERSION@
+Libs: -L${libdir} -lcdda_interface -lcdda_paranoia
+Cflags: -I${includedir}
+
diff --git a/configure.in b/configure.in
index 3ad98ca..3ae6989 100644
--- a/configure.in
+++ b/configure.in
@@ -1,5 +1,8 @@
AC_INIT(interface/interface.c)
+VERSION="10.2"
+AC_SUBST(VERSION)
+
AC_CANONICAL_HOST
if test -z "$CC"; then
@@ -67,4 +70,4 @@ AC_SUBST(OPT)
AC_SUBST(DEBUG)
AC_SUBST(CC)
-AC_OUTPUT(Makefile interface/Makefile paranoia/Makefile)
+AC_OUTPUT(Makefile interface/Makefile paranoia/Makefile cdparanoia-3.pc)
--
2.26.2

View File

@ -0,0 +1,12 @@
diff -up cdparanoia-III-10.2/interface/interface.c.jx cdparanoia-III-10.2/interface/interface.c
--- cdparanoia-III-10.2/interface/interface.c.jx 2009-02-10 14:25:02.000000000 -0500
+++ cdparanoia-III-10.2/interface/interface.c 2009-02-10 14:25:49.000000000 -0500
@@ -115,7 +115,7 @@ long cdda_read_timed(cdrom_drive *d, voi
if(sectors>0){
/* byteswap? */
- if(d->bigendianp==-1) /* not determined yet */
+ if(buffer && d->bigendianp==-1) /* not determined yet */
d->bigendianp=data_bigendianp(d);
if(d->bigendianp!=bigendianp()){

View File

@ -0,0 +1,16 @@
diff -Naur cdparanoia-III-10.2.orig/main.c cdparanoia-III-10.2/main.c
--- cdparanoia-III-10.2.orig/main.c 2008-09-11 23:11:02.000000000 +0200
+++ cdparanoia-III-10.2/main.c 2014-04-14 21:24:10.023000000 +0200
@@ -588,10 +588,10 @@
buffer[aheadposition+19]='>';
}
- fprintf(stderr,buffer);
+ fprintf(stderr, "%s", buffer);
if (logfile != NULL && function==-1) {
- fprintf(logfile,buffer+1);
+ fprintf(logfile, "%s", buffer+1);
fprintf(logfile,"\n\n");
fflush(logfile);
}

View File

@ -0,0 +1,50 @@
diff -Naupr cdparanoia-III-10.2.orig/Makefile.in cdparanoia-III-10.2/Makefile.in
--- cdparanoia-III-10.2.orig/Makefile.in 2008-09-11 22:33:30.000000000 +0200
+++ cdparanoia-III-10.2/Makefile.in 2008-12-22 22:31:45.578372040 +0100
@@ -63,28 +63,28 @@ slib:
cd paranoia && $(MAKE) slib
install:
- $(INSTALL) -d -m 0755 $(BINDIR)
- $(INSTALL) -m 755 $(srcdir)/cdparanoia $(BINDIR)
- $(INSTALL) -d -m 0755 $(MANDIR)
- $(INSTALL) -d -m 0755 $(MANDIR)/man1
- $(INSTALL) -m 0644 $(srcdir)/cdparanoia.1 $(MANDIR)/man1
- $(INSTALL) -d -m 0755 $(INCLUDEDIR)
- $(INSTALL) -m 0644 $(srcdir)/paranoia/cdda_paranoia.h $(INCLUDEDIR)
- $(INSTALL) -d -m 0755 $(LIBDIR)
- $(INSTALL) -m 0644 $(srcdir)/paranoia/libcdda_paranoia.so.0.$(VERSION) $(LIBDIR)
- $(INSTALL) -m 0644 $(srcdir)/paranoia/libcdda_paranoia.a $(LIBDIR)
- $(INSTALL) -m 0644 $(srcdir)/interface/cdda_interface.h $(INCLUDEDIR)
- $(INSTALL) -m 0644 $(srcdir)/interface/libcdda_interface.so.0.$(VERSION) $(LIBDIR)
- $(INSTALL) -m 0644 $(srcdir)/interface/libcdda_interface.a $(LIBDIR)
- $(INSTALL) -m 0644 $(srcdir)/utils.h $(INCLUDEDIR)
+ $(INSTALL) -d -m 0755 $(DESTDIR)$(BINDIR)
+ $(INSTALL) -m 755 $(srcdir)/cdparanoia $(DESTDIR)$(BINDIR)
+ $(INSTALL) -d -m 0755 $(DESTDIR)$(MANDIR)
+ $(INSTALL) -d -m 0755 $(DESTDIR)$(MANDIR)/man1
+ $(INSTALL) -m 0644 $(srcdir)/cdparanoia.1 $(DESTDIR)$(MANDIR)/man1
+ $(INSTALL) -d -m 0755 $(DESTDIR)$(INCLUDEDIR)
+ $(INSTALL) -m 0644 $(srcdir)/paranoia/cdda_paranoia.h $(DESTDIR)$(INCLUDEDIR)
+ $(INSTALL) -d -m 0755 $(DESTDIR)$(LIBDIR)
+ $(INSTALL) -m 0755 $(srcdir)/paranoia/libcdda_paranoia.so.0.$(VERSION) $(DESTDIR)$(LIBDIR)
+ $(INSTALL) -m 0644 $(srcdir)/paranoia/libcdda_paranoia.a $(DESTDIR)$(LIBDIR)
+ $(INSTALL) -m 0644 $(srcdir)/interface/cdda_interface.h $(DESTDIR)$(INCLUDEDIR)
+ $(INSTALL) -m 0755 $(srcdir)/interface/libcdda_interface.so.0.$(VERSION) $(DESTDIR)$(LIBDIR)
+ $(INSTALL) -m 0644 $(srcdir)/interface/libcdda_interface.a $(DESTDIR)$(LIBDIR)
+ $(INSTALL) -m 0644 $(srcdir)/utils.h $(DESTDIR)$(INCLUDEDIR)
ln -fs libcdda_interface.so.0.$(VERSION) \
- $(LIBDIR)/libcdda_interface.so.0
+ $(DESTDIR)$(LIBDIR)/libcdda_interface.so.0
ln -fs libcdda_interface.so.0.$(VERSION) \
- $(LIBDIR)/libcdda_interface.so
+ $(DESTDIR)$(LIBDIR)/libcdda_interface.so
ln -fs libcdda_paranoia.so.0.$(VERSION) \
- $(LIBDIR)/libcdda_paranoia.so.0
+ $(DESTDIR)$(LIBDIR)/libcdda_paranoia.so.0
ln -fs libcdda_paranoia.so.0.$(VERSION) \
- $(LIBDIR)/libcdda_paranoia.so
+ $(DESTDIR)$(LIBDIR)/libcdda_paranoia.so
cdparanoia: $(OFILES) $(LIBDEP)
$(LD) $(CFLAGS) $(LDFLAGS) $(OFILES) \

View File

@ -1,24 +1,24 @@
diff -pruN cdparanoia-III-10.2.orig/interface/Makefile.in cdparanoia-III-10.2/interface/Makefile.in
--- cdparanoia-III-10.2.orig/interface/Makefile.in 2011-12-30 16:30:42.292074083 +1100
+++ cdparanoia-III-10.2/interface/Makefile.in 2011-12-30 16:30:59.983074083 +1100
diff -up cdparanoia-III-10.2/interface/Makefile.in.jx cdparanoia-III-10.2/interface/Makefile.in
--- cdparanoia-III-10.2/interface/Makefile.in.jx 2008-08-21 12:08:54.000000000 -0400
+++ cdparanoia-III-10.2/interface/Makefile.in 2018-03-07 13:12:53.999947802 -0500
@@ -46,7 +46,7 @@ libcdda_interface.a: $(OFILES)
$(RANLIB) libcdda_interface.a
libcdda_interface.so: $(OFILES)
- $(CC) -fpic -shared -o libcdda_interface.so.0.$(VERSION) -Wl,-soname -Wl,libcdda_interface.so.0 $(OFILES) $(LIBS)
+ $(CC) -fpic -shared $(LDFLAGS) -o libcdda_interface.so.0.$(VERSION) -Wl,-soname -Wl,libcdda_interface.so.0 $(OFILES) $(LIBS)
+ $(CC) $(LDFLAGS) -fpic -shared -o libcdda_interface.so.0.$(VERSION) -Wl,-soname -Wl,libcdda_interface.so.0 $(OFILES) $(LIBS)
[ -e libcdda_interface.so.0 ] || ln -s libcdda_interface.so.0.$(VERSION) libcdda_interface.so.0
[ -e libcdda_interface.so ] || ln -s libcdda_interface.so.0.$(VERSION) libcdda_interface.so
diff -pruN cdparanoia-III-10.2.orig/paranoia/Makefile.in cdparanoia-III-10.2/paranoia/Makefile.in
--- cdparanoia-III-10.2.orig/paranoia/Makefile.in 2011-12-30 16:30:42.292074083 +1100
+++ cdparanoia-III-10.2/paranoia/Makefile.in 2011-12-30 16:31:53.520074087 +1100
diff -up cdparanoia-III-10.2/paranoia/Makefile.in.jx cdparanoia-III-10.2/paranoia/Makefile.in
--- cdparanoia-III-10.2/paranoia/Makefile.in.jx 2008-09-04 15:02:47.000000000 -0400
+++ cdparanoia-III-10.2/paranoia/Makefile.in 2018-03-07 13:12:39.352765050 -0500
@@ -44,7 +44,7 @@ libcdda_paranoia.a: $(OFILES)
$(RANLIB) libcdda_paranoia.a
libcdda_paranoia.so: $(OFILES)
- $(CC) -fpic -shared -o libcdda_paranoia.so.0.$(VERSION) -Wl,-soname -Wl,libcdda_paranoia.so.0 $(OFILES) -L ../interface -lcdda_interface
+ $(CC) -fpic -shared $(LDFLAGS) -o libcdda_paranoia.so.0.$(VERSION) -Wl,-soname -Wl,libcdda_paranoia.so.0 $(OFILES) -L ../interface -lcdda_interface
+ $(CC) $(LDFLAGS) -fpic -shared -o libcdda_paranoia.so.0.$(VERSION) -Wl,-soname -Wl,libcdda_paranoia.so.0 $(OFILES) -L ../interface -lcdda_interface
[ -e libcdda_paranoia.so.0 ] || ln -s libcdda_paranoia.so.0.$(VERSION) libcdda_paranoia.so.0
[ -e libcdda_paranoia.so ] || ln -s libcdda_paranoia.so.0.$(VERSION) libcdda_paranoia.so

View File

@ -0,0 +1,27 @@
Index: cdparanoia-III-10.2/configure
===================================================================
--- cdparanoia-III-10.2.orig/configure
+++ cdparanoia-III-10.2/configure
@@ -1289,9 +1289,6 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu
-cp $srcdir/configure.guess $srcdir/config.guess
-cp $srcdir/configure.sub $srcdir/config.sub
-
ac_aux_dir=
for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
if test -f $ac_dir/install-sh; then
Index: cdparanoia-III-10.2/configure.in
===================================================================
--- cdparanoia-III-10.2.orig/configure.in
+++ cdparanoia-III-10.2/configure.in
@@ -1,8 +1,5 @@
AC_INIT(interface/interface.c)
-cp $srcdir/configure.guess $srcdir/config.guess
-cp $srcdir/configure.sub $srcdir/config.sub
-
AC_CANONICAL_HOST
if test -z "$CC"; then