From 67e712770d707e78cc5949d896f3cd0df355a92b Mon Sep 17 00:00:00 2001 From: "B. Watson" Date: Mon, 15 Sep 2014 14:29:43 +0700 Subject: audio/sonic-visualiser: Updated for version 2.3. Signed-off-by: Willy Sudiarto Raharjo --- audio/sonic-visualiser/README | 17 ++++++++ audio/sonic-visualiser/doinst.sh | 7 +--- audio/sonic-visualiser/gcc47.diff | 20 ---------- audio/sonic-visualiser/libx11.diff | 11 ------ audio/sonic-visualiser/setcap.sh | 1 + audio/sonic-visualiser/sonic-visualiser.1 | 42 ++++++++++++++++++++ audio/sonic-visualiser/sonic-visualiser.SlackBuild | 46 +++++++++++++++------- audio/sonic-visualiser/sonic-visualiser.info | 8 ++-- audio/sonic-visualiser/sonic-visualiser.xml | 13 ++++++ 9 files changed, 110 insertions(+), 55 deletions(-) delete mode 100644 audio/sonic-visualiser/gcc47.diff delete mode 100644 audio/sonic-visualiser/libx11.diff create mode 100644 audio/sonic-visualiser/setcap.sh create mode 100644 audio/sonic-visualiser/sonic-visualiser.1 create mode 100644 audio/sonic-visualiser/sonic-visualiser.xml (limited to 'audio') diff --git a/audio/sonic-visualiser/README b/audio/sonic-visualiser/README index bb4e1a82d9..1f7737033c 100644 --- a/audio/sonic-visualiser/README +++ b/audio/sonic-visualiser/README @@ -1,4 +1,21 @@ +sonic-visualiser (audio file visualiser) + Sonic Visualiser is an application for viewing and analysing the contents of music audio files. The aim of Sonic Visualiser is to be the first program you reach for when want to study a musical recording rather than simply listen to it. + +Optional dependencies, detected at build time: + +liblo - allows remote control of sonic-visualiser via OSC. +portaudio - allows sonic-visualiser to run without a JACK server. +pulseaudio - as above. NOT TESTED, you're on your own with this. + +If you get compile errors that mention vamphostsdk, update vamp-plugin-sdk +to version 2.5 (or later, if it exists). + +This package uses POSIX filesystem capabilities to execute with +elevated privileges (required for realtime audio processing). This +may be considered a security/stability risk. Please read +http://www.slackbuilds.org/caps/ for more information. To disable +capabilities, pass SETCAP=no to the script. diff --git a/audio/sonic-visualiser/doinst.sh b/audio/sonic-visualiser/doinst.sh index 1f8ff67ded..9a8ded3c60 100644 --- a/audio/sonic-visualiser/doinst.sh +++ b/audio/sonic-visualiser/doinst.sh @@ -2,9 +2,6 @@ if [ -x /usr/bin/update-desktop-database ]; then /usr/bin/update-desktop-database -q usr/share/applications >/dev/null 2>&1 fi -if [ -e usr/share/icons/hicolor/icon-theme.cache ]; then - if [ -x /usr/bin/gtk-update-icon-cache ]; then - /usr/bin/gtk-update-icon-cache usr/share/icons/hicolor >/dev/null 2>&1 - fi +if [ -x /usr/bin/update-mime-database ]; then + /usr/bin/update-mime-database usr/share/mime >/dev/null 2>&1 fi - diff --git a/audio/sonic-visualiser/gcc47.diff b/audio/sonic-visualiser/gcc47.diff deleted file mode 100644 index e19d4fd28e..0000000000 --- a/audio/sonic-visualiser/gcc47.diff +++ /dev/null @@ -1,20 +0,0 @@ ---- sonic-visualiser-1.9/svcore/data/fileio/CodedAudioFileReader.cpp.gcc47 2011-10-10 22:37:09.000000000 +0700 -+++ sonic-visualiser-1.9/svcore/data/fileio/CodedAudioFileReader.cpp 2012-03-03 11:45:00.426572588 +0700 -@@ -22,6 +22,7 @@ - #include "base/Serialiser.h" - #include "base/Resampler.h" - -+#include - #include - #include - #include ---- sonic-visualiser-1.9/svcore/data/model/WritableWaveFileModel.cpp.gcc47 2011-10-10 22:37:09.000000000 +0700 -+++ sonic-visualiser-1.9/svcore/data/model/WritableWaveFileModel.cpp 2012-03-03 11:46:42.603157996 +0700 -@@ -26,6 +26,7 @@ - - #include - #include -+#include - - //#define DEBUG_WRITABLE_WAVE_FILE_MODEL 1 - diff --git a/audio/sonic-visualiser/libx11.diff b/audio/sonic-visualiser/libx11.diff deleted file mode 100644 index 2b37386e9b..0000000000 --- a/audio/sonic-visualiser/libx11.diff +++ /dev/null @@ -1,11 +0,0 @@ ---- sonic-visualiser-1.8/sonic-visualiser/sonic-visualiser.pro.implicit-dso 2011-04-08 17:56:20.000000000 +0200 -+++ sonic-visualiser-1.8/sonic-visualiser/sonic-visualiser.pro 2011-05-31 23:11:17.157498460 +0200 -@@ -23,7 +23,7 @@ - - contains(DEFINES, BUILD_STATIC):LIBS -= -ljack - --LIBS = -L../svapp -L../svgui -L../svcore -lsvapp -lsvgui -lsvcore $$LIBS -+LIBS = -L../svapp -L../svgui -L../svcore -lsvapp -lsvgui -lsvcore -lX11 $$LIBS - - PRE_TARGETDEPS += ../svapp/libsvapp.a \ - ../svgui/libsvgui.a \ diff --git a/audio/sonic-visualiser/setcap.sh b/audio/sonic-visualiser/setcap.sh new file mode 100644 index 0000000000..d736e2a106 --- /dev/null +++ b/audio/sonic-visualiser/setcap.sh @@ -0,0 +1 @@ +[ -x /sbin/setcap ] && /sbin/setcap cap_ipc_lock,cap_sys_nice=ep usr/bin/sonic-visualiser diff --git a/audio/sonic-visualiser/sonic-visualiser.1 b/audio/sonic-visualiser/sonic-visualiser.1 new file mode 100644 index 0000000000..f39f576533 --- /dev/null +++ b/audio/sonic-visualiser/sonic-visualiser.1 @@ -0,0 +1,42 @@ +.TH SONIC-VISUALISER 1 "November 17, 2010" +.SH NAME +sonic-visualiser \- viewing and analysing the contents of music audio files +.SH SYNOPSIS +.B sonic-visualiser +[\fIoptions\fR] [\fIfile\fR] ... +.SH DESCRIPTION +.B Sonic Visualiser +is a program for viewing and exploring audio data for semantic music +analysis and annotation. +.PP +.B Sonic Visualiser +could be of particular interest to musicologists, archivists, +signal-processing researchers and anyone else looking for a friendly way to +take a look at what lies inside the audio file. +.PP +After the installation, the application is available from the +.B Applications +menu. +.SH OPTIONS +.TP +\fB\-h\fR, \fB\-\-help\fR +show this help message and exit +.TP +\fB\-\-no\-audio\fR +Do not attempt to open an audio output device. +.TP +\fB\-\-no\-osc\fR +Do not provide an Open Sound Control port for remote control. +.PP +One or more Sonic Visualiser (.sv) and audio files may be provided. +.SH "SEE ALSO" +The complete documentation is available online at: +.br +.B +http://www.sonicvisualiser.org/documentation.html +.SH "AUTHOR" +sonic-visualiser was written by Chris Cannam +and others. +.PP +This manual page was written by Alessio Treglia , +for the Debian project (but may be used by others). diff --git a/audio/sonic-visualiser/sonic-visualiser.SlackBuild b/audio/sonic-visualiser/sonic-visualiser.SlackBuild index 26fd3269e8..e61e39d019 100644 --- a/audio/sonic-visualiser/sonic-visualiser.SlackBuild +++ b/audio/sonic-visualiser/sonic-visualiser.SlackBuild @@ -6,8 +6,15 @@ # Licensed under the WTFPL. See http://www.wtfpl.net/txt/copying/ for details. +# 20140913 bkw: +# - finally updated (from 1.9 to 2.3) +# - add man page +# - use png icon rather than svg +# - add MIME types for desktop integration +# - add realtime capabilities + PRGNAM=sonic-visualiser -VERSION=${VERSION:-1.9} +VERSION=${VERSION:-2.3} BUILD=${BUILD:-1} TAG=${TAG:-_SBo} @@ -53,11 +60,6 @@ find -L . \ \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \ -exec chmod 644 {} \; -# add some missing includes and libraries, patches from here: -# http://cvs.rpmfusion.org/viewvc/rpms/sonic-visualiser-freeworld/F-17/?root=free -patch -p1 < $CWD/libx11.diff -patch -p1 < $CWD/gcc47.diff - CFLAGS="$SLKCFLAGS" \ CXXFLAGS="$SLKCFLAGS" \ ./configure \ @@ -72,29 +74,43 @@ CXXFLAGS="$SLKCFLAGS" \ make -j1 # There is no 'make install', stick everything where it goes: -mkdir -p $PKG/usr/{bin,share/$PRGNAM/samples} -install -s -m0755 $PRGNAM/$PRGNAM $PKG/usr/bin/$PRGNAM -install -m0644 $PRGNAM/samples/* $PKG/usr/share/$PRGNAM/samples +mkdir -p $PKG/usr/share/$PRGNAM/samples $PKG/usr/bin +install -s -m0755 $PRGNAM $PKG/usr/bin/$PRGNAM +install -m0644 samples/* $PKG/usr/share/$PRGNAM/samples + +# man page borrowed from Debian +mkdir -p $PKG/usr/man/man1 +gzip -9c < $CWD/$PRGNAM.1 > $PKG/usr/man/man1/$PRGNAM.1.gz # desktop file fails to validate due to a couple of missing semicolons, # so fix it: mkdir -p $PKG/usr/share/applications sed '/^\(Categories\|MimeType\)/s,$,;,' \ - < $PRGNAM/$PRGNAM.desktop \ + < $PRGNAM.desktop \ > $PKG/usr/share/applications/$PRGNAM.desktop -mkdir -p $PKG/usr/share/icons/hicolor/scalable/apps -cp $PRGNAM/icons/sv-icon.svg $PKG/usr/share/icons/hicolor/scalable/apps +# define MIME types to associate *.sv and *.svl +mkdir -p $PKG/usr/share/mime/packages +cat $CWD/$PRGNAM.xml > $PKG/usr/share/mime/packages/$PRGNAM.xml + +mkdir -p $PKG/usr/share/pixmaps +cat icons/sv-128x128.png > $PKG/usr/share/pixmaps/sv-icon.png mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION -cp -a \ - $PRGNAM/{CHANGELOG,COPYING,README,README.OSC} \ - $PKG/usr/doc/$PRGNAM-$VERSION +cp -a CHANGELOG CITATION COPYING README* $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 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/$PRGNAM + chmod 0750 $PKG/usr/bin/$PRGNAM +fi + cd $PKG /sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz} diff --git a/audio/sonic-visualiser/sonic-visualiser.info b/audio/sonic-visualiser/sonic-visualiser.info index 180dcc13fe..e0615301ac 100644 --- a/audio/sonic-visualiser/sonic-visualiser.info +++ b/audio/sonic-visualiser/sonic-visualiser.info @@ -1,10 +1,10 @@ PRGNAM="sonic-visualiser" -VERSION="1.9" +VERSION="2.3" HOMEPAGE="http://sonicvisualiser.org/" -DOWNLOAD="http://code.soundsoftware.ac.uk/attachments/download/194/sonic-visualiser-1.9.tar.gz" -MD5SUM="a50037994d180c7b9b113fbde3131a8c" +DOWNLOAD="https://code.soundsoftware.ac.uk/attachments/download/918/sonic-visualiser-2.3.tar.gz" +MD5SUM="3c26444561dcff2ce87d1d3e36f178a3" DOWNLOAD_x86_64="" MD5SUM_x86_64="" -REQUIRES="jack-audio-connection-kit liblrdf rubberband" +REQUIRES="jack-audio-connection-kit liblrdf rubberband vamp-plugin-sdk sord" MAINTAINER="B. Watson" EMAIL="yalhcru@gmail.com" diff --git a/audio/sonic-visualiser/sonic-visualiser.xml b/audio/sonic-visualiser/sonic-visualiser.xml new file mode 100644 index 0000000000..9de7cf410b --- /dev/null +++ b/audio/sonic-visualiser/sonic-visualiser.xml @@ -0,0 +1,13 @@ + + + + Sonic Visualiser Session + + + + + Sonic Visualiser Layer + + + + -- cgit v1.2.3