diff --git a/README.md b/README.md index b3aee42..22135c0 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,4 @@ # alsa-plugins +Plugins for the Advanced Linux Sound Architecture (ALSA). + diff --git a/alsa-plugins.spec b/alsa-plugins.spec new file mode 100644 index 0000000..e689287 --- /dev/null +++ b/alsa-plugins.spec @@ -0,0 +1,188 @@ +Name: alsa-plugins +Version: 1.2.7.1 +Release: 1mamba +Summary: Plugins for the Advanced Linux Sound Architecture (ALSA) +Group: System/Libraries +Vendor: openmamba +Distribution: openmamba +Packager: Silvan Calarco +URL: https://www.alsa-project.org/wiki/Main_Page +Source: https://github.com/alsa-project/alsa-plugins.git/v%{version}/alsa-plugins-%{version}.tar.bz2 +Patch0: libalsa-plugins-1.0.23-jack_torben.patch +Patch1: libalsa-plugins-1.1.7-upstream-fix-a52_close.patch +License: LGPL +## AUTOBUILDREQ-BEGIN +BuildRequires: glibc-devel +BuildRequires: libalsa-devel +BuildRequires: libavcodec-ffmpeg-devel +BuildRequires: libavutil-ffmpeg-devel +BuildRequires: libjack-devel +BuildRequires: libpulseaudio-devel +BuildRequires: libsamplerate-devel +BuildRequires: libspeexdsp-devel +BuildRequires: libswresample-ffmpeg-devel +## AUTOBUILDREQ-END +BuildRequires: libavcodec-ffmpeg-devel >= 4.1 +BuildRequires: libavutil-ffmpeg-devel >= 4.1 +BuildRequires: libpulseaudio-devel >= 9.0-1mamba +Provides: libalsa-plugins +Obsoletes: libalsa-plugins <= 1.2.6 + +%description +Plugins for the Advanced Linux Sound Architecture (ALSA). + +%debug_package + +%prep +%setup -q +#%patch0 -p1 +#%patch1 -p1 +autoreconf -f -i + +%build +%configure \ + --disable-lavrate + +%make + +%install +[ "%{buildroot}" != / ] && rm -rf "%{buildroot}" +%makeinstall + +%clean +[ "%{buildroot}" != / ] && rm -rf "%{buildroot}" + +%files +%defattr(-,root,root) +%{_sysconfdir}/alsa/conf.d/*.conf +%{_sysconfdir}/alsa/conf.d/*.conf.example +%{_libdir}/alsa-lib/libasound_module_* +%{_datadir}/alsa/alsa.conf.d/*.conf +%doc COPYING + +%changelog +* Thu Jan 05 2023 Silvan Calarco 1.2.7.1-1mamba +- update to 1.2.7.1 + +* Sat Feb 05 2022 Silvan Calarco 1.2.6-1mamba +- update to 1.2.6 + +* Wed Jun 16 2021 Automatic Build System 1.2.5-1mamba +- automatic update by autodist + +* Fri Feb 21 2020 Automatic Build System 1.2.2-1mamba +- automatic version update by autodist + +* Thu Nov 21 2019 Automatic Build System 1.2.1-1mamba +- automatic version update by autodist + +* Tue May 14 2019 Silvan Calarco 1.1.9-2mamba +- configure with --disable-lavrate to fix audacity (see https://bugs.archlinux.org/task/60586) + +* Tue May 14 2019 Silvan Calarco 1.1.9-1mamba +- update to 1.1.9 + +* Sun Jan 13 2019 Silvan Calarco 1.1.8-1mamba +- update to 1.1.8 + +* Tue Nov 27 2018 Silvan Calarco 1.1.7-3mamba +- upstream patch which should fix audacity + +* Sat Nov 24 2018 Silvan Calarco 1.1.7-2mamba +- rebuilt with ffmpeg 4.1 + +* Thu Oct 25 2018 Automatic Build System 1.1.7-1mamba +- automatic version update by autodist + +* Sun Apr 15 2018 Automatic Build System 1.1.6-1mamba +- automatic version update by autodist + +* Sat Nov 18 2017 Automatic Build System 1.1.5-1mamba +- automatic update by autodist + +* Sun Jun 18 2017 Automatic Build System 1.1.4-1mamba +- automatic version update by autodist + +* Sat Jun 25 2016 Automatic Build System 1.1.1-3mamba +- rebuilt by autoport with build requirements: libpulseaudio-devel>=9.0-1mamba + +* Mon Apr 25 2016 Silvan Calarco 1.1.1-2mamba +- rebuilt with pulseaudio 8.0 (arm) + +* Thu Apr 07 2016 Automatic Build System 1.1.1-1mamba +- automatic version update by autodist + +* Mon Nov 16 2015 Automatic Build System 1.1.0-1mamba +- automatic version update by autodist + +* Tue Mar 10 2015 Automatic Build System 1.0.29-1mamba +- automatic version update by autodist + +* Sun Jun 22 2014 Automatic Build System 1.0.28-1mamba +- automatic version update by autodist + +* Fri Mar 07 2014 Silvan Calarco 1.0.27-2mamba +- rebuilt with pulseaudio 4.0 + +* Sat Apr 13 2013 Automatic Build System 1.0.27-1mamba +- automatic version update by autodist + +* Sun Sep 23 2012 Automatic Build System 1.0.26-1mamba +- automatic version update by autodist + +* Fri Jan 27 2012 Automatic Build System 1.0.25-1mamba +- automatic version update by autodist + +* Sat Feb 05 2011 Automatic Build System 1.0.24-1mamba +- update to 1.0.24 + +* Mon Dec 13 2010 Silvan Calarco 1.0.23-2mamba +- jack_plug: added Torbenh patch from http://lists.linuxaudio.org/pipermail/linux-audio-user/2010-October/073562.html + +* Sat Apr 17 2010 Automatic Build System 1.0.23-1mamba +- automatic update to 1.0.23 by autodist + +* Wed Dec 16 2009 Automatic Build System 1.0.22-1mamba +- automatic update to 1.0.22 by autodist + +* Tue Sep 01 2009 Automatic Build System 1.0.21-1mamba +- automatic update to 1.0.21 by autodist + +* Thu May 07 2009 Automatic Build System 1.0.20-1mamba +- automatic update to 1.0.20 by autodist + +* Mon Jan 19 2009 Silvan Calarco 1.0.19-1mamba +- automatic update to 1.0.19 by autodist + +* Fri Jan 02 2009 Silvan Calarco 1.0.18rc3-1mamba +- automatic update by autodist + +* Wed Dec 10 2008 Silvan Calarco 1.0.18-3mamba +- automatic rebuild by autodist + +* Fri Nov 14 2008 Silvan Calarco 1.0.18-2mamba +- automatic rebuild by autodist + +* Thu Nov 13 2008 Silvan Calarco 1.0.18-1mamba +- automatic update to 1.0.18 by autodist + +* Thu Aug 21 2008 gil 1.0.17-1mamba +- update to 1.0.17 + +* Sun Feb 17 2008 Silvan Calarco 1.0.16-1mamba +- update to 1.0.16 + +* Thu Oct 18 2007 Silvan Calarco 1.0.15-1mamba +- update to 1.0.15 + +* Mon Jun 04 2007 Silvan Calarco 1.0.14-1mamba +- update to 1.0.14 + +* Fri Jan 26 2007 Silvan Calarco 1.0.13-2qilnx +- rebuilt + +* Sun Oct 01 2006 Silvan Calarco 1.0.13-1qilnx +- update to version 1.0.13 by autospec + +* Wed Sep 27 2006 Silvan Calarco 1.0.12-1qilnx +- package created by autospec diff --git a/libalsa-plugins-1.0.23-jack_torben.patch b/libalsa-plugins-1.0.23-jack_torben.patch new file mode 100644 index 0000000..4fb99fd --- /dev/null +++ b/libalsa-plugins-1.0.23-jack_torben.patch @@ -0,0 +1,59 @@ +diff -Nru alsa-plugins-1.0.23.orig//jack/pcm_jack.c alsa-plugins-1.0.23/jack/pcm_jack.c +--- alsa-plugins-1.0.23.orig//jack/pcm_jack.c 2010-04-16 13:11:10.000000000 +0200 ++++ alsa-plugins-1.0.23/jack/pcm_jack.c 2010-12-13 22:21:56.985418598 +0100 +@@ -315,7 +315,6 @@ + snd_pcm_jack_t *jack; + int err; + int fd[2]; +- static unsigned int num = 0; + char jack_client_name[32]; + + assert(pcmp); +@@ -341,14 +340,14 @@ + return -EINVAL; + } + +- if (snprintf(jack_client_name, sizeof(jack_client_name), "alsa-jack.%s%s.%d.%d", name, +- stream == SND_PCM_STREAM_PLAYBACK ? "P" : "C", getpid(), num++) ++ if (snprintf(jack_client_name, sizeof(jack_client_name), "%s_%s", name, ++ stream == SND_PCM_STREAM_PLAYBACK ? "P" : "C" ) + >= (int)sizeof(jack_client_name)) { + fprintf(stderr, "%s: WARNING: JACK client name '%s' truncated to %d characters, might not be unique\n", + __func__, jack_client_name, (int)strlen(jack_client_name)); + } + +- jack->client = jack_client_new(jack_client_name); ++ jack->client = jack_client_open(jack_client_name, JackNullOption, NULL); + + if (jack->client == 0) { + snd_pcm_jack_free(jack); +@@ -364,6 +363,7 @@ + socketpair(AF_LOCAL, SOCK_STREAM, 0, fd); + + jack->fd = fd[0]; ++ fcntl( jack->fd, F_SETFL, O_NONBLOCK ); + + jack->io.version = SND_PCM_IOPLUG_VERSION; + jack->io.name = "ALSA <-> JACK PCM I/O Plugin"; +@@ -397,6 +397,7 @@ + snd_config_t *playback_conf = NULL; + snd_config_t *capture_conf = NULL; + int err; ++ (void) root; + + snd_config_for_each(i, next, conf) { + snd_config_t *n = snd_config_iterator_entry(i); +@@ -405,6 +406,13 @@ + continue; + if (strcmp(id, "comment") == 0 || strcmp(id, "type") == 0 || strcmp(id, "hint") == 0) + continue; ++ if (strcmp(id, "client_name") == 0) { ++ const char *jack_name; ++ if (snd_config_get_string(n, &jack_name) < 0) ++ continue; ++ name = strdup(jack_name); ++ continue; ++ } + if (strcmp(id, "playback_ports") == 0) { + if (snd_config_get_type(n) != SND_CONFIG_TYPE_COMPOUND) { + SNDERR("Invalid type for %s", id); diff --git a/libalsa-plugins-1.1.7-upstream-fix-a52_close.patch b/libalsa-plugins-1.1.7-upstream-fix-a52_close.patch new file mode 100644 index 0000000..9b3a815 --- /dev/null +++ b/libalsa-plugins-1.1.7-upstream-fix-a52_close.patch @@ -0,0 +1,34 @@ +From a4e7e1282c57a2f4e83afe9a4008042d8b4c5bb9 Mon Sep 17 00:00:00 2001 +From: Jaroslav Kysela +Date: Tue, 23 Oct 2018 09:32:46 +0200 +Subject: [PATCH] a52_close: set slave to NULL to avoid double pcm free in + open fcn + +Signed-off-by: Jaroslav Kysela +--- + a52/pcm_a52.c | 7 +++++-- + 1 file changed, 5 insertions(+), 2 deletions(-) + +diff --git a/a52/pcm_a52.c b/a52/pcm_a52.c +index e431fd0..b005bc2 100644 +--- a/a52/pcm_a52.c ++++ b/a52/pcm_a52.c +@@ -654,10 +654,13 @@ static int a52_poll_revents(snd_pcm_ioplug_t *io, struct pollfd *pfd, + static int a52_close(snd_pcm_ioplug_t *io) + { + struct a52_ctx *rec = io->private_data; ++ snd_pcm_t *slave = rec->slave; + + a52_free(rec); +- if (rec->slave) +- return snd_pcm_close(rec->slave); ++ if (slave) { ++ rec->slave = NULL; ++ return snd_pcm_close(slave); ++ } + return 0; + } + +-- +1.7.11.7 +