summaryrefslogtreecommitdiff
blob: 089ced6bd9f498c87dca3403b15e36f12c79cd6c (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
# Copyright 1999-2005 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/media-libs/dssi/dssi-0.9.ebuild,v 1.1 2005/10/09 01:12:02 matsuu Exp $

inherit eutils multilib

IUSE="qt"

DESCRIPTION="DSSI Soft Synth Interface"
HOMEPAGE="http://dssi.sourceforge.net/"
SRC_URI="mirror://sourceforge/${PN}/${P}.tar.gz"

LICENSE="LGPL-2.1 BSD"
SLOT="0"
KEYWORDS="~amd64 ~x86"

DEPEND=">=media-libs/alsa-lib-1.0
	>=media-libs/liblo-0.12
	>=media-sound/jack-audio-connection-kit-0.99.0-r1
	>=media-libs/ladspa-sdk-1.12-r2
	>=media-libs/libsndfile-1.0.11
	>=media-libs/libsamplerate-0.1.1-r1
	sys-apps/sed
	dev-util/pkgconfig
	qt? ( >=x11-libs/qt-3 )"

src_unpack() {
	unpack ${A}
	cd ${S}
	epatch ${FILESDIR}/${P}-gentoo.patch
	sed -i -e "s@^prefix=.*@prefix='/usr'@" \
		-e "s@^libdir=.*@libdir='/usr/$(get_libdir)'@" dssi.pc || die
}

src_compile() {
	emake OPTFLAGS="${CFLAGS}" -C jack-dssi-host || die "emake failed"
	if use qt; then
		emake OPTFLAGS="${CFLAGS}" -C examples || die "emake faild"
	fi
}

src_install() {
	dobin jack-dssi-host/jack-dssi-host
	insinto /usr/include; doins dssi/dssi.h
	insinto /usr/$(get_libdir)/pkgconfig; doins dssi.pc

	if use qt; then
		emake -C examples \
			PREFIX=${D}/usr \
			LIBDIR=${D}/usr/$(get_libdir) \
			install || die
	fi

	dodoc README doc/TODO doc/*.txt
}