summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'dev-lang/luajit/files/luajit-2.1.1727870382-fix-ljlibd-prefix.patch')
-rw-r--r--dev-lang/luajit/files/luajit-2.1.1727870382-fix-ljlibd-prefix.patch25
1 files changed, 25 insertions, 0 deletions
diff --git a/dev-lang/luajit/files/luajit-2.1.1727870382-fix-ljlibd-prefix.patch b/dev-lang/luajit/files/luajit-2.1.1727870382-fix-ljlibd-prefix.patch
new file mode 100644
index 000000000000..98ae276fcc9f
--- /dev/null
+++ b/dev-lang/luajit/files/luajit-2.1.1727870382-fix-ljlibd-prefix.patch
@@ -0,0 +1,25 @@
+# LJLIBD is traversed at runtime, should be relative to
+# PREFIX instead of DESTDIR/PREFIX
+#
+# https://github.com/LuaJIT/LuaJIT/issues/1303
+# https://bugs.gentoo.org/943395
+
+--- a/Makefile
++++ b/Makefile
+@@ -37,12 +37,13 @@
+ DPREFIX= $(DESTDIR)$(PREFIX)
+ INSTALL_BIN= $(DPREFIX)/bin
+ INSTALL_LIB= $(DPREFIX)/$(MULTILIB)
+-INSTALL_SHARE= $(DPREFIX)/share
++INSTALL_SHARE_LOCAL= $(PREFIX)/share
++INSTALL_SHARE= $(DESTDIR)$(INSTALL_SHARE_LOCAL)
+ INSTALL_DEFINC= $(DPREFIX)/include/luajit-$(MMVERSION)
+ INSTALL_INC= $(INSTALL_DEFINC)
+
+-export INSTALL_LJLIBD= $(INSTALL_SHARE)/luajit-$(MMVERSION)
+-INSTALL_JITLIB= $(INSTALL_LJLIBD)/jit
++export INSTALL_LJLIBD= $(INSTALL_SHARE_LOCAL)/luajit-$(MMVERSION)
++INSTALL_JITLIB= $(DESTDIR)$(INSTALL_LJLIBD)/jit
+ INSTALL_LMODD= $(INSTALL_SHARE)/lua
+ INSTALL_LMOD= $(INSTALL_LMODD)/$(ABIVER)
+ INSTALL_CMODD= $(INSTALL_LIB)/lua