summaryrefslogtreecommitdiff
blob: 48ba876cc522935c72fe943646d200492384cb05 (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
# Copyright 1999-2004 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/media-libs/libsoundtouch/libsoundtouch-1.2.1.ebuild,v 1.3 2004/10/04 20:15:45 eradicator Exp $

IUSE=""

S="${WORKDIR}/SoundTouch-${PV}"

DESCRIPTION="Audio processing library for changing the tempo, pitch and playback rates."
HOMEPAGE="http://sky.prohosting.com/oparviai/soundtouch/"
SRC_URI="http://sky.prohosting.com/oparviai/soundtouch/soundtouch_v${PV}.zip"

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

# FIXME:
#
# I wanted to use 'static' and 'pic' USE flags, but anything
# other than a static lib produces segfaults in soundstretch. :-(
# So I let alone the '$myconf' option, so one can test options
# easily with: myconf="--enable-foo" emerge libsoundtouch

RDEPEND="virtual/libc"

DEPEND="app-arch/unzip"

src_unpack() {
	unpack ${A} || die "unpack failed"
	cd ${S}

	# change sample type from integer to float (more accurate)
	sed -i -e "s|#define INTEGER_SAMPLES|//#define INTEGER_SAMPLES|g" \
		-e "s|//#define FLOAT_SAMPLES|#define FLOAT_SAMPLES|g" include/STTypes.h
}

src_compile() {
	econf $myconf || die "./configure failed"
	# fixes C(XX)FLAGS from configure, so we can use *ours*
	emake CFLAGS="$CFLAGS" CXXFLAGS="$CXXFLAGS" || die "emake failed"
}

src_install() {
	make DESTDIR=${D} pkgdocdir=/usr/share/doc/${P} install || die
	rm -f ${D}/usr/share/doc/${P}/COPYING.TXT  # remove obsolete LICENCE file
}