summaryrefslogtreecommitdiff
blob: 8377d7fa7fdc42ad2eb585be3e9c7abb30d61a93 (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
# Copyright 1999-2005 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/app-text/convertlit/convertlit-1.8.ebuild,v 1.6 2005/04/21 20:36:41 blubb Exp $

MY_P="clit${PV//./}"

DESCRIPTION="CLit converts MS ebook .lit files to .opf (xml+html+png+jpg)"
HOMEPAGE="http://www.convertlit.com/"
SRC_URI="http://www.convertlit.com/${MY_P}src.zip"

LICENSE="GPL-2"
SLOT="0"

KEYWORDS="x86 ppc amd64"
DEPEND="dev-libs/libtommath
	>=sys-apps/sed-4
	app-arch/unzip"
RDEPEND=""	# link libtommath statically
IUSE=""

S=${WORKDIR}

src_compile() {
	cd ${S}/lib
	sed -i -e "/^CFLAGS/s/-O3 -Wall/${CFLAGS}/" Makefile \
		|| die "sed lib/Makefile failed."
	emake || die "make lib failed"
	cd ${S}/${MY_P}
	sed -i -e "/^CFLAGS/s:-Wall -O2:${CFLAGS}:" \
		-e "s:../libtommath-0.30:/usr/lib:g" Makefile \
		|| die "sed ${MY_P}/Makefile failed."
	emake || die "make ${MY_P} failed"
}

src_install() {
	dobin ${S}/${MY_P}/clit
	dodoc ${S}/README
}