summaryrefslogtreecommitdiff
blob: c71b237f2b88b8ac6a1e9e2b27762417a932d509 (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
# Copyright 1999-2005 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/x11-misc/adesklets/adesklets-0.4.11.ebuild,v 1.1 2005/09/02 08:23:05 s4t4n Exp $

DESCRIPTION="An interactive Imlib2 console for the X Window system"
HOMEPAGE="http://adesklets.sf.net/"
SRC_URI="mirror://sourceforge/adesklets/${P}.tar.bz2"

SLOT="0"
LICENSE="GPL-2"
KEYWORDS="~x86 ~amd64 ~ppc"
IUSE="X python"

DEPEND="virtual/libc
	>=sys-libs/readline-4.3-r5
	>=media-libs/imlib2-1.2.0-r2
	X? ( virtual/x11 )
	python? ( >=dev-lang/python-2.3.4-r1 )"

src_compile()
{
	local myconf=""

	use X || myconf="--without-x"
	use python || myconf="${myconf} --without-python-support"

	econf ${myconf} || die
	emake || die
}

src_install()
{
	dodir usr/share/info
	dodir usr/share/man/man1
	make DESTDIR=${D} install || die
	doinfo doc/*.info || die "info page installation failed"
	doman doc/*.1 || die "man page installation failed"
	dodoc ChangeLog INSTALL NEWS TODO AUTHORS
}

pkg_postinst()
{
	use X ||
	{
		ewarn "You did not install the X Window support for ${P}"
		ewarn "If you intend to use it to display desklets, this"
		ewarn "is a mistake."
		ewarn
		ewarn "Type USE=\"X\" emerge adesklets to correct this."
		ewarn
		einfo "Please also note that if it is what you intended"
		einfo "to do, you need also to install imlib2 without"
		einfo "X support to effectively remove all dependencies."
		einfo
	}

	use python ||
	{
		ewarn "You did not install the python bindings for ${P}"
		ewarn "If you intend to use it to display desklets, this"
		ewarn "is most probably an error."
		ewarn
		ewarn "Type USE=\"python\" emerge adesklets to correct this."
	}
}