aboutsummaryrefslogtreecommitdiff
path: root/libraries/libpng-legacy12/libpng-legacy12.SlackBuild
diff options
context:
space:
mode:
Diffstat (limited to 'libraries/libpng-legacy12/libpng-legacy12.SlackBuild')
-rw-r--r--libraries/libpng-legacy12/libpng-legacy12.SlackBuild24
1 files changed, 13 insertions, 11 deletions
diff --git a/libraries/libpng-legacy12/libpng-legacy12.SlackBuild b/libraries/libpng-legacy12/libpng-legacy12.SlackBuild
index b1f5469f874d..e05777da4b72 100644
--- a/libraries/libpng-legacy12/libpng-legacy12.SlackBuild
+++ b/libraries/libpng-legacy12/libpng-legacy12.SlackBuild
@@ -21,22 +21,24 @@ UPSTREAM_VER=${UPSTREAM_VER:-1.4.20}
UPSTREAM_BUILD=${UPSTREAM_BUILD:-1}
UPSTREAM_TAG=${UPSTREAM_TAG:-_slack14.1}
-# N.B. do NOT change i486 to i586 here, since this is a repack
-# of a Slack 14.1 package.
if [ -z "$ARCH" ]; then
case "$( uname -m )" in
- i?86) ARCH=i486 ;;
- arm*) ARCH=arm ;;
+ i?86) ARCH=i586 ;;
*) ARCH=$( uname -m ) ;;
esac
fi
-# We reset ARCH to i486 if it's i586 or i686, to match Slack 14.1's ARCH.
-case "$ARCH" in
- i?86) LIBDIRSUFFIX=""; ARCH=i486 ;;
- x86_64) LIBDIRSUFFIX="64" ;;
- *) echo "Warning: unrecognized ARCH '$ARCH'" ;;
-esac
+if [ "$ARCH" = "x86_64" ]; then
+ SRCARCH=$ARCH
+ LIBDIRSUFFIX="64"
+ # 2023-05-17 DW: allow any x86
+elif [[ $ARCH = i?86 ]]; then
+ SRCARCH=i486
+ LIBDIRSUFFIX=
+else
+ echo "$ARCH architecture is unsupported." >/dev/stderr
+ exit 1
+fi
if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then
echo "$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE"
@@ -47,7 +49,7 @@ TMP=${TMP:-/tmp/SBo}
PKG=$TMP/package-$PRGNAM
OUTPUT=${OUTPUT:-/tmp}
-UPSTREAM=libpng-$UPSTREAM_VER-$ARCH-$UPSTREAM_BUILD$UPSTREAM_TAG
+UPSTREAM=libpng-$UPSTREAM_VER-$SRCARCH-$UPSTREAM_BUILD$UPSTREAM_TAG
set -e