diff options
Diffstat (limited to 'audio/mididings')
-rw-r--r-- | audio/mididings/README | 2 | ||||
-rw-r--r-- | audio/mididings/git2tarxz.sh | 44 | ||||
-rw-r--r-- | audio/mididings/mididings.SlackBuild | 76 | ||||
-rw-r--r-- | audio/mididings/mididings.info | 10 |
4 files changed, 97 insertions, 35 deletions
diff --git a/audio/mididings/README b/audio/mididings/README index 1c312f798c..686f56d6df 100644 --- a/audio/mididings/README +++ b/audio/mididings/README @@ -8,3 +8,5 @@ on Linux. Features: - Modifying and converting MIDI events - Seamless switching between patches - MIDI event monitoring, running external commands + +For API documentation, see: http://dsacre.github.io/mididings/doc/ diff --git a/audio/mididings/git2tarxz.sh b/audio/mididings/git2tarxz.sh new file mode 100644 index 0000000000..0ec2387f83 --- /dev/null +++ b/audio/mididings/git2tarxz.sh @@ -0,0 +1,44 @@ +#!/bin/sh + +# Create source tarball from git repo, with generated version +# number. + +# Note that this script doesn't need to be run as root. It does +# need to be able to write to the current directory it's run from. + +# Takes one optional argument, which is the commit or tag to create +# a tarball of. With no arg, HEAD is used. + +PRGNAM=mididings +CLONE_URL=https://github.com/dsacre/mididings + +set -e + +GITDIR=$( mktemp -dt $PRGNAM.git.XXXXXX ) +rm -rf $GITDIR +git clone $CLONE_URL $GITDIR + +CWD="$( pwd )" +cd $GITDIR + +if [ "$1" != "" ]; then + git reset --hard "$1" || exit 1 +fi + +GIT_SHA=$( git rev-parse --short HEAD ) + +DATE=$( git log --date=format:%Y%m%d --format=%cd | head -1 ) + +VERSION=${DATE}_${GIT_SHA} + +rm -rf .git +find . -name .gitignore -print0 | xargs -0 rm -f + +cd "$CWD" +rm -rf $PRGNAM-$VERSION $PRGNAM-$VERSION.tar.xz +mv $GITDIR $PRGNAM-$VERSION +tar cvfJ $PRGNAM-$VERSION.tar.xz $PRGNAM-$VERSION + +echo +echo "Created tarball: $PRGNAM-$VERSION.tar.xz" +echo "VERSION=$VERSION" diff --git a/audio/mididings/mididings.SlackBuild b/audio/mididings/mididings.SlackBuild index 710b5dd19c..266247ef06 100644 --- a/audio/mididings/mididings.SlackBuild +++ b/audio/mididings/mididings.SlackBuild @@ -1,15 +1,39 @@ -#!/bin/sh +#!/bin/bash # Slackware build script for mididings -# Written by B. Watson (yalhcru@gmail.com) +# Written by B. Watson (urchlay@slackware.uk) # Licensed under the WTFPL. See http://www.wtfpl.net/txt/copying/ for details. +# 20211230 bkw: +# - updated for v20151117_bbec99a. +# - don't install doc/*, it's the *source* for the documentation. +# - do install doc/examples, it's just python code. + +# Notes to self: + +# The documentation for mididings requires an archaic version of +# Sphinx to build it. Modern Sphinx (4.2 on SBo) won't work. Rather +# than diving into that rabbit hole, I'm just adding a link to the +# docs on upstream's site. + +# Debian has man pages for mididings and livedings, but they're +# horribly outdated (2010). Don't include here. + +# Previous versions were built with libsmf, and could process MIDI +# files as-is. This version needs pysmf for that purpose, and we don't +# (yet) have it on SBo, so there's no MIDI file support. However, you +# could always use a MIDI player to play a file and connect its output +# to mididings, so it's not a show-stopper. + +cd $(dirname $0) ; CWD=$(pwd) + PRGNAM=mididings -VERSION=${VERSION:-20120419} -BUILD=${BUILD:-1} +VERSION=${VERSION:-20151117_bbec99a} +BUILD=${BUILD:-2} TAG=${TAG:-_SBo} +PKGTYPE=${PKGTYPE:-tgz} if [ -z "$ARCH" ]; then case "$( uname -m )" in @@ -19,51 +43,43 @@ 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} -if [ "$ARCH" = "i586" ]; then - SLKCFLAGS="-O2 -march=i586 -mtune=i686" - LIBDIRSUFFIX="" -elif [ "$ARCH" = "i686" ]; then - SLKCFLAGS="-O2 -march=i686 -mtune=i686" - LIBDIRSUFFIX="" -elif [ "$ARCH" = "x86_64" ]; then - SLKCFLAGS="-O2 -fPIC" - LIBDIRSUFFIX="64" -else - SLKCFLAGS="-O2" - LIBDIRSUFFIX="" -fi - set -e rm -rf $PKG mkdir -p $TMP $PKG $OUTPUT cd $TMP rm -rf $PRGNAM-$VERSION -tar xvf $CWD/$PRGNAM-$VERSION.tar.gz +tar xvf $CWD/$PRGNAM-$VERSION.tar.xz 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 {} \+ + +# "async" is a keyword in recent pythons, code uses it as a variable name. +sed -i 's,async,is_async,g' $PRGNAM/units/call.py + +# make it look for e.g. -lboost_python39.so (not -lboost_python-py39.so). +sed -i '/^boost_python_suffixes/s,-py,,' setup.py -python setup.py install --root=$PKG --enable-smf +python3 setup.py install --root=$PKG -find $PKG | xargs file | grep -e "executable" -e "shared object" | grep ELF \ - | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true +strip $PKG/usr/lib*/py*/site-*/*.so mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION -cp -a COPYING NEWS PKG-INFO README doc/* $PKG/usr/doc/$PRGNAM-$VERSION +cp -a COPYING NEWS README doc/examples $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.${PKGTYPE:-tgz} +/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE diff --git a/audio/mididings/mididings.info b/audio/mididings/mididings.info index 390a629600..e7be59f6ff 100644 --- a/audio/mididings/mididings.info +++ b/audio/mididings/mididings.info @@ -1,10 +1,10 @@ PRGNAM="mididings" -VERSION="20120419" +VERSION="20151117_bbec99a" HOMEPAGE="http://das.nasophon.de/mididings/" -DOWNLOAD="http://das.nasophon.de/download/mididings-20120419.tar.gz" -MD5SUM="5d4b642a1b76817b742f01cda60c0a3f" +DOWNLOAD="https://slackware.uk/~urchlay/src/mididings-20151117_bbec99a.tar.xz" +MD5SUM="5e5c8f28ded3ac58f7d0913ef091f6a8" DOWNLOAD_x86_64="" MD5SUM_x86_64="" -REQUIRES="jack libsmf pyliblo decorator" +REQUIRES="jack pyliblo python3-decorator" MAINTAINER="B. Watson" -EMAIL="yalhcru@gmail.com" +EMAIL="urchlay@slackware.uk" |