diff options
Diffstat (limited to 'audio/bristol/bristol.SlackBuild')
-rw-r--r-- | audio/bristol/bristol.SlackBuild | 49 |
1 files changed, 36 insertions, 13 deletions
diff --git a/audio/bristol/bristol.SlackBuild b/audio/bristol/bristol.SlackBuild index 568cc54b40..c4535e2859 100644 --- a/audio/bristol/bristol.SlackBuild +++ b/audio/bristol/bristol.SlackBuild @@ -1,19 +1,28 @@ -#!/bin/sh +#!/bin/bash # Slackware build script for bristol -# Written by Zbigniew Baniewski, <zbigniew.baniewski@gmail.com> -# Modified by B. Watson, yalhcru@gmail.com +# Written by Zbigniew Baniewski, <email removed> +# Modified by B. Watson, urchlay@slackware.uk # Licensed under the WTFPL. See http://www.wtfpl.net/txt/copying/ for details. +# 20211130 bkw: BUILD=2 +# - fix build on -current (again). +# - new-style icons. +# - get rid of .la files. +# - add launch-bristol script, so desktop users can choose a synth +# instead of only being able to use the B3. # 20170621 bkw: fix build on -current # 20141030 bkw: make VERSION respect environment +cd $(dirname $0) ; CWD=$(pwd) + PRGNAM=bristol VERSION=${VERSION:-0.60.11} -BUILD=${BUILD:-1} +BUILD=${BUILD:-2} TAG=${TAG:-_SBo} +PKGTYPE=${PKGTYPE:-tgz} if [ -z "$ARCH" ]; then case "$( uname -m )" in @@ -23,7 +32,11 @@ if [ -z "$ARCH" ]; then esac fi -CWD=$(pwd) +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} @@ -51,11 +64,8 @@ rm -rf $PRGNAM-$VERSION tar xvf $CWD/$PRGNAM-$VERSION.tar.gz cd $PRGNAM-$VERSION chown -R root:root . -find -L . \ - \( -perm 777 -o -perm 775 -o -perm 750 -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 {} \; +find -L . -perm /111 -a \! -perm 755 -a -exec chmod 755 {} \+ -o \ + \! -perm /111 -a \! -perm 644 -a -exec chmod 644 {} \+ # Patch from Debian to fix alsa-lib API breakage. patch -p1 < $CWD/03-rm_alsa-iatomic.h.patch @@ -66,6 +76,7 @@ sed -i "s,/usr/lib,/usr/lib$LIBDIRSUFFIX,g" \ sed -i "s,/usr/X11R6/lib,/usr/X11R6/lib$LIBDIRSUFFIX,g" \ configure Makefile.* brighton/Makefile.* libbrightonX11/Makefile.* +SLKCFLAGS+=" -fcommon" CFLAGS="$SLKCFLAGS" \ CXXFLAGS="$SLKCFLAGS" \ ./configure \ @@ -81,15 +92,27 @@ CXXFLAGS="$SLKCFLAGS" \ make make install-strip DESTDIR=$PKG +install -m0755 -oroot -groot $CWD/launch-bristol $PKG/usr/bin +rm -f $PKG/usr/lib*/*.la + # "install -m0644" rather than "cp -a" so the docs aren't executable! mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION install -m0644 AUTHORS COPYING COPYING.GPL NEWS README ChangeLog \ $PKG/usr/doc/$PRGNAM-$VERSION cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild -# icon rendered from bicon.svg +for px in 16 32 48 64 128; do + size=${px}x${px} + dir=$PKG/usr/share/icons/hicolor/$size/apps + mkdir -p $dir + convert -background none -resize $size bitmaps/bicon.svg $dir/$PRGNAM.png +done + +mkdir -p $PKG/usr/share/icons/hicolor/scalable/apps +cat bitmaps/bicon.svg > $PKG/usr/share/icons/hicolor/scalable/apps/$PRGNAM.svg + mkdir -p $PKG/usr/share/pixmaps -cat $CWD/$PRGNAM.png > $PKG/usr/share/pixmaps/$PRGNAM.png +ln -s ../icons/hicolor/48x48/apps/$PRGNAM.png $PKG/usr/share/pixmaps/$PRGNAM.png # .desktop written for this SlackBuild mkdir -p $PKG/usr/share/applications @@ -111,4 +134,4 @@ if [ "${SETCAP:-yes}" = "yes" ]; then 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 |