summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarek Szuba <marecki@gentoo.org>2020-12-24 01:15:32 +0000
committerMarek Szuba <marecki@gentoo.org>2020-12-24 01:21:50 +0000
commita6cadd4611a2a83868f637c86ae7a45a6521cd14 (patch)
treef10f774e1080f66ea925d49a7bb5d1fcdb967b9a /app-eselect/eselect-lua
parentdev-python/fakeredis: Stabilize 1.4.5 ALLARCHES, #761454 (diff)
downloadgentoo-a6cadd4611a2a83868f637c86ae7a45a6521cd14.tar.gz
gentoo-a6cadd4611a2a83868f637c86ae7a45a6521cd14.tar.bz2
gentoo-a6cadd4611a2a83868f637c86ae7a45a6521cd14.zip
app-eselect/eselect-lua: only symlink the executables and the man pages
Looks like I owe mjo an apology - the reason I hadn't noticed the lua.pc problem he'd described was that I had already patched my eselect-lua to only symlink the binaries and the man pages, which patch I ended up having forgotten to commit during the bump to version 3. Signed-off-by: Marek Szuba <marecki@gentoo.org>
Diffstat (limited to 'app-eselect/eselect-lua')
-rw-r--r--app-eselect/eselect-lua/eselect-lua-4.ebuild (renamed from app-eselect/eselect-lua/eselect-lua-3.ebuild)0
-rw-r--r--app-eselect/eselect-lua/files/lua.eselect-4 (renamed from app-eselect/eselect-lua/files/lua.eselect-3)42
2 files changed, 0 insertions, 42 deletions
diff --git a/app-eselect/eselect-lua/eselect-lua-3.ebuild b/app-eselect/eselect-lua/eselect-lua-4.ebuild
index 3529ad194141..3529ad194141 100644
--- a/app-eselect/eselect-lua/eselect-lua-3.ebuild
+++ b/app-eselect/eselect-lua/eselect-lua-4.ebuild
diff --git a/app-eselect/eselect-lua/files/lua.eselect-3 b/app-eselect/eselect-lua/files/lua.eselect-4
index b46c226f8ee2..15364c039c87 100644
--- a/app-eselect/eselect-lua/files/lua.eselect-3
+++ b/app-eselect/eselect-lua/files/lua.eselect-4
@@ -11,13 +11,6 @@ HEADER_FILES="lauxlib.h luaconf.h lua.h lua.hpp lualib.h"
remove_symlinks() {
rm -f "${EROOT}"/usr/bin/{lua,luac} &>/dev/null
- for dir in $(get_libdirs) ; do
- rm -f "${EROOT}"${dir}/liblua.so &>/dev/null && \
- rm -f "${EROOT}"${dir}/pkgconfig/lua.pc &>/dev/null
- done
- for f in $HEADER_FILES ; do
- rm -f "${EROOT}"/usr/include/${f}
- done
rm -f "${EROOT}"/usr/share/man/man1/lua{,c}.1{,.*} &>/dev/null
}
@@ -32,45 +25,10 @@ set_symlinks() {
if [[ -f "${bin_prefix}"/luac${ver} ]]; then
ln -s luac${ver} $(_dup "${bin_prefix}"/luac)
fi
- for dir in $(get_libdirs) ; do
- if has 'jit*' ${ver}; then
- type -p lua${ver} &>/dev/null || die -q "It's something wrong with your lua${ver} installation: it's binary leads to broken symlink"
- local abi=$(lua${ver} -e 'print(_VERSION:match("%d.%d"))')
- local libname=libluajit-${abi}.so.${ver##jit-}
- test -f "${EROOT}/${dir}/${libname}" || die -q "Can't find libluajit for lua${ver} (lua abi: ${abi})"
- ln -s ${libname} $(_dup "${EROOT}/${dir}"/liblua.so)
- else
- ln -s liblua${ver}.so $(_dup "${EROOT}/${dir}"/liblua.so)
- fi
- ln -s lua${ver}.pc $(_dup "${EROOT}/${dir}"/pkgconfig/lua.pc)
- done
for manpage in "${EROOT}"/usr/share/man/man1/lua{,c}${ver}.1.* ; do
test -f ${manpage} &&
ln -s $(basename "${manpage}") $(_dup "${manpage//${ver}}")
done
- for header in $HEADER_FILES ; do
- local hdr;
- if has 'jit*' ${ver}; then
- type -p lua${ver} &>/dev/null || die -q "lua${ver} binary is missing (or leads to broken symlink)"
- local jit_v=$(lua${ver} -e 'print(jit.version:match("%d.%d"))')
- hdr=luajit-${jit_v}/${header};
- else
- hdr=lua${ver}/${header};
- fi
- test -f "${EROOT}/usr/include/${hdr}" || die -q "Missing header: ${header}"
- ln -s "${hdr}" $(_dup "${EROOT}"/usr/include/${header})
- done
-}
-
-get_libdirs() {
- local dir libdirs
- for dir in $(list_libdirs); do
- [[ -L ${EROOT}/usr/${dir} ]] && continue
- ls "${EROOT}"/usr/${dir}/liblua*.* > /dev/null 2>&1 || continue
-
- libdirs+=' '/usr/${dir}
- done
- echo ${libdirs:-/usr/lib}
}
find_targets() {