diff options
Diffstat (limited to 'audio/muse/muse.SlackBuild')
-rw-r--r-- | audio/muse/muse.SlackBuild | 47 |
1 files changed, 36 insertions, 11 deletions
diff --git a/audio/muse/muse.SlackBuild b/audio/muse/muse.SlackBuild index a8c4d3193e..2644f7dc5f 100644 --- a/audio/muse/muse.SlackBuild +++ b/audio/muse/muse.SlackBuild @@ -1,29 +1,44 @@ -#!/bin/sh +#!/bin/bash # Slackware build script for muse # Written by Felix Pfeifer pfeifer[dot]felix[at]googlemail[dot]com +# 20200416 bkw: Modified by the SlackBuilds.org project +# - updated for v3.1 +# - don't install docs in /usr/share/doc +# - add realtime capability support + +cd $(dirname $0) ; CWD=$(pwd) + PRGNAM=muse -VERSION=${VERSION:-3.0.2} +VERSION=${VERSION:-3.1.1} BUILD=${BUILD:-1} TAG=${TAG:-_SBo} +PKGTYPE=${PKGTYPE:-tgz} if [ -z "$ARCH" ]; then case "$( uname -m )" in - i?86) ARCH=i486 ;; + i?86) ARCH=i586 ;; arm*) ARCH=arm ;; *) ARCH=$( uname -m ) ;; esac fi -CWD=$(pwd) +# If the variable PRINT_PACKAGE_NAME is set, then this script will report what +# the name of the created package would be, and then exit. This information +# could be useful to other scripts. +if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then + echo "$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE" + exit 0 +fi + TMP=${TMP:-/tmp/SBo} PKG=$TMP/package-$PRGNAM OUTPUT=${OUTPUT:-/tmp} -if [ "$ARCH" = "i486" ]; then - SLKCFLAGS="-O2 -march=i486 -mtune=i686" +if [ "$ARCH" = "i586" ]; then + SLKCFLAGS="-O2 -march=i586 -mtune=i686" LIBDIRSUFFIX="" elif [ "$ARCH" = "i686" ]; then SLKCFLAGS="-O2 -march=i686 -mtune=i686" @@ -51,6 +66,9 @@ find -L . \ \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \ -exec chmod 644 {} \; +# Change the INSTALL_NAME or every path in the package is versioned +sed -e "s/muse-3.1/muse/" -i CMakeLists.txt + mkdir -p build cd build cmake \ @@ -71,15 +89,22 @@ mv $PKG/usr/share/man $PKG/usr/man find $PKG/usr/man -type f -exec gzip -9 {} \; for i in $( find $PKG/usr/man -type l ) ; do ln -s $( readlink $i ).gz $i.gz ; rm $i ; done -mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION -cp -a \ - AUTHORS COPYING ChangeLog NEWS README* SECURITY \ - $PKG/usr/doc/$PRGNAM-$VERSION +mkdir -p $PKG/usr/doc +mv $PKG/usr/share/doc/$PRGNAM $PKG/usr/doc/$PRGNAM-$VERSION +rmdir $PKG/usr/share/doc 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 +# Only add capability stuff if not disabled: +if [ "${SETCAP:-yes}" = "yes" ]; then + cat $CWD/setcap.sh >> $PKG/install/doinst.sh + # Only allow execution by audio group + chown root:audio $PKG/usr/bin/muse3 + chmod 0750 $PKG/usr/bin/muse3 +fi + 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 |