diff options
Diffstat (limited to 'source/n/libgpg-error/libgpg-error.SlackBuild')
-rwxr-xr-x | source/n/libgpg-error/libgpg-error.SlackBuild | 41 |
1 files changed, 34 insertions, 7 deletions
diff --git a/source/n/libgpg-error/libgpg-error.SlackBuild b/source/n/libgpg-error/libgpg-error.SlackBuild index 73397d93e..c47d98138 100755 --- a/source/n/libgpg-error/libgpg-error.SlackBuild +++ b/source/n/libgpg-error/libgpg-error.SlackBuild @@ -1,7 +1,7 @@ #!/bin/sh # Copyright 2006, 2009 Robby Workman, Northport, AL, USA -# Copyright 2007, 2008, 2009, 2010 Patrick J. Volkerding, Sebeka, MN, USA +# Copyright 2007, 2008, 2009, 2010, 2015 Patrick J. Volkerding, Sebeka, MN, USA # All rights reserved. # # Redistribution and use of this script, with or without modification, is @@ -29,7 +29,7 @@ BUILD=${BUILD:-1} # Automatically determine the architecture we're building on: if [ -z "$ARCH" ]; then case "$( uname -m )" in - i?86) export ARCH=i486 ;; + i?86) export ARCH=i586 ;; arm*) export ARCH=arm ;; # Unless $ARCH is already set, use uname -m for all other archs: *) export ARCH=$( uname -m ) ;; @@ -42,8 +42,8 @@ CWD=$(pwd) TMP=${TMP:-/tmp} PKG=$TMP/package-$PKGNAM -if [ "$ARCH" = "i486" ]; then - SLKCFLAGS="-O2 -march=i486 -mtune=i686" +if [ "$ARCH" = "i586" ]; then + SLKCFLAGS="-O2 -march=i586 -mtune=i686" LIBDIRSUFFIX="" elif [ "$ARCH" = "s390" ]; then SLKCFLAGS="-O2" @@ -75,9 +75,10 @@ CXXFLAGS="$SLKCFLAGS" \ --prefix=/usr \ --libdir=/usr/lib${LIBDIRSUFFIX} \ --infodir=/usr/info \ + --mandir=/usr/man \ --docdir=/usr/doc/$PKGNAM-$VERSION \ --enable-shared=yes \ - --enable-static=yes \ + --enable-static=no \ --build=$ARCH-slackware-linux \ --host=$ARCH-slackware-linux @@ -94,8 +95,34 @@ mkdir -p $PKG/lib${LIBDIRSUFFIX} cp -a lib*.so.? ../../lib${LIBDIRSUFFIX} ) -find $PKG | xargs file | grep -e "executable" -e "shared object" \ - | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null +# Strip binaries: +( cd $PKG + find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null + find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null +) + +# Compress and if needed symlink the man pages: +if [ -d $PKG/usr/man ]; then + ( cd $PKG/usr/man + for manpagedir in $(find . -type d -name "man*") ; do + ( cd $manpagedir + for eachpage in $( find . -type l -maxdepth 1) ; do + ln -s $( readlink $eachpage ).gz $eachpage.gz + rm $eachpage + done + gzip -9 *.? + ) + done + ) +fi + +# Compress info files, if any: +if [ -d $PKG/usr/info ]; then + ( cd $PKG/usr/info + rm -f dir + gzip -9 * + ) +fi mkdir -p $PKG/usr/doc/$PKGNAM-$VERSION cp -a \ |