summaryrefslogtreecommitdiff
blob: fdc4701c6fc17d02bf0fb6d61edd80fff76b0fc9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
# Copyright 1999-2005 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/media-sound/esound/esound-0.2.36-r1.ebuild,v 1.7 2005/08/29 20:01:23 gmsoft Exp $

inherit libtool gnome.org eutils

DESCRIPTION="The Enlightened Sound Daemon"
HOMEPAGE="http://www.tux.org/~ricdude/EsounD.html"

LICENSE="LGPL-2"
SLOT="0"
KEYWORDS="~alpha ~amd64 ~arm hppa ia64 ~mips ~ppc ~ppc-macos ~ppc64 sparc x86"
IUSE="alsa debug ipv6 static tcpd"

# esound comes with arts support, but it hasn't been tested yet, feel free to
# submit patches/improvements
DEPEND=">=media-libs/audiofile-0.1.5
	alsa? ( >=media-libs/alsa-lib-0.5.10b )
	tcpd? ( >=sys-apps/tcp-wrappers-7.6-r2 )"
#	arts? ( kde-base/arts )

src_unpack() {

	unpack ${A}
	cd ${S}

	epatch ${FILESDIR}/${PN}-0.2.32-amd64.patch
	# please note, this is a conditional, version specific patch!!!
	# when bumping avoid bugs like #103969
	use ppc-macos && epatch ${FILESDIR}/${P}-ppc-macos.patch
}

src_compile() {
	local myconf="--sysconfdir=/etc/esd $(use_enable ipv6) \
		$(use_enable static) $(use_enable debug debugging) $(use_enable alsa) \
		$(use_with tcpd libwrap)"

	elibtoolize

	econf $myconf || die "Configure failed"

	make || die "Make failed"
}

src_install() {

	make DESTDIR="${D}" install  || die "Installation failed"

	dodoc AUTHORS ChangeLog MAINTAINERS NEWS README TIPS TODO

	[ -d "docs/html" ] && dohtml -r docs/html/*

	newconfd ${FILESDIR}/esound.conf.d esound

	extradepend=""
	use tcpd && extradepend=" portmap"
	use alsa && extradepend="$extradepend alsasound"
	sed "s/@extradepend@/$extradepend/" <${FILESDIR}/esound.init.d >${T}/esound
	doinitd ${T}/esound

}