diff options
Diffstat (limited to 'system/lzop/lzop.SlackBuild')
-rw-r--r-- | system/lzop/lzop.SlackBuild | 39 |
1 files changed, 23 insertions, 16 deletions
diff --git a/system/lzop/lzop.SlackBuild b/system/lzop/lzop.SlackBuild index 9b79e00db1..f961122123 100644 --- a/system/lzop/lzop.SlackBuild +++ b/system/lzop/lzop.SlackBuild @@ -1,8 +1,9 @@ -#!/bin/sh +#!/bin/bash # Slackware build script for lzop # Copyright (c) 2011-2017 LEVAI Daniel +# Copyright (c) 2020 B. Watson # All rights reserved. # # * Redistribution and use in source and binary forms, with or without @@ -25,10 +26,15 @@ # OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF # ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +# 20200129 bkw: take over maintenance, simplify build, remove some cruft. + +cd $(dirname $0) ; CWD=$(pwd) + PRGNAM=lzop VERSION=${VERSION:-1.04} BUILD=${BUILD:-1} TAG=${TAG:-_SBo} +PKGTYPE=${PKGTYPE:-tgz} if [ -z "$ARCH" ]; then case "$( uname -m )" in @@ -38,7 +44,11 @@ if [ -z "$ARCH" ]; then esac fi -CWD=$(pwd) +if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then + echo "$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE" + exit 0 +fi + TMP=${TMP:-/tmp/SBo} PKG=$TMP/package-$PRGNAM OUTPUT=${OUTPUT:-/tmp} @@ -66,11 +76,8 @@ rm -rf $PRGNAM-$VERSION tar xvf $CWD/$PRGNAM-$VERSION.tar.gz cd $PRGNAM-$VERSION 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 {} \; +find -L . -perm /111 -a \! -perm 755 -a -exec chmod 755 {} \+ -o \ + \! -perm /111 -a \! -perm 644 -a -exec chmod 644 {} \+ CFLAGS="$SLKCFLAGS" \ ./configure \ @@ -80,20 +87,20 @@ CFLAGS="$SLKCFLAGS" \ --build=$ARCH-slackware-linux make -DESTDIR=$PKG make install - -strip --strip-unneeded $PKG/usr/bin/lzop +make install-strip DESTDIR=$PKG +gzip -9 $PKG/usr/man/man?/*.? -find $PKG/usr/man -type f -exec gzip -9 {} \; +# 20200129 bkw: We really don't need the docs in every possible format. We +# already got a man page in /usr/man, and .tex is the source format. Leave +# the HTML, plain text, and PostScript. +for ext in pod tex man; do + rm -f $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.$ext +done -mkdir -p -m 755 $PKG/usr/doc/$PRGNAM-$VERSION -cp AUTHORS COPYING INSTALL NEWS README THANKS \ - $PKG/usr/doc/$PRGNAM-$VERSION/ cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild -find $PKG/usr/doc -type f -exec chmod 0644 {} \; mkdir -p $PKG/install cat $CWD/slack-desc > $PKG/install/slack-desc cd $PKG -/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz} +/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE |