SHA256
1
0
forked from pool/alsa-utils
alsa-utils/alsa-utils.spec

176 lines
5.3 KiB
RPMSpec
Raw Normal View History

#
# spec file for package alsa-utils
#
# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via http://bugs.opensuse.org/
#
Accepting request 237959 from home:tiwai:branches:multimedia:libs - Updated to alsa-utils 1.0.28: All pervious fix patches are obsoleted: 0001-alsactl-alsa-state.service-fix-typo-rkill-kill.patch 0002-alsaloop-fix-wrong-alias-for-signal.h.patch 0003-aplay-fix-two-off-by-one-errors.patch 0004-alsaloop-add-z-syslog-option-to-use-syslog-for-error.patch 0005-amixer-actually-print-all-TLVs-in-a-container-TLV.patch 0006-amixer-fix-indentation-when-printing-container-TLV-c.patch 0007-alsaloop-pcmjob.c-use-portable-way-to-initialize-rec.patch 0008-speaker-test-Fix-chmapped-channel-selection-without-.patch 0009-speaker-test-Always-show-chmap-channel-names-if-avai.patch 0010-speaker-test-Show-out-of-chmap-channels-as-Unknown.patch 0011-alsaconf-support-newer-m-i-t-and-kmod.patch 0012-alsaconf-update-gentoo-to-use-modprobe.d-method-as-e.patch 0013-configure-detect-udevdir-via-pkg-config-fallback-to-.patch 0014-alsactl-Add-monitor-command.patch 0015-alsactl-Fix-REMOVE-event-handling-in-monitor-command.patch 0016-alsactl-monitor-all-cards-as-default.patch 0017-alsactl-Fix-the-va_list-initialization-in-cerror_-an.patch 0018-aplay-fix-pcm_read-return-value.patch 0019-alsa-restore.rules-refer-to-correct-attr.patch 0020-aplay-fix-timespec-to-msec-conversion.patch 0021-speaker-test-add-force-frequency-option-to-allow-hz-.patch 0022-speaker-test-update-man-page-for-new-X-arg-also-cons.patch OBS-URL: https://build.opensuse.org/request/show/237959 OBS-URL: https://build.opensuse.org/package/show/multimedia:libs/alsa-utils?expand=0&rev=100
2014-06-18 14:59:24 +02:00
%define package_version 1.0.28
#
%if 0%{?suse_version} > 1130
%define use_systemd 1
%define use_varlib 1
%if 0%{?suse_version} == 1140
%define _unitdir /lib/systemd/system
%endif
BuildRequires: systemd
%else
%define use_systemd 0
%define use_varlib 0
%endif
%if 0%{?suse_version} > 1200
%define _udevdir %(pkg-config --variable=udevdir udev)
%else
%define _udevdir /lib/udev
%endif
Name: alsa-utils
Accepting request 237959 from home:tiwai:branches:multimedia:libs - Updated to alsa-utils 1.0.28: All pervious fix patches are obsoleted: 0001-alsactl-alsa-state.service-fix-typo-rkill-kill.patch 0002-alsaloop-fix-wrong-alias-for-signal.h.patch 0003-aplay-fix-two-off-by-one-errors.patch 0004-alsaloop-add-z-syslog-option-to-use-syslog-for-error.patch 0005-amixer-actually-print-all-TLVs-in-a-container-TLV.patch 0006-amixer-fix-indentation-when-printing-container-TLV-c.patch 0007-alsaloop-pcmjob.c-use-portable-way-to-initialize-rec.patch 0008-speaker-test-Fix-chmapped-channel-selection-without-.patch 0009-speaker-test-Always-show-chmap-channel-names-if-avai.patch 0010-speaker-test-Show-out-of-chmap-channels-as-Unknown.patch 0011-alsaconf-support-newer-m-i-t-and-kmod.patch 0012-alsaconf-update-gentoo-to-use-modprobe.d-method-as-e.patch 0013-configure-detect-udevdir-via-pkg-config-fallback-to-.patch 0014-alsactl-Add-monitor-command.patch 0015-alsactl-Fix-REMOVE-event-handling-in-monitor-command.patch 0016-alsactl-monitor-all-cards-as-default.patch 0017-alsactl-Fix-the-va_list-initialization-in-cerror_-an.patch 0018-aplay-fix-pcm_read-return-value.patch 0019-alsa-restore.rules-refer-to-correct-attr.patch 0020-aplay-fix-timespec-to-msec-conversion.patch 0021-speaker-test-add-force-frequency-option-to-allow-hz-.patch 0022-speaker-test-update-man-page-for-new-X-arg-also-cons.patch OBS-URL: https://build.opensuse.org/request/show/237959 OBS-URL: https://build.opensuse.org/package/show/multimedia:libs/alsa-utils?expand=0&rev=100
2014-06-18 14:59:24 +02:00
Version: 1.0.28
Release: 0
Summary: Advanced Linux Sound Architecture Utilities
License: GPL-2.0+
Group: Productivity/Multimedia/Sound/Players
Url: http://www.alsa-project.org/
Source: ftp://ftp.alsa-project.org/pub/utils/alsa-utils-%{package_version}.tar.bz2
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
BuildRequires: automake
BuildRequires: libsamplerate-devel
BuildRequires: ncurses-devel
BuildRequires: pkgconfig
BuildRequires: xmlto
Requires: alsa
Requires: dialog
Requires: pciutils
Provides: alsa-conf
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%if 0%{?suse_version} > 1200
BuildRequires: libudev-devel
%endif
%description
This package contains utility programs supporting ALSA, Advanced Linux
Sound Architecture.
%prep
%setup -q -n %{name}-%{package_version}
# fix stupid automake's automatic action
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
%endif
%build
export AUTOMAKE_JOBS="%{?_smp_mflags}"
%if 0%{?suse_version} < 1020
gettextize -f
%endif
autoreconf -fi
opts=""
%if %{use_systemd}
opts="$opts --with-systemdsystemunitdir=%{_unitdir}"
%endif
%if ! %{use_varlib}
opts="$opts --with-asound-state-dir=/etc"
%endif
%if 0%{?suse_version} < 1030
opts="$opts --disable-xmlto"
%endif
opts="$opts --with-udev-rules-dir=%{_udevdir}/rules.d"
%configure --with-curses=ncursesw $opts
make %{?_smp_mflags}
%install
make DESTDIR=%{buildroot} install %{?_smp_mflags}
mkdir -p %{buildroot}%{_datadir}/alsa/init/preinit
mkdir -p %{buildroot}%{_datadir}/alsa/init/postinit
for i in %{_sourcedir}/[0-9]*.conf; do
install -c -m 0644 $i %{buildroot}%{_datadir}/alsa/init/postinit
done
%find_lang %{name} --all-name
%if %{use_systemd}
ln -s alsa-restore.service %{buildroot}%{_unitdir}/alsasound.service
%endif
%if %{use_varlib}
mkdir -p %{buildroot}%{_localstatedir}/lib/alsa
%endif
%files -f %{name}.lang
%defattr(-, root, root)
%doc COPYING ChangeLog INSTALL README TODO
%doc seq/aconnect/README*
%doc seq/aseqnet/README*
%doc %{_mandir}/man*/*
%doc %{_mandir}/fr
%{_bindir}/*
%{_sbindir}/*
%{_datadir}/sounds/alsa
%{_datadir}/alsa
%{_udevdir}
%if %{use_systemd}
%{_unitdir}/*.service
%{_unitdir}/basic.target.wants/alsa-state.service
%{_unitdir}/basic.target.wants/alsa-restore.service
%{_unitdir}/shutdown.target.wants/alsa-store.service
%endif
%if %{use_varlib}
%{_localstatedir}/lib/alsa
%endif
%changelog