summaryrefslogtreecommitdiff
blob: a66672a7020e5e9159860a2ea63f2a6d01d1cf33 (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-2004 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/dev-tcltk/itcl/itcl-3.2.1-r1.ebuild,v 1.7 2004/06/25 02:07:09 agriffis Exp $

inherit eutils

MY_P=${PN}${PV}
S=${WORKDIR}/${MY_P}
IUSE=""
DESCRIPTION="Object Oriented Enhancements for Tcl/Tk"
SRC_URI="mirror://sourceforge/incrtcl/${MY_P}_src.tgz"
HOMEPAGE="http://www.tcltk.com/${PN}/"

SLOT="0"
LICENSE="as-is BSD"
KEYWORDS="x86 ~ppc sparc ~amd64"
DEPEND="dev-lang/tk"
PDEPEND="dev-tcltk/iwidgets"

src_unpack() {
	unpack ${A}
	epatch ${FILESDIR}/${P}-gentoo.diff
	# fix an undefined const glitch for Tcl8.3
	sed -i '1004h;1004d;1006G' ${S}/itcl/generic/itcl_class.c
}

src_compile() {
	econf || die "econf failed"
	emake DESTDIR="${D}" CFLAGS_DEFAULT="${CFLAGS}" || die "emake failed"
}

src_install() {
	make DESTDIR="${D}" install || die	"make install failed"
	dodoc CHANGES INCOMPATIBLE README TODO license.terms
	dodoc doc/*
	dosym /usr/lib/itcl3.2 /usr/lib/itcl
	dosym /usr/lib/itk3.2 /usr/lib/itk
}