diff options
Diffstat (limited to 'development/sloccount')
-rw-r--r-- | development/sloccount/sloccount.SlackBuild | 47 | ||||
-rw-r--r-- | development/sloccount/sloccount.info | 8 |
2 files changed, 28 insertions, 27 deletions
diff --git a/development/sloccount/sloccount.SlackBuild b/development/sloccount/sloccount.SlackBuild index 0ecf82bf0e96..7c6c105ebf04 100644 --- a/development/sloccount/sloccount.SlackBuild +++ b/development/sloccount/sloccount.SlackBuild @@ -1,14 +1,16 @@ #!/bin/sh # Slackware build script for SLOCcount -# Written by Aleksandar B. Samardzic <asamardzic@matf.bg.ac.yu> +# Written by Aleksandar B. Samardzic <asamardzic@math.rs> # Modified by the SlackBuilds.org project +# Updated for Slackware 13.0 by Heinz Wiesinger <pprkut@liwjatan.at> PRGNAM=sloccount VERSION=2.26 ARCH=${ARCH:-i486} BUILD=${BUILD:-1} TAG=${TAG:-_SBo} + CWD=$(pwd) TMP=${TMP:-/tmp/SBo} PKG=$TMP/package-$PRGNAM @@ -16,8 +18,13 @@ OUTPUT=${OUTPUT:-/tmp} if [ "$ARCH" = "i486" ]; then SLKCFLAGS="-O2 -march=i486 -mtune=i686" -elif [ "$ARCH" = "i686" ]; then + 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 @@ -31,35 +38,27 @@ cd $PRGNAM-$VERSION chown -R root:root . chmod -R u+w,go+r-w,a-s . -# Patching makefile; patch posted upstream, so following line should be -# (hopefully) deleted sometimes. -sed -i \ - -e '40s/$/ $(CFLAGS)/' \ - -e '73s/share/usr/' \ - -e '166a\\t$(INSTALL_A_DIR) $(INSTALL_DIR)' \ - -e '187s/ install_docs//' \ - makefile +make \ + CC="gcc -Wall $SLKCFLAGS" -CFLAGS="$SLKCFLAGS" CXXFLAGS="$SLCKCFLAGS" make -make install PREFIX=$PKG +# avoid make install error +mkdir -p $PKG/usr/bin -( 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 -) +make \ + CC="gcc -Wall $SLKCFLAGS" \ + PREFIX="$PKG/usr" \ + MAN_DIR="$PKG/usr/man" \ + DOC_DIR="$PKG/usr/doc/$PRGNAM-$VERSION" \ + install -( cd $PKG/usr/man - find . -type f -exec gzip -9 {} \; - for i in $(find . -type l) ; do ln -s $(readlink $i).gz $i.gz ; rm $i ; done -) +find $PKG | xargs file | grep -e "executable" -e "shared object" | grep ELF \ + | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true -mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION -cp -a COPYING ChangeLog README SOURCES TODO sloccount.html table.html \ - $PKG/usr/doc/$PRGNAM-$VERSION +cp -a COPYING SOURCES $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 cd $PKG -/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.tgz +/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz} diff --git a/development/sloccount/sloccount.info b/development/sloccount/sloccount.info index 66f0d489020a..1d75413bd57b 100644 --- a/development/sloccount/sloccount.info +++ b/development/sloccount/sloccount.info @@ -3,6 +3,8 @@ VERSION="2.26" HOMEPAGE="http://www.dwheeler.com/sloccount/" DOWNLOAD="http://www.dwheeler.com/sloccount/sloccount-2.26.tar.gz" MD5SUM="09abd6e2a016ebaf7552068a1dba1249" -MAINTAINER="Aleksandar B. Samardzic" -EMAIL="asamardzic@matf.bg.ac.yu" -APPROVED="rworkman" +DOWNLOAD_x86_64="" +MD5SUM_x86_64="" +MAINTAINER="Heinz Wiesinger" +EMAIL="pprkut@liwjatan.at" +APPROVED="Erik Hanson" |