libao: Update to 1.2.2

Fixes a NULL pointer dereference, among other issues.

Make libao-sun the default driver for NetBSD.
This commit is contained in:
nia 2019-11-24 00:35:56 +00:00
parent 53c15001de
commit 142152cd9d
17 changed files with 74 additions and 182 deletions

View file

@ -1,10 +1,10 @@
# $NetBSD: Makefile,v 1.3 2013/04/06 15:46:33 rodent Exp $
# $NetBSD: Makefile,v 1.4 2019/11/24 00:35:56 nia Exp $
.include "../../audio/libao/Makefile.common"
PKGNAME= ${DISTNAME:S/libao/libao-alsa/}
COMMENT+= (OSS plugin)
COMMENT+= (ALSA plugin)
CONFIGURE_ARGS= --enable-alsa
BUILD_DIRS= src/plugins/alsa

View file

@ -1,10 +1,10 @@
# $NetBSD: Makefile,v 1.15 2014/02/06 18:37:23 wiz Exp $
# $NetBSD: Makefile,v 1.16 2019/11/24 00:35:56 nia Exp $
.include "../../audio/libao/Makefile.common"
PKGNAME= ${DISTNAME:S/libao/libao-esound/}
COMMENT+= (esound plugin)
COMMENT+= (ESD plugin)
CONFIGURE_ARGS:= ${CONFIGURE_ARGS:S/disable-esd/enable-esd/g}
BUILD_DIRS= src/plugins/esd

View file

