summaryrefslogtreecommitdiff
blob: dfcffa88cd4f1e247740d92ec83b1a2209cf1354 (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
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
# Copyright 1999-2002 Gentoo Technologies, Inc.
# Distributed under the terms of the GNU General Public License, v2 or later
# Author Achim Gottinger <achim@gentoo.org>
# $Header: /var/cvsroot/gentoo-x86/x11-libs/gtk+/gtk+-1.2.10-r7.ebuild,v 1.2 2002/04/12 19:12:03 spider Exp $

S=${WORKDIR}/${P}
DESCRIPTION="The GIMP Toolkit"
HOMEPAGE="http://www.gtk.org/"
SRC_URI="ftp://ftp.gtk.org/pub/gtk/v1.2/${P}.tar.gz
         ftp://ftp.gnome.org/pub/GNOME/stable/sources/gtk+/${P}.tar.gz
         http://ftp.gnome.org/pub/GNOME/stable/sources/gtk+/${P}.tar.gz"

DEPEND="virtual/glibc virtual/x11
        =dev-libs/glib-1.2*
		nls? ( sys-devel/gettext
		dev-util/intltool )"

src_unpack() {

	unpack ${A}
	
	cd ${S}
	patch -p0 < ${FILESDIR}/gtk-1.2.10.patch || die

	cd ..
	patch -p0 < ${FILESDIR}/${PV}/gtk+-filesel-navigation-buttons.patch || die
	patch -p0 < ${FILESDIR}/${PV}/gtk+-filesel-move-fileops.patch || die
	patch -p0 < ${FILESDIR}/${PV}/gtk+-filesel-save-dir.patch || die
	patch -p0 < ${FILESDIR}/${PV}/gtk+-filesel-dirchanged-fix.patch || die
	
}

src_compile() {

	local myconf

	use nls || myconf="${myconf} --disable-nls"

	if [ "${DEBUG}" ]
	then
		myconf="${myconf} --enable-debug=yes"
	else
		myconf="${myconf} --enable-debug=no"
	fi

	./configure --host=${CHOST} 					\
		    --prefix=/usr 					\
		    --mandir=/usr/share/man 				\
		    --sysconfdir=/etc/X11 				\
		    --with-xinput=xfree 				\
		    --with-x 						\
		    ${myconf} || die

	emake || die
}

src_install() {

	make install DESTDIR=${D} || die

	preplib /usr

	dodoc AUTHORS COPYING ChangeLog* HACKING
	dodoc NEWS* README* TODO
	docinto docs
	cd docs
	dodoc *.txt *.gif text/*
	dohtml -r html

	#install nice, clean-looking gtk+ style
	insinto /usr/share/themes/Gentoo/gtk
	doins ${FILESDIR}/gtkrc
}

pkg_postinst() {

	echo
	echo "**********************************************************************"
	echo "* Older versions added /etc/X11/gtk/gtkrc which changed settings for *"
	echo "* all themes it seems.  Please remove it manually as it will not due *"
	echo "* to /env protection.                                                *"
	echo "*                                                                    *"
	echo "* NB:  The old gtkrc is available through the new Gentoo gtk theme.  *"
	echo "**********************************************************************"
	echo
}