add some media-sound packages

This commit is contained in:
2020-05-10 13:52:30 +03:00
parent b2d5f88926
commit 236b78d73f
14 changed files with 561 additions and 0 deletions

View File

@@ -0,0 +1,3 @@
AUX pulseaudio-11.1-disable-flat-volumes.patch 1992 BLAKE2B 1ffbaf129d57abc7c02f430bdd59a76384456d7ef020e9765bc0541327279dcf7d005d87fe989fd0c89b2767564f99af87ece8c374e1d67c5d1cae1695f0819c SHA512 603f60ef38aeba83038fe5dc9e5f6a82e42d10a7f057f158b489dd04857c3bc8203b728d9df6736314ee3002648390cd564fdce347f2e6791e901a47041dd1fc
DIST pulseaudio-13.0.tar.xz 1901768 BLAKE2B 651a80f54525f196bcb036d893fedd4d9f34e10459918281397a45f498c31bff0d0c836f4e64aab5ac2612ffd5a0cab1a41ea710bbee5fd34dfc9ea1236deea9 SHA512 d445b8ccd43029a0ca0e456fc9291a79d3434d6496ead7eb329ab348d5249235e8bde6cf2be68765d8f761452dbe1486fb10c739e40b1e67ed75787bbd24ac0c
EBUILD pulseaudio-13.0.ebuild 5363 BLAKE2B 948a4b8d20c5b039043759bba33286516c4e2a9eec4f31e996740949fe984fd3f56731ee8f75c4f8904a58859918f12bddb55dea44f221e754592ace54f49a4e SHA512 6ef9c5468f8f8a9e52cd8ad0214399da4664294ae7e7d98bd69f8a6b6478e53913f0a86bad5c2162971104cba57c4a8315dac8dacf4473bf0cfe2287cbbc69bc

View File

@@ -0,0 +1,48 @@
diff -up a/man/pulse-daemon.conf.5.xml.in b/man/pulse-daemon.conf.5.xml.in
--- a/man/pulse-daemon.conf.5.xml.in 2016-05-26 23:21:17.000000000 -0500
+++ b/man/pulse-daemon.conf.5.xml.in 2016-05-31 10:01:55.679976730 -0500
@@ -220,7 +220,7 @@ License along with PulseAudio; if not, s
<p><opt>flat-volumes=</opt> Enable 'flat' volumes, i.e. where
possible let the sink volume equal the maximum of the volumes of
the inputs connected to it. Takes a boolean argument, defaults
- to <opt>yes</opt>.</p>
+ to <opt>no</opt>.</p>
</option>
</section>
diff -up a/src/daemon/daemon-conf.c b/src/daemon/daemon-conf.c
--- a/src/daemon/daemon-conf.c 2016-05-26 23:21:17.000000000 -0500
+++ b/src/daemon/daemon-conf.c 2016-05-31 10:01:55.680976735 -0500
@@ -68,7 +68,7 @@ static const pa_daemon_conf default_conf
.realtime_priority = 5, /* Half of JACK's default rtprio */
.disallow_module_loading = false,
.disallow_exit = false,
- .flat_volumes = true,
+ .flat_volumes = false,
.exit_idle_time = 20,
.scache_idle_time = 20,
.script_commands = NULL,
diff -up a/src/daemon/daemon.conf.in b/src/daemon/daemon.conf.in
--- a/src/daemon/daemon.conf.in 2016-05-31 10:01:55.680976735 -0500
+++ b/src/daemon/daemon.conf.in 2016-05-31 10:02:28.048133267 -0500
@@ -57,7 +57,7 @@ ifelse(@HAVE_DBUS@, 1, [dnl
; enable-lfe-remixing = no
; lfe-crossover-freq = 0
-; flat-volumes = yes
+; flat-volumes = no
ifelse(@HAVE_SYS_RESOURCE_H@, 1, [dnl
; rlimit-fsize = -1
diff -up a/src/pulsecore/core.c b/src/pulsecore/core.c
--- a/src/pulsecore/core.c 2016-05-26 23:21:17.000000000 -0500
+++ b/src/pulsecore/core.c 2016-05-31 10:01:55.681976740 -0500
@@ -135,7 +135,7 @@ pa_core* pa_core_new(pa_mainloop_api *m,
c->exit_idle_time = -1;
c->scache_idle_time = 20;
- c->flat_volumes = true;
+ c->flat_volumes = false;
c->disallow_module_loading = false;
c->disallow_exit = false;
c->running_as_daemon = false;

View File

@@ -0,0 +1,195 @@
# Copyright 1999-2019 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=6
inherit autotools bash-completion-r1 flag-o-matic gnome2-utils linux-info systemd user udev multilib-minimal
DESCRIPTION="A networked sound server with an advanced plugin system"
HOMEPAGE="https://www.freedesktop.org/wiki/Software/PulseAudio/"
SRC_URI="https://freedesktop.org/software/pulseaudio/releases/${P}.tar.xz"
LICENSE="LGPL-2.1"
SLOT="0"
KEYWORDS="alpha amd64 ~arm arm64 ~hppa ~ia64 ppc ppc64 ~sh sparc x86 ~amd64-linux ~x86-linux"
# +alsa-plugin as discussed in bug #519530
IUSE="+caps +glib headers-only ipv6 libressl cpu_flags_arm_neon selinux ssl"
# libpcre needed in some cases, bug #472228
CDEPEND="
|| (
elibc_glibc? ( virtual/libc )
elibc_uclibc? ( virtual/libc )
dev-libs/libpcre
)
>=media-libs/libsndfile-1.0.20[${MULTILIB_USEDEP}]
caps? ( >=sys-libs/libcap-2.22-r2[${MULTILIB_USEDEP}] )
glib? ( >=dev-libs/glib-2.26.0:2[${MULTILIB_USEDEP}] )
ssl? (
!libressl? ( dev-libs/openssl:0= )
libressl? ( dev-libs/libressl:= )
)
dev-libs/libltdl:0
selinux? ( sec-policy/selinux-pulseaudio )
" # libltdl is a valid RDEPEND, libltdl.so is used for native abi in pulsecore and daemon
RDEPEND="${CDEPEND}
"
DEPEND="${RDEPEND}
sys-devel/m4
dev-libs/libatomic_ops
virtual/pkgconfig
>=sys-devel/gettext-0.19.3
"
PATCHES=(
"${FILESDIR}"/pulseaudio-11.1-disable-flat-volumes.patch # bug 627894
)
pkg_pretend() {
CONFIG_CHECK="~HIGH_RES_TIMERS"
WARNING_HIGH_RES_TIMERS="CONFIG_HIGH_RES_TIMERS:\tis not set (required for enabling timer-based scheduling in pulseaudio)\n"
check_extra_config
if linux_config_exists; then
local snd_hda_prealloc_size=$(linux_chkconfig_string SND_HDA_PREALLOC_SIZE)
if [ -n "${snd_hda_prealloc_size}" ] && [ "${snd_hda_prealloc_size}" -lt 2048 ]; then
ewarn "A preallocated buffer-size of 2048 (kB) or higher is recommended for the HD-audio driver!"
ewarn "CONFIG_SND_HDA_PREALLOC_SIZE=${snd_hda_prealloc_size}"
fi
fi
}
pkg_setup() {
linux-info_pkg_setup
gnome2_environment_reset #543364
enewgroup audio 18 # Just make sure it exists
}
src_prepare() {
default
# Skip test that cannot work with sandbox, bug #501846
sed -i -e '/lock-autospawn-test /d' src/Makefile.am || die
sed -i -e 's/lock-autospawn-test$(EXEEXT) //' src/Makefile.in || die
eautoreconf
}
multilib_src_configure() {
local myconf=(
--disable-adrian-aec
--disable-esound
--disable-gconf
--disable-solaris
--enable-largefile
--localstatedir="${EPREFIX}"/var
--with-systemduserunitdir=$(systemd_get_userunitdir)
--with-udev-rules-dir="${EPREFIX}/$(get_udevdir)"/rules.d
--disable-alsa
--disable-bluez5
--disable-gtk3
--disable-jack
--disable-samplerate
--disable-lirc
--disable-orc
--disable-oss-output
$(multilib_native_use_enable glib gsettings)
$(multilib_native_use_enable ssl openssl)
# tests involve random modules, so just do them for the native
--disable-default-build-tests
--disable-udev
--disable-webrtc-aec
--disable-avahi
--without-fftw
--without-soxr
--with-database=simple
--disable-asyncns
$(use_enable glib glib2)
$(use_enable cpu_flags_arm_neon neon-opt)
--disable-tcpwrap
--disable-dbus
--disable-x11
--disable-systemd-daemon
--disable-systemd-login
--disable-systemd-journal
$(use_enable ipv6)
$(use_with caps)
)
if ! multilib_is_native_abi; then
myconf+=(
# hack around unnecessary checks
# (results don't matter, we're not building anything using it)
ac_cv_lib_ltdl_lt_dladvise_init=yes
LIBSPEEX_CFLAGS=' '
LIBSPEEX_LIBS=' '
)
else
# Make padsp work for non-native ABI, supposedly only possible with glibc; this is used by /usr/bin/padsp that comes from native build, thus we need this argument for native build
if use elibc_glibc ; then
myconf+=( --with-pulsedsp-location="${EPREFIX}"'/usr/\\$$LIB/pulseaudio' )
fi
fi
ECONF_SOURCE=${S} \
econf "${myconf[@]}"
}
multilib_src_compile() {
if multilib_is_native_abi; then
emake
else
local targets=( libpulse.la libpulsedsp.la libpulse-simple.la )
use glib && targets+=( libpulse-mainloop-glib.la )
emake -C src ${targets[*]}
fi
}
multilib_src_test() {
# We avoid running the toplevel check target because that will run
# po/'s tests too, and they are broken. Officially, it should work
# with intltool 0.41, but that doesn't look like a stable release.
if multilib_is_native_abi; then
emake -C src check
fi
}
multilib_src_install() {
if multilib_is_native_abi; then
emake -j1 DESTDIR="${D}" bashcompletiondir="$(get_bashcompdir)" install
else
local targets=( libpulse.la libpulse-simple.la )
use glib && targets+=( libpulse-mainloop-glib.la )
emake DESTDIR="${D}" install-pkgconfigDATA
emake DESTDIR="${D}" -C src \
install-libLTLIBRARIES \
install-padsplibLTLIBRARIES \
lib_LTLIBRARIES="${targets[*]}" \
install-pulseincludeHEADERS
fi
}
multilib_src_install_all() {
dodoc NEWS README todo
# Create the state directory
use prefix || diropts -o pulse -g pulse -m0755
find "${ED}" \( -name '*.a' -o -name '*.la' \) -delete || die
if use headers-only ; then
rm -rf "${D}"/usr/bin "${D}"/usr/lib "${D}"/usr/lib64/{[a-o]*,[q-z]*,pu*} "${D}"/usr/share "${D}"/etc || die
fi
}
pkg_postinst() {
gnome2_schemas_update
}
pkg_postrm() {
gnome2_schemas_update
}