From f1de5263ca80f507fa0b462913ce519b23cc91ef Mon Sep 17 00:00:00 2001 From: Matteo Bernardini Date: Wed, 12 Sep 2012 18:08:32 +0200 Subject: audio/hydrogen: Added a patch for raptor2 and another for gcc-4.7.x. Signed-off-by: Matteo Bernardini --- audio/hydrogen/README | 3 +- audio/hydrogen/hydrogen.SlackBuild | 6 ++-- audio/hydrogen/patches/gcc47.patch | 33 ++++++++++++++++++++++ .../patches/sconstruct-install-images.patch | 26 +++++++++++++++++ audio/hydrogen/patches/sconstruct-raptor2.patch | 11 ++++++++ audio/hydrogen/sconstruct-install-images.patch | 26 ----------------- 6 files changed, 76 insertions(+), 29 deletions(-) create mode 100644 audio/hydrogen/patches/gcc47.patch create mode 100644 audio/hydrogen/patches/sconstruct-install-images.patch create mode 100644 audio/hydrogen/patches/sconstruct-raptor2.patch delete mode 100644 audio/hydrogen/sconstruct-install-images.patch diff --git a/audio/hydrogen/README b/audio/hydrogen/README index 6f5f4b8494..7056665f28 100644 --- a/audio/hydrogen/README +++ b/audio/hydrogen/README @@ -2,5 +2,6 @@ Hydrogen is an advanced drum machine for GNU/Linux. It's main goal is to bring professional yet simple and intuitive pattern-based drum programming. -portaudio and portmidi are optional dependencies. +rubberband, portaudio and portmidi are optional +dependencies. PORTAUDIO=yes enables portmidi support. diff --git a/audio/hydrogen/hydrogen.SlackBuild b/audio/hydrogen/hydrogen.SlackBuild index 41b280b0e1..d01da9b775 100644 --- a/audio/hydrogen/hydrogen.SlackBuild +++ b/audio/hydrogen/hydrogen.SlackBuild @@ -27,7 +27,7 @@ PRGNAM=hydrogen VERSION=${VERSION:-0.9.5} -BUILD=${BUILD:-5} +BUILD=${BUILD:-6} TAG=${TAG:-_SBo} if [ -z "$ARCH" ]; then @@ -87,7 +87,9 @@ else EXTRACONF="$EXTRACONF jack=0" fi -patch --verbose -p1 < $CWD/sconstruct-install-images.patch +patch --verbose -p1 < $CWD/patches/sconstruct-install-images.patch +patch --verbose -p1 < $CWD/patches/sconstruct-raptor2.patch +patch --verbose -p1 < $CWD/patches/gcc47.patch QTDIR=$QT4DIR \ scons \ diff --git a/audio/hydrogen/patches/gcc47.patch b/audio/hydrogen/patches/gcc47.patch new file mode 100644 index 0000000000..41537bc647 --- /dev/null +++ b/audio/hydrogen/patches/gcc47.patch @@ -0,0 +1,33 @@ +diff -Naur hydrogen-0.9.5.orig/gui/src/MainForm.cpp hydrogen-0.9.5/gui/src/MainForm.cpp +--- hydrogen-0.9.5.orig/gui/src/MainForm.cpp 2011-02-08 10:15:04.000000000 +0100 ++++ hydrogen-0.9.5/gui/src/MainForm.cpp 2012-09-12 17:40:17.305970299 +0200 +@@ -20,6 +20,7 @@ + * + */ + #include "version.h" ++#include "unistd.h" + + + #include +diff -Naur hydrogen-0.9.5.orig/gui/src/SongEditor/SongEditor.cpp hydrogen-0.9.5/gui/src/SongEditor/SongEditor.cpp +--- hydrogen-0.9.5.orig/gui/src/SongEditor/SongEditor.cpp 2010-03-28 12:06:05.000000000 +0200 ++++ hydrogen-0.9.5/gui/src/SongEditor/SongEditor.cpp 2012-09-12 17:37:17.764043771 +0200 +@@ -23,6 +23,7 @@ + #include + #include + #include ++#include + + #include + #include +diff -Naur hydrogen-0.9.5.orig/libs/hydrogen/src/IO/portmidi_driver.cpp hydrogen-0.9.5/libs/hydrogen/src/IO/portmidi_driver.cpp +--- hydrogen-0.9.5.orig/libs/hydrogen/src/IO/portmidi_driver.cpp 2010-02-01 22:06:17.000000000 +0100 ++++ hydrogen-0.9.5/libs/hydrogen/src/IO/portmidi_driver.cpp 2012-09-12 17:45:38.426002346 +0200 +@@ -20,6 +20,7 @@ + * + */ + ++#include "unistd.h" + #include "PortMidiDriver.h" + + #include diff --git a/audio/hydrogen/patches/sconstruct-install-images.patch b/audio/hydrogen/patches/sconstruct-install-images.patch new file mode 100644 index 0000000000..4618d302c0 --- /dev/null +++ b/audio/hydrogen/patches/sconstruct-install-images.patch @@ -0,0 +1,26 @@ +diff -Naur a/Sconstruct b/Sconstruct +--- a/Sconstruct 2011-03-15 12:22:35.000000000 +0000 ++++ b/Sconstruct 2011-10-28 03:17:21.000000000 +0100 +@@ -214,12 +214,7 @@ + for file in files: + if file.endswith(".png"): + +- if env['prefix'].endswith("/"): +- dname = dir[2:] +- else: +- dname = dir[1:] +- +- env.Alias(target="install", source=env.Install(dir= env['DESTDIR'] + env['prefix'] + '/share/hydrogen/' + dname, source= dir + "/" + file)) ++ env.Alias(target="install", source=env.Install(dir= env['DESTDIR'] + env['prefix'] + '/share/hydrogen/img/gray' + file)) + + def get_hydrogen_gui( lib_hydrogen , opts ): + includes, cppflags, ldflags = get_platform_flags( opts ) +@@ -301,7 +296,7 @@ + env.Alias(target="install", source=env.Install(dir= env['DESTDIR'] + env['prefix'] + '/share/hydrogen/data', source="./data/img")) + + #add every img in ./data/img to the install list. +- os.path.walk("./data/img/",install_images,env) ++ os.path.walk("./data/img/gray",install_images,env) + + + env.Alias(target="install", source=env.Install(dir= env['DESTDIR'] + env['prefix'] + '/share/hydrogen/data', source="./data/drumkits")) diff --git a/audio/hydrogen/patches/sconstruct-raptor2.patch b/audio/hydrogen/patches/sconstruct-raptor2.patch new file mode 100644 index 0000000000..a5e374410f --- /dev/null +++ b/audio/hydrogen/patches/sconstruct-raptor2.patch @@ -0,0 +1,11 @@ +diff -Naur hydrogen-0.9.5.orig/Sconstruct hydrogen-0.9.5/Sconstruct +--- hydrogen-0.9.5.orig/Sconstruct 2011-03-15 13:22:35.000000000 +0100 ++++ hydrogen-0.9.5/Sconstruct 2012-09-12 17:32:56.865019039 +0200 +@@ -81,6 +81,7 @@ + if str(env['libarchive']) == "1": cppflags.append('-DLIBARCHIVE_SUPPORT') + + includes.append( './' ) ++ includes.append( '/usr/include/raptor2' ) + includes.append( 'gui/src/' ) + includes.append( '3rdparty/install/include' ) + diff --git a/audio/hydrogen/sconstruct-install-images.patch b/audio/hydrogen/sconstruct-install-images.patch deleted file mode 100644 index 4618d302c0..0000000000 --- a/audio/hydrogen/sconstruct-install-images.patch +++ /dev/null @@ -1,26 +0,0 @@ -diff -Naur a/Sconstruct b/Sconstruct ---- a/Sconstruct 2011-03-15 12:22:35.000000000 +0000 -+++ b/Sconstruct 2011-10-28 03:17:21.000000000 +0100 -@@ -214,12 +214,7 @@ - for file in files: - if file.endswith(".png"): - -- if env['prefix'].endswith("/"): -- dname = dir[2:] -- else: -- dname = dir[1:] -- -- env.Alias(target="install", source=env.Install(dir= env['DESTDIR'] + env['prefix'] + '/share/hydrogen/' + dname, source= dir + "/" + file)) -+ env.Alias(target="install", source=env.Install(dir= env['DESTDIR'] + env['prefix'] + '/share/hydrogen/img/gray' + file)) - - def get_hydrogen_gui( lib_hydrogen , opts ): - includes, cppflags, ldflags = get_platform_flags( opts ) -@@ -301,7 +296,7 @@ - env.Alias(target="install", source=env.Install(dir= env['DESTDIR'] + env['prefix'] + '/share/hydrogen/data', source="./data/img")) - - #add every img in ./data/img to the install list. -- os.path.walk("./data/img/",install_images,env) -+ os.path.walk("./data/img/gray",install_images,env) - - - env.Alias(target="install", source=env.Install(dir= env['DESTDIR'] + env['prefix'] + '/share/hydrogen/data', source="./data/drumkits")) -- cgit v1.2.3