media-libs/a52dec: fix musl

use getopt from glibc/musl instead of outdated bundled lib

Closes: https://bugs.gentoo.org/944997
Signed-off-by: Nicolas PARLANT <nicolas.parlant@parhuet.fr>
Part-of: https://github.com/gentoo/gentoo/pull/44685
Closes: https://github.com/gentoo/gentoo/pull/44685
Signed-off-by: Sam James <sam@gentoo.org>
This commit is contained in:
Nicolas PARLANT
2025-11-20 12:08:35 +01:00
committed by Sam James
parent d1e0499718
commit e447517c5c
2 changed files with 22 additions and 0 deletions

View File

@@ -23,6 +23,7 @@ PATCHES=(
"${FILESDIR}"/${P}-tests-optional.patch
"${FILESDIR}"/${P}-test-hidden-symbols.patch
"${FILESDIR}"/${P}-dont-mangle-cflags.patch
"${FILESDIR}"/${P}-rm_getopt.patch
)
src_prepare() {
@@ -31,6 +32,9 @@ src_prepare() {
sed -i -e 's:AM_CONFIG_HEADER:AC_CONFIG_HEADERS:' configure.in || die # bug #466978
mv configure.{in,ac} || die
# use getopt.h from glibc/musl, bug 944997
rm src/getopt.h || die
eautoreconf
filter-flags -fprefetch-loop-arrays

View File

@@ -0,0 +1,18 @@
see https://bugs.gentoo.org/944997
use getopt from glibc/musl instead, getopt.h must be removed too
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -1,10 +1,10 @@
bin_PROGRAMS = a52dec extract_a52
-a52dec_SOURCES = a52dec.c getopt.c gettimeofday.c
+a52dec_SOURCES = a52dec.c gettimeofday.c
a52dec_LDADD = $(top_builddir)/liba52/liba52.la \
$(top_builddir)/libao/libao.a @LIBAO_LIBS@
-extract_a52_SOURCES = extract_a52.c getopt.c
+extract_a52_SOURCES = extract_a52.c
man_MANS = a52dec.1 extract_a52.1
-EXTRA_DIST = configure.incl getopt.h gettimeofday.h $(man_MANS)
+EXTRA_DIST = configure.incl gettimeofday.h $(man_MANS)