aboutsummaryrefslogtreecommitdiff
path: root/audio/surge-synthesizer-lv2
diff options
context:
space:
mode:
authorYuri Victorovich <yuri@FreeBSD.org>2020-04-15 19:44:34 +0000
committerYuri Victorovich <yuri@FreeBSD.org>2020-04-15 19:44:34 +0000
commit71378f9c3946b1dce479f929c049db036f5c3229 (patch)
treed2809ae87d3ee4031d1a3ceabf3778d311ccc821 /audio/surge-synthesizer-lv2
parent2dc2bf2cb43f54f6b4718b271e2170f849ebf8cf (diff)
downloadports-71378f9c3946b1dce479f929c049db036f5c3229.tar.gz
ports-71378f9c3946b1dce479f929c049db036f5c3229.zip
Notes
Diffstat (limited to 'audio/surge-synthesizer-lv2')
-rw-r--r--audio/surge-synthesizer-lv2/Makefile55
-rw-r--r--audio/surge-synthesizer-lv2/distinfo17
-rw-r--r--audio/surge-synthesizer-lv2/files/patch-CMakeLists.txt27
-rw-r--r--audio/surge-synthesizer-lv2/files/patch-scripts_linux_package-vst3.sh10
-rw-r--r--audio/surge-synthesizer-lv2/files/patch-src_linux_UserInteractionsLinux.cpp10
-rw-r--r--audio/surge-synthesizer-lv2/files/patch-vst3sdk_cmake_modules_PlatformToolset.cmake11
-rw-r--r--audio/surge-synthesizer-lv2/files/patch-vst3sdk_pluginterfaces_base_fplatform.h19
-rw-r--r--audio/surge-synthesizer-lv2/files/patch-vst3sdk_pluginterfaces_base_funknown.cpp29
-rw-r--r--audio/surge-synthesizer-lv2/files/patch-vstgui.surge_vstgui_lib_vstguibase.h11
-rw-r--r--audio/surge-synthesizer-lv2/pkg-descr6
10 files changed, 195 insertions, 0 deletions
diff --git a/audio/surge-synthesizer-lv2/Makefile b/audio/surge-synthesizer-lv2/Makefile
new file mode 100644
index 000000000000..253e8b37a263
--- /dev/null
+++ b/audio/surge-synthesizer-lv2/Makefile
@@ -0,0 +1,55 @@
+# $FreeBSD$
+
+PORTNAME= surge-synthesizer
+DISTVERSIONPREFIX= release_
+DISTVERSION= 1.6.6-58
+DISTVERSIONSUFFIX= -g3dbd1be
+CATEGORIES= audio
+PKGNAMESUFFIX= -lv2
+
+MAINTAINER= yuri@FreeBSD.org
+COMMENT= Surge Synthesizer LV2 and VST plug-in
+
+LICENSE= GPLv3
+LICENSE_FILE= ${WRKSRC}/LICENSE
+
+BUILD_DEPENDS= lv2>0:audio/lv2 \
+ ${LOCALBASE}/include/nanosvg.h:graphics/nanosvg \
+ xcb-util-keysyms>0:x11/xcb-util-keysyms
+LIB_DEPENDS= libxkbcommon.so:x11/libxkbcommon \
+ libxcb-cursor.so:x11/xcb-util-cursor \
+ libxcb-util.so:x11/xcb-util
+
+USES= cmake compiler:c++17-lang gnome pkgconfig python:build shebangfix xorg
+SHEBANG_FILES= build-linux.sh
+USE_GNOME= cairo
+USE_XORG= xcb
+USE_GITHUB= yes
+GH_PROJECT= surge
+GH_TUPLE= \
+ surge-synthesizer:vst3sdk:10287bc37bbb34324b8097369e2ec4eb73a51d65:surge_synthesizer_vst3sdk/vst3sdk \
+ surge-synthesizer:vstgui:313faee9db026b1d6254c91d8650e7da58e005a5:surge_synthesizer_vstgui/vstgui.surge \
+ craigsapp:midifile:41e450bcd5ba1c0419f69664944434b0abf9d7ba:craigsapp_midifile/libs/midifile \
+ steinbergmedia:vst3_base:37dbdb6ff7af29e518877f57f14050594164a0d6:steinbergmedia_vst3_base/vst3sdk/base \
+ steinbergmedia:vst3_cmake:f7ae22417019aa355de6f7ec46ecf890d3c2a76f:steinbergmedia_vst3_cmake/vst3sdk/cmake \
+ steinbergmedia:vst3_pluginterfaces:6c6bb30d18c3d5a553e55aa74afc5d146571be0a:steinbergmedia_vst3_pluginterfaces/vst3sdk/pluginterfaces \
+ steinbergmedia:vst3_public_sdk:ced72c00d5c1365a4cca16cdbfb871be2496848b:steinbergmedia_vst3_public_sdk/vst3sdk/public.sdk \
+
+BINARY_ALIAS= python=${PYTHON_CMD}
+
+PLIST_FILES= lib/lv2/Surge.lv2/Surge.so \
+ lib/lv2/Surge.lv2/Surge_dsp.ttl \
+ lib/lv2/Surge.lv2/Surge_ui.ttl \
+ lib/lv2/Surge.lv2/manifest.ttl \
+ lib/vst/Surge.so
+
+do-install:
+ # LV2 plugin
+ ${MKDIR} ${STAGEDIR}${PREFIX}/lib/lv2
+ cd ${WRKSRC}/products && ${COPYTREE_SHARE} Surge.lv2 ${STAGEDIR}${PREFIX}/lib/lv2
+ ${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/lv2/Surge.lv2/Surge.so
+ # VST plugin
+ ${MKDIR} ${STAGEDIR}${PREFIX}/lib/vst
+ ${INSTALL_LIB} ${WRKSRC}/products/Surge.vst3/Contents/*/Surge.so ${STAGEDIR}${PREFIX}/lib/vst
+
+.include <bsd.port.mk>
diff --git a/audio/surge-synthesizer-lv2/distinfo b/audio/surge-synthesizer-lv2/distinfo
new file mode 100644
index 000000000000..55069876c04c
--- /dev/null
+++ b/audio/surge-synthesizer-lv2/distinfo
@@ -0,0 +1,17 @@
+TIMESTAMP = 1586972142
+SHA256 (surge-synthesizer-surge-release_1.6.6-58-g3dbd1be_GH0.tar.gz) = bcd54076adac3ae1d3d13e9b068b1cece0b262b0c45323fed52b69da2ee53cd9
+SIZE (surge-synthesizer-surge-release_1.6.6-58-g3dbd1be_GH0.tar.gz) = 79161919
+SHA256 (surge-synthesizer-vst3sdk-10287bc37bbb34324b8097369e2ec4eb73a51d65_GH0.tar.gz) = b1eb4d7a5fc714ebb058c77bf7250254ee310a6ffd2b77ef702a12ab4bf9ec10
+SIZE (surge-synthesizer-vst3sdk-10287bc37bbb34324b8097369e2ec4eb73a51d65_GH0.tar.gz) = 266390
+SHA256 (surge-synthesizer-vstgui-313faee9db026b1d6254c91d8650e7da58e005a5_GH0.tar.gz) = 797051fe2e28b096c9a890f10eca44440eae4da58b83227595db5bc871c1e57d
+SIZE (surge-synthesizer-vstgui-313faee9db026b1d6254c91d8650e7da58e005a5_GH0.tar.gz) = 1914445
+SHA256 (craigsapp-midifile-41e450bcd5ba1c0419f69664944434b0abf9d7ba_GH0.tar.gz) = 6723c1be730dd73ba1c2903e59a044d26b702c07bec6f567d86f1ee77ab8607e
+SIZE (craigsapp-midifile-41e450bcd5ba1c0419f69664944434b0abf9d7ba_GH0.tar.gz) = 147607
+SHA256 (steinbergmedia-vst3_base-37dbdb6ff7af29e518877f57f14050594164a0d6_GH0.tar.gz) = 1826460d36c2c6a461d29b1b8db9a142c5a621038d15e24812c46343a26dee7a
+SIZE (steinbergmedia-vst3_base-37dbdb6ff7af29e518877f57f14050594164a0d6_GH0.tar.gz) = 61067
+SHA256 (steinbergmedia-vst3_cmake-f7ae22417019aa355de6f7ec46ecf890d3c2a76f_GH0.tar.gz) = bdfba137d724c69a4ee0852a82a94008feca0d4b1e157ce8559321cdebdb0e86
+SIZE (steinbergmedia-vst3_cmake-f7ae22417019aa355de6f7ec46ecf890d3c2a76f_GH0.tar.gz) = 13355
+SHA256 (steinbergmedia-vst3_pluginterfaces-6c6bb30d18c3d5a553e55aa74afc5d146571be0a_GH0.tar.gz) = 67f97965c5080e8031192504d90df43b3225b71abf678283569b1f30d2ece3f3
+SIZE (steinbergmedia-vst3_pluginterfaces-6c6bb30d18c3d5a553e55aa74afc5d146571be0a_GH0.tar.gz) = 84830
+SHA256 (steinbergmedia-vst3_public_sdk-ced72c00d5c1365a4cca16cdbfb871be2496848b_GH0.tar.gz) = 38f589ce1a430cc3d93671e28337968b6d8998eda83216943b5546136edd3e47
+SIZE (steinbergmedia-vst3_public_sdk-ced72c00d5c1365a4cca16cdbfb871be2496848b_GH0.tar.gz) = 5861222
diff --git a/audio/surge-synthesizer-lv2/files/patch-CMakeLists.txt b/audio/surge-synthesizer-lv2/files/patch-CMakeLists.txt
new file mode 100644
index 000000000000..523c6a224db3
--- /dev/null
+++ b/audio/surge-synthesizer-lv2/files/patch-CMakeLists.txt
@@ -0,0 +1,27 @@
+--- CMakeLists.txt.orig 2020-04-15 15:01:57 UTC
++++ CMakeLists.txt
+@@ -334,7 +334,6 @@ elseif( UNIX AND NOT APPLE )
+
+ set(OS_LINK_LIBRARIES
+ pthread
+- stdc++fs
+ gcc_s
+ gcc
+ dl
+@@ -689,7 +688,7 @@ if( BUILD_LV2 )
+ WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
+ COMMAND echo "Packaging up LV2 component"
+ COMMAND mkdir -p products/Surge.lv2
+- COMMAND cp build/libsurge-lv2.so products/Surge.lv2/Surge.so
++ COMMAND cp ../.build/libsurge-lv2.so products/Surge.lv2/Surge.so
+ COMMAND python scripts/linux/generate-lv2-ttl.py products/Surge.lv2/Surge.so
+ )
+
+@@ -759,7 +758,6 @@ if( BUILD_HEADLESS )
+ target_sources( surge-headless PUBLIC src/linux/ConfigurationXml.S )
+ target_link_libraries(surge-headless
+ PRIVATE
+- stdc++fs
+ Threads::Threads
+ )
+ endif()
diff --git a/audio/surge-synthesizer-lv2/files/patch-scripts_linux_package-vst3.sh b/audio/surge-synthesizer-lv2/files/patch-scripts_linux_package-vst3.sh
new file mode 100644
index 000000000000..d2fb3e8ac7ff
--- /dev/null
+++ b/audio/surge-synthesizer-lv2/files/patch-scripts_linux_package-vst3.sh
@@ -0,0 +1,10 @@
+--- scripts/linux/package-vst3.sh.orig 2020-04-15 18:28:12 UTC
++++ scripts/linux/package-vst3.sh
+@@ -15,4 +15,6 @@ fi
+
+ VST_SO_DIR="$BUNDLE_DIR/Contents/x86_64-linux"
+ mkdir -p "$VST_SO_DIR"
+-cp build/libsurge-vst3.so "$VST_SO_DIR"/Surge.so
++cp ../.build/libsurge-vst3.so "$VST_SO_DIR"/Surge.so
++
++echo "package-vst3.sh is done"
diff --git a/audio/surge-synthesizer-lv2/files/patch-src_linux_UserInteractionsLinux.cpp b/audio/surge-synthesizer-lv2/files/patch-src_linux_UserInteractionsLinux.cpp
new file mode 100644
index 000000000000..4798bbd203bf
--- /dev/null
+++ b/audio/surge-synthesizer-lv2/files/patch-src_linux_UserInteractionsLinux.cpp
@@ -0,0 +1,10 @@
+--- src/linux/UserInteractionsLinux.cpp.orig 2020-04-15 17:52:26 UTC
++++ src/linux/UserInteractionsLinux.cpp
+@@ -6,6 +6,7 @@
+ #include <unistd.h>
+ #include <string.h>
+ #include <thread>
++#include <sstream>
+
+ /*
+ ** In June 2019, @baconpaul chose to implement these with an attempt
diff --git a/audio/surge-synthesizer-lv2/files/patch-vst3sdk_cmake_modules_PlatformToolset.cmake b/audio/surge-synthesizer-lv2/files/patch-vst3sdk_cmake_modules_PlatformToolset.cmake
new file mode 100644
index 000000000000..de062fb99433
--- /dev/null
+++ b/audio/surge-synthesizer-lv2/files/patch-vst3sdk_cmake_modules_PlatformToolset.cmake
@@ -0,0 +1,11 @@
+--- vst3sdk/cmake/modules/PlatformToolset.cmake.orig 2020-04-15 18:18:33 UTC
++++ vst3sdk/cmake/modules/PlatformToolset.cmake
+@@ -32,7 +32,7 @@ macro(setupPlatformToolset)
+ else()
+ set(CMAKE_POSITION_INDEPENDENT_CODE TRUE)
+ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++14 -Wno-multichar")
+- link_libraries(stdc++fs pthread dl)
++ link_libraries(pthread dl)
+ endif()
+ #------------
+ elseif(SMTG_WIN)
diff --git a/audio/surge-synthesizer-lv2/files/patch-vst3sdk_pluginterfaces_base_fplatform.h b/audio/surge-synthesizer-lv2/files/patch-vst3sdk_pluginterfaces_base_fplatform.h
new file mode 100644
index 000000000000..d317d8ef5868
--- /dev/null
+++ b/audio/surge-synthesizer-lv2/files/patch-vst3sdk_pluginterfaces_base_fplatform.h
@@ -0,0 +1,19 @@
+--- vst3sdk/pluginterfaces/base/fplatform.h.orig 2020-04-15 17:42:41 UTC
++++ vst3sdk/pluginterfaces/base/fplatform.h
+@@ -76,14 +76,14 @@
+ #endif
+ //-----------------------------------------------------------------------------
+ // LINUX
+-#elif __gnu_linux__
++#elif __gnu_linux__ || defined(__FreeBSD__) || defined(__DragonFly__)
+ #define SMTG_OS_LINUX 1
+ #define SMTG_OS_MACOS 0
+ #define SMTG_OS_WINDOWS 0
+ #define SMTG_OS_IOS 0
+ #define SMTG_OS_OSX 0
+
+- #include <endian.h>
++ #include <sys/endian.h>
+ #if __BYTE_ORDER == __LITTLE_ENDIAN
+ #define BYTEORDER kLittleEndian
+ #else
diff --git a/audio/surge-synthesizer-lv2/files/patch-vst3sdk_pluginterfaces_base_funknown.cpp b/audio/surge-synthesizer-lv2/files/patch-vst3sdk_pluginterfaces_base_funknown.cpp
new file mode 100644
index 000000000000..2fb3f6c52504
--- /dev/null
+++ b/audio/surge-synthesizer-lv2/files/patch-vst3sdk_pluginterfaces_base_funknown.cpp
@@ -0,0 +1,29 @@
+--- vst3sdk/pluginterfaces/base/funknown.cpp.orig 2020-04-15 17:56:07 UTC
++++ vst3sdk/pluginterfaces/base/funknown.cpp
+@@ -36,8 +36,13 @@
+ #endif
+
+ #if SMTG_OS_LINUX
+-#include <ext/atomicity.h>
++#if defined(__FreeBSD__) || defined(__DragonFly__)
++# include <sys/types.h>
++# include <machine/atomic.h>
++#else
++# include <ext/atomicity.h>
+ #endif
++#endif
+
+ namespace Steinberg {
+
+@@ -72,7 +77,11 @@ int32 PLUGIN_API atomicAdd (int32& var, int32 d)
+ #elif SMTG_OS_MACOS
+ return OSAtomicAdd32Barrier (d, (int32_t*)&var);
+ #elif SMTG_OS_LINUX
++#if defined(__FreeBSD__) || defined(__DragonFly__)
++ (*(u_int *)(&var) += (d));
++#else
+ __gnu_cxx::__atomic_add (&var, d);
++#endif
+ return var;
+ #else
+ #warning implement me!
diff --git a/audio/surge-synthesizer-lv2/files/patch-vstgui.surge_vstgui_lib_vstguibase.h b/audio/surge-synthesizer-lv2/files/patch-vstgui.surge_vstgui_lib_vstguibase.h
new file mode 100644
index 000000000000..369b9735ea13
--- /dev/null
+++ b/audio/surge-synthesizer-lv2/files/patch-vstgui.surge_vstgui_lib_vstguibase.h
@@ -0,0 +1,11 @@
+--- vstgui.surge/vstgui/lib/vstguibase.h.orig 2020-04-15 17:36:33 UTC
++++ vstgui.surge/vstgui/lib/vstguibase.h
+@@ -121,7 +121,7 @@
+ using std::min;
+ using std::max;
+
+-#elif defined(__linux__)
++#elif defined(__linux__) || defined(__FreeBSD__) || defined(__DragonFly__)
+ #include <cstdint>
+ #include <type_traits>
+ #include <algorithm>
diff --git a/audio/surge-synthesizer-lv2/pkg-descr b/audio/surge-synthesizer-lv2/pkg-descr
new file mode 100644
index 000000000000..822b43d53ad0
--- /dev/null
+++ b/audio/surge-synthesizer-lv2/pkg-descr
@@ -0,0 +1,6 @@
+Surge is an Open Source Digital Synthesizer, originally written and sold as
+a commercial product by @kurasu/Claes Johanson at vember audio. In September
+of 2018, Claes released a partially completed version of Surge 1.6 under GPL3,
+and a group of developers have been improving it since.
+
+WWW: https://surge-synthesizer.github.io/