summaryrefslogtreecommitdiffstats
path: root/system/blake2/blake2.SlackBuild
diff options
context:
space:
mode:
Diffstat (limited to 'system/blake2/blake2.SlackBuild')
-rw-r--r--system/blake2/blake2.SlackBuild28
1 files changed, 21 insertions, 7 deletions
diff --git a/system/blake2/blake2.SlackBuild b/system/blake2/blake2.SlackBuild
index ee33615ac3..a586a1ed2a 100644
--- a/system/blake2/blake2.SlackBuild
+++ b/system/blake2/blake2.SlackBuild
@@ -1,4 +1,4 @@
-#!/bin/sh
+#!/bin/bash
# Slackware build script for blake2
@@ -22,11 +22,18 @@
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+# 20220301 bkw: Modified by SlackBuilds.org, BUILD=2:
+# - use SLKCFLAGS.
+# - install binary stripped.
+
+cd $(dirname $0) ; CWD=$(pwd)
+
PRGNAM=blake2
VERSION=${VERSION:-20160619}
SRCNAM=BLAKE2
-BUILD=${BUILD:-1}
+BUILD=${BUILD:-2}
TAG=${TAG:-_SBo}
+PKGTYPE=${PKGTYPE:-tgz}
if [ -z "$ARCH" ]; then
case "$( uname -m )" in
@@ -36,11 +43,16 @@ if [ -z "$ARCH" ]; then
esac
fi
-CWD=$(pwd)
+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}
+# 20220404 bkw: nothing here uses LIBDIRSUFFIX.
if [ "$ARCH" = "i586" ]; then
SLKCFLAGS="-O2 -march=i586 -mtune=i686"
LIBDIRSUFFIX=""
@@ -66,15 +78,17 @@ 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 \
+ -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 {} \;
+ -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \+
+[ "${FORCE_SLACK_CFLAGS:-no}" = "yes" ] && export CFLAGS="$SLKCFLAGS"
cd b2sum
make
+
mkdir -p $PKG/usr/bin
-install -m 0755 b2sum $PKG/usr/bin/b2sum
+install -s -m 0755 b2sum $PKG/usr/bin/b2sum
cd ..
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
@@ -85,4 +99,4 @@ mkdir -p $PKG/install
cat $CWD/slack-desc > $PKG/install/slack-desc
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