@ -1,4 +1,4 @@
# $NetBSD: Makefile,v 1.7 2013/04/06 15:46:33 rodent Exp $
# $NetBSD: Makefile,v 1.8 2019/11/24 00:35:57 nia Exp $
.include "../../audio/libao/Makefile.common"
@ -8,7 +8,7 @@ COMMENT+= (MacOS X plugin)
ONLY_FOR_PLATFORM+= Darwin-*-*
CONFIGURE_ARGS:= ${CONFIGURE_ARGS:S/ENABLE_MACOSX=no/ENABLE_MACOSX=yes/g}
CONFIGURE_ENV:= ${CONFIGURE_ENV:S/have_macosx=no//1}
BUILD_DIRS= src/plugins/macosx
INSTALL_DIRS= src/plugins/macosx

View file

@ -1,10 +1,10 @@
# $NetBSD: Makefile,v 1.2 2012/02/15 21:50:17 hans Exp $
# $NetBSD: Makefile,v 1.3 2019/11/24 00:35:57 nia Exp $
.include "../../audio/libao/Makefile.common"
PKGNAME= ${DISTNAME:S/libao/libao-nas/}
COMMENT+= (nas plugin)
COMMENT+= (NAS plugin)
CONFIGURE_ARGS:= ${CONFIGURE_ARGS:S/disable-nas/enable-nas/g}
BUILD_DIRS= src/plugins/nas

View file

@ -1,4 +1,4 @@
# $NetBSD: Makefile,v 1.10 2013/04/06 15:46:34 rodent Exp $
# $NetBSD: Makefile,v 1.11 2019/11/24 00:35:57 nia Exp $
.include "../../audio/libao/Makefile.common"
@ -8,7 +8,9 @@ COMMENT+= (OSS plugin)
NOT_FOR_PLATFORM+= Darwin-*-* Interix-*-* SunOS-5.[0-9]-* SunOS-5.10-*
CONFIGURE_ARGS:= ${CONFIGURE_ARGS:S/ENABLE_OSS=no/ENABLE_OSS=yes/g}
CONFIGURE_ENV:= ${CONFIGURE_ENV:S/ac_cv_header_sys_soundcard_h=no//1}
CONFIGURE_ENV:= ${CONFIGURE_ENV:S/ac_cv_header_machine_soundcard_h=no//1}
BUILD_DIRS= src/plugins/oss
INSTALL_DIRS= src/plugins/oss

View file

@ -1,11 +1,10 @@
# $NetBSD: Makefile,v 1.21 2019/09/18 14:17:05 ryoon Exp $
# $NetBSD: Makefile,v 1.22 2019/11/24 00:35:57 nia Exp $
.include "../../audio/libao/Makefile.common"
PKGNAME= ${DISTNAME:S/libao/libao-pulse/}
PKGREVISION= 10
COMMENT+= (pulse plugin)
COMMENT+= (PulseAudio plugin)
CONFIGURE_ARGS:= ${CONFIGURE_ARGS:S/disable-pulse/enable-pulse/g}
BUILD_DIRS= src/plugins/pulse

View file

@ -1,4 +1,4 @@
# $NetBSD: Makefile,v 1.10 2016/03/27 22:45:48 jperkin Exp $
# $NetBSD: Makefile,v 1.11 2019/11/24 00:35:57 nia Exp $
.include "../../audio/libao/Makefile.common"
@ -9,7 +9,7 @@ COMMENT+= (Sun audio plugin)
# no support for the sun audio interface
NOT_FOR_PLATFORM+= Darwin-*-* DragonFly-*-* FreeBSD-*-* Linux-*-*
CONFIGURE_ARGS:= ${CONFIGURE_ARGS:S/ENABLE_SUN_AUDIO=no/ENABLE_SUN_AUDIO=yes/g}
CONFIGURE_ENV:= ${CONFIGURE_ENV:S/ac_cv_header_sys_audioio_h=no//1}
BUILD_DIRS= src/plugins/sun
INSTALL_DIRS= src/plugins/sun

View file

@ -1,17 +0,0 @@
===========================================================================
$NetBSD: MESSAGE.common,v 1.3 2008/12/18 16:36:11 jmcneill Exp $
This libao package provides its core library but no output plugins
by itself. You will have to install an audio/libao-* plugin package
in order to get audio working.
libao-arts -- aRts plugin
libao-esound -- EsounD (ESD or Enlighten Sound Daemon) plugin
libao-macosx -- MacOS X plugin
libao-oss -- OSS (Open Sound System) plugin
libao-pulse -- PulseAudio plugin
libao-sun -- Sun audio plugin
Not all are available on every platform.
===========================================================================

View file

@ -1,8 +1,7 @@
# $NetBSD: Makefile,v 1.34 2014/10/09 14:05:56 wiz Exp $
# $NetBSD: Makefile,v 1.35 2019/11/24 00:35:56 nia Exp $
.include "Makefile.common"
post-install:
${INSTALL_DATA_DIR} ${DESTDIR}${PREFIX}/lib/ao/plugins-4
INSTALLATION_DIRS+= lib/ao/plugins-4
.include "../../mk/bsd.pkg.mk"

View file

@ -1,4 +1,4 @@
# $NetBSD: Makefile.common,v 1.39 2017/08/16 20:21:03 wiz Exp $
# $NetBSD: Makefile.common,v 1.40 2019/11/24 00:35:56 nia Exp $
#
# used by audio/libao-alsa/Makefile
# used by audio/libao-arts/Makefile
@ -9,9 +9,9 @@
# used by audio/libao-sun/Makefile
# used by audio/libao-pulse/Makefile
DISTNAME= libao-1.2.0
DISTNAME= libao-1.2.2
CATEGORIES= audio devel
MASTER_SITES= http://downloads.xiph.org/releases/ao/
MASTER_SITES= ${MASTER_SITE_GITHUB:=xiph/}
MAINTAINER= pkgsrc-users@NetBSD.org
HOMEPAGE= https://www.xiph.org/ao/
@ -21,28 +21,34 @@ LICENSE= gnu-gpl-v2
DISTINFO_FILE= ${.CURDIR}/../../audio/libao/distinfo
PATCHDIR= ${.CURDIR}/../../audio/libao/patches
GNU_CONFIGURE= yes
USE_TOOLS+= gmake pkg-config
USE_LIBTOOL= yes
MAKE_FLAGS+= MANDIR=${PREFIX}/${PKGMANDIR}
MAKE_FLAGS+= mandir=${PREFIX}/${PKGMANDIR}
GNU_CONFIGURE= yes
USE_TOOLS+= autoreconf autoconf automake
USE_TOOLS+= gmake pkg-config
USE_LIBTOOL= yes
MAKE_FLAGS+= MANDIR=${PREFIX}/${PKGMANDIR}
MAKE_FLAGS+= mandir=${PREFIX}/${PKGMANDIR}
PKGCONFIG_OVERRIDE+= ao.pc.in
CONFIGURE_ARGS+= --disable-alsa
CONFIGURE_ARGS+= --disable-alsa09
CONFIGURE_ARGS+= --disable-arts
CONFIGURE_ARGS+= --disable-esd
CONFIGURE_ARGS+= --disable-esdtest
CONFIGURE_ARGS+= --disable-nas
CONFIGURE_ARGS+= --disable-pulse
CONFIGURE_ARGS+= ENABLE_AIX_AUDIO=no
CONFIGURE_ARGS+= ENABLE_IRIX=no
CONFIGURE_ARGS+= ENABLE_OSS=no
CONFIGURE_ARGS+= ENABLE_SUN_AUDIO=no
CONFIGURE_ARGS+= ENABLE_MACOSX=no
CONFIGURE_ARGS+= ENABLE_SOLARIS=no
CONFIGURE_ENV+= ac_cv_header_sys_audio_h=no # disable AIX audio by default
CONFIGURE_ENV+= ac_cv_lib_audio_ALwritesamps=no # disable IRIX audio by default
CONFIGURE_ENV+= ac_cv_header_sys_soundcard_h=no # disable OSS by default
CONFIGURE_ENV+= ac_cv_header_machine_soundcard_h=no
CONFIGURE_ENV+= ac_cv_header_sys_audioio_h=no # disable Sun audio by default
CONFIGURE_ENV+= ac_cv_header_sndio_h=no # disable sndio by default
CONFIGURE_ENV+= have_macosx=no # disable macOS audio by default
MAKE_ENV+= DLLIB=${BUILDLINK_LDADD.dl}
MAKE_ENV+= DLLIB=${BUILDLINK_LDADD.dl:Q}
pre-configure:
cd ${WRKSRC} && autoreconf -isf
.include "../../mk/dlopen.buildlink3.mk"
.include "../../mk/oss.buildlink3.mk"

View file

@ -1,4 +1,4 @@
# $NetBSD: buildlink3.mk,v 1.16 2018/01/07 13:03:54 rillig Exp $
# $NetBSD: buildlink3.mk,v 1.17 2019/11/24 00:35:56 nia Exp $
BUILDLINK_TREE+= libao
@ -11,10 +11,14 @@ BUILDLINK_PKGSRCDIR.libao?= ../../audio/libao
.if !defined(_LIBAO_BUILDING_PLUGIN)
. include "../../mk/bsd.fast.prefs.mk"
. if ${OPSYS} != "Darwin" && ${OPSYS} != "Interix" && ${OPSYS} != "SunOS"
_LIBAO_DEFAULT_PLUGIN= oss
. elif ${OPSYS} == "NetBSD" || ${OPSYS} == "SunOS"
. if ${OPSYS} == "NetBSD" || ${OPSYS} == "SunOS"
_LIBAO_DEFAULT_PLUGIN= sun
. elif ${OPSYS} == "Linux"
_LIBAO_DEFAULT_PLUGIN= alsa
. elif ${OPSYS} == "Darwin"
_LIBAO_DEFAULT_PLUGIN= macosx
. elif ${OPSYS} != "Interix"
_LIBAO_DEFAULT_PLUGIN= oss
. else
_LIBAO_DEFAULT_PLUGIN=
. endif

View file

@ -1,10 +1,8 @@
$NetBSD: distinfo,v 1.25 2015/11/03 01:12:36 agc Exp $
$NetBSD: distinfo,v 1.26 2019/11/24 00:35:56 nia Exp $
SHA1 (libao-1.2.0.tar.gz) = 6b1d2c6a2e388e3bb6ebea158d51afef18aacc56
RMD160 (libao-1.2.0.tar.gz) = 00921bf311f8d7a2be1f860221811924402beebd
SHA512 (libao-1.2.0.tar.gz) = 9456953826c188d67129ad78366bb86d6243499f2cd340d20d61366f7e40a33f3f8ab601c7f18ce9e24aa22f898093b482b2415b7e428c1486ef7e5ac27b3ee4
Size (libao-1.2.0.tar.gz) = 464596 bytes
SHA1 (patch-ab) = dbab16863b62b1df33444ceb518d3c5a11b590fd
SHA1 (patch-ae) = 55f13b97d76f605cd99d948e3e85ffff44e5546a
SHA1 (patch-af) = 6c71ac364615a914771fc4951c6ce7eaf0f02bf1
SHA1 (patch-src_plugins_alsa_Makefile.in) = 44dfc6371022c135219027702511897bad228ecb
SHA1 (libao-1.2.2.tar.gz) = aa2a6ac0df63c702e46477ea5ce4a9b32e0d4306
RMD160 (libao-1.2.2.tar.gz) = d65fa3dc31b591d22bb8a47c71a91615cc1919cf
SHA512 (libao-1.2.2.tar.gz) = d2736d25b60862e7d7469611ce31b1df40a4366ab160e2ff1b46919ae91692d1596c8468e4f016303b306fc3ac1bddc7b727f535a362f403c3fe7c6532e9045a
Size (libao-1.2.2.tar.gz) = 96134 bytes
SHA1 (patch-src_plugins_alsa_ao__alsa.c) = 9047608f232c4e4bfd5e4b3fcac3831750b0eef3
SHA1 (patch-src_plugins_sun_ao__sun.c) = 6ba6d6ae4311a8a48dd7bb55e33d4516ac68b607

View file

@ -1,13 +0,0 @@
$NetBSD: patch-ab,v 1.8 2007/11/30 17:50:31 wiz Exp $
--- src/plugins/oss/Makefile.in.orig 2007-05-24 10:51:47.000000000 +0000
+++ src/plugins/oss/Makefile.in
@@ -222,7 +222,7 @@ AUTOMAKE_OPTIONS = foreign
@HAVE_OSS_TRUE@osssources = ao_oss.c
INCLUDES = -I$(top_builddir)/include/ao -I$(top_srcdir)/include
lib_LTLIBRARIES = $(ossltlibs)
-liboss_la_LDFLAGS = @PLUGIN_LDFLAGS@
+liboss_la_LDFLAGS = @PLUGIN_LDFLAGS@ ${LIBOSSAUDIO}
liboss_la_SOURCES = $(osssources)
EXTRA_DIST = ao_oss.c
all: all-am

View file

@ -1,81 +0,0 @@
$NetBSD: patch-ae,v 1.9 2010/05/19 18:17:27 drochner Exp $
--- configure.orig 2010-03-26 01:24:37.000000000 +0000
+++ configure
@@ -13132,6 +13132,10 @@ else
BUILD_ESD="yes"
fi
+if test "$BUILD_ESD" = "no"; then
+ HAVE_ESD_TRUE='#'
+ HAVE_ESD_FALSE=
+fi;
if test "$BUILD_ESD" = "yes"; then
@@ -13739,6 +13743,10 @@ else
HAVE_OSS_FALSE=
fi
+if test "x${ENABLE_OSS}" = xno; then
+ HAVE_OSS_TRUE='#'
+ HAVE_OSS_FALSE=
+fi
have_alsa="no";
@@ -14304,6 +14312,10 @@ else
HAVE_SUN_AUDIO_FALSE=
fi
+if test "x${ENABLE_SUN_AUDIO}" = xno; then
+ HAVE_SUN_AUDIO_TRUE='#'
+ HAVE_SUN_AUDIO_FALSE=
+fi
have_sndio="no";
@@ -14782,6 +14794,10 @@ else
HAVE_AIX_AUDIO_FALSE=
fi
+if test "x${ENABLE_AIX_AUDIO}" = xno; then
+ HAVE_AIX_AUDIO_TRUE='#'
+ HAVE_AIX_AUDIO_FALSE=
+fi
# Check whether --enable-arts was given.
@@ -15145,6 +15161,10 @@ else
HAVE_IRIX_FALSE=
fi
+if test "x${ENABLE_IRIX}" = xno; then
+ HAVE_IRIX_TRUE='#'
+ HAVE_IRIX_FALSE=
+fi
case $host in
@@ -15163,6 +15183,10 @@ else
HAVE_MACOSX_FALSE=
fi
+if test "x${ENABLE_MACOSX}" = xno; then
+ HAVE_MACOSX_TRUE='#'
+ HAVE_MACOSX_FALSE=
+fi
@@ -16921,6 +16945,10 @@ else
HAVE_SOLARIS_FALSE=
fi
+if test "x${ENABLE_SOLARIS}" = xno; then
+ HAVE_SOLARIS_TRUE='#'
+ HAVE_SOLARIS_FALSE=
+fi

View file

@ -1,22 +0,0 @@
$NetBSD: patch-src_plugins_alsa_Makefile.in,v 1.1 2014/02/18 20:49:00 wiz Exp $
--- src/plugins/alsa/Makefile.in.orig 2014-01-27 23:57:41.000000000 +0000
+++ src/plugins/alsa/Makefile.in
@@ -118,7 +118,7 @@ am__uninstall_files_from_dir = { \
}
am__installdirs = "$(DESTDIR)$(libdir)"
LTLIBRARIES = $(lib_LTLIBRARIES)
-libalsa_la_DEPENDENCIES = ../../libao.la
+libalsa_la_DEPENDENCIES = $(PREFIX)/lib/libao.la
am__libalsa_la_SOURCES_DIST = ao_alsa.c
@HAVE_ALSA_TRUE@am__objects_1 = ao_alsa.lo
am_libalsa_la_OBJECTS = $(am__objects_1)
@@ -351,7 +351,7 @@ AUTOMAKE_OPTIONS = foreign
INCLUDES = -I$(top_builddir)/include/ao -I$(top_srcdir)/include
lib_LTLIBRARIES = $(alsaltlibs)
libalsa_la_LDFLAGS = @PLUGIN_LDFLAGS@
-libalsa_la_LIBADD = @ALSA_LIBS@ ../../libao.la
+libalsa_la_LIBADD = @ALSA_LIBS@ $(PREFIX)/lib/libao.la
libalsa_la_SOURCES = $(alsasources)
EXTRA_DIST = ao_alsa.c
all: all-am

View file

@ -1,6 +1,8 @@
$NetBSD: patch-af,v 1.6 2014/02/06 18:37:08 wiz Exp $
$NetBSD: patch-src_plugins_alsa_ao__alsa.c,v 1.1 2019/11/24 00:35:56 nia Exp $
--- src/plugins/alsa/ao_alsa.c.orig 2014-01-27 17:02:05.000000000 +0000
Allow building on non-Linux.
--- src/plugins/alsa/ao_alsa.c.orig 2016-11-14 08:03:30.000000000 +0000
+++ src/plugins/alsa/ao_alsa.c
@@ -39,6 +39,10 @@
#include <alsa/asoundlib.h>

View file

@ -0,0 +1,15 @@
$NetBSD: patch-src_plugins_sun_ao__sun.c,v 1.1 2019/11/24 00:35:56 nia Exp $
Fix device selection.
--- src/plugins/sun/ao_sun.c.orig 2016-11-14 08:03:30.000000000 +0000
+++ src/plugins/sun/ao_sun.c
@@ -160,7 +160,7 @@ int ao_plugin_open(ao_device *device, ao
if(internal->dev==NULL){
char buf[80];
- sprintf(buf,"/dev/sound/%d",internal->id);
+ snprintf(buf,sizeof(buf),"/dev/audio%d",internal->id);
internal->dev=strdup(buf);
}