aboutsummaryrefslogtreecommitdiff
path: root/libraries/lua-posix/lua-posix.SlackBuild
diff options
context:
space:
mode:
Diffstat (limited to 'libraries/lua-posix/lua-posix.SlackBuild')
-rw-r--r--libraries/lua-posix/lua-posix.SlackBuild30
1 files changed, 13 insertions, 17 deletions
diff --git a/libraries/lua-posix/lua-posix.SlackBuild b/libraries/lua-posix/lua-posix.SlackBuild
index dd351655c260d..e7bf79dccb5ea 100644
--- a/libraries/lua-posix/lua-posix.SlackBuild
+++ b/libraries/lua-posix/lua-posix.SlackBuild
@@ -1,7 +1,7 @@
#!/bin/sh
# Slackware build script for lua-posix
-# Copyright 2019 abooksigun <abooksigun09@gmail.com>
+# Copyright 2020 abooksigun <abooksigun09@gmail.com>
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
@@ -23,7 +23,7 @@
PRGNAM=lua-posix
SRCNAM=luaposix
-VERSION=${VERSION:-34.1.1}
+VERSION=${VERSION:-35.0}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
@@ -69,22 +69,18 @@ find -L . \
\( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \
-exec chmod 644 {} \;
-build-aux/luke all
-build-aux/luke PREFIX=$PKG/usr install
+LUAVER=${LUAVER:-"5.1 5.2 5.3 5.4 jit"}
-# lua 5.2 support.
-if $(lua5.2 -v &> /dev/null); then
- sed -i '1s|lua.*|lua5.2|' build-aux/luke
- build-aux/luke all
- build-aux/luke PREFIX=$PKG/usr install
-fi
-
-# lua 5.3 support
-if $(lua5.3 -v &> /dev/null); then
- sed -i '1s|lua.*|lua5.3|' build-aux/luke
- build-aux/luke all
- build-aux/luke PREFIX=$PKG/usr install
-fi
+for i in $LUAVER
+do
+ if [ $i != 5.1 ]; then ver=$i; fi
+ if $(lua$ver -v &> /dev/null)
+ then
+ sed -i "1s|lua.*|lua$ver|" build-aux/luke
+ build-aux/luke all
+ build-aux/luke PREFIX=$PKG/usr install
+ fi
+done
find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \
| cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true