summaryrefslogtreecommitdiff
path: root/source/ap/powertop/powertop.SlackBuild
diff options
context:
space:
mode:
Diffstat (limited to 'source/ap/powertop/powertop.SlackBuild')
-rwxr-xr-xsource/ap/powertop/powertop.SlackBuild10
1 files changed, 7 insertions, 3 deletions
diff --git a/source/ap/powertop/powertop.SlackBuild b/source/ap/powertop/powertop.SlackBuild
index ceab1272..79857b07 100755
--- a/source/ap/powertop/powertop.SlackBuild
+++ b/source/ap/powertop/powertop.SlackBuild
@@ -1,6 +1,6 @@
#!/bin/bash
-# Copyright 2010, 2012, 2018 Patrick J. Volkerding, Sebeka, MN, USA
+# Copyright 2010, 2012, 2018, 2019 Patrick J. Volkerding, Sebeka, MN, USA
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
@@ -28,7 +28,7 @@
cd $(dirname $0) ; CWD=$(pwd)
PKGNAM=powertop
-VERSION=${VERSION:-$(echo $PKGNAM-*.tar.?z | rev | cut -f 3- -d . | cut -f 1 -d - | rev | tr -d 'v')}
+VERSION=${VERSION:-$(echo $PKGNAM-*.tar.?z | rev | cut -f 3- -d . | cut -f 1 -d - | rev)}
BUILD=${BUILD:-1}
# Automatically determine the architecture we're building on:
@@ -73,7 +73,7 @@ fi
cd $TMP
rm -rf ${PKGNAM}-${VERSION}
tar xvf $CWD/${PKGNAM}-v$VERSION.tar.?z || tar xvf $CWD/${PKGNAM}-$VERSION.tar.?z || exit 1
-cd ${PKGNAM}-v$VERSION || ${PKGNAM}-v$VERSION || exit 1
+cd ${PKGNAM}-$VERSION || exit 1
# Make sure ownerships and permissions are sane:
chown -R root:root .
@@ -83,6 +83,10 @@ find . \
\( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \
-exec chmod 644 {} \+
+if [ ! -r configure ]; then
+ NOCONFIGURE=1 ./autogen.sh
+fi
+
LDFLAGS=" -lresolv -lz " \
CFLAGS="$SLKCFLAGS" \
CXXFLAGS="$SLKCFLAGS" \