Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 746737 - media-sound/pulseaudio: EAPI 7, GLEP 81
Summary: media-sound/pulseaudio: EAPI 7, GLEP 81
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo Linux Gnome Desktop Team
URL:
Whiteboard:
Keywords: EBUILD, PATCH, PullRequest
Depends on:
Blocks:
 
Reported: 2020-10-05 16:04 UTC by David Michael
Modified: 2020-11-23 10:19 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
pulseaudio-13.0 EAPI 7 (pulseaudio-13.0-r1.ebuild,11.05 KB, text/plain)
2020-10-05 16:04 UTC, David Michael
Details
acct-group/pulse-access (pulse-access-0.ebuild,150 bytes, text/plain)
2020-10-05 16:05 UTC, David Michael
Details
acct-group/pulse (pulse-0.ebuild,150 bytes, text/plain)
2020-10-05 16:06 UTC, David Michael
Details
acct-user/pulse (pulse-0.ebuild,280 bytes, text/plain)
2020-10-05 16:06 UTC, David Michael
Details
metadata.xml for all GLEP 81 packages (metadata.xml,253 bytes, text/plain)
2020-10-05 16:07 UTC, David Michael
Details
acct-user/pulse (pulse-0.ebuild,310 bytes, text/plain)
2020-10-05 16:11 UTC, David Michael
Details
poc fix (p.patch,2.25 KB, patch)
2020-11-23 02:36 UTC, flippynelle
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description David Michael 2020-10-05 16:04:39 UTC
Created attachment 663877 [details]
pulseaudio-13.0 EAPI 7

I'd like to start trying PulseAudio RCs (which are not packaged in Gentoo), but the current ebuild has issues that I'd like to see fixed in the process.  Most noteworthy is the fact that it's a non-EAPI-7 multilib ebuild which breaks sysroot cross-compilation.

I put GLEP 81 deps in RDEPEND and not BDEPEND since I only see them used in compiled C files in the source.  There is the !prefix diropts line which tries to use the pulse user/group at build time, but it doesn't exist for non-system-wide builds, so it looks like it didn't work.  Even with system-wide, the binpkg doesn't have state directories, so I dropped it.

Ebuilds are attached.  User/group IDs are unspecified since I think a Gentoo developer has to do that.  Here is the diff in case that's easier.

--- media-sound/pulseaudio/pulseaudio-13.0.ebuild
+++ media-sound/pulseaudio/pulseaudio-13.0-r1.ebuild
@@ -1,8 +1,8 @@
 # Copyright 1999-2020 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
+EAPI=7
+inherit autotools bash-completion-r1 flag-o-matic gnome2-utils linux-info systemd udev multilib-minimal
 
 DESCRIPTION="A networked sound server with an advanced plugin system"
 HOMEPAGE="https://www.freedesktop.org/wiki/Software/PulseAudio/"
@@ -15,7 +15,7 @@
 LICENSE="!gdbm? ( LGPL-2.1 ) gdbm? ( GPL-2 )"
 
 SLOT="0"
-KEYWORDS="~alpha amd64 arm arm64 ~hppa ~ia64 ppc ppc64 sparc x86 ~amd64-linux ~x86-linux"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~amd64-linux ~x86-linux"
 
 # +alsa-plugin as discussed in bug #519530
 IUSE="+alsa +alsa-plugin +asyncns bluetooth +caps dbus doc equalizer elogind gconf
@@ -36,7 +36,7 @@
 "
 
 # libpcre needed in some cases, bug #472228
-CDEPEND="
+RDEPEND="
 	|| (
 		elibc_glibc? ( virtual/libc )
 		elibc_uclibc? ( virtual/libc )
@@ -82,25 +82,16 @@
 	systemd? ( sys-apps/systemd:0=[${MULTILIB_USEDEP}] )
 	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}
 	realtime? ( sys-auth/rtkit )
 	gconf? ( >=gnome-base/gconf-3.2.6 )
-"
+" # libltdl is a valid RDEPEND, libltdl.so is used for native abi in pulsecore and daemon
 
 DEPEND="${RDEPEND}
-	sys-devel/m4
-	doc? ( app-doc/doxygen )
-	test? ( >=dev-libs/check-0.9.10 )
 	X? (
 		x11-base/xorg-proto
 		>=x11-libs/libXtst-1.0.99.2[${MULTILIB_USEDEP}]
 	)
 	dev-libs/libatomic_ops
-	virtual/pkgconfig
-	system-wide? ( dev-util/unifdef )
-	>=sys-devel/gettext-0.19.3
 "
 # This is a PDEPEND to avoid a circular dep
 PDEPEND="
@@ -115,7 +106,19 @@
 	system-wide? (
 		alsa? ( media-sound/alsa-utils )
 		bluetooth? ( >=net-wireless/bluez-5 )
+		acct-user/pulse
+		acct-group/pulse-access
 	)
