1 # Copyright 1999-2008 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/www/viewcvs.gentoo.org/raw_cvs/gentoo-x86/media-sound/alsa-utils/alsa-utils-1.0.17.ebuild,v 1.1 2008/08/02 21:00:32 betelgeuse Exp $
5 inherit eutils autotools
9 DESCRIPTION
="Advanced Linux Sound Architecture Utils (alsactl, alsamixer, etc.)"
10 HOMEPAGE
="http://www.alsa-project.org/"
11 SRC_URI
="mirror://alsaproject/utils/${MY_P}.tar.bz2"
15 KEYWORDS
="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sh ~sparc ~x86"
16 IUSE
="nls midi minimal"
18 DEPEND
=">=sys-libs/ncurses-5.1
21 >=media-libs/alsa-lib-${PV}"
24 !minimal? ( sys-apps/pciutils )"
26 S
="${WORKDIR}/${MY_P}"
29 if use midi
&& ! built_with_use
--missing true media-libs
/alsa-lib midi
; then
31 eerror
"To be able to build alsa-utils with midi support you need"
32 eerror
"to have built media-libs/alsa-lib with midi USE flag."
33 die
"Missing midi USE flag on media-libs/alsa-lib"
41 epatch
"${FILESDIR}/${PN}-1.0.11_rc2-nls.patch"
42 epatch
"${FILESDIR}/${PN}-1.0.11_rc5-alsaconf-redirect.patch"
43 epatch
"${FILESDIR}/${PN}-1.0.14-alsaconf-modules-update.patch"
44 epatch
"${FILESDIR}/${PN}-1.0.17-seq.patch"
45 epatch
"${FILESDIR}/git-update.patch"
46 # epatch "${FILESDIR}/makefile-fix.patch"
48 AT_M4DIR
="m4" eautoreconf
52 econf $
(use_enable nls
) \
53 $
(use_enable midi sequencer
) \
54 || die
"configure failed"
56 emake || die
"make failed"
60 if [[ -a /etc
/modules.d
/alsa
]] && [[ ! -a /etc
/modprobe.d
/alsa
]]; then
61 elog
"Moving old alsa configuration in modules.d to new"
62 elog
"location in modprobe.d in /etc/"
63 mv "${ROOT}/etc/modules.d/alsa" "${ROOT}/etc/modprobe.d/alsa"
68 local ALSA_UTILS_DOCS
="ChangeLog README TODO
69 seq/aconnect/README.aconnect
70 seq/aseqnet/README.aseqnet"
72 emake DESTDIR
="${D}" install || die
"Installation Failed"
74 dodoc
${ALSA_UTILS_DOCS} || die
75 newdoc alsamixer
/README README.alsamixer || die
77 newinitd
"${FILESDIR}/alsasound.initd" alsasound
78 newconfd
"${FILESDIR}/alsasound.confd" alsasound
79 insinto
/etc
/modprobe.d
80 newins
"${FILESDIR}/alsa-modules.conf-rc" alsa
87 elog
"To take advantage of the init script, and automate the process of"
88 elog
"loading and unloading the ALSA sound drivers as well as"
89 elog
"storing and restoring sound-card mixer levels you should"
90 elog
"add alsasound to the boot runlevel. You can do this as"
92 elog
" # rc-update add alsasound boot"
95 ewarn
"The minimal use flag disables the dependency on pciutils that"
96 ewarn
"is needed by alsaconf at runtime."