aboutsummaryrefslogtreecommitdiff
path: root/libraries
diff options
context:
space:
mode:
authorB. Watson <urchlay@slackware.uk>2024-10-17 05:31:15 -0400
committerWilly Sudiarto Raharjo <willysr@slackbuilds.org>2024-11-02 19:28:31 +0700
commitd9213b65db635cadf438594ed585a3e15e078806 (patch)
tree589a9812248790c4f812897fbd39d273bb3d9fc2 /libraries
parentf5ad029c32e024812ede173bc4292c40dc739dbf (diff)
libraries/lua-lpeg: Build with lua 5.4.
Signed-off-by: B. Watson <urchlay@slackware.uk> Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'libraries')
-rw-r--r--libraries/lua-lpeg/README3
-rw-r--r--libraries/lua-lpeg/lua-lpeg.SlackBuild18
2 files changed, 10 insertions, 11 deletions
diff --git a/libraries/lua-lpeg/README b/libraries/lua-lpeg/README
index 2953c759c3ff..3b6d228b72b0 100644
--- a/libraries/lua-lpeg/README
+++ b/libraries/lua-lpeg/README
@@ -11,3 +11,6 @@ patterns allow much better documentation (as it is easy to comment
the code, to break complex definitions in smaller parts, etc.) and
are extensible, as we can define new functions to create and compose
patterns.
+
+Optional dependency: lua51 (autodetected). Install this if you need
+lua-lpeg support for lua-5.1 applications.
diff --git a/libraries/lua-lpeg/lua-lpeg.SlackBuild b/libraries/lua-lpeg/lua-lpeg.SlackBuild
index b6771369dfde..fa7a3c447705 100644
--- a/libraries/lua-lpeg/lua-lpeg.SlackBuild
+++ b/libraries/lua-lpeg/lua-lpeg.SlackBuild
@@ -24,12 +24,14 @@
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+# 20241017 bkw: Modified by SlackBuilds.org, BUILD=2: update for lua 5.4.
+
cd $(dirname $0) ; CWD=$(pwd)
PRGNAM=lua-lpeg
SRCNAM=lpeg
VERSION=${VERSION:-1.1.0}
-BUILD=${BUILD:-1}
+BUILD=${BUILD:-2}
TAG=${TAG:-_SBo}
PKGTYPE=${PKGTYPE:-tgz}
@@ -69,25 +71,19 @@ rm -rf $SRCNAM-$VERSION
tar xvf $CWD/$SRCNAM-$VERSION.tar.gz
cd $SRCNAM-$VERSION
chown -R root:root .
-find -L . \
- \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \
- -o -perm 511 \) -exec chmod 755 {} \; -o \
- \( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \
- -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \;
+find -L . -perm /111 -a \! -perm 755 -a -exec chmod 755 {} + -o \
+ \! -perm /111 -a \! -perm 644 -a -exec chmod 644 {} +
-for v in "" "5.2" "5.3"; do
+for v in "" "5.1"; do
_pkgconfigv=$(echo $v | tr --delete .)
if pkg-config --exists lua$_pkgconfigv; then
make LUADIR=/usr/include/lua${v}/
- install -m 0755 -D lpeg.so $PKG/$(pkg-config --variable INSTALL_CMOD lua$_pkgconfigv)/lpeg.so
+ install -s -m 0755 -D lpeg.so $PKG/$(pkg-config --variable INSTALL_CMOD lua$_pkgconfigv)/lpeg.so
install -m 0644 -D re.lua $PKG/$(pkg-config --variable INSTALL_LMOD lua$_pkgconfigv)/re.lua
make clean
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
-
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
cp -a HISTORY README.* $PKG/usr/doc/$PRGNAM-$VERSION
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild