summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'dev-lua')
-rw-r--r--dev-lua/lunix/files/patches/99999999/compat52-luajit.patch20
-rw-r--r--dev-lua/lunix/lunix-99999999.ebuild2
2 files changed, 22 insertions, 0 deletions
diff --git a/dev-lua/lunix/files/patches/99999999/compat52-luajit.patch b/dev-lua/lunix/files/patches/99999999/compat52-luajit.patch
new file mode 100644
index 0000000..8df3c63
--- /dev/null
+++ b/dev-lua/lunix/files/patches/99999999/compat52-luajit.patch
@@ -0,0 +1,20 @@
+diff -NaurBwd a/src/unix.c b/src/unix.c
+--- a/src/unix.c 2017-05-10 18:12:19.819388720 +0700
++++ b/src/unix.c 2017-05-10 18:13:55.792661605 +0700
+@@ -483,6 +483,7 @@
+ } /* lua_absindex() */
+
+
++#ifndef LUA_OK
+ static void *luaL_testudata(lua_State *L, int index, const char *tname) {
+ void *p = lua_touserdata(L, index);
+ int eq;
+@@ -523,6 +524,7 @@
+
+ #define luaL_newlib(L, l) \
+ (luaL_newlibtable((L), (l)), luaL_setfuncs((L), (l), 0))
++#endif
+
+
+ #define lua_rawlen lua_objlen
+
diff --git a/dev-lua/lunix/lunix-99999999.ebuild b/dev-lua/lunix/lunix-99999999.ebuild
index c13c0fb..b77a2fb 100644
--- a/dev-lua/lunix/lunix-99999999.ebuild
+++ b/dev-lua/lunix/lunix-99999999.ebuild
@@ -25,6 +25,8 @@ RDEPEND="${DEPEND}"
DOCS=(doc/.)
EXAMPLES=(examples/.)
+PATCHES=("${FILESDIR}/patches/${PV}")
+
all_lua_prepare() {
sed -r \
-e "s@(^prefix ).*@\1=/usr@" \