summaryrefslogtreecommitdiff
blob: 38ed335493d306bf499ab9005b80930d0ce1671f (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
# Copyright 1999-2008 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/media-sound/kid3/kid3-1.1.ebuild,v 1.1 2008/10/27 11:52:42 scarabeus Exp $

EAPI="2"

inherit eutils cmake-utils

DESCRIPTION="A simple ID3 tag editor for QT/KDE."
HOMEPAGE="http://kid3.sourceforge.net/"
SRC_URI="mirror://sourceforge/kid3/${P}.tar.gz"
LICENSE="GPL-2"

SLOT="0"
KEYWORDS="~amd64 ~x86"
IUSE="+flac +musicbrainz"

# Kde cannot be disabled configure violates
# sandbox and i aint fixing it.
# Currently we preffer kde4 over kde3.
DEPEND=">=media-libs/id3lib-3.8.3
	>=media-libs/taglib-1.4-r1
	media-libs/libmp4v2
	media-libs/libvorbis
	flac? (	media-libs/flac[cxx] )
	|| (
		>=kde-base/kdelibs-3.9
		kde-base/kdelibs:3.5
	)
	musicbrainz? (
		media-libs/musicbrainz:3
		media-libs/tunepimp
	)"

src_configure() {
	if has_version ">=kde-base/kdelibs-3.9"; then
		# we shall use kde4
		# there is option WITH_KDE but kde is needed anyway
		# so forcing
		mycmakeargs="${mycmakeargs}
		-DWITH_KDE=ON
		-DWITH_TAGLIB=ON
		-DWITH_VORBIS=ON
		$(cmake-utils_use_with flac FLAC)
		$(cmake-utils_use_with musicbrainz TUNEPIMP)
		"
		cmake-utils_src_configure
	else
		# we shall use kde3
		# Compile fails without taglib, forced on.
		# Ditto for vorbis, so there you go.
		econf \
			--with-kde \
			--with-taglib \
			--without-arts \
			--with-vorbis \
			$(use_with flac)
			$(use_with musicbrainz)
	fi
}