aboutsummaryrefslogtreecommitdiff
path: root/academic/solfege
diff options
context:
space:
mode:
authorB. Watson <urchlay@slackware.uk>2024-08-12 20:10:22 -0400
committerWilly Sudiarto Raharjo <willysr@slackbuilds.org>2024-08-17 18:14:15 +0700
commit30944c8a626f86cb73eaf5898e07e832a92a9926 (patch)
tree93289e036fdd90eb7bc891828cd1d309e530d29e /academic/solfege
parent8732442cc086ca8a6bc710d80cf7af239b4031a7 (diff)
academic/solfege: New maintainer.
Signed-off-by: B. Watson <urchlay@slackware.uk> Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'academic/solfege')
-rw-r--r--academic/solfege/README13
-rw-r--r--academic/solfege/doinst.sh4
-rw-r--r--academic/solfege/solfege.SlackBuild89
-rw-r--r--academic/solfege/solfege.info10
4 files changed, 60 insertions, 56 deletions
diff --git a/academic/solfege/README b/academic/solfege/README
index de9342734467..7b045c2d1c13 100644
--- a/academic/solfege/README
+++ b/academic/solfege/README
@@ -15,3 +15,16 @@ Features
* Remembering rhythmic patterns
* Theory: name intervals and scales
* Cadences
+
+Notes:
+
+1. If you don't hear any audio, you may have to edit the ~/.solfegerc
+ file and add "-Os -o hw:0" to the midi_player_options.
+ Mine looks like:
+
+ midi_player_options=-Os -o hw:0 -idqq %s
+
+ I don't see a way to make this change via the GUI.
+
+2. Although freepats is listed as required in the .info file, this
+ will work with eawpats instead.
diff --git a/academic/solfege/doinst.sh b/academic/solfege/doinst.sh
index e2c5000afb7c..38bba88fdaf4 100644
--- a/academic/solfege/doinst.sh
+++ b/academic/solfege/doinst.sh
@@ -1,14 +1,12 @@
config() {
NEW="$1"
OLD="$(dirname $NEW)/$(basename $NEW .new)"
- # If there's no config file by that name, mv it over:
+
if [ ! -r $OLD ]; then
mv $NEW $OLD
elif [ "$(cat $OLD | md5sum)" = "$(cat $NEW | md5sum)" ]; then
- # toss the redundant copy
rm $NEW
fi
- # Otherwise, we leave the .new copy for the admin to consider...
}
config etc/solfege.new
diff --git a/academic/solfege/solfege.SlackBuild b/academic/solfege/solfege.SlackBuild
index 4b69490ae430..d165a0458602 100644
--- a/academic/solfege/solfege.SlackBuild
+++ b/academic/solfege/solfege.SlackBuild
@@ -1,27 +1,39 @@
#!/bin/bash
# Slackware build script for solfege
-# Written by Phillip Warner <pc_warner@yahoo.com>
+# Originally written by Phillip Warner <email removed>.
+# Modified and now maintained by B. Watson <urchlay@slackware.uk>.
+
+# Original version of this script had no license. Modified version is
+# licensed under the WTFPL. See http://www.wtfpl.net/txt/copying/ for details.
+
+# 20240812 bkw: BUILD=2
+# - take over maintenance.
+# - don't generate broken help if lilypond is installed.
+# - ARCH=noarch (no compiled C/etc here).
+# - Add notes to README about what I had to do to get audio to
+# work, and about freepats vs. eawpats.
+
+# Note: 3.22.2 (from 2013) is still the latest stable. I tried 3.23.4,
+# the latest development release (from 2016), but it fails to start
+# up, with some Python stack trace stuff. Stable still works (though
+# there are some spurious error dialogs), so stick with it.
+
+# Looks like it's abandoned upstream.
+
+# If you're wondering why this can't just be dropped from the repo...
+# it could be. But there's nothing else in the repo that does the same
+# job (ear training and music theory exercises).
cd $(dirname $0) ; CWD=$(pwd)
PRGNAM=solfege
VERSION=${VERSION:-3.22.2}
-BUILD=${BUILD:-1}
+BUILD=${BUILD:-2}
TAG=${TAG:-_SBo}
PKGTYPE=${PKGTYPE:-tgz}
+ARCH=noarch
-if [ -z "$ARCH" ]; then
- case "$( uname -m )" in
- i?86) ARCH=i586 ;;
- arm*) ARCH=arm ;;
- *) ARCH=$( uname -m ) ;;
- esac
-fi
-
-# 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
@@ -31,34 +43,17 @@ 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 {} \+
# Fix Makefile.in so it does not require txt2man
# We will copy over our own man page
@@ -68,32 +63,30 @@ CFLAGS="$SLKCFLAGS" \
CPPFLAGS="$SLKCFLAGS" \
./configure \
--prefix=/usr \
- --libdir=/usr/lib${LIBDIRSUFFIX} \
--sysconfdir=/etc \
--disable-oss-sound \
--mandir=/usr/man
+# 20240812 bkw: solfege source will rebuild all the PNG images
+# in the help/ dir if lilypond is found, otherwise use shipped versions.
+# There are 2 reasons to want to avoid this: (1) to save build time,
+# and (2) because the generated files are actually incorrect!
+# There's no --disable-lilypond config option, but this works:
+sed -i '/LILYPOND/s,:=.*,:=,' Makefile
+
CFLAGS="$SLKCFLAGS" make
# We either had to install this or txt2man
-cat $CWD/solfege.1 > $TMP/$PRGNAM-$VERSION/solfege.1
+cat $CWD/solfege.1 > solfege.1
make install DESTDIR=$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
-
-( 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
-)
-
+gzip $PKG/usr/man/man*/*
mv $PKG/etc/solfege $PKG/etc/solfege.new
-mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
-cp -a AUTHORS COPYING README ChangeLog changelog FAQ INSTALL \
- $PKG/usr/doc/$PRGNAM-$VERSION
-cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
+PKGDOC=$PKG/usr/doc/$PRGNAM-$VERSION
+mkdir -p $PKGDOC
+cp -a AUTHORS COPYING README ChangeLog changelog FAQ $PKGDOC
+cat $CWD/$PRGNAM.SlackBuild > $PKGDOC/$PRGNAM.SlackBuild
mkdir -p $PKG/install
cat $CWD/slack-desc > $PKG/install/slack-desc
diff --git a/academic/solfege/solfege.info b/academic/solfege/solfege.info
index 557ac09b33b8..b1e46181bb3d 100644
--- a/academic/solfege/solfege.info
+++ b/academic/solfege/solfege.info
@@ -1,10 +1,10 @@
PRGNAM="solfege"
VERSION="3.22.2"
-HOMEPAGE="https://www.solfege.org/"
-DOWNLOAD="https://downloads.sourceforge.net/solfege/solfege-3.22.2.tar.gz"
-MD5SUM="ee9778d2b960b7afb375c5b3c3878222"
+HOMEPAGE="https://www.gnu.org/software/solfege/"
+DOWNLOAD="https://ftp.gnu.org/gnu/solfege/solfege-3.22.2.tar.xz"
+MD5SUM="e9d44fc0d50f62ab8518c942b6ad49e1"
DOWNLOAD_x86_64=""
MD5SUM_x86_64=""
REQUIRES="TiMidity++ freepats"
-MAINTAINER="Phillip Warner"
-EMAIL="pc_warner@yahoo.com"
+MAINTAINER="B. Watson"
+EMAIL="urchlay@slackware.uk"