summaryrefslogtreecommitdiff
blob: 6a1d325dffed28e6cdc4eaf8d397adf74ccd1e72 (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-2016 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Id$

EAPI=6

inherit autotools

DESCRIPTION="Audio Tag Tool Ogg/Mp3 Tagger"
HOMEPAGE="http://pwp.netcabo.pt/paol/tagtool"
SRC_URI="mirror://sourceforge/${PN}/${P}.tar.bz2"

LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~amd64 ~ppc ~sparc ~x86"
IUSE="vorbis mp3"

RDEPEND="x11-libs/gtk+:2
	>=gnome-base/libglade-2.6
	mp3? ( >=media-libs/id3lib-3.8.3-r6 )
	vorbis? ( >=media-libs/libvorbis-1 )
	!mp3? ( !vorbis? ( >=media-libs/libvorbis-1 ) )"
DEPEND="${RDEPEND}
	virtual/pkgconfig"

PATCHES=(
	"${FILESDIR}"/${P}-underlinking.patch
)

src_prepare() {
	# QA fix for wrong boolean value
	sed -i -e 's/Terminal=False/Terminal=false/' data/tagtool.desktop.in || die

	default
	eautoreconf
}

src_configure() {
	local myconf

	use mp3 || myconf="${myconf} --disable-mp3"
	use vorbis || myconf="${myconf} --disable-vorbis"

	if ! use mp3 && ! use vorbis; then
		einfo "One of USE flags is required, enabling vorbis for you."
		myconf="--disable-mp3"
	fi

	econf ${myconf}
}

src_install() {
	emake \
		DESTDIR="${D}" \
		GNOME_SYSCONFDIR="${D}/etc" \
		sysdir="${D}/usr/share/applets/Multimedia" \
		install || die

	dodoc ChangeLog NEWS README TODO THANKS
}