pulseaudio: fix multilib packaging
PATCH 1/5 pulseaudio: fix multilib packaging
The magic multilibisation doesn't quite catch every instance, so replace 'pulseaudio' with ${PN} where needed to ensure the packaging is as intended.
--- meta/recipes-multimedia/pulseaudio/pulseaudio.inc | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-)
meta/recipes-multimedia/pulseaudio/pulseaudio.inc +4 -6
@@ -210,11 +210,9 @@ pkg_postinst_${PN}-server() { } python populate_packages_prepend() { - #d.setVar('PKG_pulseaudio', 'pulseaudio') - plugindir = d.expand('${libdir}/pulse-${PV}/modules/') - do_split_packages(d, plugindir, '^module-(.*)\.so$', 'pulseaudio-module-%s', 'PulseAudio module for %s', extra_depends='', prepend=True) - do_split_packages(d, plugindir, '^lib(.*)\.so$', 'pulseaudio-lib-%s', 'PulseAudio library for %s', extra_depends='', prepend=True) + do_split_packages(d, plugindir, '^module-(.*)\.so$', '${PN}-module-%s', 'PulseAudio module for %s', extra_depends='', prepend=True) + do_split_packages(d, plugindir, '^lib(.*)\.so$', '${PN}-lib-%s', 'PulseAudio library for %s', extra_depends='', prepend=True) } RDEPENDS_pulseaudio-server = " \
@@ -250,8 +248,8 @@ RDEPENDS_pulseaudio-server += "alsa-plugins-pulseaudio-conf" RDEPENDS_pulseaudio-module-console-kit =+ "${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'consolekit', '', d)}" RDEPENDS_pulseaudio-misc += "pulseaudio-module-cli-protocol-unix" -FILES_pulseaudio-module-gconf += "${libexecdir}/pulse/gconf-helper" -FILES_pulseaudio-module-alsa-card += "${datadir}/pulseaudio/alsa-mixer" +FILES_${PN}-module-gconf += "${libexecdir}/pulse/gconf-helper" +FILES_${PN}-module-alsa-card += "${datadir}/pulseaudio/alsa-mixer" # The console-kit module is good to have on X11 systems (it keeps PulseAudio # running for the duration of the user login session). The device-manager and
Signature · 1 line
2.11.0
PATCH 2/5 pulseaudio: enforce empty PN
The intention is that PN is empty, enforce that so new files don't end up in PN silently.
--- meta/recipes-multimedia/pulseaudio/pulseaudio.inc | 1 + 1 file changed, 1 insertion(+)
meta/recipes-multimedia/pulseaudio/pulseaudio.inc +1 -0
@@ -193,6 +193,7 @@ SYSTEMD_SERVICE_${PN}-server = "pulseaudio.service" FILES_${PN}-misc = "${bindir}/* ${libdir}/pulseaudio/libpulsedsp.so" # Allow the pulseaudio package to be created empty as a placeholder (-dbg and -dev depend on it) +FILES_${PN} = "" ALLOW_EMPTY_${PN} = "1" CONFFILES_libpulse = "${sysconfdir}/pulse/client.conf"
Signature · 1 line
2.11.0
PATCH 3/5 gsettings: allow the schemas to be in any package
In reply to Ross BurtonInstead of assuming that the schemas are located in ${PN}, add a GSETTINGS_PACKAGE variable for the package name and default it to ${PN}.
For recipe that can conditionally ship schemas, support GSETTINGS_PACKAGE being empty gracefully by doing nothing.
(From OE-Core rev: 28e84a07dd74636554bdf7622da167a1fe1af963)
--- meta/classes/gsettings.bbclass | 48 +++++++++++++++++++++++------------------- 1 file changed, 26 insertions(+), 22 deletions(-)
meta/classes/gsettings.bbclass +26 -22
@@ -7,32 +7,36 @@ # TODO use a trigger so that this runs once per package operation run - -RDEPENDS_${PN} += "glib-2.0-utils" - -FILES_${PN} += "${datadir}/glib-2.0/schemas" - -PACKAGE_WRITE_DEPS += "glib-2.0-native" +GSETTINGS_PACKAGE ?= "${PN}" + +python __anonymous() { + pkg = d.getVar("GSETTINGS_PACKAGE") + if pkg: + d.appendVar("PACKAGE_WRITE_DEPS", " glib-2.0-native") + d.appendVar("RDEPENDS_" + pkg, " ${MLPREFIX}glib-2.0-utils") + d.appendVar("FILES_" + pkg, " ${datadir}/glib-2.0/schemas") +} gsettings_postinstrm () { glib-compile-schemas $D${datadir}/glib-2.0/schemas } python populate_packages_append () { - pkg = d.getVar('PN') - bb.note("adding gsettings postinst scripts to %s" % pkg) - - postinst = d.getVar('pkg_postinst_%s' % pkg) or d.getVar('pkg_postinst') - if not postinst: - postinst = '#!/bin/sh\n' - postinst += d.getVar('gsettings_postinstrm') - d.setVar('pkg_postinst_%s' % pkg, postinst) - - bb.note("adding gsettings postrm scripts to %s" % pkg) - - postrm = d.getVar('pkg_postrm_%s' % pkg) or d.getVar('pkg_postrm') - if not postrm: - postrm = '#!/bin/sh\n' - postrm += d.getVar('gsettings_postinstrm') - d.setVar('pkg_postrm_%s' % pkg, postrm) + pkg = d.getVar('GSETTINGS_PACKAGE') + if pkg: + bb.note("adding gsettings postinst scripts to %s" % pkg) + + postinst = d.getVar('pkg_postinst_%s' % pkg) or d.getVar('pkg_postinst') + if not postinst: + postinst = '#!/bin/sh\n' + postinst += d.getVar('gsettings_postinstrm') + d.setVar('pkg_postinst_%s' % pkg, postinst) + + bb.note("adding gsettings postrm scripts to %s" % pkg) + + postrm = d.getVar('pkg_postrm_%s' % pkg) or d.getVar('pkg_postrm') + if not postrm: + postrm = '#!/bin/sh\n' + postrm += d.getVar('gsettings_postinstrm') + d.setVar('pkg_postrm_%s' % pkg, postrm) }
Signature · 1 line
2.11.0
PATCH 4/5 pulseaudio: add PACKAGECONFIGs for GConf and GSettings
In reply to Ross BurtonBehaviour is kept the same.
(From OE-Core rev: 577ce3462b9f37f6c73f07aaf53f68b8dee1887a)
--- meta/recipes-multimedia/pulseaudio/pulseaudio.inc | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-)
meta/recipes-multimedia/pulseaudio/pulseaudio.inc +9 -8
@@ -58,10 +58,10 @@ LIC_FILES_CHKSUM = "file://LICENSE;md5=0e5cd938de1a7a53ea5adac38cc10c39 \ DEPENDS = "libatomic-ops libsndfile1 libtool intltool-native" # optional -DEPENDS += "udev alsa-lib glib-2.0 gconf" +DEPENDS += "udev alsa-lib glib-2.0" DEPENDS += "speexdsp libxml-parser-perl-native libcap" -inherit autotools bash-completion pkgconfig useradd gettext perlnative bluetooth systemd manpages +inherit autotools bash-completion pkgconfig useradd gettext perlnative bluetooth systemd manpages gsettings # *.desktop rules wont be generated during configure and build will fail # if using --disable-nls
@@ -97,20 +97,18 @@ EXTRA_OECONF += "--without-fftw" # very good anyway, better alternatives exist (such as the webrtc canceller). EXTRA_OECONF += "--disable-adrian-aec" -# FIXME: The gsettings module is temporarily disabled, because adding support -# for it is a bit complicated. -EXTRA_OECONF += "--disable-gsettings" - PACKAGECONFIG ??= "${@bb.utils.contains('DISTRO_FEATURES', 'bluetooth', '${BLUEZ}', '', d)} \ ${@bb.utils.contains('DISTRO_FEATURES', 'zeroconf', 'avahi', '', d)} \ ${@bb.utils.contains('DISTRO_FEATURES', '3g', 'ofono', '', d)} \ ${@bb.utils.filter('DISTRO_FEATURES', 'ipv6 systemd x11', d)} \ - dbus \ + dbus gconf \ " PACKAGECONFIG[dbus] = "--enable-dbus,--disable-dbus,dbus" PACKAGECONFIG[bluez4] = "--enable-bluez4,--disable-bluez4,bluez4 sbc" PACKAGECONFIG[bluez5] = "--enable-bluez5,--disable-bluez5,bluez5 sbc" +PACKAGECONFIG[gconf] = "--enable-gconf,--disable-gconf,gconf" +PACKAGECONFIG[gsettings] = "--enable-gsettings,--disable-gsettings,glib-2.0-native glib-2.0" PACKAGECONFIG[ofono] = "--enable-bluez5-ofono-headset,--disable-bluez5-ofono-headset,ofono" PACKAGECONFIG[gtk] = "--enable-gtk3,--disable-gtk3,gtk+3" PACKAGECONFIG[systemd] = "--enable-systemd-daemon --enable-systemd-login --enable-systemd-journal --with-systemduserunitdir=${systemd_user_unitdir},--disable-systemd-daemon --disable-systemd-login --disable-systemd-journal,systemd"
@@ -249,8 +247,11 @@ RDEPENDS_pulseaudio-server += "alsa-plugins-pulseaudio-conf" RDEPENDS_pulseaudio-module-console-kit =+ "${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'consolekit', '', d)}" RDEPENDS_pulseaudio-misc += "pulseaudio-module-cli-protocol-unix" -FILES_${PN}-module-gconf += "${libexecdir}/pulse/gconf-helper" FILES_${PN}-module-alsa-card += "${datadir}/pulseaudio/alsa-mixer" +FILES_${PN}-module-gconf += "${libexecdir}/pulse/gconf-helper" + +GSETTINGS_PACKAGE = "${@bb.utils.contains('PACKAGECONFIG', 'gsettings', '${PN}-module-gsettings', '', d)}" +FILES_${PN}-module-gsettings += "${libexecdir}/pulse/gsettings-helper ${datadir}/GConf/gsettings ${datadir}/glib-2.0/schemas" # The console-kit module is good to have on X11 systems (it keeps PulseAudio # running for the duration of the user login session). The device-manager and
Signature · 1 line
2.11.0
PATCH 5/5 pulseaudio: switch configuration module from GConf to GSettings
In reply to Ross BurtonThe only user of the configuration module is paprefs, which as of 1.0 uses GSettings not GConf.
Also GConf is unmaintained, so one less recipe using it is good.
(From OE-Core rev: 4825ae198aedcd09c60559cb6233c0f8b6ecce32)
--- meta/recipes-multimedia/pulseaudio/pulseaudio.inc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
meta/recipes-multimedia/pulseaudio/pulseaudio.inc +1 -1
@@ -101,7 +101,7 @@ PACKAGECONFIG ??= "${@bb.utils.contains('DISTRO_FEATURES', 'bluetooth', '${BLUEZ ${@bb.utils.contains('DISTRO_FEATURES', 'zeroconf', 'avahi', '', d)} \ ${@bb.utils.contains('DISTRO_FEATURES', '3g', 'ofono', '', d)} \ ${@bb.utils.filter('DISTRO_FEATURES', 'ipv6 systemd x11', d)} \ - dbus gconf \ + dbus gsettings \ " PACKAGECONFIG[dbus] = "--enable-dbus,--disable-dbus,dbus"
Signature · 1 line
2.11.0