updated to 1.0.27
This commit is contained in:
parent
1ddee9ccf3
commit
09e283e543
1
.gitignore
vendored
1
.gitignore
vendored
@ -28,3 +28,4 @@ alsa-utils-1.0.23.tar.bz2
|
|||||||
/alsa-utils-1.0.24.1.tar.bz2
|
/alsa-utils-1.0.24.1.tar.bz2
|
||||||
/alsa-utils-1.0.25.tar.bz2
|
/alsa-utils-1.0.25.tar.bz2
|
||||||
/alsa-utils-1.0.26.tar.bz2
|
/alsa-utils-1.0.26.tar.bz2
|
||||||
|
/alsa-utils-1.0.27.tar.bz2
|
||||||
|
29
alsa-info.sh
29
alsa-info.sh
@ -1,6 +1,6 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
SCRIPT_VERSION=0.4.60
|
SCRIPT_VERSION=0.4.61
|
||||||
CHANGELOG="http://www.alsa-project.org/alsa-info.sh.changelog"
|
CHANGELOG="http://www.alsa-project.org/alsa-info.sh.changelog"
|
||||||
|
|
||||||
#################################################################################
|
#################################################################################
|
||||||
@ -111,7 +111,7 @@ cleanup() {
|
|||||||
|
|
||||||
withaplay() {
|
withaplay() {
|
||||||
echo "!!Aplay/Arecord output" >> $FILE
|
echo "!!Aplay/Arecord output" >> $FILE
|
||||||
echo "!!------------" >> $FILE
|
echo "!!--------------------" >> $FILE
|
||||||
echo "" >> $FILE
|
echo "" >> $FILE
|
||||||
echo "APLAY" >> $FILE
|
echo "APLAY" >> $FILE
|
||||||
echo "" >> $FILE
|
echo "" >> $FILE
|
||||||
@ -149,7 +149,7 @@ withamixer() {
|
|||||||
|
|
||||||
withalsactl() {
|
withalsactl() {
|
||||||
echo "!!Alsactl output" >> $FILE
|
echo "!!Alsactl output" >> $FILE
|
||||||
echo "!!-------------" >> $FILE
|
echo "!!--------------" >> $FILE
|
||||||
echo "" >> $FILE
|
echo "" >> $FILE
|
||||||
exe=""
|
exe=""
|
||||||
if [ -x /usr/sbin/alsactl ]; then
|
if [ -x /usr/sbin/alsactl ]; then
|
||||||
@ -244,7 +244,7 @@ withsysfs() {
|
|||||||
|
|
||||||
withdmesg() {
|
withdmesg() {
|
||||||
echo "!!ALSA/HDA dmesg" >> $FILE
|
echo "!!ALSA/HDA dmesg" >> $FILE
|
||||||
echo "!!------------------" >> $FILE
|
echo "!!--------------" >> $FILE
|
||||||
echo "" >> $FILE
|
echo "" >> $FILE
|
||||||
dmesg | grep -C1 -E 'ALSA|HDA|HDMI|sound|hda.codec|hda.intel' >> $FILE
|
dmesg | grep -C1 -E 'ALSA|HDA|HDMI|sound|hda.codec|hda.intel' >> $FILE
|
||||||
echo "" >> $FILE
|
echo "" >> $FILE
|
||||||
@ -416,6 +416,7 @@ ESDINST=$(which esd 2>/dev/null| sed 's|^[^/]*||' 2>/dev/null)
|
|||||||
PAINST=$(which pulseaudio 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)
|
ARTSINST=$(which artsd 2>/dev/null| sed 's|^[^/]*||' 2>/dev/null)
|
||||||
JACKINST=$(which jackd 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)
|
DMIDECODE=$(which dmidecode 2>/dev/null| sed 's|^[^/]*||' 2>/dev/null)
|
||||||
|
|
||||||
#Check for DMI data
|
#Check for DMI data
|
||||||
@ -424,10 +425,12 @@ if [ -d /sys/class/dmi/id ]; then
|
|||||||
DMI_SYSTEM_MANUFACTURER=$(cat /sys/class/dmi/id/sys_vendor 2>/dev/null)
|
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_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_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
|
elif [ -x $DMIDECODE ]; then
|
||||||
DMI_SYSTEM_MANUFACTURER=$($DMIDECODE -s system-manufacturer 2>/dev/null)
|
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_NAME=$($DMIDECODE -s system-product-name 2>/dev/null)
|
||||||
DMI_SYSTEM_PRODUCT_VERSION=$($DMIDECODE -s system-version 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
|
fi
|
||||||
|
|
||||||
cat /proc/asound/modules 2>/dev/null|awk {'print $2'}>$TEMPDIR/alsamodules.tmp
|
cat /proc/asound/modules 2>/dev/null|awk {'print $2'}>$TEMPDIR/alsamodules.tmp
|
||||||
@ -469,6 +472,7 @@ echo "" >> $FILE
|
|||||||
echo "Manufacturer: $DMI_SYSTEM_MANUFACTURER" >> $FILE
|
echo "Manufacturer: $DMI_SYSTEM_MANUFACTURER" >> $FILE
|
||||||
echo "Product Name: $DMI_SYSTEM_PRODUCT_NAME" >> $FILE
|
echo "Product Name: $DMI_SYSTEM_PRODUCT_NAME" >> $FILE
|
||||||
echo "Product Version: $DMI_SYSTEM_PRODUCT_VERSION" >> $FILE
|
echo "Product Version: $DMI_SYSTEM_PRODUCT_VERSION" >> $FILE
|
||||||
|
echo "Firmware Version: $DMI_SYSTEM_FIRMWARE_VERSION" >> $FILE
|
||||||
echo "" >> $FILE
|
echo "" >> $FILE
|
||||||
echo "" >> $FILE
|
echo "" >> $FILE
|
||||||
echo "!!Kernel Information" >> $FILE
|
echo "!!Kernel Information" >> $FILE
|
||||||
@ -526,7 +530,14 @@ echo " Installed - Yes ($JACKINST)" >> $FILE
|
|||||||
echo " Running - $JACKRUNNING" >> $FILE
|
echo " Running - $JACKRUNNING" >> $FILE
|
||||||
echo "" >> $FILE
|
echo "" >> $FILE
|
||||||
fi
|
fi
|
||||||
if [[ -z "$PAINST" && -z "$ESDINST" && -z "$ARTSINST" && -z "$JACKINST" ]];then
|
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 "No sound servers found." >> $FILE
|
||||||
echo "" >> $FILE
|
echo "" >> $FILE
|
||||||
fi
|
fi
|
||||||
@ -544,7 +555,7 @@ cat $TEMPDIR/lspci.tmp >> $FILE
|
|||||||
echo "" >> $FILE
|
echo "" >> $FILE
|
||||||
echo "" >> $FILE
|
echo "" >> $FILE
|
||||||
echo "!!Advanced information - PCI Vendor/Device/Subsystem ID's" >> $FILE
|
echo "!!Advanced information - PCI Vendor/Device/Subsystem ID's" >> $FILE
|
||||||
echo "!!--------------------------------------------------------" >> $FILE
|
echo "!!-------------------------------------------------------" >> $FILE
|
||||||
echo "" >> $FILE
|
echo "" >> $FILE
|
||||||
lspci -vvn |grep -A1 040[1-3] >> $FILE
|
lspci -vvn |grep -A1 040[1-3] >> $FILE
|
||||||
echo "" >> $FILE
|
echo "" >> $FILE
|
||||||
@ -563,7 +574,7 @@ fi
|
|||||||
if [ -d "$SYSFS" ]
|
if [ -d "$SYSFS" ]
|
||||||
then
|
then
|
||||||
echo "!!Loaded sound module options" >> $FILE
|
echo "!!Loaded sound module options" >> $FILE
|
||||||
echo "!!--------------------------" >> $FILE
|
echo "!!---------------------------" >> $FILE
|
||||||
echo "" >> $FILE
|
echo "" >> $FILE
|
||||||
for mod in `cat /proc/asound/modules|awk {'print $2'}`;do
|
for mod in `cat /proc/asound/modules|awk {'print $2'}`;do
|
||||||
echo "!!Module: $mod" >> $FILE
|
echo "!!Module: $mod" >> $FILE
|
||||||
@ -591,7 +602,7 @@ fi
|
|||||||
if [ -s "$TEMPDIR/alsa-ac97.tmp" ]
|
if [ -s "$TEMPDIR/alsa-ac97.tmp" ]
|
||||||
then
|
then
|
||||||
echo "!!AC97 Codec information" >> $FILE
|
echo "!!AC97 Codec information" >> $FILE
|
||||||
echo "!!---------------------------" >> $FILE
|
echo "!!----------------------" >> $FILE
|
||||||
echo "--startcollapse--" >> $FILE
|
echo "--startcollapse--" >> $FILE
|
||||||
echo "" >> $FILE
|
echo "" >> $FILE
|
||||||
cat $TEMPDIR/alsa-ac97.tmp >> $FILE
|
cat $TEMPDIR/alsa-ac97.tmp >> $FILE
|
||||||
@ -605,7 +616,7 @@ fi
|
|||||||
if [ -s "$TEMPDIR/alsa-usbmixer.tmp" ]
|
if [ -s "$TEMPDIR/alsa-usbmixer.tmp" ]
|
||||||
then
|
then
|
||||||
echo "!!USB Mixer information" >> $FILE
|
echo "!!USB Mixer information" >> $FILE
|
||||||
echo "!!---------------------------" >> $FILE
|
echo "!!---------------------" >> $FILE
|
||||||
echo "--startcollapse--" >> $FILE
|
echo "--startcollapse--" >> $FILE
|
||||||
echo "" >> $FILE
|
echo "" >> $FILE
|
||||||
cat $TEMPDIR/alsa-usbmixer.tmp >> $FILE
|
cat $TEMPDIR/alsa-usbmixer.tmp >> $FILE
|
||||||
|
@ -1,10 +1,17 @@
|
|||||||
|
#
|
||||||
|
# Note that two different ALSA card state management schemes exist and they
|
||||||
|
# can be switched using a file exist check - /etc/alsa/state-daemon.conf .
|
||||||
|
#
|
||||||
|
|
||||||
[Unit]
|
[Unit]
|
||||||
Description=Restore Sound Card State
|
Description=Restore Sound Card State
|
||||||
|
ConditionPathExists=!/etc/alsa/state-daemon.conf
|
||||||
DefaultDependencies=no
|
DefaultDependencies=no
|
||||||
After=sysinit.target
|
After=alsa-state.service
|
||||||
Before=shutdown.target
|
Before=shutdown.target
|
||||||
Conflicts=shutdown.target
|
Conflicts=shutdown.target
|
||||||
|
|
||||||
[Service]
|
[Service]
|
||||||
Type=oneshot
|
Type=oneshot
|
||||||
ExecStart=-/sbin/alsactl -E ALSA_CONFIG_PATH=/etc/alsa/alsactl.conf --initfile=/lib/alsa/init/00main restore
|
ExecStart=-/sbin/alsactl -E ALSA_CONFIG_PATH=/etc/alsa/alsactl.conf --initfile=/lib/alsa/init/00main restore
|
||||||
|
StandardOutput=syslog
|
||||||
|
17
alsa-state.service
Normal file
17
alsa-state.service
Normal file
@ -0,0 +1,17 @@
|
|||||||
|
#
|
||||||
|
# Note that two different ALSA card state management schemes exist and they
|
||||||
|
# can be switched using a file exist check - /etc/alsa/state-daemon.conf .
|
||||||
|
#
|
||||||
|
|
||||||
|
[Unit]
|
||||||
|
Description=Manage Sound Card State (restore and store)
|
||||||
|
ConditionPathExists=/etc/alsa/state-daemon.conf
|
||||||
|
DefaultDependencies=no
|
||||||
|
After=sysinit.target
|
||||||
|
Before=shutdown.target
|
||||||
|
Conflicts=shutdown.target
|
||||||
|
|
||||||
|
[Service]
|
||||||
|
Type=simple
|
||||||
|
ExecStart=-/usr/sbin/alsactl -s -n 19 -c -E ALSA_CONFIG_PATH=/etc/alsa/alsactl.conf --initfile=/lib/alsa/init/00main rdaemon
|
||||||
|
ExecStop=-/usr/sbin/alsactl -s rkill save_and_quit
|
@ -1,8 +1,15 @@
|
|||||||
|
#
|
||||||
|
# Note that two different ALSA card state management schemes exist and they
|
||||||
|
# can be switched using a file exist check - /etc/alsa/state-daemon.conf .
|
||||||
|
#
|
||||||
|
|
||||||
[Unit]
|
[Unit]
|
||||||
Description=Store Sound Card State
|
Description=Store Sound Card State
|
||||||
|
ConditionPathExists=!/etc/alsa/state-daemon.conf
|
||||||
DefaultDependencies=no
|
DefaultDependencies=no
|
||||||
Before=shutdown.target
|
Before=shutdown.target
|
||||||
|
|
||||||
[Service]
|
[Service]
|
||||||
Type=oneshot
|
Type=oneshot
|
||||||
ExecStart=/sbin/alsactl -E ALSA_CONFIG_PATH=/etc/alsa/alsactl.conf store
|
ExecStart=/sbin/alsactl -E ALSA_CONFIG_PATH=/etc/alsa/alsactl.conf store
|
||||||
|
StandardOutput=syslog
|
||||||
|
@ -1,10 +1,10 @@
|
|||||||
%define baseversion 1.0.26
|
%define baseversion 1.0.27
|
||||||
#define fixversion .1
|
#define fixversion .1
|
||||||
|
|
||||||
Summary: Advanced Linux Sound Architecture (ALSA) utilities
|
Summary: Advanced Linux Sound Architecture (ALSA) utilities
|
||||||
Name: alsa-utils
|
Name: alsa-utils
|
||||||
Version: %{baseversion}%{?fixversion}
|
Version: %{baseversion}%{?fixversion}
|
||||||
Release: 2%{?dist}
|
Release: 1%{?dist}
|
||||||
License: GPLv2+
|
License: GPLv2+
|
||||||
Group: Applications/Multimedia
|
Group: Applications/Multimedia
|
||||||
URL: http://www.alsa-project.org/
|
URL: http://www.alsa-project.org/
|
||||||
@ -16,6 +16,7 @@ Source10: alsa.rules
|
|||||||
Source11: alsactl.conf
|
Source11: alsactl.conf
|
||||||
Source20: alsa-restore.service
|
Source20: alsa-restore.service
|
||||||
Source21: alsa-store.service
|
Source21: alsa-store.service
|
||||||
|
Source22: alsa-state.service
|
||||||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
||||||
BuildRequires: alsa-lib-devel >= %{baseversion}
|
BuildRequires: alsa-lib-devel >= %{baseversion}
|
||||||
BuildRequires: libsamplerate-devel
|
BuildRequires: libsamplerate-devel
|
||||||
@ -24,7 +25,9 @@ BuildRequires: gettext-devel
|
|||||||
BuildRequires: xmlto
|
BuildRequires: xmlto
|
||||||
BuildRequires: systemd-units >= 39-2
|
BuildRequires: systemd-units >= 39-2
|
||||||
Conflicts: udev <= 179-2
|
Conflicts: udev <= 179-2
|
||||||
Requires: alsa-lib >= %{baseversion}, systemd-units >= 39-2, dialog
|
# use latest alsa-lib - the executables in this package requires latest API
|
||||||
|
# alsa-info.sh script requires the dialog package
|
||||||
|
Requires: alsa-lib%{?_isa} >= %{baseversion}, systemd-units >= 39-2, dialog
|
||||||
Conflicts: filesystem < 3
|
Conflicts: filesystem < 3
|
||||||
|
|
||||||
%description
|
%description
|
||||||
@ -51,6 +54,7 @@ install -p -m 644 %{SOURCE10} $RPM_BUILD_ROOT/%{_prefix}/lib/udev/rules.d/90-als
|
|||||||
mkdir -p $RPM_BUILD_ROOT/%{_unitdir}
|
mkdir -p $RPM_BUILD_ROOT/%{_unitdir}
|
||||||
install -p -m 644 %{SOURCE20} $RPM_BUILD_ROOT/%{_unitdir}/alsa-restore.service
|
install -p -m 644 %{SOURCE20} $RPM_BUILD_ROOT/%{_unitdir}/alsa-restore.service
|
||||||
install -p -m 644 %{SOURCE21} $RPM_BUILD_ROOT/%{_unitdir}/alsa-store.service
|
install -p -m 644 %{SOURCE21} $RPM_BUILD_ROOT/%{_unitdir}/alsa-store.service
|
||||||
|
install -p -m 644 %{SOURCE22} $RPM_BUILD_ROOT/%{_unitdir}/alsa-state.service
|
||||||
|
|
||||||
# Install support utilities
|
# Install support utilities
|
||||||
mkdir -p -m755 $RPM_BUILD_ROOT/%{_bindir}
|
mkdir -p -m755 $RPM_BUILD_ROOT/%{_bindir}
|
||||||
@ -95,6 +99,13 @@ ln -s alsa-info %{buildroot}/usr/bin/alsa-info.sh
|
|||||||
%dir %{_prefix}/lib/alsa/init/
|
%dir %{_prefix}/lib/alsa/init/
|
||||||
%dir /var/lib/alsa/
|
%dir /var/lib/alsa/
|
||||||
|
|
||||||
|
%pre
|
||||||
|
if [ ! -r /lib/systemd/system/alsa-state.service ]; then
|
||||||
|
[ -d /etc/alsa ] || mkdir -m 0755 /etc/alsa
|
||||||
|
echo "# Remove this file to disable the alsactl daemon mode" > \
|
||||||
|
/etc/alsa/state-daemon.conf
|
||||||
|
fi
|
||||||
|
|
||||||
%post
|
%post
|
||||||
if [ -s /etc/alsa/asound.state -a ! -s /etc/asound.state ] ; then
|
if [ -s /etc/alsa/asound.state -a ! -s /etc/asound.state ] ; then
|
||||||
mv /etc/alsa/asound.state /etc/asound.state
|
mv /etc/alsa/asound.state /etc/asound.state
|
||||||
@ -104,6 +115,10 @@ if [ -s /etc/asound.state -a ! -s /var/lib/alsa/asound.state ] ; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Fri Apr 12 2013 Jaroslav Kysela <jkysela@redhat.com> - 1.0.27-1
|
||||||
|
- Updated to 1.0.27, activated the alsactl daemon mode
|
||||||
|
- Updated alsa-info.sh to 0.4.61
|
||||||
|
|
||||||
* Wed Feb 13 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.26-2
|
* Wed Feb 13 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.26-2
|
||||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
|
||||||
|
|
||||||
|
11
alsa.rules
11
alsa.rules
@ -1,4 +1,7 @@
|
|||||||
ACTION=="add", SUBSYSTEM=="sound", KERNEL=="controlC*", \
|
ACTION=="add", SUBSYSTEM=="sound", KERNEL=="controlC*", KERNELS!="card*", GOTO="alsa_restore_go"
|
||||||
RUN+="/sbin/alsactl -E ALSA_CONFIG_PATH=/etc/alsa/alsactl.conf --initfile=/lib/alsa/init/00main restore /dev/$name"
|
|
||||||
ACTION=="remove", SUBSYSTEM=="sound", KERNEL=="controlC*", \
|
LABEL="alsa_restore_go"
|
||||||
RUN+="/sbin/alsactl -E ALSA_CONFIG_PATH=/etc/alsa/alsactl.conf store /dev/$name"
|
TEST!="/etc/alsa/state-daemon.conf", RUN+="/sbin/alsactl -E ALSA_CONFIG_PATH=/etc/alsa/alsactl.conf --initfile=/lib/alsa/init/00main restore /dev/$name"
|
||||||
|
TEST=="/etc/alsa/state-daemon.conf", RUN+="/sbin/alsactl -E ALSA_CONFIG_PATH=/etc/alsa/alsactl.conf --initfile=/lib/alsa/init/00main nrestore /dev/$name"
|
||||||
|
|
||||||
|
LABEL="alsa_restore_end"
|
||||||
|
Loading…
Reference in New Issue
Block a user