]> Pileus Git - ~andy/sunrise/blob - dev-libs/lua-gd/lua-gd-2.0.33.2.ebuild
app-dicts/words-bin: Adding ~amd64 keyword
[~andy/sunrise] / dev-libs / lua-gd / lua-gd-2.0.33.2.ebuild
1 # Copyright 1999-2012 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: $
4
5 EAPI=4
6
7 inherit eutils toolchain-funcs versionator
8
9 MY_P=${PN}-$(replace_version_separator 3 'r' )
10
11 DESCRIPTION="Lua bindings to Thomas Boutell's gd library"
12 HOMEPAGE="http://lua-gd.luaforge.net/"
13 SRC_URI="http://luaforge.net/frs/download.php/1592/${MY_P}.tar.gz
14         mirror://sourceforge/${PN}/${PN}/${MY_P}%20%28for%20Lua%205.1%29/${MY_P}.tar.gz"
15
16 LICENSE="MIT"
17 SLOT="0"
18 KEYWORDS="~amd64 ~x86"
19 IUSE="doc examples"
20
21 RDEPEND="dev-lang/lua
22         media-libs/gd[png]"
23 DEPEND="${RDEPEND}
24         virtual/pkgconfig"
25
26 S=${WORKDIR}/${MY_P}
27
28 src_prepare() {
29         epatch "${FILESDIR}/${P}-makefile.patch"
30 }
31
32 src_compile() {
33         emake LUAPKG=lua CC="$(tc-getCC)"
34 }
35
36 src_install() {
37         emake install LUAPKG=lua DESTDIR="${D}"
38         dodoc README
39
40         if use doc; then
41                 dohtml doc/*
42         fi
43
44         if use examples; then
45                 insinto /usr/share/doc/${PF}
46                 doins -r demos
47         fi
48 }