diff options
author | James Meyer <james.meyer@operamail.com> | 2012-08-21 19:13:29 (GMT) |
---|---|---|
committer | James Meyer <james.meyer@operamail.com> | 2012-08-21 19:13:29 (GMT) |
commit | e6a003f00a9e2555f19b30717186d942e6f18056 (patch) | |
tree | 864d0ee1f8946a14b94ea41daf68dacef9fb1628 | |
parent | 70ccf2020802a6fee96815b553aea2ea4f9a99be (diff) | |
download | linhes_pkgbuild-e6a003f00a9e2555f19b30717186d942e6f18056.zip linhes_pkgbuild-e6a003f00a9e2555f19b30717186d942e6f18056.tar.gz linhes_pkgbuild-e6a003f00a9e2555f19b30717186d942e6f18056.tar.bz2 |
alsa-utils: 1.0.25
-rwxr-xr-x[-rw-r--r--] | abs/core/alsa-utils/90alsa | 1 | ||||
-rw-r--r-- | abs/core/alsa-utils/PKGBUILD | 24 | ||||
-rwxr-xr-x | abs/core/alsa-utils/alsa | 48 | ||||
-rw-r--r-- | abs/core/alsa-utils/alsa.conf.d | 4 | ||||
-rw-r--r-- | abs/core/alsa-utils/alsaconf.patch | 32 |
5 files changed, 41 insertions, 68 deletions
diff --git a/abs/core/alsa-utils/90alsa b/abs/core/alsa-utils/90alsa index 9027813..9f18bef 100644..100755 --- a/abs/core/alsa-utils/90alsa +++ b/abs/core/alsa-utils/90alsa @@ -11,4 +11,3 @@ aplay -d 1 /dev/zero *) exit $NA ;; esac - diff --git a/abs/core/alsa-utils/PKGBUILD b/abs/core/alsa-utils/PKGBUILD index 2486b03..918a84d 100644 --- a/abs/core/alsa-utils/PKGBUILD +++ b/abs/core/alsa-utils/PKGBUILD @@ -1,28 +1,28 @@ -# $Id$ +# $Id: PKGBUILD 157726 2012-04-29 04:09:24Z allan $ # Maintainer: Tobias Powalowski <tpowa@archlinux.org> # Contributor: judd <jvinet@zeroflux.org> pkgname=alsa-utils -pkgver=1.0.24.2 -pkgrel=1 +pkgver=1.0.25 +pkgrel=3 pkgdesc="An alternative implementation of Linux sound support" arch=('i686' 'x86_64') url="http://www.alsa-project.org" #can not use >=$pkgver due to use of letters in alsa-lib update versioning -depends=("alsa-lib>1.0.24" 'dialog' 'pciutils' 'ncurses' 'psmisc') +depends=("alsa-lib>1.0.24" 'dialog' 'pciutils' 'ncurses' 'psmisc' 'libsamplerate') makedepends=('xmlto' 'docbook-xsl') license=('GPL') source=(ftp://ftp.alsa-project.org/pub/utils/$pkgname-${pkgver}.tar.bz2 alsa - alsaconf.patch alsa.conf.d 90alsa) backup=(etc/conf.d/alsa) build() { cd ${srcdir}/${pkgname}-${pkgver} - patch -Np1 -i ../alsaconf.patch - ./configure --prefix=/usr + ./configure --prefix=/usr --disable-alsaconf \ + --with-udev-rules-dir=/usr/lib/udev/rules.d \ + --with-systemdsystemunitdir=/usr/lib/systemd/system make } @@ -32,11 +32,11 @@ package() { install -D -m755 ../alsa ${pkgdir}/etc/rc.d/alsa install -D -m644 ../alsa.conf.d ${pkgdir}/etc/conf.d/alsa install -D -m755 ../90alsa ${pkgdir}/etc/pm/sleep.d/90alsa + # dir where to save ALSA state install -d ${pkgdir}/var/lib/alsa } -md5sums=('8238cd57cb301d1c36bcf0ecb59ce6b2' - '3ef812cae83053d01cd560284efad71f' - '62ebef77d5617d0036012cc541dcf23c' - '93089f0d8872078939f76dd2acaebc2b' - '71b67e9578512e071253966f9403e01d') +md5sums=('f81f9dcb9a014fd32cb3a70066a5b9a9' + '2ba1a1cbf653bf1a69f8a720fd6549da' + '4c8ae9f976c7df5e271a4cb91ccc7767' + '529216f6a46e61a546640e08ea7a0879') diff --git a/abs/core/alsa-utils/alsa b/abs/core/alsa-utils/alsa index 08f76af..1e7b57f 100755 --- a/abs/core/alsa-utils/alsa +++ b/abs/core/alsa-utils/alsa @@ -7,50 +7,56 @@ case "$1" in start) stat_busy "Restoring ALSA Levels" - /usr/sbin/alsactl $ALSA_ARGS restore - if [ $? -gt 0 ]; then - stat_fail - else + if [[ ! -e /var/lib/alsa/asound.state ]]; then + /usr/sbin/alsactl $ALSA_ARGS store || { stat_fail; exit 1; } + fi + if /usr/sbin/alsactl $ALSA_ARGS restore; then stat_done add_daemon alsa + else + stat_fail + exit 1 fi POWERSAVE=${POWERSAVE:-0} - if [ -e /sys/module/snd_ac97_codec/parameters/power_save \ - -a $POWERSAVE -ne 0 ]; then + if [[ -e /sys/module/snd_ac97_codec/parameters/power_save ]] \ + && (( $POWERSAVE )); then echo $POWERSAVE > /sys/module/snd_ac97_codec/parameters/power_save - [ -c /dev/dsp ] && echo 1 > /dev/dsp + [[ -c /dev/dsp ]] && echo 1 > /dev/dsp fi - - if [ -e /sys/module/snd_hda_intel/parameters/power_save \ - -a $POWERSAVE -ne 0 ]; then + if [[ -e /sys/module/snd_hda_intel/parameters/power_save ]] \ + && (( $POWERSAVE )); then echo $POWERSAVE > /sys/module/snd_hda_intel/parameters/power_save - [ -c /dev/dsp ] && echo 1 > /dev/dsp + [[ -c /dev/dsp ]] && echo 1 > /dev/dsp fi ;; stop) SAVE_VOLUME=${SAVE_VOLUME:-yes} - if [ "$SAVE_VOLUME" == "yes" ]; then + if [[ "$SAVE_VOLUME" = "yes" ]]; then stat_busy "Saving ALSA Levels" - /usr/sbin/alsactl $ALSA_ARGS store + /usr/sbin/alsactl $ALSA_ARGS store || { stat_fail; exit 1; } else stat_busy "Stopping ALSA" fi if [ "$MUTE_VOLUME" == "yes" ]; then - /usr/bin/amixer -q set Master 0 mute - fi - if [ $? -gt 0 ]; then - stat_fail - else - stat_done - rm_daemon alsa + /usr/bin/amixer -q set Master 0 mute || { stat_fail; exit 1; } fi + stat_done + rm_daemon alsa ;; restart) $0 stop sleep 1 $0 start ;; + force-restart) + stat_busy "Trying to TERM or KILL processes that are blocking ALSA..." + FILES="$(ls -1 /dev/snd/* | grep -vi control)" + fuser -k -SIGTERM $FILES + fuser -k $FILES + stat_done + $0 restart + ;; *) - echo "usage: $0 {start|stop|restart}" + echo "usage: $0 {start|stop|restart|force-restart}" esac diff --git a/abs/core/alsa-utils/alsa.conf.d b/abs/core/alsa-utils/alsa.conf.d index 2c4a92e..bd50dcc 100644 --- a/abs/core/alsa-utils/alsa.conf.d +++ b/abs/core/alsa-utils/alsa.conf.d @@ -1,6 +1,6 @@ # Arguments for alsactl -# example: ALSA_ARGS="--file /var/run/alsa-state" -ALSA_ARGS="" +# example: ALSA_ARGS="--file /var/lib/alsa/asound.state" +ALSA_ARGS="--file /var/lib/alsa/asound.state" # Enables powersaving mode for AC97 and hda_intel audio chips. # Set to 1 to enable powersaving. diff --git a/abs/core/alsa-utils/alsaconf.patch b/abs/core/alsa-utils/alsaconf.patch deleted file mode 100644 index ec79fe9..0000000 --- a/abs/core/alsa-utils/alsaconf.patch +++ /dev/null @@ -1,32 +0,0 @@ -diff -Naur alsa-utils-1.0.9a-orig/alsaconf/alsaconf.in alsa-utils-1.0.9a/alsaconf/alsaconf.in ---- alsa-utils-1.0.9a-orig/alsaconf/alsaconf.in 2005-03-24 00:24:52.000000000 -0800 -+++ alsa-utils-1.0.9a/alsaconf/alsaconf.in 2005-07-18 09:25:02.000000000 -0700 -@@ -58,6 +58,8 @@ - distribution="redhat" - elif test -f /etc/fedora-release && grep -q "Fedora" /etc/fedora-release; then - distribution="fedora" -+elif test -f /etc/arch-release && grep -q "Arch" /etc/arch-release; then -+ distribution="arch" - elif [ -f /etc/slackware-version -o -f /etc/slamd64-version ]; then - distribution="slackware" - else -@@ -382,6 +384,8 @@ - rcalsasound=/etc/rc.d/init.d/alsasound - elif [ -x /etc/init.d/alsa ]; then - rcalsasound=/etc/init.d/alsa -+elif [ -x /etc/rc.d/alsa ]; then -+ rcalsasound=/etc/rc.d/alsa - else - rcalsasound=rcalsasound - fi ---- alsa-utils-1.0.9a-orig/alsaconf/alsaconf.in 2010-01-03 19:44:08.000000000 +0100 -+++ alsa-utils-1.0.9a-orig/alsaconf/alsaconf.in 2010-01-03 19:44:08.000000000 +0100 -@@ -315,7 +315,7 @@ - 3.[789]*) - ;; - *) -- cfgout="/etc/modprobe.d/sound" -+ cfgout="/etc/modprobe.d/sound.conf" - cfgoldout="" - ;; - esac |