+	acct-group/audio
+"
+
+BDEPEND="
+	doc? ( app-doc/doxygen )
+	system-wide? ( dev-util/unifdef )
+	test? ( >=dev-libs/check-0.9.10 )
+	sys-devel/gettext
+	sys-devel/m4
+	virtual/pkgconfig
 "
 
 PATCHES=(
@@ -139,14 +142,6 @@
 pkg_setup() {
 	linux-info_pkg_setup
 	gnome2_environment_reset #543364
-
-	enewgroup audio 18 # Just make sure it exists
-
-	if use system-wide; then
-		enewgroup pulse-access
-		enewgroup pulse
-		enewuser pulse -1 -1 /var/run/pulse pulse,audio
-	fi
 }
 
 src_prepare() {
@@ -300,20 +295,17 @@
 	else
 		# Prevent warnings when system-wide is not used, bug #447694
 		if use dbus ; then
-			rm "${ED%/}"/etc/dbus-1/system.d/pulseaudio-system.conf || die
+			rm "${ED}"/etc/dbus-1/system.d/pulseaudio-system.conf || die
 		fi
 	fi
 
 	if use zeroconf ; then
 		sed -e '/module-zeroconf-publish/s:^#::' \
-			-i "${ED%/}/etc/pulse/default.pa" || die
+			-i "${ED}/etc/pulse/default.pa" || die
 	fi
 
 	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
 }
Comment 1 David Michael 2020-10-05 16:05:46 UTC
Created attachment 663880 [details]
acct-group/pulse-access
Comment 2 David Michael 2020-10-05 16:06:15 UTC
Created attachment 663883 [details]
acct-group/pulse
Comment 3 David Michael 2020-10-05 16:06:50 UTC
Created attachment 663886 [details]
acct-user/pulse
Comment 4 David Michael 2020-10-05 16:07:26 UTC
Created attachment 663889 [details]
metadata.xml for all GLEP 81 packages
Comment 5 David Michael 2020-10-05 16:11:46 UTC
Created attachment 663895 [details]
acct-user/pulse
Comment 6 Larry the Git Cow gentoo-dev 2020-11-06 03:55:49 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=47f63d7efca2d55bae9071630b685d368b48adc0

commit 47f63d7efca2d55bae9071630b685d368b48adc0
Author:     David Michael <fedora.dm0@gmail.com>
AuthorDate: 2020-11-06 03:14:23 +0000
Commit:     Matt Turner <mattst88@gentoo.org>
CommitDate: 2020-11-06 03:55:41 +0000

    media-sound/pulseaudio: EAPI 7, GLEP 81
    
    Closes: https://bugs.gentoo.org/746737
    Package-Manager: Portage-3.0.8, Repoman-3.0.2
    Signed-off-by: David Michael <fedora.dm0@gmail.com>
    Signed-off-by: Matt Turner <mattst88@gentoo.org>

 media-sound/pulseaudio/pulseaudio-13.0-r1.ebuild | 353 +++++++++++++++++++++++
 1 file changed, 353 insertions(+)
Comment 7 flippynelle 2020-11-23 02:36:13 UTC
Created attachment 674395 [details, diff]
poc fix

/var/tmp/portage/media-sound/pulseaudio-13.0-r1/work/pulseaudio-13.0/configure --prefix=/usr --build=x86_64-pc-linux-gnu --host=x86_64-pc-linux-gnu --mandir=/usr/share/man --infodir=/usr/share/info --datadir=/usr/share --sysconfdir=/etc --localstatedir=/var/lib --disable-dependency-tracking --disable-silent-rules --docdir=/usr/share/doc/pulseaudio-13.0-r1 --htmldir=/usr/share/doc/pulseaudio-13.0-r1/html --with-sysroot=/ --libdir=/usr/lib64 --disable-adrian-aec --disable-esound --disable-gconf --disable-solaris --enable-largefile --localstatedir=/var --with-systemduserunitdir=/usr/lib/systemd/user --with-udev-rules-dir=//lib/udev/rules.d --enable-alsa --disable-bluez5 --enable-gsettings --disable-gtk3 --disable-jack --disable-samplerate --disable-lirc --enable-orc --disable-oss-output --enable-openssl --disable-default-build-tests --enable-udev --disable-webrtc-aec --disable-avahi --without-fftw --with-soxr --with-database=gdbm --enable-glib2 --enable-asyncns --disable-neon-opt --disable-tcpwrap --enable-dbus --enable-x11 --disable-systemd-daemon --disable-systemd-login --disable-systemd-journal --disable-ipv6 --with-caps --enable-systemd-login SYSTEMDLOGIN_CFLAGS=-I/usr/include/elogind SYSTEMDLOGIN_LIBS=-L/lib64 -lelogind --with-pulsedsp-location=/usr/\\$$LIB/pulseaudio
configure: error: unrecognized option: `-lelogind'
Try `/var/tmp/portage/media-sound/pulseaudio-13.0-r1/work/pulseaudio-13.0/configure --help' for more information
Comment 8 David Michael 2020-11-23 02:49:27 UTC
You might want to make a new bug for your issue for visibility, and because it is unrelated to this bug and applies to older versions as well.
Comment 9 flippynelle 2020-11-23 03:02:30 UTC
Srry, busy. But you're right it's in prev. too (at least):
/var/db/repos/gentoo/media-sound/pulseaudio/pulseaudio-13.0.ebuild
Comment 10 flippynelle 2020-11-23 10:19:29 UTC
Did it in https://bugs.gentoo.org/756196
Thanks for your advice.