diff options
-rw-r--r-- | system/hddtemp/hddtemp.SlackBuild | 23 | ||||
-rw-r--r-- | system/hddtemp/hddtemp.patch | 24 |
2 files changed, 35 insertions, 12 deletions
diff --git a/system/hddtemp/hddtemp.SlackBuild b/system/hddtemp/hddtemp.SlackBuild index 9095f02965..d6470bfc93 100644 --- a/system/hddtemp/hddtemp.SlackBuild +++ b/system/hddtemp/hddtemp.SlackBuild @@ -9,7 +9,7 @@ PRGNAM=hddtemp SRCVERSION=${SRCVERSION:-0.3-beta15} VERSION=$(echo $SRCVERSION | tr -d "-") -BUILD=${BUILD:-1} +BUILD=${BUILD:-2} TAG=${TAG:-_SBo} if [ -z "$ARCH" ]; then @@ -39,7 +39,7 @@ else LIBDIRSUFFIX="" fi -set -e +set -e rm -rf $PKG mkdir -p $TMP $PKG $OUTPUT @@ -49,10 +49,12 @@ tar xvf $CWD/$PRGNAM-$SRCVERSION.tar.bz2 cd $PRGNAM-$SRCVERSION 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 \ - \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \ - -exec chmod 644 {} \; + \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \ + -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 {} \; + +patch -p1 < $CWD/hddtemp.patch CFLAGS="$SLKCFLAGS" \ CXXFLAGS="$SLKCFLAGS" \ @@ -65,14 +67,11 @@ CXXFLAGS="$SLKCFLAGS" \ make make install DESTDIR=$PKG -find $PKG | xargs file | grep -e "executable" -e "shared object" | grep ELF \ +find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \ | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true -( cd $PKG/usr/man - find . -type f -exec gzip -9 {} \; - for i in $(find . -type l) ; do ln -s $(readlink $i).gz $i.gz ; rm $i ; done -) - +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 mkdir -p $PKG/etc/hddtemp cp -a $CWD/hddtemp.db $PKG/etc/hddtemp/hddtemp.db.new diff --git a/system/hddtemp/hddtemp.patch b/system/hddtemp/hddtemp.patch new file mode 100644 index 0000000000..904a674c93 --- /dev/null +++ b/system/hddtemp/hddtemp.patch @@ -0,0 +1,24 @@ +__USE_GNU needs to be in effect when including sys/ucontext.h, +and signal.h pulls it in in some setups. + +diff -up hddtemp-0.3-beta15/src/backtrace.c~ hddtemp-0.3-beta15/src/backtrace.c +--- hddtemp-0.3-beta15/src/backtrace.c~ 2006-04-19 05:38:14.000000000 +0300 ++++ hddtemp-0.3-beta15/src/backtrace.c 2010-02-14 21:59:47.000000000 +0200 +@@ -27,13 +27,12 @@ + #include <stdlib.h> + #include <unistd.h> + #include <linux/ptrace.h> ++#define __USE_GNU ++#include <ucontext.h> + #include <signal.h> + #include <bits/sigcontext.h> + #include <sys/param.h> + +-#define __USE_GNU +-#include <ucontext.h> +- + #define MAX_BTSIZE 64 + + void backtrace_handler(int n, siginfo_t *ist, void *extra) { + + |