diff options
| author | Valery <valery@vslash.com> | 2026-03-06 20:55:38 +0000 |
|---|---|---|
| committer | Vladimir Druzenko <vvd@FreeBSD.org> | 2026-03-06 21:04:34 +0000 |
| commit | 94861f14b4187fc691357cc1f7ece432399ad1c7 (patch) | |
| tree | c52476979ae38fb72ad67d02b9f6bd40464159b9 | |
| parent | 9e5a13d91315147609f1755e579d374ef1074244 (diff) | |
audio/spiralsynthmodular: Fix "undefined symbol" errors at runtime
* Behavior *
- At runtime, for each synth plugin, we got:
dlerror() output:
/usr/local/lib/SpiralPlugins/AmpPlugin.so: Undefined symbol "_ZN10SpiralInfo6LOCALEE"
* Why *
- It seems this comes from the way newer compiler manage static
properties. (SSM is 25yo).
- This error has already been reported long times ago on Linux distro.
* Fix *
- A way to fix it without rewriting the wheel is to inline static
properties in the header.
While here improve port:
- Add LICENSE.
- Register dependiencies.
- Replace CPPFLAGS and LIBS with USES=localbase.
- Parametrize version in WRKSRC.
- Remove unnecessary REINPLACE_CMD in
SpiralSound/Plugins/LADSPAPlugin/Makefile.in.
- Merge STRIP_CMD.
PR: 293552
MFH: 2026Q1
(cherry picked from commit 8fedf8cd90ccc775af0f5e2a203f4c94f233bdd1)
| -rw-r--r-- | audio/spiralsynthmodular/Makefile | 24 | ||||
| -rw-r--r-- | audio/spiralsynthmodular/files/patch-SpiralSound_SpiralInfo.C | 64 | ||||
| -rw-r--r-- | audio/spiralsynthmodular/files/patch-SpiralSound_SpiralInfo.h | 70 |
3 files changed, 146 insertions, 12 deletions
diff --git a/audio/spiralsynthmodular/Makefile b/audio/spiralsynthmodular/Makefile index dfd4c5cb42a8..2dceb8fa932a 100644 --- a/audio/spiralsynthmodular/Makefile +++ b/audio/spiralsynthmodular/Makefile @@ -1,6 +1,6 @@ PORTNAME= spiralsynthmodular PORTVERSION= 0.2.2a -PORTREVISION= 13 +PORTREVISION= 14 CATEGORIES= audio MASTER_SITES= SF/spiralmodular/spiralmodular/${PORTVERSION}%20%28Latest%20Version%29 DISTNAME= spiralmodular-${PORTVERSION} @@ -9,19 +9,21 @@ MAINTAINER= ports@FreeBSD.org COMMENT= Object-oriented modular softsynth/sequencer/sampler WWW= https://www.pawfal.org/Software/SSM/ -BUILD_DEPENDS= ${LOCALBASE}/include/ladspa.h:audio/ladspa \ - jackd:audio/jack +LICENSE= GPLv2 +LICENSE_FILE= ${WRKSRC}/COPYING + +BUILD_DEPENDS= ${LOCALBASE}/include/ladspa.h:audio/ladspa LIB_DEPENDS= libfltk.so:x11-toolkits/fltk \ + libfontconfig.so:x11-fonts/fontconfig \ + libjack.so:audio/jack \ libsndfile.so:audio/libsndfile -USES= xorg -USE_XORG= x11 +USES= localbase xorg +USE_XORG= x11 xcursor xext xfixes xft xinerama xrender GNU_CONFIGURE= yes CONFIGURE_ENV= FLTK_CONFIG="${FLTK_CONFIG}" -CPPFLAGS+= -I${LOCALBASE}/include -LIBS+= -L${LOCALBASE}/lib -WRKSRC= ${WRKDIR}/spiralmodular-0.2.2 +WRKSRC= ${WRKDIR}/spiralmodular-${PORTVERSION:C|[a-z]+||} OPTIONS_DEFINE= OPTIMIZED_CFLAGS @@ -35,8 +37,6 @@ post-patch: s|^SpiralSound/Plugins/MidiPlugin/Makefile||; \ s|MidiPlugin||' \ ${CONFIGURE_WRKSRC}/${CONFIGURE_SCRIPT} - @${REINPLACE_CMD} -e 's|-I/usr/X11R6/include|-I${LOCALBASE}/include|' \ - ${WRKSRC}/SpiralSound/Plugins/LADSPAPlugin/Makefile.in @${REINPLACE_CMD} -e 's|O_SYNC|O_FSYNC|' \ ${WRKSRC}/SpiralSound/Midi.C @${REINPLACE_CMD} -e 's|True|true|; s|False|false|' \ @@ -58,7 +58,7 @@ post-patch: s|fl_file_chooser.H|Fl_File_Chooser.H|g' post-install: - ${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/${PORTNAME} - ${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/SpiralPlugins/*.so + ${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/${PORTNAME} \ + ${STAGEDIR}${PREFIX}/lib/SpiralPlugins/*.so .include <bsd.port.mk> diff --git a/audio/spiralsynthmodular/files/patch-SpiralSound_SpiralInfo.C b/audio/spiralsynthmodular/files/patch-SpiralSound_SpiralInfo.C new file mode 100644 index 000000000000..b02b173350a1 --- /dev/null +++ b/audio/spiralsynthmodular/files/patch-SpiralSound_SpiralInfo.C @@ -0,0 +1,64 @@ +--- SpiralSound/SpiralInfo.C.orig 2003-08-16 06:16:08 UTC ++++ SpiralSound/SpiralInfo.C +@@ -31,25 +31,25 @@ float RandFloat (float s, float e) { + + + +-string SpiralInfo::LOCALE = "EN"; +-int SpiralInfo::BUFSIZE = 512; +-int SpiralInfo::FRAGSIZE = 256; +-int SpiralInfo::FRAGCOUNT = 8; +-int SpiralInfo::SAMPLERATE = 44100; +-long SpiralInfo::MAXSAMPLE = 32767; +-float SpiralInfo::VALUECONV = 1.0f/MAXSAMPLE; +-bool SpiralInfo::WANTMIDI = false; +-int SpiralInfo::FILTERGRAN = 50; +-string SpiralInfo::OUTPUTFILE = "/dev/dsp"; +-string SpiralInfo::MIDIFILE = "/dev/midi"; +-int SpiralInfo::POLY = 1; +-bool SpiralInfo::USEPLUGINLIST = false; +-unsigned SpiralInfo::GUI_COLOUR = 179; +-unsigned SpiralInfo::SCOPE_BG_COLOUR = fl_rgb_color (20, 60, 20); +-unsigned SpiralInfo::SCOPE_FG_COLOUR = fl_rgb_color (100, 200, 100); +-unsigned SpiralInfo::SCOPE_SEL_COLOUR = FL_WHITE; +-unsigned SpiralInfo::SCOPE_IND_COLOUR = fl_rgb_color (203, 255, 0); +-unsigned SpiralInfo::SCOPE_MRK_COLOUR = fl_rgb_color (155, 155, 50); ++//string SpiralInfo::LOCALE = "EN"; ++//int SpiralInfo::BUFSIZE = 512; ++//int SpiralInfo::FRAGSIZE = 256; ++//int SpiralInfo::FRAGCOUNT = 8; ++//int SpiralInfo::SAMPLERATE = 44100; ++//long SpiralInfo::MAXSAMPLE = 32767; ++//float SpiralInfo::VALUECONV = 1.0f/MAXSAMPLE; ++//bool SpiralInfo::WANTMIDI = false; ++//int SpiralInfo::FILTERGRAN = 50; ++//string SpiralInfo::OUTPUTFILE = "/dev/dsp"; ++//string SpiralInfo::MIDIFILE = "/dev/midi"; ++//int SpiralInfo::POLY = 1; ++//bool SpiralInfo::USEPLUGINLIST = false; ++//unsigned SpiralInfo::GUI_COLOUR = 179; ++//unsigned SpiralInfo::SCOPE_BG_COLOUR = fl_rgb_color (20, 60, 20); ++//unsigned SpiralInfo::SCOPE_FG_COLOUR = fl_rgb_color (100, 200, 100); ++//unsigned SpiralInfo::SCOPE_SEL_COLOUR = FL_WHITE; ++//unsigned SpiralInfo::SCOPE_IND_COLOUR = fl_rgb_color (203, 255, 0); ++//unsigned SpiralInfo::SCOPE_MRK_COLOUR = fl_rgb_color (155, 155, 50); + + /*int SpiralInfo::GUICOL_Tool=179; + int SpiralInfo::GUICOL_Button=181; +@@ -57,11 +57,11 @@ int SpiralInfo::GUIDEVICE_Box=30;*/ + int SpiralInfo::GUICOL_Device=181; + int SpiralInfo::GUIDEVICE_Box=30;*/ + +-int SpiralInfo::GUICOL_Tool=48; +-int SpiralInfo::GUICOL_Button=42; +-int SpiralInfo::GUICOL_Canvas=50; +-int SpiralInfo::GUICOL_Device=52; +-int SpiralInfo::GUIDEVICE_Box=30; ++//int SpiralInfo::GUICOL_Tool=48; ++//int SpiralInfo::GUICOL_Button=42; ++//int SpiralInfo::GUICOL_Canvas=50; ++//int SpiralInfo::GUICOL_Device=52; ++//int SpiralInfo::GUIDEVICE_Box=30; + + vector<string> SpiralInfo::PLUGINVEC; + diff --git a/audio/spiralsynthmodular/files/patch-SpiralSound_SpiralInfo.h b/audio/spiralsynthmodular/files/patch-SpiralSound_SpiralInfo.h new file mode 100644 index 000000000000..c29b654c9ea1 --- /dev/null +++ b/audio/spiralsynthmodular/files/patch-SpiralSound_SpiralInfo.h @@ -0,0 +1,70 @@ +--- SpiralSound/SpiralInfo.h.orig 2003-07-22 22:08:41 UTC ++++ SpiralSound/SpiralInfo.h +@@ -23,6 +23,8 @@ + #include <string> + #include <vector> + #include <stdlib.h> ++#include "FL/fl_draw.H" ++#include "FL/fl_message.H" + #include "Sample.h" + + using namespace std; +@@ -40,34 +42,34 @@ class SpiralInfo { + void SavePrefs(); + static void Alert (string Text); + static void Log (string Text); +- static int BUFSIZE; +- static int FRAGSIZE; +- static int FRAGCOUNT; +- static int SAMPLERATE; +- static long MAXSAMPLE; +- static float VALUECONV; +- static bool WANTMIDI; +- static int FILTERGRAN; +- static string OUTPUTFILE; +- static string MIDIFILE; +- static bool USEPLUGINLIST; +- static int POLY; +- static string LOCALE; +- static unsigned GUI_COLOUR; +- static unsigned SCOPE_BG_COLOUR; +- static unsigned SCOPE_FG_COLOUR; +- static unsigned SCOPE_SEL_COLOUR; +- static unsigned SCOPE_IND_COLOUR; +- static unsigned SCOPE_MRK_COLOUR; ++ inline static int BUFSIZE=512; ++ inline static int FRAGSIZE=256; ++ inline static int FRAGCOUNT=8; ++ inline static int SAMPLERATE=44100; ++ inline static long MAXSAMPLE=32767; ++ inline static float VALUECONV=1.0f/MAXSAMPLE; ++ inline static bool WANTMIDI=false; ++ inline static int FILTERGRAN=50; ++ inline static string OUTPUTFILE="/dev/dsp"; ++ inline static string MIDIFILE="/dev/midi"; ++ inline static bool USEPLUGINLIST=false; ++ inline static int POLY=1; ++ inline static string LOCALE="EN"; ++ inline static unsigned GUI_COLOUR=179; ++ inline static unsigned SCOPE_BG_COLOUR=fl_rgb_color (20, 60, 20); ++ inline static unsigned SCOPE_FG_COLOUR=fl_rgb_color (100, 200, 100); ++ inline static unsigned SCOPE_SEL_COLOUR= FL_WHITE; ++ inline static unsigned SCOPE_IND_COLOUR= fl_rgb_color (203, 255, 0); ++ inline static unsigned SCOPE_MRK_COLOUR= fl_rgb_color (155, 155, 50); + static SpiralInfo* Get(); + void SetColours(); + static string PLUGIN_PATH; + static vector<string> PLUGINVEC; +- static int GUICOL_Tool; +- static int GUICOL_Button; +- static int GUICOL_Canvas; +- static int GUICOL_Device; +- static int GUIDEVICE_Box; ++ inline static int GUICOL_Tool=48; ++ inline static int GUICOL_Button=42; ++ inline static int GUICOL_Canvas=50; ++ inline static int GUICOL_Device=52; ++ inline static int GUIDEVICE_Box=30; + private: + string m_ResFileName; + int m_Version; |
