From 2e7a5374dd164ea5aa543b6e8155cb681c4408aa Mon Sep 17 00:00:00 2001 From: ajacoutot Date: Fri, 25 May 2012 07:15:41 +0000 Subject: [PATCH] Update liba52 to 0.7.5-cvs snapshot. This was intended to be the 0.7.5 release but uptream project is essentially dead and the fixes and improvements since 0.7.4 are worth getting in. from Brad, maintainer timeout --- audio/liba52/Makefile | 42 ++++++++++--------- audio/liba52/distinfo | 10 ++--- audio/liba52/patches/patch-configure | 14 ------- audio/liba52/patches/patch-configure_in | 40 ++++++++++++++++++ audio/liba52/patches/patch-liba52_bitstream_c | 8 ++-- .../patches/patch-libao_audio_out_oss_c | 25 +++++------ audio/liba52/pkg/DESCR | 4 +- audio/liba52/pkg/PLIST | 10 +++-- 8 files changed, 92 insertions(+), 61 deletions(-) delete mode 100644 audio/liba52/patches/patch-configure create mode 100644 audio/liba52/patches/patch-configure_in diff --git a/audio/liba52/Makefile b/audio/liba52/Makefile index b1b4df4a2b9..f63e2a67be1 100644 --- a/audio/liba52/Makefile +++ b/audio/liba52/Makefile @@ -1,30 +1,34 @@ -#$OpenBSD: Makefile,v 1.17 2012/03/29 13:38:13 sthen Exp $ +# $OpenBSD: Makefile,v 1.18 2012/05/25 07:15:41 ajacoutot Exp $ +COMMENT = free library for decoding ATSC A/52 streams, aka AC-3 + +V = 0.7.5 +DISTNAME = a52dec-snapshot # 0.7.5-cvs +PKGNAME = liba52-${V} CATEGORIES = audio +MASTER_SITES = http://comstyle.com/source/ + +SHARED_LIBS = a52 1.0 -COMMENT = AC-3 decoding library -DISTNAME = a52dec-0.7.4 -PKGNAME = liba52-0.7.4 -REVISION = 2 -MASTER_SITES = http://liba52.sourceforge.net/files/ HOMEPAGE = http://liba52.sourceforge.net/ -SHARED_LIBS += a52 0.0 # .0.0 MAINTAINER = Marc Espie -CONFIGURE_STYLE = gnu -CONFIGURE_ARGS += ${CONFIGURE_SHARED} -MODGNU_CONFIG_GUESS_DIRS = ${WRKSRC}/autotools -SEPARATE_BUILD = Yes -USE_LIBTOOL = Yes -USE_GROFF = Yes - -# GPL +# GPLv2+ PERMIT_DISTFILES_CDROM = Yes -PERMIT_DISTFILES_FTP = Yes -PERMIT_PACKAGE_CDROM = Yes -PERMIT_PACKAGE_FTP = Yes +PERMIT_DISTFILES_FTP = Yes +PERMIT_PACKAGE_CDROM = Yes +PERMIT_PACKAGE_FTP = Yes -WANTLIB = c m ossaudio +WANTLIB = c m ossaudio + +WRKDIST = ${WRKDIR}/a52dec-${V}-cvs + +USE_LIBTOOL = Yes +SEPARATE_BUILD = Yes +CONFIGURE_STYLE = autoconf +AUTOCONF_VERSION = 2.59 +CONFIGURE_ARGS += ${CONFIGURE_SHARED} +MODGNU_CONFIG_GUESS_DIRS = ${WRKSRC}/autotools .include diff --git a/audio/liba52/distinfo b/audio/liba52/distinfo index b27bd39736a..e01d94e334e 100644 --- a/audio/liba52/distinfo +++ b/audio/liba52/distinfo @@ -1,5 +1,5 @@ -MD5 (a52dec-0.7.4.tar.gz) = yqn1vEQjLciu6nc/6la+gA== -RMD160 (a52dec-0.7.4.tar.gz) = W2OzTFhA5xgrczytQekWqNSHXrE= -SHA1 (a52dec-0.7.4.tar.gz) = ebM72NidrXQ2+FuRVK01ZnqjcyE= -SHA256 (a52dec-0.7.4.tar.gz) = oh1ySrOzkzMwGUNTaH34LEdbXfuZdRPu9MJd5shl7DM= -SIZE (a52dec-0.7.4.tar.gz) = 241507 +MD5 (a52dec-snapshot.tar.gz) = FynHUH92sNTMBFQJJsXQ1w== +RMD160 (a52dec-snapshot.tar.gz) = d3yeskVYwXuHgAdyCjlzGpYKHHM= +SHA1 (a52dec-snapshot.tar.gz) = LmSHj9xbzXnia4AgnnpEOyAT6cE= +SHA256 (a52dec-snapshot.tar.gz) = kETGWygUNg+s8B1Ndn17M8oXRlQLNa3158bZDkeFb/4= +SIZE (a52dec-snapshot.tar.gz) = 389367 diff --git a/audio/liba52/patches/patch-configure b/audio/liba52/patches/patch-configure deleted file mode 100644 index 97ac2e8bf0e..00000000000 --- a/audio/liba52/patches/patch-configure +++ /dev/null @@ -1,14 +0,0 @@ -$OpenBSD: patch-configure,v 1.1 2006/02/07 07:43:11 steven Exp $ ---- configure.orig Sun Jul 28 05:50:42 2002 -+++ configure Tue Feb 7 01:03:57 2006 -@@ -2751,9 +2751,8 @@ if test x"$GCC" = x"yes"; then - - - -- OPT_CFLAGS=`echo "$CFLAGS"|sed "s/-O[0-9]*//g"` -+ OPT_CFLAGS="$CFLAGS" - -- OPT_CFLAGS="$OPT_CFLAGS -O3" - echo "$as_me:$LINENO: checking if $CC supports $OPT_CFLAGS flags" >&5 - echo $ECHO_N "checking if $CC supports $OPT_CFLAGS flags... $ECHO_C" >&6 - SAVE_CFLAGS="$CFLAGS" diff --git a/audio/liba52/patches/patch-configure_in b/audio/liba52/patches/patch-configure_in new file mode 100644 index 00000000000..d616ee1b6ee --- /dev/null +++ b/audio/liba52/patches/patch-configure_in @@ -0,0 +1,40 @@ +$OpenBSD: patch-configure_in,v 1.1 2012/05/25 07:15:41 ajacoutot Exp $ +--- configure.in.orig Tue May 15 02:33:28 2012 ++++ configure.in Tue May 15 02:34:15 2012 +@@ -30,13 +30,6 @@ if test x"$GCC" = x"yes"; then + TRY_CFLAGS="$OPT_CFLAGS -Wall" + AC_TRY_CFLAGS([$TRY_CFLAGS $CFLAGS],[OPT_CFLAGS="$TRY_CFLAGS"]) + +- dnl -O3 +- changequote(<<,>>) +- TRY_CFLAGS=`echo "$OPT_CFLAGS $CFLAGS"|sed "s/-O[0-9]*//g"` +- changequote([,]) +- TRY_CFLAGS="$TRY_CFLAGS -O3" +- AC_TRY_CFLAGS([$TRY_CFLAGS],[OPT_CFLAGS="$TRY_CFLAGS"; CFLAGS=""]) +- + AC_ARG_ENABLE([debug], + [ --enable-debug debug mode configuration]) + if test x"$enable_debug" = x"yes"; then +@@ -50,22 +43,6 @@ if test x"$GCC" = x"yes"; then + dnl -fno-common + TRY_CFLAGS="$OPT_CFLAGS -fno-common" + AC_TRY_CFLAGS([$TRY_CFLAGS $CFLAGS],[OPT_CFLAGS="$TRY_CFLAGS"]) +- +- dnl arch-specific flags +- case "$host" in +- i?86-* | k?-*) +- case "$host" in +- i386-*) TRY_CFLAGS="$OPT_CFLAGS -mcpu=i386";; +- i486-*) TRY_CFLAGS="$OPT_CFLAGS -mcpu=i486";; +- i586-*) TRY_CFLAGS="$OPT_CFLAGS -mcpu=pentium";; +- i686-*) TRY_CFLAGS="$OPT_CFLAGS -mcpu=pentiumpro";; +- k6-*) TRY_CFLAGS="$OPT_CFLAGS -mcpu=k6";; +- esac +- AC_TRY_CFLAGS([$TRY_CFLAGS $CFLAGS],[OPT_CFLAGS="$TRY_CFLAGS"]);; +- sparc-* | sparc64-*) +- TRY_CFLAGS="$OPT_CFLAGS -mtune=ultrasparc" +- AC_TRY_CFLAGS([$TRY_CFLAGS $CFLAGS],[OPT_CFLAGS="$TRY_CFLAGS"]);; +- esac + elif test x"$CC" = x"tendracc"; then + dnl TenDRA portability checking compiler + TENDRA=yes diff --git a/audio/liba52/patches/patch-liba52_bitstream_c b/audio/liba52/patches/patch-liba52_bitstream_c index 73c1d19a4d1..692cddd85fb 100644 --- a/audio/liba52/patches/patch-liba52_bitstream_c +++ b/audio/liba52/patches/patch-liba52_bitstream_c @@ -1,6 +1,6 @@ -$OpenBSD: patch-liba52_bitstream_c,v 1.3 2002/08/22 12:19:17 espie Exp $ ---- liba52/bitstream.c.orig Sun Jul 28 03:52:06 2002 -+++ liba52/bitstream.c Thu Aug 22 13:51:10 2002 +$OpenBSD: patch-liba52_bitstream_c,v 1.4 2012/05/25 07:15:41 ajacoutot Exp $ +--- liba52/bitstream.c.orig Sat May 31 20:28:55 2003 ++++ liba52/bitstream.c Tue May 15 02:19:52 2012 @@ -23,6 +23,7 @@ #include "config.h" @@ -20,4 +20,4 @@ $OpenBSD: patch-liba52_bitstream_c,v 1.3 2002/08/22 12:19:17 espie Exp $ + align = (ptrdiff_t)buf & 3; state->buffer_start = (uint32_t *) (buf - align); state->bits_left = 0; - bitstream_get (state, align * 8); + state->current_word = 0; diff --git a/audio/liba52/patches/patch-libao_audio_out_oss_c b/audio/liba52/patches/patch-libao_audio_out_oss_c index 595733a8871..cdbbfdeafb8 100644 --- a/audio/liba52/patches/patch-libao_audio_out_oss_c +++ b/audio/liba52/patches/patch-libao_audio_out_oss_c @@ -1,15 +1,12 @@ -$OpenBSD: patch-libao_audio_out_oss_c,v 1.3 2002/08/22 12:19:17 espie Exp $ ---- libao/audio_out_oss.c.orig Sun Apr 28 12:23:02 2002 -+++ libao/audio_out_oss.c Thu Aug 22 13:49:19 2002 -@@ -153,9 +153,9 @@ static ao_instance_t * oss_open (int fla - instance->set_params = 1; - instance->flags = flags; +$OpenBSD: patch-libao_audio_out_oss_c,v 1.4 2012/05/25 07:15:41 ajacoutot Exp $ +--- libao/audio_out_oss.c.orig Sun Nov 30 19:24:58 2003 ++++ libao/audio_out_oss.c Tue May 15 02:24:59 2012 +@@ -48,7 +48,7 @@ + #include + #endif -- instance->fd = open ("/dev/dsp", O_WRONLY); -+ instance->fd = open ("/dev/audio", O_WRONLY); - if (instance->fd < 0) { -- fprintf (stderr, "Can not open /dev/dsp\n"); -+ fprintf (stderr, "Can not open /dev/audio\n"); - free (instance); - return NULL; - } +-#if defined(__NetBSD__) ++#if defined(__NetBSD__) || defined(__OpenBSD__) + #define OSS_DEVICE "/dev/audio" + #else + #define OSS_DEVICE "/dev/dsp" diff --git a/audio/liba52/pkg/DESCR b/audio/liba52/pkg/DESCR index 0d82e2a8a8c..5b7fa5039e4 100644 --- a/audio/liba52/pkg/DESCR +++ b/audio/liba52/pkg/DESCR @@ -1 +1,3 @@ -AC-3 decoding library, to use with DVDs. +It is a free library for decoding ATSC A/52 streams, aka AC-3. The +A/52 standard is used in a variety of applications, e.g., digital +television and DVD. diff --git a/audio/liba52/pkg/PLIST b/audio/liba52/pkg/PLIST index eb85a735418..e986487fa40 100644 --- a/audio/liba52/pkg/PLIST +++ b/audio/liba52/pkg/PLIST @@ -1,6 +1,7 @@ -@comment $OpenBSD: PLIST,v 1.4 2004/08/05 03:28:12 espie Exp $ -bin/a52dec -bin/extract_a52 +@comment $OpenBSD: PLIST,v 1.5 2012/05/25 07:15:41 ajacoutot Exp $ +%%SHARED%% +@bin bin/a52dec +@bin bin/extract_a52 include/a52dec/ include/a52dec/a52.h include/a52dec/attributes.h @@ -8,6 +9,7 @@ include/a52dec/audio_out.h include/a52dec/mm_accel.h lib/liba52.a lib/liba52.la +lib/pkgconfig/ +lib/pkgconfig/liba52.pc @man man/man1/a52dec.1 @man man/man1/extract_a52.1 -%%SHARED%%