forked from pool/alsa-utils
Accepting request 287970 from home:tiwai:branches:multimedia:libs
- Update to alsa-utils 1.0.29: just a version bump including previous fixes - Drop obsoleted patches: 0001-alsactl-save-state-do-not-call-rename-for-stdio.patch 0002-alsamixer-include-missing-mixer_controls.h.patch 0003-Add-alsa-info.sh-to-alsa-utils-repo.patch 0004-Add-missing-alsa-info-entry-to-the-root-Makefile.am.patch 0005-alsa-info-Make-sure-all-full-script-is-run-even-with.patch 0006-alsa-info-Refactor-withall-logic.patch 0007-speaker-test-Add-missing-draining-at-the-end.patch 0008-alsactl-Fix-the-file-locking-routines-for-the-state-.patch 0009-alsactl-aded-missing-monitor-prototype.patch 0010-speaker-text-fix-simple-signess-assignment-warning.patch 0011-monitor-fix-clang-warning-Declared-variable-length-a.patch 0012-alsactl-coverity-missing_va_end-va_end-was-not-calle.patch 0013-Revert-aplay-fix-pcm_read-return-value.patch 0014-amixer-Make-dB-case-insensitive-in-set-commands.patch 0015-amixer-Parse-the-value-more-strictly.patch 0016-alsactl-add-missing-state_unlock-call.patch 0017-alsactl-init-Change-the-basic-rules-description.patch 0018-alsactl-init-Add-Line-Out-to-list-of-outputs-to-init.patch 0019-configure-allow-contitional-compilation-of-alsaucm.patch OBS-URL: https://build.opensuse.org/request/show/287970 OBS-URL: https://build.opensuse.org/package/show/multimedia:libs/alsa-utils?expand=0&rev=114
This commit is contained in:
parent
c1e4b30d69
commit
563fed14f0
@ -1,26 +0,0 @@
|
||||
From 03a652e18ddc2eaad9b6ff3653515d54bd273d75 Mon Sep 17 00:00:00 2001
|
||||
From: Jaroslav Kysela <perex@perex.cz>
|
||||
Date: Wed, 25 Jun 2014 10:47:21 +0200
|
||||
Subject: [PATCH 1/2] alsactl: save state - do not call rename for stdio
|
||||
|
||||
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
|
||||
---
|
||||
alsactl/state.c | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/alsactl/state.c b/alsactl/state.c
|
||||
index c33f5017999f..e0c6f2e02e9b 100644
|
||||
--- a/alsactl/state.c
|
||||
+++ b/alsactl/state.c
|
||||
@@ -1626,7 +1626,7 @@ int save_state(const char *file, const char *cardname)
|
||||
snd_output_close(out);
|
||||
if (err < 0) {
|
||||
error("snd_config_save: %s", snd_strerror(err));
|
||||
- } else {
|
||||
+ } else if (nfile) {
|
||||
err = rename(nfile, file);
|
||||
if (err < 0)
|
||||
error("rename failed: %s (%s)", strerror(-err), file);
|
||||
--
|
||||
2.0.0
|
||||
|
@ -1,24 +0,0 @@
|
||||
From c788ce9b6088e2c937f77231eab520c3d16e0c76 Mon Sep 17 00:00:00 2001
|
||||
From: Jaroslav Kysela <perex@perex.cz>
|
||||
Date: Wed, 25 Jun 2014 10:49:23 +0200
|
||||
Subject: [PATCH 2/2] alsamixer: include missing mixer_controls.h
|
||||
|
||||
---
|
||||
alsamixer/mainloop.c | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/alsamixer/mainloop.c b/alsamixer/mainloop.c
|
||||
index 351f57f8590e..79d81a99cfc1 100644
|
||||
--- a/alsamixer/mainloop.c
|
||||
+++ b/alsamixer/mainloop.c
|
||||
@@ -29,6 +29,7 @@
|
||||
#include "widget.h"
|
||||
#include "mixer_widget.h"
|
||||
#include "mixer_display.h"
|
||||
+#include "mixer_controls.h"
|
||||
#include "mainloop.h"
|
||||
|
||||
static WINDOW *curses_initialized;
|
||||
--
|
||||
2.0.0
|
||||
|
@ -1,977 +0,0 @@
|
||||
From 87a9446d2837a00de963c48653d6aad71cb2ad83 Mon Sep 17 00:00:00 2001
|
||||
From: Takashi Iwai <tiwai@suse.de>
|
||||
Date: Wed, 30 Jul 2014 12:18:07 +0200
|
||||
Subject: [PATCH] Add alsa-info.sh to alsa-utils repo
|
||||
|
||||
Copied the latest version (0.4.63) from alsa-driver repo.
|
||||
|
||||
Signed-off-by: Takashi Iwai <tiwai@suse.de>
|
||||
---
|
||||
alsa-info/Makefile.am | 1 +
|
||||
alsa-info/alsa-info.sh | 935 +++++++++++++++++++++++++++++++++++++++++++++++++
|
||||
configure.ac | 2 +-
|
||||
3 files changed, 937 insertions(+), 1 deletion(-)
|
||||
create mode 100644 alsa-info/Makefile.am
|
||||
create mode 100755 alsa-info/alsa-info.sh
|
||||
|
||||
diff --git a/alsa-info/Makefile.am b/alsa-info/Makefile.am
|
||||
new file mode 100644
|
||||
index 000000000000..1a47e602ba38
|
||||
--- /dev/null
|
||||
+++ b/alsa-info/Makefile.am
|
||||
@@ -0,0 +1 @@
|
||||
+sbin_SCRIPTS = alsa-info.sh
|
||||
diff --git a/alsa-info/alsa-info.sh b/alsa-info/alsa-info.sh
|
||||
new file mode 100755
|
||||
index 000000000000..859d7bca6b1c
|
||||
--- /dev/null
|
||||
+++ b/alsa-info/alsa-info.sh
|
||||
@@ -0,0 +1,935 @@
|
||||
+#!/bin/bash
|
||||
+
|
||||
+SCRIPT_VERSION=0.4.63
|
||||
+CHANGELOG="http://www.alsa-project.org/alsa-info.sh.changelog"
|
||||
+
|
||||
+#################################################################################
|
||||
+#Copyright (C) 2007 Free Software Foundation.
|
||||
+
|
||||
+#This program is free software; you can redistribute it and/or modify
|
||||
+#it under the terms of the GNU General Public License as published by
|
||||
+#the Free Software Foundation; either version 2 of the License, or
|
||||
+#(at your option) any later version.
|
||||
+
|
||||
+#This program is distributed in the hope that it will be useful,
|
||||
+#but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
+#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
+#GNU General Public License for more details.
|
||||
+
|
||||
+#You should have received a copy of the GNU General Public License
|
||||
+#along with this program; if not, write to the Free Software
|
||||
+#Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
||||
+
|
||||
+##################################################################################
|
||||
+
|
||||
+#The script was written for 2 main reasons:
|
||||
+# 1. Remove the need for the devs/helpers to ask several questions before we can easily help the user.
|
||||
+# 2. Allow newer/inexperienced ALSA users to give us all the info we need to help them.
|
||||
+
|
||||
+#Set the locale (this may or may not be a good idea.. let me know)
|
||||
+export LC_ALL=C
|
||||
+
|
||||
+#Change the PATH variable, so we can run lspci (needed for some distros)
|
||||
+PATH=$PATH:/bin:/sbin:/usr/bin:/usr/sbin
|
||||
+BGTITLE="ALSA-Info v $SCRIPT_VERSION"
|
||||
+PASTEBINKEY="C9cRIO8m/9y8Cs0nVs0FraRx7U0pHsuc"
|
||||
+#Define some simple functions
|
||||
+
|
||||
+pbcheck(){
|
||||
+ [[ $UPLOAD = "no" ]] && return
|
||||
+
|
||||
+ if [[ -z $PASTEBIN ]]; then
|
||||
+ [[ $(ping -c1 www.alsa-project.org) ]] || KEEP_FILES="yes" UPLOAD="no" PBERROR="yes"
|
||||
+ else
|
||||
+ [[ $(ping -c1 www.pastebin.ca) ]] || KEEP_FILES="yes" UPLOAD="no" PBERROR="yes"
|
||||
+ fi
|
||||
+}
|
||||
+
|
||||
+update() {
|
||||
+ SHFILE=`mktemp -t alsa-info.XXXXXXXXXX` || exit 1
|
||||
+ wget -O $SHFILE "http://www.alsa-project.org/alsa-info.sh" >/dev/null 2>&1
|
||||
+ REMOTE_VERSION=`grep SCRIPT_VERSION $SHFILE |head -n1 |sed 's/.*=//'`
|
||||
+ if [ "$REMOTE_VERSION" != "$SCRIPT_VERSION" ]; then
|
||||
+ if [[ -n $DIALOG ]]
|
||||
+ then
|
||||
+ OVERWRITE=
|
||||
+ if [ -w $0 ]; then
|
||||
+ dialog --yesno "Newer version of ALSA-Info has been found\n\nDo you wish to install it?\nNOTICE: The original file $0 will be overwritten!" 0 0
|
||||
+ DIALOG_EXIT_CODE=$?
|
||||
+ if [[ $DIALOG_EXIT_CODE = 0 ]]; then
|
||||
+ OVERWRITE=yes
|
||||
+ fi
|
||||
+ fi
|
||||
+ if [ -z "$OVERWRITE" ]; then
|
||||
+ dialog --yesno "Newer version of ALSA-Info has been found\n\nDo you wish to download it?" 0 0
|
||||
+ DIALOG_EXIT_CODE=$?
|
||||
+ fi
|
||||
+ if [[ $DIALOG_EXIT_CODE = 0 ]]
|
||||
+ then
|
||||
+ echo "Newer version detected: $REMOTE_VERSION"
|
||||
+ echo "To view the ChangeLog, please visit $CHANGELOG"
|
||||
+ if [ "$OVERWRITE" = "yes" ]; then
|
||||
+ cp $SHFILE $0
|
||||
+ echo "ALSA-Info script has been updated to v $REMOTE_VERSION"
|
||||
+ echo "Please re-run the script"
|
||||
+ rm $SHFILE 2>/dev/null
|
||||
+ else
|
||||
+ echo "ALSA-Info script has been downloaded as $SHFILE."
|
||||
+ echo "Please re-run the script from new location."
|
||||
+ fi
|
||||
+ exit
|
||||
+ else
|
||||
+ rm $SHFILE 2>/dev/null
|
||||
+ fi
|
||||
+ else
|
||||
+ echo "Newer version detected: $REMOTE_VERSION"
|
||||
+ echo "To view the ChangeLog, please visit $CHANGELOG"
|
||||
+ if [ -w $0 ]; then
|
||||
+ echo "The original file $0 will be overwritten!"
|
||||
+ echo -n "If you do not like to proceed, press Ctrl-C now.." ; read inp
|
||||
+ cp $SHFILE $0
|
||||
+ echo "ALSA-Info script has been updated. Please re-run it."
|
||||
+ rm $SHFILE 2>/dev/null
|
||||
+ else
|
||||
+ echo "ALSA-Info script has been downloaded $SHFILE."
|
||||
+ echo "Please, re-run it from new location."
|
||||
+ fi
|
||||
+ exit
|
||||
+ fi
|
||||
+ else
|
||||
+ rm $SHFILE 2>/dev/null
|
||||
+ fi
|
||||
+}
|
||||
+
|
||||
+cleanup() {
|
||||
+ if [ -n "$TEMPDIR" -a "$KEEP_FILES" != "yes" ]; then
|
||||
+ rm -rf "$TEMPDIR" 2>/dev/null
|
||||
+ fi
|
||||
+ test -n "$KEEP_OUTPUT" || rm -f "$NFILE"
|
||||
+}
|
||||
+
|
||||
+
|
||||
+withaplay() {
|
||||
+ echo "!!Aplay/Arecord output" >> $FILE
|
||||
+ echo "!!--------------------" >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+ echo "APLAY" >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+ aplay -l >> $FILE 2>&1
|
||||
+ echo "" >> $FILE
|
||||
+ echo "ARECORD" >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+ arecord -l >> $FILE 2>&1
|
||||
+ echo "" >> $FILE
|
||||
+}
|
||||
+
|
||||
+withlsmod() {
|
||||
+ echo "!!All Loaded Modules" >> $FILE
|
||||
+ echo "!!------------------" >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+ lsmod |awk {'print $1'} >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+}
|
||||
+
|
||||
+withamixer() {
|
||||
+ echo "!!Amixer output" >> $FILE
|
||||
+ echo "!!-------------" >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+ for i in `grep "]: " /proc/asound/cards | awk -F ' ' '{ print $1} '` ; do
|
||||
+ CARD_NAME=`grep "^ *$i " $TEMPDIR/alsacards.tmp|awk {'print $2'}`
|
||||
+ echo "!!-------Mixer controls for card $i $CARD_NAME]" >> $FILE
|
||||
+ echo "" >>$FILE
|
||||
+ amixer -c$i info>> $FILE 2>&1
|
||||
+ amixer -c$i>> $FILE 2>&1
|
||||
+ echo "" >> $FILE
|
||||
+ done
|
||||
+ echo "" >> $FILE
|
||||
+}
|
||||
+
|
||||
+withalsactl() {
|
||||
+ echo "!!Alsactl output" >> $FILE
|
||||
+ echo "!!--------------" >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+ exe=""
|
||||
+ if [ -x /usr/sbin/alsactl ]; then
|
||||
+ exe="/usr/sbin/alsactl"
|
||||
+ fi
|
||||
+ if [ -x /usr/local/sbin/alsactl ]; then
|
||||
+ exe="/usr/local/sbin/alsactl"
|
||||
+ fi
|
||||
+ if [ -z "$exe" ]; then
|
||||
+ exe=`whereis alsactl | cut -d ' ' -f 2`
|
||||
+ fi
|
||||
+ $exe -f $TEMPDIR/alsactl.tmp store
|
||||
+ echo "--startcollapse--" >> $FILE
|
||||
+ cat $TEMPDIR/alsactl.tmp >> $FILE
|
||||
+ echo "--endcollapse--" >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+}
|
||||
+
|
||||
+withdevices() {
|
||||
+ echo "!!ALSA Device nodes" >> $FILE
|
||||
+ echo "!!-----------------" >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+ ls -la /dev/snd/* >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+}
|
||||
+
|
||||
+withconfigs() {
|
||||
+if [[ -e $HOME/.asoundrc ]] || [[ -e /etc/asound.conf ]] || [[ -e $HOME/.asoundrc.asoundconf ]]
|
||||
+then
|
||||
+ echo "!!ALSA configuration files" >> $FILE
|
||||
+ echo "!!------------------------" >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+
|
||||
+ #Check for ~/.asoundrc
|
||||
+ if [[ -e $HOME/.asoundrc ]]
|
||||
+ then
|
||||
+ echo "!!User specific config file (~/.asoundrc)" >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+ cat $HOME/.asoundrc >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+ fi
|
||||
+ #Check for .asoundrc.asoundconf (seems to be Ubuntu specific)
|
||||
+ if [[ -e $HOME/.asoundrc.asoundconf ]]
|
||||
+ then
|
||||
+ echo "!!asoundconf-generated config file" >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+ cat $HOME/.asoundrc.asoundconf >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+ fi
|
||||
+ #Check for /etc/asound.conf
|
||||
+ if [[ -e /etc/asound.conf ]]
|
||||
+ then
|
||||
+ echo "!!System wide config file (/etc/asound.conf)" >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+ cat /etc/asound.conf >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+ fi
|
||||
+fi
|
||||
+}
|
||||
+
|
||||
+withsysfs() {
|
||||
+ local i f
|
||||
+ local printed=""
|
||||
+ for i in /sys/class/sound/*; do
|
||||
+ case "$i" in
|
||||
+ */hwC?D?)
|
||||
+ if [ -f $i/init_pin_configs ]; then
|
||||
+ if [ -z "$printed" ]; then
|
||||
+ echo "!!Sysfs Files" >> $FILE
|
||||
+ echo "!!-----------" >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+ fi
|
||||
+ for f in init_pin_configs driver_pin_configs user_pin_configs init_verbs hints; do
|
||||
+ echo "$i/$f:" >> $FILE
|
||||
+ cat $i/$f >> $FILE
|
||||
+ echo >> $FILE
|
||||
+ done
|
||||
+ printed=yes
|
||||
+ fi
|
||||
+ ;;
|
||||
+ esac
|
||||
+ done
|
||||
+ if [ -n "$printed" ]; then
|
||||
+ echo "" >> $FILE
|
||||
+ fi
|
||||
+}
|
||||
+
|
||||
+withdmesg() {
|
||||
+ echo "!!ALSA/HDA dmesg" >> $FILE
|
||||
+ echo "!!--------------" >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+ dmesg | grep -C1 -E 'ALSA|HDA|HDMI|snd[_-]|sound|hda.codec|hda.intel' >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+}
|
||||
+
|
||||
+withall() {
|
||||
+ withdevices
|
||||
+ withconfigs
|
||||
+ withaplay
|
||||
+ withamixer
|
||||
+ withalsactl
|
||||
+ withlsmod
|
||||
+ withsysfs
|
||||
+ withdmesg
|
||||
+}
|
||||
+
|
||||
+get_alsa_library_version() {
|
||||
+ ALSA_LIB_VERSION=`grep VERSION_STR /usr/include/alsa/version.h 2>/dev/null|awk {'print $3'}|sed 's/"//g'`
|
||||
+
|
||||
+ if [ -z "$ALSA_LIB_VERSION" ]; then
|
||||
+ if [ -f /etc/lsb-release ]; then
|
||||
+ . /etc/lsb-release
|
||||
+ case "$DISTRIB_ID" in
|
||||
+ Ubuntu)
|
||||
+ if which dpkg > /dev/null ; then
|
||||
+ ALSA_LIB_VERSION=`dpkg -l libasound2 | tail -1 | awk '{print $3}' | cut -f 1 -d -`
|
||||
+ fi
|
||||
+
|
||||
+ if [ "$ALSA_LIB_VERSION" = "<none>" ]; then
|
||||
+ ALSA_LIB_VERSION=""
|
||||
+ fi
|
||||
+ return
|
||||
+ ;;
|
||||
+ *)
|
||||
+ return
|
||||
+ ;;
|
||||
+ esac
|
||||
+ elif [ -f /etc/debian_version ]; then
|
||||
+ if which dpkg > /dev/null ; then
|
||||
+ ALSA_LIB_VERSION=`dpkg -l libasound2 | tail -1 | awk '{print $3}' | cut -f 1 -d -`
|
||||
+ fi
|
||||
+
|
||||
+ if [ "$ALSA_LIB_VERSION" = "<none>" ]; then
|
||||
+ ALSA_LIB_VERSION=""
|
||||
+ fi
|
||||
+ return
|
||||
+ fi
|
||||
+ fi
|
||||
+}
|
||||
+
|
||||
+
|
||||
+#Run checks to make sure the programs we need are installed.
|
||||
+LSPCI=$(which lspci 2>/dev/null| sed 's|^[^/]*||' 2>/dev/null);
|
||||
+TPUT=$(which tput 2>/dev/null| sed 's|^[^/]*||' 2>/dev/null);
|
||||
+DIALOG=$(which dialog 2>/dev/null | sed 's|^[^/]*||' 2>/dev/null);
|
||||
+
|
||||
+#Check to see if sysfs is enabled in the kernel. We'll need this later on
|
||||
+SYSFS=$(mount |grep sysfs|awk {'print $3'});
|
||||
+
|
||||
+#Check modprobe config files for sound related options
|
||||
+SNDOPTIONS=$(modprobe -c|sed -n 's/^options \(snd[-_][^ ]*\)/\1:/p')
|
||||
+
|
||||
+KEEP_OUTPUT=
|
||||
+NFILE=""
|
||||
+
|
||||
+PASTEBIN=""
|
||||
+WWWSERVICE="www.alsa-project.org"
|
||||
+WELCOME="yes"
|
||||
+PROCEED="yes"
|
||||
+UPLOAD="ask"
|
||||
+REPEAT=""
|
||||
+while [ -z "$REPEAT" ]; do
|
||||
+REPEAT="no"
|
||||
+case "$1" in
|
||||
+ --update|--help|--about)
|
||||
+ WELCOME="no"
|
||||
+ PROCEED="no"
|
||||
+ ;;
|
||||
+ --upload)
|
||||
+ UPLOAD="yes"
|
||||
+ WELCOME="no"
|
||||
+ ;;
|
||||
+ --no-upload)
|
||||
+ UPLOAD="no"
|
||||
+ WELCOME="no"
|
||||
+ ;;
|
||||
+ --pastebin)
|
||||
+ PASTEBIN="yes"
|
||||
+ WWWSERVICE="pastebin"
|
||||
+ ;;
|
||||
+ --no-dialog)
|
||||
+ DIALOG=""
|
||||
+ REPEAT=""
|
||||
+ shift
|
||||
+ ;;
|
||||
+ --stdout)
|
||||
+ DIALOG=""
|
||||
+ UPLOAD="no"
|
||||
+ WELCOME="no"
|
||||
+ TOSTDOUT="yes"
|
||||
+ ;;
|
||||
+esac
|
||||
+done
|
||||
+
|
||||
+
|
||||
+#Script header output.
|
||||
+if [ "$WELCOME" = "yes" ]; then
|
||||
+greeting_message="\
|
||||
+
|
||||
+This script visits the following commands/files to collect diagnostic
|
||||
+information about your ALSA installation and sound related hardware.
|
||||
+
|
||||
+ dmesg
|
||||
+ lspci
|
||||
+ lsmod
|
||||
+ aplay
|
||||
+ amixer
|
||||
+ alsactl
|
||||
+ /proc/asound/
|
||||
+ /sys/class/sound/
|
||||
+ ~/.asoundrc (etc.)
|
||||
+
|
||||
+See '$0 --help' for command line options.
|
||||
+"
|
||||
+if [ -n "$DIALOG" ]; then
|
||||
+ dialog --backtitle "$BGTITLE" \
|
||||
+ --title "ALSA-Info script v $SCRIPT_VERSION" \
|
||||
+ --msgbox "$greeting_message" 20 80
|
||||
+else
|
||||
+ echo "ALSA Information Script v $SCRIPT_VERSION"
|
||||
+ echo "--------------------------------"
|
||||
+ echo "$greeting_message"
|
||||
+fi # dialog
|
||||
+fi # WELCOME
|
||||
+
|
||||
+#Set the output file
|
||||
+TEMPDIR=`mktemp -t -d alsa-info.XXXXXXXXXX` || exit 1
|
||||
+FILE="$TEMPDIR/alsa-info.txt"
|
||||
+if [ -z "$NFILE" ]; then
|
||||
+ NFILE=`mktemp -t alsa-info.txt.XXXXXXXXXX` || exit 1
|
||||
+fi
|
||||
+
|
||||
+trap cleanup 0
|
||||
+
|
||||
+if [ "$PROCEED" = "yes" ]; then
|
||||
+
|
||||
+if [ -z "$LSPCI" ]; then
|
||||
+ if [ -d /sys/bus/pci ]; then
|
||||
+ echo "This script requires lspci. Please install it, and re-run this script."
|
||||
+ exit 0
|
||||
+ fi
|
||||
+fi
|
||||
+
|
||||
+#Fetch the info and store in temp files/variables
|
||||
+DISTRO=`grep -ihs "buntu\|SUSE\|Fedora\|PCLinuxOS\|MEPIS\|Mandriva\|Debian\|Damn\|Sabayon\|Slackware\|KNOPPIX\|Gentoo\|Zenwalk\|Mint\|Kubuntu\|FreeBSD\|Puppy\|Freespire\|Vector\|Dreamlinux\|CentOS\|Arch\|Xandros\|Elive\|SLAX\|Red\|BSD\|KANOTIX\|Nexenta\|Foresight\|GeeXboX\|Frugalware\|64\|SystemRescue\|Novell\|Solaris\|BackTrack\|KateOS\|Pardus" /etc/{issue,*release,*version}`
|
||||
+KERNEL_VERSION=`uname -r`
|
||||
+KERNEL_PROCESSOR=`uname -p`
|
||||
+KERNEL_MACHINE=`uname -m`
|
||||
+KERNEL_OS=`uname -o`
|
||||
+[[ `uname -v | grep SMP` ]] && KERNEL_SMP="Yes" || KERNEL_SMP="No"
|
||||
+ALSA_DRIVER_VERSION=`cat /proc/asound/version |head -n1|awk {'print $7'} |sed 's/\.$//'`
|
||||
+get_alsa_library_version
|
||||
+ALSA_UTILS_VERSION=`amixer -v |awk {'print $3'}`
|
||||
+LAST_CARD=$((`grep "]: " /proc/asound/cards | wc -l` - 1 ))
|
||||
+
|
||||
+ESDINST=$(which esd 2>/dev/null| sed 's|^[^/]*||' 2>/dev/null)
|
||||
+PAINST=$(which pulseaudio 2>/dev/null| sed 's|^[^/]*||' 2>/dev/null)
|
||||
+ARTSINST=$(which artsd 2>/dev/null| sed 's|^[^/]*||' 2>/dev/null)
|
||||
+JACKINST=$(which jackd 2>/dev/null| sed 's|^[^/]*||' 2>/dev/null)
|
||||
+ROARINST=$(which roard 2>/dev/null| sed 's|^[^/]*||' 2>/dev/null)
|
||||
+DMIDECODE=$(which dmidecode 2>/dev/null| sed 's|^[^/]*||' 2>/dev/null)
|
||||
+
|
||||
+#Check for DMI data
|
||||
+if [ -d /sys/class/dmi/id ]; then
|
||||
+ # No root privileges are required when using sysfs method
|
||||
+ DMI_SYSTEM_MANUFACTURER=$(cat /sys/class/dmi/id/sys_vendor 2>/dev/null)
|
||||
+ DMI_SYSTEM_PRODUCT_NAME=$(cat /sys/class/dmi/id/product_name 2>/dev/null)
|
||||
+ DMI_SYSTEM_PRODUCT_VERSION=$(cat /sys/class/dmi/id/product_version 2>/dev/null)
|
||||
+ DMI_SYSTEM_FIRMWARE_VERSION=$(cat /sys/class/dmi/id/bios_version 2>/dev/null)
|
||||
+elif [ -x $DMIDECODE ]; then
|
||||
+ DMI_SYSTEM_MANUFACTURER=$($DMIDECODE -s system-manufacturer 2>/dev/null)
|
||||
+ DMI_SYSTEM_PRODUCT_NAME=$($DMIDECODE -s system-product-name 2>/dev/null)
|
||||
+ DMI_SYSTEM_PRODUCT_VERSION=$($DMIDECODE -s system-version 2>/dev/null)
|
||||
+ DMI_SYSTEM_FIRMWARE_VERSION=$($DMIDECODE -s bios-version 2>/dev/null)
|
||||
+fi
|
||||
+
|
||||
+cat /proc/asound/modules 2>/dev/null|awk {'print $2'}>$TEMPDIR/alsamodules.tmp
|
||||
+cat /proc/asound/cards >$TEMPDIR/alsacards.tmp
|
||||
+if [[ ! -z "$LSPCI" ]]; then
|
||||
+lspci |grep -i "multi\|audio">$TEMPDIR/lspci.tmp
|
||||
+fi
|
||||
+
|
||||
+#Check for HDA-Intel cards codec#*
|
||||
+cat /proc/asound/card*/codec\#* > $TEMPDIR/alsa-hda-intel.tmp 2> /dev/null
|
||||
+
|
||||
+#Check for AC97 cards codec
|
||||
+cat /proc/asound/card*/codec97\#0/ac97\#0-0 > $TEMPDIR/alsa-ac97.tmp 2> /dev/null
|
||||
+cat /proc/asound/card*/codec97\#0/ac97\#0-0+regs > $TEMPDIR/alsa-ac97-regs.tmp 2> /dev/null
|
||||
+
|
||||
+#Check for USB mixer setup
|
||||
+cat /proc/asound/card*/usbmixer > $TEMPDIR/alsa-usbmixer.tmp 2> /dev/null
|
||||
+
|
||||
+#Fetch the info, and put it in $FILE in a nice readable format.
|
||||
+if [[ -z $PASTEBIN ]]; then
|
||||
+echo "upload=true&script=true&cardinfo=" > $FILE
|
||||
+else
|
||||
+echo "name=$USER&type=33&description=/tmp/alsa-info.txt&expiry=&s=Submit+Post&content=" > $FILE
|
||||
+fi
|
||||
+echo "!!################################" >> $FILE
|
||||
+echo "!!ALSA Information Script v $SCRIPT_VERSION" >> $FILE
|
||||
+echo "!!################################" >> $FILE
|
||||
+echo "" >> $FILE
|
||||
+echo "!!Script ran on: `LANG=C TZ=UTC date`" >> $FILE
|
||||
+echo "" >> $FILE
|
||||
+echo "" >> $FILE
|
||||
+echo "!!Linux Distribution" >> $FILE
|
||||
+echo "!!------------------" >> $FILE
|
||||
+echo "" >> $FILE
|
||||
+echo $DISTRO >> $FILE
|
||||
+echo "" >> $FILE
|
||||
+echo "" >> $FILE
|
||||
+echo "!!DMI Information" >> $FILE
|
||||
+echo "!!---------------" >> $FILE
|
||||
+echo "" >> $FILE
|
||||
+echo "Manufacturer: $DMI_SYSTEM_MANUFACTURER" >> $FILE
|
||||
+echo "Product Name: $DMI_SYSTEM_PRODUCT_NAME" >> $FILE
|
||||
+echo "Product Version: $DMI_SYSTEM_PRODUCT_VERSION" >> $FILE
|
||||
+echo "Firmware Version: $DMI_SYSTEM_FIRMWARE_VERSION" >> $FILE
|
||||
+echo "" >> $FILE
|
||||
+echo "" >> $FILE
|
||||
+echo "!!Kernel Information" >> $FILE
|
||||
+echo "!!------------------" >> $FILE
|
||||
+echo "" >> $FILE
|
||||
+echo "Kernel release: $KERNEL_VERSION" >> $FILE
|
||||
+echo "Operating System: $KERNEL_OS" >> $FILE
|
||||
+echo "Architecture: $KERNEL_MACHINE" >> $FILE
|
||||
+echo "Processor: $KERNEL_PROCESSOR" >> $FILE
|
||||
+echo "SMP Enabled: $KERNEL_SMP" >> $FILE
|
||||
+echo "" >> $FILE
|
||||
+echo "" >> $FILE
|
||||
+echo "!!ALSA Version" >> $FILE
|
||||
+echo "!!------------" >> $FILE
|
||||
+echo "" >> $FILE
|
||||
+echo "Driver version: $ALSA_DRIVER_VERSION" >> $FILE
|
||||
+echo "Library version: $ALSA_LIB_VERSION" >> $FILE
|
||||
+echo "Utilities version: $ALSA_UTILS_VERSION" >> $FILE
|
||||
+echo "" >> $FILE
|
||||
+echo "" >> $FILE
|
||||
+echo "!!Loaded ALSA modules" >> $FILE
|
||||
+echo "!!-------------------" >> $FILE
|
||||
+echo "" >> $FILE
|
||||
+cat $TEMPDIR/alsamodules.tmp >> $FILE
|
||||
+echo "" >> $FILE
|
||||
+echo "" >> $FILE
|
||||
+echo "!!Sound Servers on this system" >> $FILE
|
||||
+echo "!!----------------------------" >> $FILE
|
||||
+echo "" >> $FILE
|
||||
+if [[ -n $PAINST ]];then
|
||||
+[[ `pgrep '^(.*/)?pulseaudio$'` ]] && PARUNNING="Yes" || PARUNNING="No"
|
||||
+echo "Pulseaudio:" >> $FILE
|
||||
+echo " Installed - Yes ($PAINST)" >> $FILE
|
||||
+echo " Running - $PARUNNING" >> $FILE
|
||||
+echo "" >> $FILE
|
||||
+fi
|
||||
+if [[ -n $ESDINST ]];then
|
||||
+[[ `pgrep '^(.*/)?esd$'` ]] && ESDRUNNING="Yes" || ESDRUNNING="No"
|
||||
+echo "ESound Daemon:" >> $FILE
|
||||
+echo " Installed - Yes ($ESDINST)" >> $FILE
|
||||
+echo " Running - $ESDRUNNING" >> $FILE
|
||||
+echo "" >> $FILE
|
||||
+fi
|
||||
+if [[ -n $ARTSINST ]];then
|
||||
+[[ `pgrep '^(.*/)?artsd$'` ]] && ARTSRUNNING="Yes" || ARTSRUNNING="No"
|
||||
+echo "aRts:" >> $FILE
|
||||
+echo " Installed - Yes ($ARTSINST)" >> $FILE
|
||||
+echo " Running - $ARTSRUNNING" >> $FILE
|
||||
+echo "" >> $FILE
|
||||
+fi
|
||||
+if [[ -n $JACKINST ]];then
|
||||
+[[ `pgrep '^(.*/)?jackd$'` ]] && JACKRUNNING="Yes" || JACKRUNNING="No"
|
||||
+echo "Jack:" >> $FILE
|
||||
+echo " Installed - Yes ($JACKINST)" >> $FILE
|
||||
+echo " Running - $JACKRUNNING" >> $FILE
|
||||
+echo "" >> $FILE
|
||||
+fi
|
||||
+if [[ -n $ROARINST ]];then
|
||||
+[[ `pgrep '^(.*/)?roard$'` ]] && ROARRUNNING="Yes" || ROARRUNNING="No"
|
||||
+echo "RoarAudio:" >> $FILE
|
||||
+echo " Installed - Yes ($ROARINST)" >> $FILE
|
||||
+echo " Running - $ROARRUNNING" >> $FILE
|
||||
+echo "" >> $FILE
|
||||
+fi
|
||||
+if [[ -z "$PAINST" && -z "$ESDINST" && -z "$ARTSINST" && -z "$JACKINST" && -z "$ROARINST" ]];then
|
||||
+echo "No sound servers found." >> $FILE
|
||||
+echo "" >> $FILE
|
||||
+fi
|
||||
+echo "" >> $FILE
|
||||
+echo "!!Soundcards recognised by ALSA" >> $FILE
|
||||
+echo "!!-----------------------------" >> $FILE
|
||||
+echo "" >> $FILE
|
||||
+cat $TEMPDIR/alsacards.tmp >> $FILE
|
||||
+echo "" >> $FILE
|
||||
+echo "" >> $FILE
|
||||
+
|
||||
+if [[ ! -z "$LSPCI" ]]; then
|
||||
+echo "!!PCI Soundcards installed in the system" >> $FILE
|
||||
+echo "!!--------------------------------------" >> $FILE
|
||||
+echo "" >> $FILE
|
||||
+cat $TEMPDIR/lspci.tmp >> $FILE
|
||||
+echo "" >> $FILE
|
||||
+echo "" >> $FILE
|
||||
+echo "!!Advanced information - PCI Vendor/Device/Subsystem ID's" >> $FILE
|
||||
+echo "!!-------------------------------------------------------" >> $FILE
|
||||
+echo "" >> $FILE
|
||||
+lspci -vvn |grep -A1 040[1-3] >> $FILE
|
||||
+echo "" >> $FILE
|
||||
+echo "" >> $FILE
|
||||
+fi
|
||||
+
|
||||
+if [ "$SNDOPTIONS" ]
|
||||
+then
|
||||
+echo "!!Modprobe options (Sound related)" >> $FILE
|
||||
+echo "!!--------------------------------" >> $FILE
|
||||
+echo "" >> $FILE
|
||||
+modprobe -c|sed -n 's/^options \(snd[-_][^ ]*\)/\1:/p' >> $FILE
|
||||
+echo "" >> $FILE
|
||||
+echo "" >> $FILE
|
||||
+fi
|
||||
+
|
||||
+if [ -d "$SYSFS" ]
|
||||
+then
|
||||
+echo "!!Loaded sound module options" >> $FILE
|
||||
+echo "!!---------------------------" >> $FILE
|
||||
+echo "" >> $FILE
|
||||
+for mod in `cat /proc/asound/modules|awk {'print $2'}`;do
|
||||
+echo "!!Module: $mod" >> $FILE
|
||||
+for params in `echo $SYSFS/module/$mod/parameters/*`; do
|
||||
+ echo -ne "\t";
|
||||
+ echo "$params : `cat $params`" | sed 's:.*/::';
|
||||
+done >> $FILE
|
||||
+echo "" >> $FILE
|
||||
+done
|
||||
+echo "" >> $FILE
|
||||
+fi
|
||||
+
|
||||
+if [ -s "$TEMPDIR/alsa-hda-intel.tmp" ]; then
|
||||
+ echo "!!HDA-Intel Codec information" >> $FILE
|
||||
+ echo "!!---------------------------" >> $FILE
|
||||
+ echo "--startcollapse--" >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+ cat $TEMPDIR/alsa-hda-intel.tmp >> $FILE
|
||||
+ echo "--endcollapse--" >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+fi
|
||||
+
|
||||
+if [ -s "$TEMPDIR/alsa-ac97.tmp" ]; then
|
||||
+ echo "!!AC97 Codec information" >> $FILE
|
||||
+ echo "!!----------------------" >> $FILE
|
||||
+ echo "--startcollapse--" >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+ cat $TEMPDIR/alsa-ac97.tmp >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+ cat $TEMPDIR/alsa-ac97-regs.tmp >> $FILE
|
||||
+ echo "--endcollapse--" >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+fi
|
||||
+
|
||||
+if [ -s "$TEMPDIR/alsa-usbmixer.tmp" ]; then
|
||||
+ echo "!!USB Mixer information" >> $FILE
|
||||
+ echo "!!---------------------" >> $FILE
|
||||
+ echo "--startcollapse--" >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+ cat $TEMPDIR/alsa-usbmixer.tmp >> $FILE
|
||||
+ echo "--endcollapse--" >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+fi
|
||||
+
|
||||
+#If no command line options are specified, then run as though --with-all was specified
|
||||
+if [ -z "$1" ]; then
|
||||
+ update
|
||||
+ withall
|
||||
+ pbcheck
|
||||
+fi
|
||||
+
|
||||
+fi # proceed
|
||||
+
|
||||
+#loop through command line arguments, until none are left.
|
||||
+if [ -n "$1" ]; then
|
||||
+ until [ -z "$1" ]
|
||||
+ do
|
||||
+ case "$1" in
|
||||
+ --pastebin)
|
||||
+ update
|
||||
+ withall
|
||||
+ pbcheck
|
||||
+ ;;
|
||||
+ --update)
|
||||
+ update
|
||||
+ exit
|
||||
+ ;;
|
||||
+ --upload)
|
||||
+ UPLOAD="yes"
|
||||
+ withall
|
||||
+ ;;
|
||||
+ --no-upload)
|
||||
+ UPLOAD="no"
|
||||
+ withall
|
||||
+ ;;
|
||||
+ --output)
|
||||
+ shift
|
||||
+ NFILE="$1"
|
||||
+ KEEP_OUTPUT="yes"
|
||||
+ ;;
|
||||
+ --debug)
|
||||
+ echo "Debugging enabled. $FILE and $TEMPDIR will not be deleted"
|
||||
+ KEEP_FILES="yes"
|
||||
+ echo ""
|
||||
+ withall
|
||||
+ ;;
|
||||
+ --with-all)
|
||||
+ withall
|
||||
+ ;;
|
||||
+ --with-aplay)
|
||||
+ withaplay
|
||||
+ ;;
|
||||
+ --with-amixer)
|
||||
+ withamixer
|
||||
+ ;;
|
||||
+ --with-alsactl)
|
||||
+ withalsactl
|
||||
+ ;;
|
||||
+ --with-devices)
|
||||
+ withdevices
|
||||
+ ;;
|
||||
+ --with-dmesg)
|
||||
+ withdmesg
|
||||
+ ;;
|
||||
+ --with-configs)
|
||||
+ if [[ -e $HOME/.asoundrc ]] || [[ -e /etc/asound.conf ]]
|
||||
+ then
|
||||
+ echo "!!ALSA configuration files" >> $FILE
|
||||
+ echo "!!------------------------" >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+
|
||||
+ #Check for ~/.asoundrc
|
||||
+ if [[ -e $HOME/.asoundrc ]]
|
||||
+ then
|
||||
+ echo "!!User specific config file ($HOME/.asoundrc)" >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+ cat $HOME/.asoundrc >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+ fi
|
||||
+
|
||||
+ #Check for /etc/asound.conf
|
||||
+ if [[ -e /etc/asound.conf ]]
|
||||
+ then
|
||||
+ echo "!!System wide config file (/etc/asound.conf)" >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+ cat /etc/asound.conf >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+ echo "" >> $FILE
|
||||
+ fi
|
||||
+ fi
|
||||
+ ;;
|
||||
+ --stdout)
|
||||
+ UPLOAD="no"
|
||||
+ withall
|
||||
+ cat $FILE
|
||||
+ rm $FILE
|
||||
+ ;;
|
||||
+ --about)
|
||||
+ echo "Written/Tested by the following users of #alsa on irc.freenode.net:"
|
||||
+ echo ""
|
||||
+ echo " wishie - Script author and developer / Testing"
|
||||
+ echo " crimsun - Various script ideas / Testing"
|
||||
+ echo " gnubien - Various script ideas / Testing"
|
||||
+ echo " GrueMaster - HDA Intel specific items / Testing"
|
||||
+ echo " olegfink - Script update function"
|
||||
+ echo " TheMuso - display to stdout functionality"
|
||||
+ exit 0
|
||||
+ ;;
|
||||
+ *)
|
||||
+ echo "alsa-info.sh version $SCRIPT_VERSION"
|
||||
+ echo ""
|
||||
+ echo "Available options:"
|
||||
+ echo " --with-aplay (includes the output of aplay -l)"
|
||||
+ echo " --with-amixer (includes the output of amixer)"
|
||||
+ echo " --with-alsactl (includes the output of alsactl)"
|
||||
+ echo " --with-configs (includes the output of ~/.asoundrc and"
|
||||
+ echo " /etc/asound.conf if they exist)"
|
||||
+ echo " --with-devices (shows the device nodes in /dev/snd/)"
|
||||
+ echo " --with-dmesg (shows the ALSA/HDA kernel messages)"
|
||||
+ echo ""
|
||||
+ echo " --output FILE (specify the file to output for no-upload mode)"
|
||||
+ echo " --update (check server for script updates)"
|
||||
+ echo " --upload (upload contents to remote server)"
|
||||
+ echo " --no-upload (do not upload contents to remote server)"
|
||||
+ echo " --pastebin (use http://pastebin.ca) as remote server"
|
||||
+ echo " instead www.alsa-project.org"
|
||||
+ echo " --stdout (print alsa information to standard output"
|
||||
+ echo " instead of a file)"
|
||||
+ echo " --about (show some information about the script)"
|
||||
+ echo " --debug (will run the script as normal, but will not"
|
||||
+ echo " delete $FILE)"
|
||||
+ exit 0
|
||||
+ ;;
|
||||
+ esac
|
||||
+ shift 1
|
||||
+ done
|
||||
+fi
|
||||
+
|
||||
+if [ "$PROCEED" = "no" ]; then
|
||||
+ exit 1
|
||||
+fi
|
||||
+
|
||||
+if [ "$UPLOAD" = "ask" ]; then
|
||||
+ if [ -n "$DIALOG" ]; then
|
||||
+ dialog --backtitle "$BGTITLE" --title "Information collected" --yes-label " UPLOAD / SHARE " --no-label " SAVE LOCALLY " --defaultno --yesno "\n\nAutomatically upload ALSA information to $WWWSERVICE?" 10 80
|
||||
+ DIALOG_EXIT_CODE=$?
|
||||
+ if [ $DIALOG_EXIT_CODE != 0 ]; then
|
||||
+ UPLOAD="no"
|
||||
+ else
|
||||
+ UPLOAD="yes"
|
||||
+ fi
|
||||
+ else
|
||||
+ echo -n "Automatically upload ALSA information to $WWWSERVICE? [y/N] : "
|
||||
+ read -e CONFIRM
|
||||
+ if [ "$CONFIRM" != "y" ]; then
|
||||
+ UPLOAD="no"
|
||||
+ else
|
||||
+ UPLOAD="yes"
|
||||
+ fi
|
||||
+ fi
|
||||
+
|
||||
+fi
|
||||
+
|
||||
+if [ "$UPLOAD" = "no" ]; then
|
||||
+
|
||||
+ if [ -z "$TOSTDOUT" ]; then
|
||||
+ mv -f $FILE $NFILE || exit 1
|
||||
+ KEEP_OUTPUT="yes"
|
||||
+ fi
|
||||
+
|
||||
+ if [[ -n $DIALOG ]]
|
||||
+ then
|
||||
+ if [[ -n $PBERROR ]]; then
|
||||
+ dialog --backtitle "$BGTITLE" --title "Information collected" --msgbox "An error occurred while contacting the $WWWSERVICE.\n Your information was NOT automatically uploaded.\n\nYour ALSA information is in $NFILE" 10 100
|
||||
+ else
|
||||
+ dialog --backtitle "$BGTITLE" --title "Information collected" --msgbox "\n\nYour ALSA information is in $NFILE" 10 60
|
||||
+ fi
|
||||
+ else
|
||||
+ echo
|
||||
+
|
||||
+ if [[ -n $PBERROR ]]; then
|
||||
+ echo "An error occurred while contacting the $WWWSERVICE."
|
||||
+ echo "Your information was NOT automatically uploaded."
|
||||
+ echo ""
|
||||
+ echo "Your ALSA information is in $NFILE"
|
||||
+ echo ""
|
||||
+ else
|
||||
+ if [ -z "$TOSTDOUT" ]; then
|
||||
+ echo ""
|
||||
+ echo "Your ALSA information is in $NFILE"
|
||||
+ echo ""
|
||||
+ fi
|
||||
+ fi
|
||||
+ fi
|
||||
+
|
||||
+ exit
|
||||
+
|
||||
+fi # UPLOAD
|
||||
+
|
||||
+#Test that wget is installed, and supports --post-file. Upload $FILE if it does, and prompt user to upload file if it doesnt.
|
||||
+if
|
||||
+WGET=$(which wget 2>/dev/null| sed 's|^[^/]*||' 2>/dev/null); [[ -n "${WGET}" ]] && [[ -x "${WGET}" ]] && [[ `wget --help |grep post-file` ]]
|
||||
+then
|
||||
+
|
||||
+if [[ -n $DIALOG ]]
|
||||
+then
|
||||
+
|
||||
+if [[ -z $PASTEBIN ]]; then
|
||||
+ wget -O - --tries=5 --timeout=60 --post-file=$FILE "http://www.alsa-project.org/cardinfo-db/" &>$TEMPDIR/wget.tmp || echo "Upload failed; exit"
|
||||
+ { for i in 10 20 30 40 50 60 70 80 90; do
|
||||
+ echo $i
|
||||
+ sleep 0.2
|
||||
+ done
|
||||
+ echo; } |dialog --backtitle "$BGTITLE" --guage "Uploading information to www.alsa-project.org ..." 6 70 0
|
||||
+else
|
||||
+ wget -O - --tries=5 --timeout=60 --post-file=$FILE "http://pastebin.ca/quiet-paste.php?api=$PASTEBINKEY&encrypt=t&encryptpw=blahblah" &>$TEMPDIR/wget.tmp || echo "Upload failed; exit"
|
||||
+ { for i in 10 20 30 40 50 60 70 80 90; do
|
||||
+ echo $i
|
||||
+ sleep 0.2
|
||||
+ done
|
||||
+ echo; } |dialog --backtitle "$BGTITLE" --guage "Uploading information to www.pastebin.ca ..." 6 70 0
|
||||
+fi
|
||||
+
|
||||
+dialog --backtitle "$BGTITLE" --title "Information uploaded" --yesno "Would you like to see the uploaded information?" 5 100
|
||||
+DIALOG_EXIT_CODE=$?
|
||||
+if [ $DIALOG_EXIT_CODE = 0 ]; then
|
||||
+ grep -v "alsa-info.txt" $FILE >$TEMPDIR/uploaded.txt
|
||||
+ dialog --backtitle "$BGTITLE" --textbox $TEMPDIR/uploaded.txt 0 0
|
||||
+fi
|
||||
+
|
||||
+clear
|
||||
+
|
||||
+# no dialog
|
||||
+else
|
||||
+
|
||||
+if [[ -z $PASTEBIN ]]; then
|
||||
+ echo -n "Uploading information to www.alsa-project.org ... "
|
||||
+ wget -O - --tries=5 --timeout=60 --post-file=$FILE http://www.alsa-project.org/cardinfo-db/ &>$TEMPDIR/wget.tmp &
|
||||
+else
|
||||
+ echo -n "Uploading information to www.pastebin.ca ... "
|
||||
+ wget -O - --tries=5 --timeout=60 --post-file=$FILE http://pastebin.ca/quiet-paste.php?api=$PASTEBINKEY &>$TEMPDIR/wget.tmp &
|
||||
+fi
|
||||
+
|
||||
+#Progess spinner for wget transfer.
|
||||
+i=1
|
||||
+sp="/-\|"
|
||||
+echo -n ' '
|
||||
+while pgrep wget &>/dev/null
|
||||
+do
|
||||
+ echo -en "\b${sp:i++%${#sp}:1}"
|
||||
+done
|
||||
+
|
||||
+echo -e "\b Done!"
|
||||
+echo ""
|
||||
+
|
||||
+fi #dialog
|
||||
+
|
||||
+#See if tput is available, and use it if it is.
|
||||
+if [ -n "$TPUT" ]; then
|
||||
+ if [[ -z $PASTEBIN ]]; then
|
||||
+ FINAL_URL=`tput setaf 1; grep "SUCCESS:" $TEMPDIR/wget.tmp | cut -d ' ' -f 2 ; tput sgr0`
|
||||
+ else
|
||||
+ FINAL_URL=`tput setaf 1; grep "SUCCESS:" $TEMPDIR/wget.tmp | sed -n 's/.*\:\([0-9]\+\).*/http:\/\/pastebin.ca\/\1/p';tput sgr0`
|
||||
+ fi
|
||||
+else
|
||||
+ if [[ -z $PASTEBIN ]]; then
|
||||
+ FINAL_URL=`grep "SUCCESS:" $TEMPDIR/wget.tmp | cut -d ' ' -f 2`
|
||||
+ else
|
||||
+ FINAL_URL=`grep "SUCCESS:" $TEMPDIR/wget.tmp | sed -n 's/.*\:\([0-9]\+\).*/http:\/\/pastebin.ca\/\1/p'`
|
||||
+ fi
|
||||
+fi
|
||||
+
|
||||
+# Output the URL of the uploaded file.
|
||||
+echo "Your ALSA information is located at $FINAL_URL"
|
||||
+echo "Please inform the person helping you."
|
||||
+echo ""
|
||||
+
|
||||
+# We couldnt find a suitable wget, so tell the user to upload manually.
|
||||
+else
|
||||
+ mv -f $FILE $NFILE || exit 1
|
||||
+ KEEP_OUTPUT="yes"
|
||||
+ if [[ -z $DIALOG ]]
|
||||
+ then
|
||||
+ if [[ -z $PASTEBIN ]]; then
|
||||
+ echo ""
|
||||
+ echo "Could not automatically upload output to http://www.alsa-project.org"
|
||||
+ echo "Possible reasons are:"
|
||||
+ echo " 1. Couldnt find 'wget' in your PATH"
|
||||
+ echo " 2. Your version of wget is less than 1.8.2"
|
||||
+ echo ""
|
||||
+ echo "Please manually upload $NFILE to http://www.alsa-project.org/cardinfo-db/ and submit your post."
|
||||
+ echo ""
|
||||
+ else
|
||||
+ echo ""
|
||||
+ echo "Could not automatically upload output to http://www.pastebin.ca"
|
||||
+ echo "Possible reasons are:"
|
||||
+ echo " 1. Couldnt find 'wget' in your PATH"
|
||||
+ echo " 2. Your version of wget is less than 1.8.2"
|
||||
+ echo ""
|
||||
+ echo "Please manually upload $NFILE to http://www.pastebin.ca/upload.php and submit your post."
|
||||
+ echo ""
|
||||
+ fi
|
||||
+ else
|
||||
+ if [[ -z $PASTEBIN ]]; then
|
||||
+ dialog --backtitle "$BGTITLE" --msgbox "Could not automatically upload output to http://www.alsa-project.org.\nPossible reasons are:\n\n 1. Couldn't find 'wget' in your PATH\n 2. Your version of wget is less than 1.8.2\n\nPlease manually upload $NFILE to http://www.alsa-project,org/cardinfo-db/ and submit your post." 25 100
|
||||
+ else
|
||||
+ dialog --backtitle "$BGTITLE" --msgbox "Could not automatically upload output to http://www.pastebin.ca.\nPossible reasons are:\n\n 1. Couldn't find 'wget' in your PATH\n 2. Your version of wget is less than 1.8.2\n\nPlease manually upload $NFILE to http://www.pastebin.ca/upload.php and submit your post." 25 100
|
||||
+ fi
|
||||
+ fi
|
||||
+fi
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index a4d2db338810..3c7032b0d346 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -360,4 +360,4 @@ AC_OUTPUT(Makefile alsactl/Makefile alsactl/init/Makefile \
|
||||
utils/alsa-utils.spec seq/Makefile seq/aconnect/Makefile \
|
||||
seq/aplaymidi/Makefile seq/aseqdump/Makefile seq/aseqnet/Makefile \
|
||||
speaker-test/Makefile speaker-test/samples/Makefile \
|
||||
- alsaloop/Makefile)
|
||||
+ alsaloop/Makefile alsa-info/Makefile)
|
||||
--
|
||||
2.0.4
|
||||
|
@ -1,25 +0,0 @@
|
||||
From 5e5fe9e573efe211dcc3ca9a5bb520bcf00f7950 Mon Sep 17 00:00:00 2001
|
||||
From: Takashi Iwai <tiwai@suse.de>
|
||||
Date: Tue, 12 Aug 2014 16:19:06 +0200
|
||||
Subject: [PATCH] Add missing alsa-info entry to the root Makefile.am
|
||||
|
||||
Signed-off-by: Takashi Iwai <tiwai@suse.de>
|
||||
---
|
||||
Makefile.am | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/Makefile.am b/Makefile.am
|
||||
index f25eee2e38ff..248eb11cb53a 100644
|
||||
--- a/Makefile.am
|
||||
+++ b/Makefile.am
|
||||
@@ -1,6 +1,6 @@
|
||||
AM_CPPFLAGS=-I$(top_srcdir)/include
|
||||
|
||||
-SUBDIRS = include alsactl alsaucm utils m4 po
|
||||
+SUBDIRS = include alsactl alsaucm utils m4 po alsa-info
|
||||
if ALSAMIXER
|
||||
SUBDIRS += alsamixer
|
||||
endif
|
||||
--
|
||||
2.0.4
|
||||
|
@ -1,32 +0,0 @@
|
||||
From 4f569affc420579a1a6e44cf51d7a1e64d6cd8d3 Mon Sep 17 00:00:00 2001
|
||||
From: David Henningsson <david.henningsson@canonical.com>
|
||||
Date: Fri, 22 Aug 2014 10:31:40 +0200
|
||||
Subject: [PATCH] alsa-info: Make sure all full script is run even with
|
||||
"output" option
|
||||
|
||||
For some reason, when the --output option is used, less information
|
||||
is included compared to when no options are used. This is unexpected.
|
||||
|
||||
Fix this by running "withall" also when the output option is used.
|
||||
|
||||
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
|
||||
Signed-off-by: Takashi Iwai <tiwai@suse.de>
|
||||
---
|
||||
alsa-info/alsa-info.sh | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/alsa-info/alsa-info.sh b/alsa-info/alsa-info.sh
|
||||
index 859d7bca6b1c..47157f06b159 100755
|
||||
--- a/alsa-info/alsa-info.sh
|
||||
+++ b/alsa-info/alsa-info.sh
|
||||
@@ -661,6 +661,7 @@ if [ -n "$1" ]; then
|
||||
shift
|
||||
NFILE="$1"
|
||||
KEEP_OUTPUT="yes"
|
||||
+ withall
|
||||
;;
|
||||
--debug)
|
||||
echo "Debugging enabled. $FILE and $TEMPDIR will not be deleted"
|
||||
--
|
||||
2.1.0
|
||||
|
@ -1,130 +0,0 @@
|
||||
From 808af5fdb00be048b485c3ea3f5a5081b99dae30 Mon Sep 17 00:00:00 2001
|
||||
From: David Henningsson <david.henningsson@canonical.com>
|
||||
Date: Fri, 22 Aug 2014 10:31:41 +0200
|
||||
Subject: [PATCH] alsa-info: Refactor "withall" logic
|
||||
|
||||
Previously, using --output, --no-upload, --upload and --pastebin
|
||||
switches implied the withall switch.
|
||||
|
||||
A more intuitive logic would be that --with-all is disabled if you
|
||||
use another --with* switch, such as --withdmesg, and only then.
|
||||
|
||||
Also update script version to reflect the behaviour change.
|
||||
|
||||
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
|
||||
Signed-off-by: Takashi Iwai <tiwai@suse.de>
|
||||
---
|
||||
alsa-info/alsa-info.sh | 23 +++++++++++++++--------
|
||||
1 file changed, 15 insertions(+), 8 deletions(-)
|
||||
|
||||
diff --git a/alsa-info/alsa-info.sh b/alsa-info/alsa-info.sh
|
||||
index 47157f06b159..acd849588141 100755
|
||||
--- a/alsa-info/alsa-info.sh
|
||||
+++ b/alsa-info/alsa-info.sh
|
||||
@@ -1,6 +1,6 @@
|
||||
#!/bin/bash
|
||||
|
||||
-SCRIPT_VERSION=0.4.63
|
||||
+SCRIPT_VERSION=0.4.64
|
||||
CHANGELOG="http://www.alsa-project.org/alsa-info.sh.changelog"
|
||||
|
||||
#################################################################################
|
||||
@@ -260,6 +260,7 @@ withall() {
|
||||
withlsmod
|
||||
withsysfs
|
||||
withdmesg
|
||||
+ WITHALL="no"
|
||||
}
|
||||
|
||||
get_alsa_library_version() {
|
||||
@@ -629,7 +630,6 @@ fi
|
||||
#If no command line options are specified, then run as though --with-all was specified
|
||||
if [ -z "$1" ]; then
|
||||
update
|
||||
- withall
|
||||
pbcheck
|
||||
fi
|
||||
|
||||
@@ -642,7 +642,6 @@ if [ -n "$1" ]; then
|
||||
case "$1" in
|
||||
--pastebin)
|
||||
update
|
||||
- withall
|
||||
pbcheck
|
||||
;;
|
||||
--update)
|
||||
@@ -651,43 +650,45 @@ if [ -n "$1" ]; then
|
||||
;;
|
||||
--upload)
|
||||
UPLOAD="yes"
|
||||
- withall
|
||||
;;
|
||||
--no-upload)
|
||||
UPLOAD="no"
|
||||
- withall
|
||||
;;
|
||||
--output)
|
||||
shift
|
||||
NFILE="$1"
|
||||
KEEP_OUTPUT="yes"
|
||||
- withall
|
||||
;;
|
||||
--debug)
|
||||
echo "Debugging enabled. $FILE and $TEMPDIR will not be deleted"
|
||||
KEEP_FILES="yes"
|
||||
echo ""
|
||||
- withall
|
||||
;;
|
||||
--with-all)
|
||||
withall
|
||||
;;
|
||||
--with-aplay)
|
||||
withaplay
|
||||
+ WITHALL="no"
|
||||
;;
|
||||
--with-amixer)
|
||||
withamixer
|
||||
+ WITHALL="no"
|
||||
;;
|
||||
--with-alsactl)
|
||||
withalsactl
|
||||
+ WITHALL="no"
|
||||
;;
|
||||
--with-devices)
|
||||
withdevices
|
||||
+ WITHALL="no"
|
||||
;;
|
||||
--with-dmesg)
|
||||
withdmesg
|
||||
+ WITHALL="no"
|
||||
;;
|
||||
--with-configs)
|
||||
+ WITHALL="no"
|
||||
if [[ -e $HOME/.asoundrc ]] || [[ -e /etc/asound.conf ]]
|
||||
then
|
||||
echo "!!ALSA configuration files" >> $FILE
|
||||
@@ -717,7 +718,9 @@ if [ -n "$1" ]; then
|
||||
;;
|
||||
--stdout)
|
||||
UPLOAD="no"
|
||||
- withall
|
||||
+ if [ -z "$WITHALL" ]; then
|
||||
+ withall
|
||||
+ fi
|
||||
cat $FILE
|
||||
rm $FILE
|
||||
;;
|
||||
@@ -766,6 +769,10 @@ if [ "$PROCEED" = "no" ]; then
|
||||
exit 1
|
||||
fi
|
||||
|
||||
+if [ -z "$WITHALL" ]; then
|
||||
+ withall
|
||||
+fi
|
||||
+
|
||||
if [ "$UPLOAD" = "ask" ]; then
|
||||
if [ -n "$DIALOG" ]; then
|
||||
dialog --backtitle "$BGTITLE" --title "Information collected" --yes-label " UPLOAD / SHARE " --no-label " SAVE LOCALLY " --defaultno --yesno "\n\nAutomatically upload ALSA information to $WWWSERVICE?" 10 80
|
||||
--
|
||||
2.1.0
|
||||
|
@ -1,30 +0,0 @@
|
||||
From f58ce3619de0612a6402c38f1cd81fb821818b60 Mon Sep 17 00:00:00 2001
|
||||
From: Takashi Iwai <tiwai@suse.de>
|
||||
Date: Tue, 16 Sep 2014 16:36:44 +0200
|
||||
Subject: [PATCH] speaker-test: Add missing draining at the end
|
||||
|
||||
Without the call of snd_pcm_drain() the pending data on the buffer
|
||||
might be discarded, which results in the abort of playback sound in
|
||||
the middle. Let's fix it.
|
||||
|
||||
Reported-and-tested-by: Jarkko Nikula <jarkko.nikula@linux.intel.com>
|
||||
Signed-off-by: Takashi Iwai <tiwai@suse.de>
|
||||
---
|
||||
speaker-test/speaker-test.c | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/speaker-test/speaker-test.c b/speaker-test/speaker-test.c
|
||||
index 61396f296c65..362efa7ffc0d 100644
|
||||
--- a/speaker-test/speaker-test.c
|
||||
+++ b/speaker-test/speaker-test.c
|
||||
@@ -1307,6 +1307,7 @@ int main(int argc, char *argv[]) {
|
||||
}
|
||||
}
|
||||
|
||||
+ snd_pcm_drain(handle);
|
||||
|
||||
free(frames);
|
||||
#ifdef CONFIG_SUPPORT_CHMAP
|
||||
--
|
||||
2.1.2
|
||||
|
@ -1,187 +0,0 @@
|
||||
From 1363f852e92c1c913474fc015f9da12d1e93d750 Mon Sep 17 00:00:00 2001
|
||||
From: Jaroslav Kysela <perex@perex.cz>
|
||||
Date: Wed, 24 Sep 2014 10:35:53 +0200
|
||||
Subject: [PATCH] alsactl: Fix the file locking routines (for the state
|
||||
management)
|
||||
|
||||
---
|
||||
alsactl/alsactl.h | 3 ++-
|
||||
alsactl/lock.c | 41 +++++++++++++++++++++++++++++++----------
|
||||
alsactl/state.c | 22 +++++++++++++---------
|
||||
3 files changed, 46 insertions(+), 20 deletions(-)
|
||||
|
||||
diff --git a/alsactl/alsactl.h b/alsactl/alsactl.h
|
||||
index 76e8c36100f9..bd9bf23e74b3 100644
|
||||
--- a/alsactl/alsactl.h
|
||||
+++ b/alsactl/alsactl.h
|
||||
@@ -25,7 +25,8 @@ void dbg_(const char *fcn, long line, const char *fmt, ...);
|
||||
#endif
|
||||
|
||||
int init(const char *file, const char *cardname);
|
||||
-int state_lock(const char *file, int lock, int timeout);
|
||||
+int state_lock(const char *file, int timeout);
|
||||
+int state_unlock(int fd, const char *file);
|
||||
int save_state(const char *file, const char *cardname);
|
||||
int load_state(const char *file, const char *initfile, const char *cardname,
|
||||
int do_init);
|
||||
diff --git a/alsactl/lock.c b/alsactl/lock.c
|
||||
index 6f85f202576d..9d7efccd7ce6 100644
|
||||
--- a/alsactl/lock.c
|
||||
+++ b/alsactl/lock.c
|
||||
@@ -30,7 +30,7 @@
|
||||
#include <sys/stat.h>
|
||||
#include "alsactl.h"
|
||||
|
||||
-static int state_lock_(const char *file, int lock, int timeout)
|
||||
+static int state_lock_(const char *file, int lock, int timeout, int _fd)
|
||||
{
|
||||
int fd = -1, err = 0;
|
||||
struct flock lck;
|
||||
@@ -50,9 +50,14 @@ static int state_lock_(const char *file, int lock, int timeout)
|
||||
snprintf(lcktxt, sizeof(lcktxt), "%10li\n", (long)getpid());
|
||||
} else {
|
||||
snprintf(lcktxt, sizeof(lcktxt), "%10s\n", "");
|
||||
+ fd = _fd;
|
||||
}
|
||||
while (fd < 0 && timeout-- > 0) {
|
||||
fd = open(nfile, O_RDWR);
|
||||
+ if (!lock && fd < 0) {
|
||||
+ err = -EIO;
|
||||
+ goto out;
|
||||
+ }
|
||||
if (fd < 0) {
|
||||
fd = open(nfile, O_RDWR|O_CREAT|O_EXCL, 0644);
|
||||
if (fd < 0) {
|
||||
@@ -74,12 +79,12 @@ static int state_lock_(const char *file, int lock, int timeout)
|
||||
err = -errno;
|
||||
goto out;
|
||||
}
|
||||
- if (st.st_size != 11) {
|
||||
+ if (st.st_size != 11 || !lock) {
|
||||
if (write(fd, lcktxt, 11) != 11) {
|
||||
err = -EIO;
|
||||
goto out;
|
||||
}
|
||||
- if (lseek(fd, 0, SEEK_SET)) {
|
||||
+ if (lock && lseek(fd, 0, SEEK_SET)) {
|
||||
err = -errno;
|
||||
goto out;
|
||||
}
|
||||
@@ -96,21 +101,37 @@ static int state_lock_(const char *file, int lock, int timeout)
|
||||
err = -EBUSY;
|
||||
goto out;
|
||||
}
|
||||
- if (write(fd, lcktxt, 11) != 11) {
|
||||
- err = -EIO;
|
||||
- goto out;
|
||||
+ if (lock) {
|
||||
+ if (write(fd, lcktxt, 11) != 11) {
|
||||
+ err = -EIO;
|
||||
+ goto out;
|
||||
+ }
|
||||
+ return fd;
|
||||
}
|
||||
+ err = 0;
|
||||
+
|
||||
out:
|
||||
+ if (fd >= 0)
|
||||
+ close(fd);
|
||||
+ return err;
|
||||
+}
|
||||
+
|
||||
+int state_lock(const char *file, int timeout)
|
||||
+{
|
||||
+ int err;
|
||||
+
|
||||
+ err = state_lock_(file, 1, timeout, -1);
|
||||
+ if (err < 0)
|
||||
+ error("file %s lock error: %s", file, strerror(-err));
|
||||
return err;
|
||||
}
|
||||
|
||||
-int state_lock(const char *file, int lock, int timeout)
|
||||
+int state_unlock(int _fd, const char *file)
|
||||
{
|
||||
int err;
|
||||
|
||||
- err = state_lock_(file, lock, timeout);
|
||||
+ err = state_lock_(file, 0, 10, _fd);
|
||||
if (err < 0)
|
||||
- error("file %s %slock error: %s", file,
|
||||
- lock ? "" : "un", strerror(-err));
|
||||
+ error("file %s unlock error: %s", file, strerror(-err));
|
||||
return err;
|
||||
}
|
||||
diff --git a/alsactl/state.c b/alsactl/state.c
|
||||
index e0c6f2e02e9b..0c897034057c 100644
|
||||
--- a/alsactl/state.c
|
||||
+++ b/alsactl/state.c
|
||||
@@ -1544,6 +1544,7 @@ int save_state(const char *file, const char *cardname)
|
||||
snd_output_t *out;
|
||||
int stdio;
|
||||
char *nfile = NULL;
|
||||
+ int lock_fd = -EINVAL;
|
||||
|
||||
err = snd_config_top(&config);
|
||||
if (err < 0) {
|
||||
@@ -1555,12 +1556,16 @@ int save_state(const char *file, const char *cardname)
|
||||
nfile = malloc(strlen(file) + 5);
|
||||
if (nfile == NULL) {
|
||||
error("No enough memory...");
|
||||
+ err = -ENOMEM;
|
||||
goto out;
|
||||
}
|
||||
strcpy(nfile, file);
|
||||
strcat(nfile, ".new");
|
||||
- if (state_lock(file, 1, 10) != 0)
|
||||
+ lock_fd = state_lock(file, 10);
|
||||
+ if (lock_fd < 0) {
|
||||
+ err = lock_fd;
|
||||
goto out;
|
||||
+ }
|
||||
}
|
||||
if (!stdio && (err = snd_input_stdio_open(&in, file, "r")) >= 0) {
|
||||
err = snd_config_load(config, in);
|
||||
@@ -1632,8 +1637,8 @@ int save_state(const char *file, const char *cardname)
|
||||
error("rename failed: %s (%s)", strerror(-err), file);
|
||||
}
|
||||
out:
|
||||
- if (!stdio)
|
||||
- state_lock(file, 0, 10);
|
||||
+ if (!stdio && lock_fd >= 0)
|
||||
+ state_unlock(lock_fd, file);
|
||||
free(nfile);
|
||||
snd_config_delete(config);
|
||||
snd_config_update_free_global();
|
||||
@@ -1646,7 +1651,7 @@ int load_state(const char *file, const char *initfile, const char *cardname,
|
||||
int err, finalerr = 0;
|
||||
snd_config_t *config;
|
||||
snd_input_t *in;
|
||||
- int stdio, locked = 0;
|
||||
+ int stdio, lock_fd = -EINVAL;
|
||||
|
||||
err = snd_config_top(&config);
|
||||
if (err < 0) {
|
||||
@@ -1657,15 +1662,14 @@ int load_state(const char *file, const char *initfile, const char *cardname,
|
||||
if (stdio) {
|
||||
err = snd_input_stdio_attach(&in, stdin, 0);
|
||||
} else {
|
||||
- err = state_lock(file, 1, 10);
|
||||
- locked = err >= 0;
|
||||
- err = err >= 0 ? snd_input_stdio_open(&in, file, "r") : err;
|
||||
+ lock_fd = state_lock(file, 10);
|
||||
+ err = lock_fd >= 0 ? snd_input_stdio_open(&in, file, "r") : lock_fd;
|
||||
}
|
||||
if (err >= 0) {
|
||||
err = snd_config_load(config, in);
|
||||
snd_input_close(in);
|
||||
- if (locked)
|
||||
- state_lock(file, 0, 10);
|
||||
+ if (lock_fd >= 0)
|
||||
+ state_unlock(lock_fd, file);
|
||||
if (err < 0) {
|
||||
error("snd_config_load error: %s", snd_strerror(err));
|
||||
goto out;
|
||||
--
|
||||
2.1.2
|
||||
|
@ -1,24 +0,0 @@
|
||||
From 74e5d57c999f8afed4f87046dcac84f6709b9196 Mon Sep 17 00:00:00 2001
|
||||
From: Jaroslav Kysela <perex@perex.cz>
|
||||
Date: Wed, 24 Sep 2014 10:46:02 +0200
|
||||
Subject: [PATCH] alsactl: aded missing monitor() prototype
|
||||
|
||||
---
|
||||
alsactl/alsactl.h | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/alsactl/alsactl.h b/alsactl/alsactl.h
|
||||
index bd9bf23e74b3..4f969ec2a4bc 100644
|
||||
--- a/alsactl/alsactl.h
|
||||
+++ b/alsactl/alsactl.h
|
||||
@@ -31,6 +31,7 @@ int save_state(const char *file, const char *cardname);
|
||||
int load_state(const char *file, const char *initfile, const char *cardname,
|
||||
int do_init);
|
||||
int power(const char *argv[], int argc);
|
||||
+int monitor(const char *name);
|
||||
int state_daemon(const char *file, const char *cardname, int period,
|
||||
const char *pidfile);
|
||||
int state_daemon_kill(const char *pidfile, const char *cmd);
|
||||
--
|
||||
2.1.2
|
||||
|
@ -1,25 +0,0 @@
|
||||
From da7a2f91de1c2089bf2b4ba247807cb716f30424 Mon Sep 17 00:00:00 2001
|
||||
From: Jaroslav Kysela <perex@perex.cz>
|
||||
Date: Wed, 24 Sep 2014 10:47:48 +0200
|
||||
Subject: [PATCH] speaker-text: fix simple signess assignment warning
|
||||
|
||||
---
|
||||
speaker-test/speaker-test.c | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/speaker-test/speaker-test.c b/speaker-test/speaker-test.c
|
||||
index 362efa7ffc0d..ccf2671725a3 100644
|
||||
--- a/speaker-test/speaker-test.c
|
||||
+++ b/speaker-test/speaker-test.c
|
||||
@@ -113,7 +113,7 @@ static snd_pcm_t *pcm_handle = NULL;
|
||||
#ifdef CONFIG_SUPPORT_CHMAP
|
||||
static snd_pcm_chmap_t *channel_map;
|
||||
static int channel_map_set;
|
||||
-static unsigned int *ordered_channels;
|
||||
+static int *ordered_channels;
|
||||
#endif
|
||||
|
||||
static const char *const channel_name[MAX_CHANNELS] = {
|
||||
--
|
||||
2.1.2
|
||||
|
@ -1,35 +0,0 @@
|
||||
From 17d4a5dd35e3e72a194ca295da98e62060a180a8 Mon Sep 17 00:00:00 2001
|
||||
From: Jaroslav Kysela <perex@perex.cz>
|
||||
Date: Wed, 24 Sep 2014 10:50:54 +0200
|
||||
Subject: [PATCH] monitor: fix clang warning - Declared variable-length array
|
||||
(VLA) has zero size
|
||||
|
||||
---
|
||||
alsactl/monitor.c | 4 ++--
|
||||
1 file changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/alsactl/monitor.c b/alsactl/monitor.c
|
||||
index 536176d0e7cb..29379ad061d0 100644
|
||||
--- a/alsactl/monitor.c
|
||||
+++ b/alsactl/monitor.c
|
||||
@@ -91,7 +91,7 @@ int monitor(const char *name)
|
||||
snd_ctl_t *ctls[MAX_CARDS];
|
||||
int ncards = 0;
|
||||
int show_cards;
|
||||
- int i, err;
|
||||
+ int i, err = 0;
|
||||
|
||||
if (!name) {
|
||||
int card = -1;
|
||||
@@ -117,7 +117,7 @@ int monitor(const char *name)
|
||||
show_cards = 0;
|
||||
}
|
||||
|
||||
- for (;;) {
|
||||
+ for (;ncards > 0;) {
|
||||
struct pollfd fds[ncards];
|
||||
|
||||
for (i = 0; i < ncards; i++)
|
||||
--
|
||||
2.1.2
|
||||
|
@ -1,38 +0,0 @@
|
||||
From 89a4f490bd974e454d82942100f241bb1a2270f3 Mon Sep 17 00:00:00 2001
|
||||
From: Jaroslav Kysela <perex@perex.cz>
|
||||
Date: Wed, 24 Sep 2014 10:52:17 +0200
|
||||
Subject: [PATCH] =?UTF-8?q?alsactl:=20coverity=20-=20missing=5Fva=5Fend=20?=
|
||||
=?UTF-8?q?=E2=80=93=20va=5Fend=20was=20not=20called=20for=20"ap"?=
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
---
|
||||
alsactl/utils.c | 4 ++--
|
||||
1 file changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/alsactl/utils.c b/alsactl/utils.c
|
||||
index b5d183cb437c..304df7cb504a 100644
|
||||
--- a/alsactl/utils.c
|
||||
+++ b/alsactl/utils.c
|
||||
@@ -157,8 +157,8 @@ void cerror_(const char *fcn, long line, int cond, const char *fmt, ...)
|
||||
fprintf(stderr, "%s: %s:%ld: ", command, fcn, line);
|
||||
vfprintf(stderr, fmt, ap);
|
||||
putc('\n', stderr);
|
||||
- va_end(ap);
|
||||
}
|
||||
+ va_end(ap);
|
||||
}
|
||||
|
||||
void dbg_(const char *fcn, long line, const char *fmt, ...)
|
||||
@@ -174,6 +174,6 @@ void dbg_(const char *fcn, long line, const char *fmt, ...)
|
||||
fprintf(stderr, "%s: %s:%ld: ", command, fcn, line);
|
||||
vfprintf(stderr, fmt, ap);
|
||||
putc('\n', stderr);
|
||||
- va_end(ap);
|
||||
}
|
||||
+ va_end(ap);
|
||||
}
|
||||
--
|
||||
2.1.2
|
||||
|
@ -1,43 +0,0 @@
|
||||
From 8f361d83cfcb39887f5fc591633e68d9448e3425 Mon Sep 17 00:00:00 2001
|
||||
From: Jaroslav Kysela <perex@perex.cz>
|
||||
Date: Wed, 1 Oct 2014 15:43:57 +0200
|
||||
Subject: [PATCH] Revert "aplay: fix pcm_read() return value"
|
||||
|
||||
This reverts commit 8aa13eec80eac312e4b99423909387660fb99b8f.
|
||||
|
||||
The semantics for pcm_read() and pcm_readv() was changed, but the
|
||||
callers expect the exact frame count as requested. It's possible
|
||||
to fix callers, but the fix is more complicated than to revert the
|
||||
change. Note that '-d' processing was broken in some cases.
|
||||
|
||||
Note: The reverted commit allows that the return value might be
|
||||
greater than requested (see the first condition in read routines).
|
||||
---
|
||||
aplay/aplay.c | 4 ++--
|
||||
1 file changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/aplay/aplay.c b/aplay/aplay.c
|
||||
index 30d3f319d97a..e58e1bcbdd7e 100644
|
||||
--- a/aplay/aplay.c
|
||||
+++ b/aplay/aplay.c
|
||||
@@ -2039,7 +2039,7 @@ static ssize_t pcm_read(u_char *data, size_t rcount)
|
||||
data += r * bits_per_frame / 8;
|
||||
}
|
||||
}
|
||||
- return result;
|
||||
+ return rcount;
|
||||
}
|
||||
|
||||
static ssize_t pcm_readv(u_char **data, unsigned int channels, size_t rcount)
|
||||
@@ -2084,7 +2084,7 @@ static ssize_t pcm_readv(u_char **data, unsigned int channels, size_t rcount)
|
||||
count -= r;
|
||||
}
|
||||
}
|
||||
- return result;
|
||||
+ return rcount;
|
||||
}
|
||||
|
||||
/*
|
||||
--
|
||||
2.1.2
|
||||
|
@ -1,29 +0,0 @@
|
||||
From 45a334e71ca9b4402fb731a934f7455cec5b0121 Mon Sep 17 00:00:00 2001
|
||||
From: Takashi Iwai <tiwai@suse.de>
|
||||
Date: Sun, 23 Nov 2014 09:40:07 +0100
|
||||
Subject: [PATCH 14/15] amixer: Make "dB" case-insensitive in set commands
|
||||
|
||||
We don't have to be necessarily too strict about case-sensitivity of
|
||||
"dB" suffix used in set commands.
|
||||
|
||||
Signed-off-by: Takashi Iwai <tiwai@suse.de>
|
||||
---
|
||||
amixer/amixer.c | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/amixer/amixer.c b/amixer/amixer.c
|
||||
index cf82892bfa2f..6a2fdb96c62f 100644
|
||||
--- a/amixer/amixer.c
|
||||
+++ b/amixer/amixer.c
|
||||
@@ -346,7 +346,7 @@ static int set_volume_simple(snd_mixer_elem_t *elem,
|
||||
if (*p == '%') {
|
||||
percent = 1;
|
||||
p++;
|
||||
- } else if (p[0] == 'd' && p[1] == 'B') {
|
||||
+ } else if (toupper(p[0]) == 'D' && toupper(p[1]) == 'B') {
|
||||
vol_type = VOL_DB;
|
||||
p += 2;
|
||||
scale = 100;
|
||||
--
|
||||
2.2.0
|
||||
|
@ -1,67 +0,0 @@
|
||||
From 088593c03980209c44a9e9cde19723361d341c0a Mon Sep 17 00:00:00 2001
|
||||
From: Takashi Iwai <tiwai@suse.de>
|
||||
Date: Sun, 23 Nov 2014 10:04:24 +0100
|
||||
Subject: [PATCH 15/15] amixer: Parse the value more strictly
|
||||
|
||||
So far amixer allows some unexpected suffix and assumes as a raw
|
||||
absolute value without returning an error. This is rather dangerous,
|
||||
e.g. user might not notice that a completely wrong value was set when
|
||||
the command line included a typo.
|
||||
|
||||
This patch makes the parser a bit more strict: it doesn't allow any
|
||||
longer invalid suffixes, instead either returns an error or skips the
|
||||
invalid value, depending on the operation mode.
|
||||
|
||||
Signed-off-by: Takashi Iwai <tiwai@suse.de>
|
||||
---
|
||||
amixer/amixer.c | 13 +++++++++++--
|
||||
1 file changed, 11 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/amixer/amixer.c b/amixer/amixer.c
|
||||
index 6a2fdb96c62f..ed60e7c3a960 100644
|
||||
--- a/amixer/amixer.c
|
||||
+++ b/amixer/amixer.c
|
||||
@@ -325,7 +325,7 @@ static int set_volume_simple(snd_mixer_elem_t *elem,
|
||||
long val, orig, pmin, pmax;
|
||||
char *p = *ptr, *s;
|
||||
int invalid = 0, percent = 0, err = 0;
|
||||
- int vol_type = std_vol_type;
|
||||
+ int vol_type;
|
||||
double scale = 1.0;
|
||||
int correct = 0;
|
||||
|
||||
@@ -344,14 +344,19 @@ static int set_volume_simple(snd_mixer_elem_t *elem,
|
||||
strtol(p, &p, 10);
|
||||
}
|
||||
if (*p == '%') {
|
||||
+ vol_type = std_vol_type;
|
||||
percent = 1;
|
||||
p++;
|
||||
} else if (toupper(p[0]) == 'D' && toupper(p[1]) == 'B') {
|
||||
vol_type = VOL_DB;
|
||||
p += 2;
|
||||
scale = 100;
|
||||
- } else
|
||||
+ } else {
|
||||
vol_type = VOL_RAW;
|
||||
+ }
|
||||
+
|
||||
+ if (*p && !strchr(",:+-", *p))
|
||||
+ invalid = 1;
|
||||
|
||||
val = (long)(strtod(s, NULL) * scale);
|
||||
if (vol_ops[dir].v[vol_type].get_range(elem, &pmin, &pmax) < 0)
|
||||
@@ -372,6 +377,10 @@ static int set_volume_simple(snd_mixer_elem_t *elem,
|
||||
}
|
||||
p++;
|
||||
}
|
||||
+
|
||||
+ if (*p && !strchr(",:", *p))
|
||||
+ invalid = 1;
|
||||
+
|
||||
if (! invalid) {
|
||||
val = check_range(val, pmin, pmax);
|
||||
err = vol_ops[dir].v[vol_type].set(elem, chn, val, correct);
|
||||
--
|
||||
2.2.0
|
||||
|
@ -1,25 +0,0 @@
|
||||
From 55d41b7fe364b55851a6038285affe9a32b8b701 Mon Sep 17 00:00:00 2001
|
||||
From: Jaroslav Kysela <perex@perex.cz>
|
||||
Date: Wed, 24 Dec 2014 20:15:26 +0100
|
||||
Subject: [PATCH] alsactl: add missing state_unlock() call
|
||||
|
||||
---
|
||||
alsactl/state.c | 2 ++
|
||||
1 file changed, 2 insertions(+)
|
||||
|
||||
diff --git a/alsactl/state.c b/alsactl/state.c
|
||||
index 0c897034057c..3908ec49b823 100644
|
||||
--- a/alsactl/state.c
|
||||
+++ b/alsactl/state.c
|
||||
@@ -1678,6 +1678,8 @@ int load_state(const char *file, const char *initfile, const char *cardname,
|
||||
int card, first = 1;
|
||||
char cardname1[16];
|
||||
|
||||
+ if (lock_fd >= 0)
|
||||
+ state_unlock(lock_fd, file);
|
||||
error("Cannot open %s for reading: %s", file, snd_strerror(err));
|
||||
finalerr = err;
|
||||
if (cardname) {
|
||||
--
|
||||
2.2.2
|
||||
|
@ -1,30 +0,0 @@
|
||||
From d522b45508a033e1bfcf40769168deb48d5c878c Mon Sep 17 00:00:00 2001
|
||||
From: David Henningsson <david.henningsson@canonical.com>
|
||||
Date: Mon, 12 Jan 2015 16:48:37 +0100
|
||||
Subject: [PATCH] alsactl/init: Change the "basic rules" description
|
||||
|
||||
We now enable more outputs than just the main speaker, so update
|
||||
the basic rules to reflect the actual situation.
|
||||
|
||||
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
|
||||
Signed-off-by: Takashi Iwai <tiwai@suse.de>
|
||||
---
|
||||
alsactl/init/default | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/alsactl/init/default b/alsactl/init/default
|
||||
index 5fb01136cdc5..64f933f1f597 100644
|
||||
--- a/alsactl/init/default
|
||||
+++ b/alsactl/init/default
|
||||
@@ -3,7 +3,7 @@
|
||||
#
|
||||
# Basic rules are:
|
||||
# - keep volumes at minimal level, but sound should be hearable
|
||||
-# - enable just main speakers for playback and main microphone for recording
|
||||
+# - enable standard outputs for playback and main microphone for recording
|
||||
#
|
||||
|
||||
# **************************************************************************
|
||||
--
|
||||
2.2.2
|
||||
|
@ -1,35 +0,0 @@
|
||||
From e1745a69fecb191b3575e39b1ec731756381fb5c Mon Sep 17 00:00:00 2001
|
||||
From: David Henningsson <david.henningsson@canonical.com>
|
||||
Date: Mon, 12 Jan 2015 16:48:38 +0100
|
||||
Subject: [PATCH] alsactl/init: Add "Line Out" to list of outputs to initialize
|
||||
|
||||
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
|
||||
Signed-off-by: Takashi Iwai <tiwai@suse.de>
|
||||
---
|
||||
alsactl/init/default | 10 ++++++++++
|
||||
1 file changed, 10 insertions(+)
|
||||
|
||||
diff --git a/alsactl/init/default b/alsactl/init/default
|
||||
index 64f933f1f597..1c84f3e859e7 100644
|
||||
--- a/alsactl/init/default
|
||||
+++ b/alsactl/init/default
|
||||
@@ -43,6 +43,16 @@ CTL{name}="Master Digital Playback Switch",CTL{do_search}=="1", \
|
||||
CTL{values}="on"
|
||||
|
||||
CTL{reset}="mixer"
|
||||
+CTL{name}="Line Out Playback Volume",PROGRAM!="__ctl_search",GOTO=""
|
||||
+# if master volume control is present, turn line out volume to max
|
||||
+ENV{has_pmaster_vol}=="true",CTL{write}=="0dB",GOTO=""
|
||||
+ENV{has_pmaster_vol}=="true",CTL{write}=="100%",GOTO=""
|
||||
+CTL{write}!="$env{pvolume}",CTL{values}="$env{ppercent}"
|
||||
+LABEL=""
|
||||
+CTL{name}="Line Out Playback Switch",CTL{do_search}=="1", \
|
||||
+ CTL{values}="on"
|
||||
+
|
||||
+CTL{reset}="mixer"
|
||||
CTL{name}="Front Playback Volume",PROGRAM!="__ctl_search",GOTO=""
|
||||
# if master volume control is present, turn front volume to max
|
||||
ENV{has_pmaster_vol}=="true",CTL{write}=="0dB",GOTO=""
|
||||
--
|
||||
2.2.2
|
||||
|
@ -1,61 +0,0 @@
|
||||
From 554706585c6d020e5cbb10be1ccb66164eed2c2f Mon Sep 17 00:00:00 2001
|
||||
From: Matthieu Crapet <Matthieu.Crapet@ingenico.com>
|
||||
Date: Wed, 14 Jan 2015 15:44:19 +0100
|
||||
Subject: [PATCH] configure: allow contitional compilation of alsaucm
|
||||
|
||||
If alsa-lib have been compiled with --disable-ucm, alsaucm can't be built.
|
||||
Detection is dynamic, no configure command line option is available for now.
|
||||
|
||||
Signed-off-by: Matthieu Crapet <Matthieu.Crapet@ingenico.com>
|
||||
Signed-off-by: Takashi Iwai <tiwai@suse.de>
|
||||
---
|
||||
Makefile.am | 5 ++++-
|
||||
configure.ac | 3 +++
|
||||
2 files changed, 7 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/Makefile.am b/Makefile.am
|
||||
index 248eb11cb53a..5bbe588a8d84 100644
|
||||
--- a/Makefile.am
|
||||
+++ b/Makefile.am
|
||||
@@ -1,6 +1,6 @@
|
||||
AM_CPPFLAGS=-I$(top_srcdir)/include
|
||||
|
||||
-SUBDIRS = include alsactl alsaucm utils m4 po alsa-info
|
||||
+SUBDIRS = include alsactl utils m4 po alsa-info
|
||||
if ALSAMIXER
|
||||
SUBDIRS += alsamixer
|
||||
endif
|
||||
@@ -22,6 +22,9 @@ endif
|
||||
if HAVE_SEQ
|
||||
SUBDIRS += seq
|
||||
endif
|
||||
+if HAVE_UCM
|
||||
+SUBDIRS += alsaucm
|
||||
+endif
|
||||
|
||||
EXTRA_DIST= TODO gitcompile
|
||||
AUTOMAKE_OPTIONS=foreign
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index 3c7032b0d346..d953e5ccb73c 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -48,6 +48,8 @@ AC_CHECK_HEADERS([alsa/rawmidi.h], [have_rawmidi="yes"], [have_rawmidi="no"],
|
||||
[#include <alsa/asoundlib.h>])
|
||||
AC_CHECK_HEADERS([alsa/seq.h], [have_seq="yes"], [have_seq="no"],
|
||||
[#include <alsa/asoundlib.h>])
|
||||
+AC_CHECK_HEADERS([alsa/use-case.h], [have_ucm="yes"], [have_ucm="no"],
|
||||
+ [#include <alsa/asoundlib.h>])
|
||||
AC_CHECK_HEADERS([samplerate.h], [have_samplerate="yes"], [have_samplerate="no"],
|
||||
[#include <samplerate.h>])
|
||||
|
||||
@@ -55,6 +57,7 @@ AM_CONDITIONAL(HAVE_PCM, test "$have_pcm" = "yes")
|
||||
AM_CONDITIONAL(HAVE_MIXER, test "$have_mixer" = "yes")
|
||||
AM_CONDITIONAL(HAVE_RAWMIDI, test "$have_rawmidi" = "yes")
|
||||
AM_CONDITIONAL(HAVE_SEQ, test "$have_seq" = "yes")
|
||||
+AM_CONDITIONAL(HAVE_UCM, test "$have_ucm" = "yes")
|
||||
AM_CONDITIONAL(HAVE_SAMPLERATE, test "$have_samplerate" = "yes")
|
||||
|
||||
dnl Check for librt
|
||||
--
|
||||
2.2.2
|
||||
|
@ -1,3 +0,0 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:f3ff4c89b0125a7797b1b13cd094cc92276e655458274967386e812d03642acc
|
||||
size 1146887
|
3
alsa-utils-1.0.29.tar.bz2
Normal file
3
alsa-utils-1.0.29.tar.bz2
Normal file
@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:5160058f3e14483ced5de919dd473f93932059454530a9b7ef97dcabd6833e9b
|
||||
size 1154497
|
@ -1,3 +1,29 @@
|
||||
-------------------------------------------------------------------
|
||||
Thu Feb 26 17:26:56 CET 2015 - tiwai@suse.de
|
||||
|
||||
- Update to alsa-utils 1.0.29:
|
||||
just a version bump including previous fixes
|
||||
- Drop obsoleted patches:
|
||||
0001-alsactl-save-state-do-not-call-rename-for-stdio.patch
|
||||
0002-alsamixer-include-missing-mixer_controls.h.patch
|
||||
0003-Add-alsa-info.sh-to-alsa-utils-repo.patch
|
||||
0004-Add-missing-alsa-info-entry-to-the-root-Makefile.am.patch
|
||||
0005-alsa-info-Make-sure-all-full-script-is-run-even-with.patch
|
||||
0006-alsa-info-Refactor-withall-logic.patch
|
||||
0007-speaker-test-Add-missing-draining-at-the-end.patch
|
||||
0008-alsactl-Fix-the-file-locking-routines-for-the-state-.patch
|
||||
0009-alsactl-aded-missing-monitor-prototype.patch
|
||||
0010-speaker-text-fix-simple-signess-assignment-warning.patch
|
||||
0011-monitor-fix-clang-warning-Declared-variable-length-a.patch
|
||||
0012-alsactl-coverity-missing_va_end-va_end-was-not-calle.patch
|
||||
0013-Revert-aplay-fix-pcm_read-return-value.patch
|
||||
0014-amixer-Make-dB-case-insensitive-in-set-commands.patch
|
||||
0015-amixer-Parse-the-value-more-strictly.patch
|
||||
0016-alsactl-add-missing-state_unlock-call.patch
|
||||
0017-alsactl-init-Change-the-basic-rules-description.patch
|
||||
0018-alsactl-init-Add-Line-Out-to-list-of-outputs-to-init.patch
|
||||
0019-configure-allow-contitional-compilation-of-alsaucm.patch
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon Jan 26 15:52:24 CET 2015 - tiwai@suse.de
|
||||
|
||||
|
@ -16,7 +16,7 @@
|
||||
#
|
||||
|
||||
|
||||
%define package_version 1.0.28
|
||||
%define package_version 1.0.29
|
||||
#
|
||||
%if 0%{?suse_version} > 1130
|
||||
%define use_systemd 1
|
||||
@ -35,7 +35,7 @@ BuildRequires: systemd
|
||||
%define _udevdir /lib/udev
|
||||
%endif
|
||||
Name: alsa-utils
|
||||
Version: 1.0.28
|
||||
Version: 1.0.29
|
||||
Release: 0
|
||||
Summary: Advanced Linux Sound Architecture Utilities
|
||||
License: GPL-2.0+
|
||||
@ -45,25 +45,6 @@ Source: ftp://ftp.alsa-project.org/pub/utils/alsa-utils-%{package_versio
|
||||
Source1: 01beep.conf
|
||||
# Patch: alsa-utils-git-fixes.diff
|
||||
# upstream fix patches
|
||||
Patch1: 0001-alsactl-save-state-do-not-call-rename-for-stdio.patch
|
||||
Patch2: 0002-alsamixer-include-missing-mixer_controls.h.patch
|
||||
Patch3: 0003-Add-alsa-info.sh-to-alsa-utils-repo.patch
|
||||
Patch4: 0004-Add-missing-alsa-info-entry-to-the-root-Makefile.am.patch
|
||||
Patch5: 0005-alsa-info-Make-sure-all-full-script-is-run-even-with.patch
|
||||
Patch6: 0006-alsa-info-Refactor-withall-logic.patch
|
||||
Patch7: 0007-speaker-test-Add-missing-draining-at-the-end.patch
|
||||
Patch8: 0008-alsactl-Fix-the-file-locking-routines-for-the-state-.patch
|
||||
Patch9: 0009-alsactl-aded-missing-monitor-prototype.patch
|
||||
Patch10: 0010-speaker-text-fix-simple-signess-assignment-warning.patch
|
||||
Patch11: 0011-monitor-fix-clang-warning-Declared-variable-length-a.patch
|
||||
Patch12: 0012-alsactl-coverity-missing_va_end-va_end-was-not-calle.patch
|
||||
Patch13: 0013-Revert-aplay-fix-pcm_read-return-value.patch
|
||||
Patch14: 0014-amixer-Make-dB-case-insensitive-in-set-commands.patch
|
||||
Patch15: 0015-amixer-Parse-the-value-more-strictly.patch
|
||||
Patch16: 0016-alsactl-add-missing-state_unlock-call.patch
|
||||
Patch17: 0017-alsactl-init-Change-the-basic-rules-description.patch
|
||||
Patch18: 0018-alsactl-init-Add-Line-Out-to-list-of-outputs-to-init.patch
|
||||
Patch19: 0019-configure-allow-contitional-compilation-of-alsaucm.patch
|
||||
#
|
||||
Patch99: alsa-utils-gettext-version-removal.diff
|
||||
BuildRequires: alsa-devel
|
||||
@ -91,25 +72,6 @@ Sound Architecture.
|
||||
sed -i -e's/EXTRA_DIST= config.rpath /EXTRA_DIST=/' Makefile.am
|
||||
# rm -f po/Makefile* po/*.gmo po/*.pot po/*.header po/stamp-*
|
||||
# patch -p1
|
||||
%patch1 -p1
|
||||
%patch2 -p1
|
||||
%patch3 -p1
|
||||
%patch4 -p1
|
||||
%patch5 -p1
|
||||
%patch6 -p1
|
||||
%patch7 -p1
|
||||
%patch8 -p1
|
||||
%patch9 -p1
|
||||
%patch10 -p1
|
||||
%patch11 -p1
|
||||
%patch12 -p1
|
||||
%patch13 -p1
|
||||
%patch14 -p1
|
||||
%patch15 -p1
|
||||
%patch16 -p1
|
||||
%patch17 -p1
|
||||
%patch18 -p1
|
||||
%patch19 -p1
|
||||
#
|
||||
%if 0%{?suse_version} < 1020
|
||||
%patch99 -p1
|
||||
@ -118,9 +80,9 @@ sed -i -e's/EXTRA_DIST= config.rpath /EXTRA_DIST=/' Makefile.am
|
||||
%build
|
||||
export AUTOMAKE_JOBS="%{?_smp_mflags}"
|
||||
%if 0%{?suse_version} < 1020
|
||||
gettextize -f
|
||||
# gettextize -f
|
||||
%endif
|
||||
autoreconf -fi
|
||||
# autoreconf -fi
|
||||
opts=""
|
||||
%if %{use_systemd}
|
||||
opts="$opts --with-systemdsystemunitdir=%{_unitdir}"
|
||||
|
Loading…
Reference in New Issue
Block a user