diff options
Diffstat (limited to 'libraries/fltk/fltk.SlackBuild')
-rw-r--r-- | libraries/fltk/fltk.SlackBuild | 30 |
1 files changed, 22 insertions, 8 deletions
diff --git a/libraries/fltk/fltk.SlackBuild b/libraries/fltk/fltk.SlackBuild index 531aab5e77fbe..6bce4e2dc431b 100644 --- a/libraries/fltk/fltk.SlackBuild +++ b/libraries/fltk/fltk.SlackBuild @@ -2,7 +2,7 @@ # Slackware build script for fltk -# Copyright 2006 LukenShiro <lukenshiro@ngi.it> +# Copyright 2006-2009 LukenShiro <lukenshiro@ngi.it> # All rights reserved. # # Redistribution and use of this script, with or without modification, is @@ -22,14 +22,12 @@ # OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF # ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -# Exit on most errors -set -e - PRGNAM=fltk VERSION=1.1.9 ARCH=${ARCH:-i486} -BUILD=${BUILD:-1} +BUILD=${BUILD:-2} TAG=${TAG:-_SBo} + CWD=$(pwd) TMP=${TMP:-/tmp/SBo} PKG=$TMP/package-$PRGNAM @@ -39,10 +37,17 @@ DOCFILES="ANNOUNCEMENT CHANGES COPYING CREDITS README" if [ "$ARCH" = "i486" ]; then SLKCFLAGS="-O2 -march=i486 -mtune=i686" + LIBDIRSUFFIX="" elif [ "$ARCH" = "i686" ]; then SLKCFLAGS="-O2 -march=i686 -mtune=i686" + LIBDIRSUFFIX="" +elif [ "$ARCH" = "x86_64" ]; then + SLKCFLAGS="-O2 -fPIC" + LIBDIRSUFFIX="64" fi +set -e + rm -rf $PKG mkdir -p $TMP $PKG $OUTPUT cd $TMP @@ -52,27 +57,36 @@ cd $PRGNAM-$VERSION chown -R root:root . chmod -R u+w,go+r-w,a-s . +# Fix linking when --libdir=/usr/lib64 +sed -i \ + -e '/RANLIB/s:$(libdir)/\(.*LIBNAME)\):$(libdir)/`basename \1`:g' \ + src/Makefile || exit + # --docdir seems to be ignored CFLAGS="$SLKCFLAGS" \ CXXFLAGS="$SLKCFLAGS" \ ./configure \ --prefix=/usr \ --sysconfdir=/etc \ + --libdir=/usr/lib${LIBDIRSUFFIX} \ --localstatedir=/var \ --mandir=/usr/man \ --enable-gl \ + --enable-largefile \ --enable-shared \ --enable-threads \ --enable-xinerama \ --enable-xft \ --enable-xdbe - + make make install DESTDIR=$PKG ( 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 + 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 ) ( cd $PKG/usr/man |