diff options
Diffstat (limited to 'python/cssutils/cssutils.SlackBuild')
-rw-r--r-- | python/cssutils/cssutils.SlackBuild | 20 |
1 files changed, 12 insertions, 8 deletions
diff --git a/python/cssutils/cssutils.SlackBuild b/python/cssutils/cssutils.SlackBuild index 577dfae533..86766b7646 100644 --- a/python/cssutils/cssutils.SlackBuild +++ b/python/cssutils/cssutils.SlackBuild @@ -1,4 +1,4 @@ -#!/bin/sh +#!/bin/bash # Slackware build script for cssutils @@ -22,12 +22,14 @@ # OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF # ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +cd $(dirname $0) ; CWD=$(pwd) + PRGNAM=cssutils VERSION=${VERSION:-1.0.2} BUILD=${BUILD:-1} TAG=${TAG:-_SBo} +PKGTYPE=${PKGTYPE:-tgz} -CWD=$(pwd) TMP=${TMP:-/tmp/SBo} PKG=$TMP/package-$PRGNAM OUTPUT=${OUTPUT:-/tmp} @@ -40,6 +42,11 @@ if [ -z "$ARCH" ]; then esac fi +if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then + echo "$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE" + exit 0 +fi + set -e rm -rf $PKG @@ -63,11 +70,8 @@ for FILE in $(find . -type f -exec grep -Pl '\r$' {} \;); do done python setup.py install --root=$PKG - -if [ "${PYTHON3:-no}" == "yes" ]; then - rm -rf build - python3 setup.py install --root=$PKG -fi +rm -rf build +python3 setup.py install --root=$PKG find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \ | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true @@ -80,4 +84,4 @@ 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.${PKGTYPE:-tgz} +/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE |