3 # Slackware build script for cpufrequtils
5 # Written by grissiom chaos.proton@gmail.com
8 VERSION
=${VERSION:-003}
15 PKG
=$TMP/package-
$PRGNAM
16 OUTPUT
=${OUTPUT:-/tmp}
19 #Don't use -j for this package
22 if [ "$ARCH" = "i486" ]; then
23 SLKCFLAGS
="-O2 -march=i486 -mtune=i686"
24 elif [ "$ARCH" = "i686" ]; then
25 SLKCFLAGS
="-O2 -march=i686 -mtune=i686"
26 elif [ "$ARCH" = "x86_64" ]; then
33 mkdir
-p $TMP $PKG $OUTPUT
35 rm -rf $PRGNAM-$VERSION
36 tar xvf
$CWD/$PRGNAM-$VERSION.
tar.gz
40 \
( -perm 777 -o -perm 775 -o -perm 711 -o -perm 555 -o -perm 511 \
) \
41 -exec chmod 755 {} \
; -o \
42 \
( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \
) \
46 make install DESTDIR
=$PKG
49 find . |
xargs file |
grep "executable" |
grep ELF | cut
-f 1 -d : |
xargs strip
--strip-unneeded 2> /dev
/null || true
50 find . |
xargs file |
grep "shared object" |
grep ELF | cut
-f 1 -d : |
xargs strip
--strip-unneeded 2> /dev
/null
54 find .
-type f
-exec gzip -9 {} \
;
55 for i
in $
( find .
-type l
) ; do ln -s $
( readlink
$i ).gz
$i.gz
; rm $i ; done
58 mkdir
-p $PKG/usr
/doc
/$PRGNAM-$VERSION
59 cp -a AUTHORS COPYING README
$PKG/usr
/doc
/$PRGNAM-$VERSION
60 cat $CWD/$PRGNAM.SlackBuild
> $PKG/usr
/doc
/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
63 cat $CWD/slack-desc
> $PKG/install
/slack-desc
66 /sbin
/makepkg
-l y
-c n
$OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.tgz