diff options
Diffstat (limited to 'office/kile/kile.SlackBuild')
-rw-r--r-- | office/kile/kile.SlackBuild | 56 |
1 files changed, 34 insertions, 22 deletions
diff --git a/office/kile/kile.SlackBuild b/office/kile/kile.SlackBuild index 93b832b1c5..8a56cf0535 100644 --- a/office/kile/kile.SlackBuild +++ b/office/kile/kile.SlackBuild @@ -9,21 +9,18 @@ ## did not write. Thanks. # Modified by the SlackBuilds.org project +# Modified by Michiel van Wessem <michiel@slackbuilds.org> to update +# to version 2.0 -# Verify script is being run by root user. -if [ "$(id -u)" != "0" ]; then - echo "This script must be run as root!" - exit -fi - -NAME=kile -VERSION=1.9.3 +PRGNAM=kile +VERSION=2.0 ARCH=${ARCH:-i486} BUILD=${BUILD:-1} TAG=${TAG:-_SBo} -CWD=`pwd` + +CWD=$(pwd) TMP=${TMP:-/tmp/SBo} -PKG=$TMP/package-$NAME +PKG=$TMP/package-$PRGNAM OUTPUT=${OUTPUT:-/tmp} if [ "$ARCH" = "i486" ]; then @@ -32,34 +29,49 @@ elif [ "$ARCH" = "i686" ]; then SLKCFLAGS="-O2 -march=i686 -mtune=i686" fi +set -e + rm -rf $PKG mkdir -p $TMP $PKG $OUTPUT cd $TMP || exit 1 -rm -rf $NAME-$VERSION -tar -jxvf $CWD/$NAME-$VERSION.tar.bz2 || exit 1 -cd $NAME-$VERSION || exit 1 -chown -R root:root . -chmod -R u+w,go+r-w,a-s . +rm -rf $PRGNAM-$VERSION +tar -jxvf $CWD/$PRGNAM-$VERSION.tar.bz2 || exit 1 +cd $PRGNAM-$VERSION || exit 1 +find . \ + \( -perm 777 -o -perm 775 -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 {} \; + +KDEPREF=$(kde-config --prefix) CFLAGS="$SLKCFLAGS" \ CXXFLAGS="$SLKCFLAGS" \ ./configure \ - --disable-debug \ + --prefix=$KDEPREF \ + --sysconfdir=/etc \ + --localstatedir=/var \ + --disable-debug \ || exit 1 make || exit 1 make install DESTDIR=$PKG || exit 1 -find $PKG | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null -find $PKG | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null +( 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 +) + +( cd $PKG/usr/ ; mv share/doc . ) -mkdir -p $PKG/usr/doc/$NAME-$VERSION -cp -a AUTHORS COPYING ChangeLog INSTALL README TODO doc/TODO \ - $PKG/usr/doc/$NAME-$VERSION +mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION +cp Building-with-cmake.txt AUTHORS COPYING ChangeLog README* TODO \ + $PKG/usr/doc/$PRGNAM-$VERSION +cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild mkdir -p $PKG/install cat $CWD/slack-desc > $PKG/install/slack-desc cat $CWD/doinst.sh > $PKG/install/doinst.sh cd $PKG -/sbin/makepkg -l y -c n -p $OUTPUT/$NAME-$VERSION-$ARCH-$BUILD$TAG.tgz +/sbin/makepkg -l y -c n -p $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.tgz |