summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorArtemis Everfree <artemis@artemis.sh>2024-11-13 17:50:32 -0800
committerSam James <sam@gentoo.org>2024-11-14 03:38:14 +0000
commitfc6fd10b22e18f1729a45a56ccd71fca410be662 (patch)
tree73861c1d6f511f4f586304c994b8e112d669310a /dev-lang
parentdev-ruby/net-imap: Stabilize 0.4.17 ppc64, #943465 (diff)
downloadgentoo-fc6fd10b22e18f1729a45a56ccd71fca410be662.tar.gz
gentoo-fc6fd10b22e18f1729a45a56ccd71fca410be662.tar.bz2
gentoo-fc6fd10b22e18f1729a45a56ccd71fca410be662.zip
dev-lang/luajit: fix LJLIBD not relative to PREFIX
luajit contains a hardcoded path (LJLIBD) where it searches for some lua libraries it installs. This patch was previously defined relative to PREFIX. Upstream commit ae4735f [1] changes them to be defined relative to DPREFIX, which is in turn relative to DESTDIR. I believe this is a bug, which I've reported upstream [2]. This commit patches the Makefile to define LJLIBD relative to PREFIX again. 1: https://github.com/LuaJIT/LuaJIT/commit/ae4735f621d89d84758769b76432d2319dda9827 2: https://github.com/LuaJIT/LuaJIT/issues/1303 Closes: https://bugs.gentoo.org/943395 Closes: https://bugs.gentoo.org/943346 Signed-off-by: Artemis Everfree <artemis@artemis.sh> Closes: https://github.com/gentoo/gentoo/pull/39311 Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'dev-lang')
-rw-r--r--dev-lang/luajit/files/luajit-2.1.1727870382-fix-ljlibd-prefix.patch25
-rw-r--r--dev-lang/luajit/luajit-2.1.1727870382-r1.ebuild (renamed from dev-lang/luajit/luajit-2.1.1727870382.ebuild)1
-rw-r--r--dev-lang/luajit/luajit-2.1.9999999999.ebuild1
3 files changed, 27 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
diff --git a/dev-lang/luajit/luajit-2.1.1727870382.ebuild b/dev-lang/luajit/luajit-2.1.1727870382-r1.ebuild
index ba62499c0453..c3beab8c9c1a 100644
--- a/dev-lang/luajit/luajit-2.1.1727870382.ebuild
+++ b/dev-lang/luajit/luajit-2.1.1727870382-r1.ebuild
@@ -43,6 +43,7 @@ LICENSE="MIT"
# this should probably be pkgmoved to 2.1 for sake of consistency.
SLOT="2/${PV}"
IUSE="lua52compat static-libs"
+PATCHES=( "${FILESDIR}/${PN}-2.1.1727870382-fix-ljlibd-prefix.patch" )
_emake() {
emake \
diff --git a/dev-lang/luajit/luajit-2.1.9999999999.ebuild b/dev-lang/luajit/luajit-2.1.9999999999.ebuild
index f8f7cfba19d2..a27f77162d26 100644
--- a/dev-lang/luajit/luajit-2.1.9999999999.ebuild
+++ b/dev-lang/luajit/luajit-2.1.9999999999.ebuild
@@ -43,6 +43,7 @@ LICENSE="MIT"
# this should probably be pkgmoved to 2.1 for sake of consistency.
SLOT="2/${PV}"
IUSE="lua52compat static-libs"
+PATCHES=( "${FILESDIR}/${PN}-2.1.1727870382-fix-ljlibd-prefix.patch" )
_emake() {
emake \