summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'dev-lua/luaexpat/luaexpat-1.1.0.ebuild')
-rw-r--r--dev-lua/luaexpat/luaexpat-1.1.0.ebuild46
1 files changed, 46 insertions, 0 deletions
diff --git a/dev-lua/luaexpat/luaexpat-1.1.0.ebuild b/dev-lua/luaexpat/luaexpat-1.1.0.ebuild
new file mode 100644
index 0000000..b386d9e
--- /dev/null
+++ b/dev-lua/luaexpat/luaexpat-1.1.0.ebuild
@@ -0,0 +1,46 @@
+# Copyright 1999-2008 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: $
+
+inherit multilib
+
+DESCRIPTION="A SAX XML parser based on the Expat library."
+HOMEPAGE="http://www.keplerproject.org/luaexpat/i"
+SRC_URI="http://luaforge.net/frs/download.php/2469/${P}.tar.gz"
+
+LICENSE=""
+SLOT="0"
+KEYWORDS="~amd64"
+IUSE=""
+
+DEPEND="dev-lang/lua
+ >=dev-libs/expat-2.0.0"
+RDEPEND="${DEPEND}"
+
+S="${WORKDIR}/${P%.*}"
+
+src_unpack() {
+ unpack ${A}
+ cd "${S}"
+
+ local luaver=
+ luaver="$(lua -v 2>&1| cut -d' ' -f2)"
+ luaver="${luaver%.*}"
+
+ sed -i \
+ -e "s:/usr/local/lib:\"${D}\"/usr/$(get_libdir):" \
+ -e "s:/usr/local/share:\"${D}\"/usr/share:" \
+ -e "s:usr/local:usr:" \
+ -e "s:\(LUA_VERSION_NUM=\).*:\1 ${luaver}0:" \
+ -e "s:5.0:${luaver}:" \
+ -e "s:-O2:-fPIC ${CFLAGS}:" \
+ config || die "sed in config failed"
+}
+
+src_compile() {
+ emake || die "emake failed"
+}
+
+src_install() {
+ emake install || die "emake install failed"
+}