summaryrefslogtreecommitdiffstats
path: root/source.local/a/smartmontools/smartmontools.SlackBuild
diff options
context:
space:
mode:
Diffstat (limited to 'source.local/a/smartmontools/smartmontools.SlackBuild')
-rwxr-xr-xsource.local/a/smartmontools/smartmontools.SlackBuild36
1 files changed, 20 insertions, 16 deletions
diff --git a/source.local/a/smartmontools/smartmontools.SlackBuild b/source.local/a/smartmontools/smartmontools.SlackBuild
index 0daf246..5588d26 100755
--- a/source.local/a/smartmontools/smartmontools.SlackBuild
+++ b/source.local/a/smartmontools/smartmontools.SlackBuild
@@ -24,25 +24,29 @@
PKGNAM=smartmontools
-VERSION=${VERSION:-$(echo $PKGNAM-*.tar.?z* | rev | cut -f 3- -d . | cut -f 1 -d - | rev)}
+VERSION=${VERSION:-5.43}
BUILD=${BUILD:-1}
-# Automatically determine the architecture we're building on:
-MARCH=$( uname -m )
-if [ -z "$ARCH" ]; then
- case "$MARCH" in
- i?86) export ARCH=i486 ;;
- armv7hl) export ARCH=$MARCH ;;
- arm*) export ARCH=arm ;;
- # Unless $ARCH is already set, use uname -m for all other archs:
- *) export ARCH=$MARCH ;;
- esac
-fi
-
-if [ "$ARCH" = "x86_64" ]; then
- LIBDIRSUFFIX="64"
+if [ -e $CWD/machine.conf ]; then
+ . $CWD/machine.conf ]
+elif [ -e /etc/slackbuild/machine.conf ]; then
+ . /etc/slackbuild/machine.conf ]
else
- LIBDIRSUFFIX=""
+ # Automatically determine the architecture we're building on:
+ if [ -z "$ARCH" ]; then
+ case "$( uname -m )" in
+ i?86) export ARCH=i486 ;;
+ arm*) export ARCH=arm ;;
+ # Unless $ARCH is already set, use uname -m for all other archs:
+ *) export ARCH=$( uname -m ) ;;
+ esac
+ fi
+ # Set CFLAGS/CXXFLAGS and LIBDIRSUFFIX:
+ if [ "$ARCH" = "x86_64" ]; then
+ LIBDIRSUFFIX="64"
+ else
+ LIBDIRSUFFIX=""
+ fi
fi
case "$ARCH" in