aboutsummaryrefslogtreecommitdiff
path: root/libraries
diff options
context:
space:
mode:
authorabooksigun <abooksigun09@gmail.com>2021-01-15 21:56:58 +0000
committerDave Woodfall <dave@slackbuilds.org>2021-01-15 21:56:58 +0000
commit2c5ec6b27f46d437a7bdc9dd2030cccf14d7e01b (patch)
tree8e03480db618e249f2033043bb6d0ce1f2ff7b69 /libraries
parentd95c5d32486e4374add977cb8f051d69fd3fa91b (diff)
libraries/lua-readline: Updated for version 2.8.
Signed-off-by: Dave Woodfall <dave@slackbuilds.org>
Diffstat (limited to 'libraries')
-rw-r--r--libraries/lua-readline/lua-readline.SlackBuild41
-rw-r--r--libraries/lua-readline/lua-readline.info6
2 files changed, 19 insertions, 28 deletions
diff --git a/libraries/lua-readline/lua-readline.SlackBuild b/libraries/lua-readline/lua-readline.SlackBuild
index 35029fe75ff79..5aad2c4fc113c 100644
--- a/libraries/lua-readline/lua-readline.SlackBuild
+++ b/libraries/lua-readline/lua-readline.SlackBuild
@@ -1,7 +1,7 @@
#!/bin/sh
# Slackware build script for lua-readline
-# Copyright 2020 abooksigun <abooksigun09@gmail.com>
+# Copyright 2021 abooksigun <abooksigun09@gmail.com>
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
@@ -23,7 +23,7 @@
PRGNAM=lua-readline
SRCNAM=readline
-VERSION=${VERSION:-2.6}
+VERSION=${VERSION:-2.8}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
@@ -69,29 +69,20 @@ find -L . \
\( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \
-exec chmod 644 {} \;
-gcc $SLKCFLAGS -I /usr/include -c C-readline.c -o C-readline.o
-gcc $SLKCFLAGS -shared -o C-readline.so C-readline.o
-
-install -D -m 0755 C-readline.so $PKG/usr/lib$LIBDIRSUFFIX/lua/5.1/C-readline.so
-install -D -m 0644 readline.lua $PKG/usr/share/lua/5.1/readline.lua
-
-# lua 5.2 support.
-if $(lua5.2 -v &> /dev/null); then
- gcc $SLKCFLAGS -I /usr/include/lua5.2 -c C-readline.c -o C-readline.o
- gcc $SLKCFLAGS -shared -o C-readline.so.5.2 C-readline.o
-
- install -D -m 0755 C-readline.so.5.2 $PKG/usr/lib$LIBDIRSUFFIX/lua/5.2/C-readline.so
- install -D -m 0644 readline.lua $PKG/usr/share/lua/5.2/readline.lua
-fi
-
-# lua 5.3 support
-if $(lua5.3 -v &> /dev/null); then
- gcc $SLKCFLAGS -I /usr/include/lua5.3 -c C-readline.c -o C-readline.o
- gcc $SLKCFLAGS -shared -o C-readline.so.5.3 C-readline.o
-
- install -D -m 0755 C-readline.so.5.3 $PKG/usr/lib$LIBDIRSUFFIX/lua/5.3/C-readline.so
- install -D -m 0644 readline.lua $PKG/usr/share/lua/5.3/readline.lua
-fi
+LUAVERS="5.1 5.2 5.3 5.4"
+
+for luaver in $LUAVERS
+do
+ if [ $luaver != 5.1 ]; then version=$luaver dir=lua$version; fi
+ if $(lua$version -v &> /dev/null)
+ then
+ gcc $SLKCFLAGS -I /usr/include/$dir -c C-readline.c -o C-readline.o
+ gcc $SLKCFLAGS -shared -o C-readline.so.$luaver C-readline.o
+
+ install -D -m 0755 C-readline.so.$luaver $PKG/usr/lib$LIBDIRSUFFIX/lua/$luaver/C-readline.so
+ install -D -m 0644 readline.lua $PKG/usr/share/lua/$luaver/readline.lua
+ 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
diff --git a/libraries/lua-readline/lua-readline.info b/libraries/lua-readline/lua-readline.info
index 85284171aa327..d5fb7a2b7665e 100644
--- a/libraries/lua-readline/lua-readline.info
+++ b/libraries/lua-readline/lua-readline.info
@@ -1,8 +1,8 @@
PRGNAM="lua-readline"
-VERSION="2.6"
+VERSION="2.8"
HOMEPAGE="http://www.pjb.com.au/comp/lua/readline.html"
-DOWNLOAD="http://www.pjb.com.au/comp/lua/readline-2.6.tar.gz"
-MD5SUM="46222ce5904c3f2f4f1f9073fc5697ce"
+DOWNLOAD="http://www.pjb.com.au/comp/lua/readline-2.8.tar.gz"
+MD5SUM="fecb33ef12e0e67062146703ef3b78b7"
DOWNLOAD_x86_64=""
MD5SUM_x86_64=""
REQUIRES="lua-posix"