summaryrefslogtreecommitdiffstats
path: root/system/rmw/rmw.SlackBuild
diff options
context:
space:
mode:
Diffstat (limited to 'system/rmw/rmw.SlackBuild')
-rw-r--r--system/rmw/rmw.SlackBuild54
1 files changed, 31 insertions, 23 deletions
diff --git a/system/rmw/rmw.SlackBuild b/system/rmw/rmw.SlackBuild
index 3bccaeea52..8b99c45f2c 100644
--- a/system/rmw/rmw.SlackBuild
+++ b/system/rmw/rmw.SlackBuild
@@ -1,8 +1,8 @@
-#!/bin/sh
+#!/bin/bash
#
# Slackware build script for rmw
#
-# Copyright 2019-2020 / Andy Alt / United States
+# Copyright 2019-2024 / Andy Alt / United States
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
@@ -22,10 +22,13 @@
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+cd $(dirname $0) ; CWD=$(pwd)
+
PRGNAM=rmw
-VERSION=${VERSION:-0.7.05}
+VERSION=${VERSION:-0.9.2}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
+PKGTYPE=${PKGTYPE:-tgz}
if [ -z "$ARCH" ]; then
case "$( uname -m )" in
@@ -35,7 +38,14 @@ if [ -z "$ARCH" ]; then
esac
fi
-CWD=$(pwd)
+# If the variable PRINT_PACKAGE_NAME is set, then this script will report what
+# the name of the created package would be, and then exit. This information
+# could be useful to other scripts.
+if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then
+ echo "$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE"
+ exit 0
+fi
+
TMP=${TMP:-/tmp/SBo}
PKG=$TMP/package-$PRGNAM
OUTPUT=${OUTPUT:-/tmp}
@@ -60,7 +70,7 @@ rm -rf $PKG
mkdir -p $TMP $PKG $OUTPUT
cd $TMP
rm -rf $PRGNAM-$VERSION
-tar xvf $CWD/$PRGNAM-$VERSION.tar.gz
+tar xvf $CWD/$PRGNAM-$VERSION.tar.xz
cd $PRGNAM-$VERSION
chown -R root:root .
find -L . \
@@ -69,23 +79,21 @@ find -L . \
\( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \
-o -perm 440 -o -perm 400 \) -exec chmod 644 {} \;
-CFLAGS="$SLKCFLAGS" \
-CXXFLAGS="$SLKCFLAGS" \
-./configure \
- --prefix=/usr \
- --mandir=/usr/man \
- --localedir=/usr/share/locale \
- --docdir=/usr/doc/$PRGNAM-$VERSION \
- --build=$ARCH-slackware-linux
-
-make
-make install-strip DESTDIR=$PKG
-
-#
-# rmw no longer searches for a system-wide config file
-#
-#mkdir -p $PKG/etc
-#cat rmwrc > $PKG/etc/rmwrc.new
+mkdir build
+cd build
+ CFLAGS="$SLKCFLAGS" \
+ CXXFLAGS="$SLKCFLAGS" \
+ meson .. \
+ --buildtype=release \
+ -Dstrip=true \
+ -Db_sanitize=none \
+ --mandir=/usr/man \
+ --prefix=/usr \
+ --localedir=/usr/share/locale \
+ -Ddocdir=/usr/doc/$PRGNAM-$VERSION
+ ninja
+ DESTDIR=$PKG ninja install
+cd ..
find $PKG/usr/man -type f -exec gzip -9 {} \;
for i in $( find $PKG/usr/man -type l ) ; do ln -s $( readlink $i ).gz $i.gz ; rm $i ; done
@@ -97,4 +105,4 @@ cat $CWD/slack-desc > $PKG/install/slack-desc
cat $CWD/doinst.sh > $PKG/install/doinst.sh
cd $PKG
-/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz}
+/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE