CWD=`pwd` TMP=${TMP:-/tmp} if [ ! -d $TMP ]; then mkdir -p $TMP fi PKG=/$TMP/package-gimp rm -rf $PKG mkdir -p $PKG VERSION=2.2.17 ARCH=${ARCH:-i486} BUILD=1_slack10.2 if [ "$ARCH" = "i386" ]; then SLKCFLAGS="-O2 -march=i386 -mcpu=i686" elif [ "$ARCH" = "i486" ]; then SLKCFLAGS="-O2 -march=i486 -mcpu=i686" elif [ "$ARCH" = "s390" ]; then SLKCFLAGS="-O2" elif [ "$ARCH" = "x86_64" ]; then SLKCFLAGS="-O2" fi cd /$TMP rm -rf gimp-$VERSION tar xjvf $CWD/gimp-$VERSION.tar.bz2 cd gimp-$VERSION ## Brute force ugliness because some macro didn't substitute correctly: #zcat $CWD/gimp.desktop.in.in.diff.gz | patch -p1 --verbose || exit 1 chown -R root:root . find . -perm 666 -exec chmod 644 {} \; find . -perm 664 -exec chmod 644 {} \; CFLAGS="$SLKCFLAGS" \ ./configure \ --prefix=/usr \ --sysconfdir=/etc \ --localstatedir=/var/lib \ --mandir=/usr/man \ --disable-static \ $ARCH-slackware-linux make -j3 || exit 1 mkdir -p $PKG/usr/share/applications $PKG/usr/share/application-registry make install DESTDIR=$PKG gzip -9 $PKG/usr/man/man?/*.? rm -f $PKG/usr/man/man?/*.? ( cd $PKG/usr/man/man1 ln -sf gimptool-2.2.1.gz gimptool.1.gz ln -sf gimp-remote-2.2.1.gz gimp-remote.1.gz ln -sf gimp-2.2.1.gz gimp.1.gz cd $PKG/usr/man/man5 ln -sf gimprc-2.2.5.gz gimprc.5.gz ) mkdir -p $PKG/usr/doc/gimp-$VERSION cp -a \ AUTHORS COPYING HACKING INSTALL LICENSE MAINTAINERS NEWS PLUGIN_MAINTAINERS README* TODO.xml \ docs/Wilber* docs/keybindings.txt docs/quick_reference* \ $PKG/usr/doc/gimp-$VERSION ( 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 ) chown -R root.bin $PKG/usr/bin mkdir -p $PKG/install cat $CWD/slack-desc > $PKG/install/slack-desc cd $PKG makepkg -l y -c n ../gimp-$VERSION-$ARCH-$BUILD.tgz