[arch-commits] Commit in libcanberra/trunk (3 files)
Jan Steffens
heftig at archlinux.org
Tue May 25 17:37:56 UTC 2021
Date: Tuesday, May 25, 2021 @ 17:37:55
Author: heftig
Revision: 416449
0.30+2+gc0620e4-4: simplify
Added:
libcanberra/trunk/40-libcanberra-gtk-module.sh
(from rev 416448, libcanberra/trunk/libcanberra.xinit)
Modified:
libcanberra/trunk/PKGBUILD
Deleted:
libcanberra/trunk/libcanberra.xinit
------------------------------+
40-libcanberra-gtk-module.sh | 13 +++++++
PKGBUILD | 67 ++++++++++++-----------------------------
libcanberra.xinit | 13 -------
3 files changed, 33 insertions(+), 60 deletions(-)
Copied: libcanberra/trunk/40-libcanberra-gtk-module.sh (from rev 416448, libcanberra/trunk/libcanberra.xinit)
===================================================================
--- 40-libcanberra-gtk-module.sh (rev 0)
+++ 40-libcanberra-gtk-module.sh 2021-05-25 17:37:55 UTC (rev 416449)
@@ -0,0 +1,13 @@
+#!/bin/sh
+
+case "${DESKTOP_SESSION-}" in
+ gnome*) # Done by gnome-settings-daemon
+ ;;
+ *)
+ # Extra check in case DESKTOP_SESSION is not set correctly
+ if [ -z "${GNOME_DESKTOP_SESSION_ID-}" ]; then
+ GTK_MODULES="${GTK_MODULES:+$GTK_MODULES:}canberra-gtk-module"
+ export GTK_MODULES
+ fi
+ ;;
+esac
Modified: PKGBUILD
===================================================================
--- PKGBUILD 2021-05-25 17:30:43 UTC (rev 416448)
+++ PKGBUILD 2021-05-25 17:37:55 UTC (rev 416449)
@@ -1,83 +1,56 @@
# Maintainer: Jan de Groot <jgc at archlinux.org>
-pkgbase=libcanberra
-pkgname=(libcanberra libcanberra-pulse libcanberra-gstreamer)
+pkgname=libcanberra
pkgver=0.30+2+gc0620e4
-pkgrel=3
+pkgrel=4
pkgdesc="A small and lightweight implementation of the XDG Sound Theme Specification"
+url="http://0pointer.de/lennart/projects/libcanberra"
arch=(x86_64)
license=(LGPL)
-depends=(libvorbis libltdl alsa-lib tdb sound-theme-freedesktop)
-makedepends=(gtk-doc libpulse gstreamer gtk2 gtk3 git)
-options=(!emptydirs libtool)
-url="http://0pointer.de/lennart/projects/libcanberra"
+depends=(libvorbis libltdl alsa-lib libpulse tdb sound-theme-freedesktop)
+makedepends=(gtk-doc gtk2 gtk3 git)
+provides=("libcanberra-pulse=$pkgver-$pkgrel" libcanberra{,-gtk,-gtk3}.so)
+replaces=("libcanberra-pulse<0.30+2+gc0620e4-4")
+options=(libtool)
_commit=c0620e432650e81062c1967cc669829dbd29b310 # master
-source=("git+http://git.0pointer.net/clone/libcanberra.git#commit=$_commit" libcanberra.xinit)
+source=("git+http://git.0pointer.net/clone/libcanberra.git#commit=$_commit"
+ 40-libcanberra-gtk-module.sh)
sha256sums=('SKIP'
'a0d0b135d3fea5c703a5f84208b79d66f671b082ae85f67b629ee2568a7ddc30')
-_plugindir=usr/lib/$pkgbase-0.30
-
pkgver() {
- cd $pkgname
+ cd libcanberra
git describe --tags | sed 's/^v//;s/-/+/g'
}
prepare() {
- cd $pkgbase
+ cd libcanberra
./autogen.sh
}
build() {
- cd $pkgbase
+ cd libcanberra
./configure --sysconfdir=/etc --prefix=/usr --localstatedir=/var \
--disable-static --with-builtin=dso --enable-null --disable-oss \
- --enable-alsa --enable-gstreamer --enable-pulse \
+ --enable-alsa --enable-pulse \
--with-systemdsystemunitdir=/usr/lib/systemd/system --enable-gtk-doc
-
sed -i -e 's/ -shared / -Wl,-O1,--as-needed\0/g' libtool
make
}
package_libcanberra() {
- optdepends=("$pkgbase-pulse: PulseAudio driver"
- "$pkgbase-gstreamer: GStreamer driver")
- provides=(libcanberra{,-gtk,-gtk3}.so)
+ cd libcanberra
- cd $pkgbase
+ make -j1 DESTDIR="$pkgdir" install
- make -j1 DESTDIR="$pkgdir" install
- rm "$pkgdir"/usr/lib/libcanberra-gtk*.la
+ rm "$pkgdir"/usr/lib/*.la
rm "$pkgdir"/usr/lib/gtk-{2,3}.0/modules/*.la
- install -D "$srcdir/libcanberra.xinit" \
- "$pkgdir/etc/X11/xinit/xinitrc.d/40-libcanberra-gtk-module.sh"
-
- # Split plugins
- for _p in pulse gstreamer; do
- mkdir ../$_p-plugin
- mv "$pkgdir/$_plugindir"/libcanberra-$_p.* ../$_p-plugin
- done
-
# FS#52370: Remove login, logout and system-ready sounds.
# We have no sound themes that include these so do not play them.
- rm -f "$pkgdir/usr/share/gnome/autostart/libcanberra-login-sound.desktop"
- rm -f "$pkgdir/usr/share/gnome/shutdown/libcanberra-logout-sound.sh"
- rm -f "$pkgdir/usr/share/gdm/autostart/LoginWindow/libcanberra-ready-sound.desktop"
-}
+ rm -r "$pkgdir"/usr/share/{gnome,gdm}
-package_libcanberra-pulse() {
- pkgdesc="PulseAudio plugin for libcanberra"
- depends=("$pkgbase=$pkgver-$pkgrel" libpulse)
-
- install -d "$pkgdir/$_plugindir"
- mv pulse-plugin/* "$pkgdir/$_plugindir"
+ install -Dt "$pkgdir/etc/X11/xinit/xinitrc.d" ../40-libcanberra-gtk-module.sh
}
-package_libcanberra-gstreamer() {
- pkgdesc="GStreamer plugin for libcanberra"
- depends=("$pkgbase=$pkgver-$pkgrel" gstreamer)
-
- install -d "$pkgdir/$_plugindir"
- mv gstreamer-plugin/* "$pkgdir/$_plugindir"
-}
+# vim:set sw=2 et:
Deleted: libcanberra.xinit
===================================================================
--- libcanberra.xinit 2021-05-25 17:30:43 UTC (rev 416448)
+++ libcanberra.xinit 2021-05-25 17:37:55 UTC (rev 416449)
@@ -1,13 +0,0 @@
-#!/bin/sh
-
-case "${DESKTOP_SESSION-}" in
- gnome*) # Done by gnome-settings-daemon
- ;;
- *)
- # Extra check in case DESKTOP_SESSION is not set correctly
- if [ -z "${GNOME_DESKTOP_SESSION_ID-}" ]; then
- GTK_MODULES="${GTK_MODULES:+$GTK_MODULES:}canberra-gtk-module"
- export GTK_MODULES
- fi
- ;;
-esac
More information about the arch-commits
mailing list