gnu: Add bespokesynth

  • Open
  • quality assurance status badge
Details
One participant
  • Sughosha
Owner
unassigned
Submitted by
Sughosha
Severity
normal
S
S
Sughosha wrote on 16 Oct 2022 21:23
(name . guix-patches@gnu.org)(address . guix-patches@gnu.org)
jxwJaej_vbaAUEYQRcM8uYOXErfjrthh65jDZ_uCi99LLOneM-6ME5rBqKK-V_wLZ8wF0X4Vvs6T510LVYnASoJj_HIS8t4Ra6dbK9ZLEPM=@proton.me
Empty Message
From f5faeab2060204a0afb22574acc0b72d430fee18 Mon Sep 17 00:00:00 2001
From: Sughosha <sughosha@proton.me>
Date: Sun, 16 Oct 2022 16:01:53 +0200
Subject: [PATCH 1/4] gnu: Add juce

* gnu/packages/music.scm (juce): New variable.
---
gnu/packages/music.scm | 32 ++++++++++++++++++++++++++++++++
1 file changed, 32 insertions(+)

Toggle diff (45 lines)
diff --git a/gnu/packages/music.scm b/gnu/packages/music.scm
index 6b37c79389..0662ec272d 100644
--- a/gnu/packages/music.scm
+++ b/gnu/packages/music.scm
@@ -1875,6 +1875,38 @@ (define-public tascam-gtk
device supports.")
(license license:expat))))
+(define-public juce
+ (package
+ (name "juce")
+ (version "7.0.2")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/juce-framework/JUCE")
+ (commit version)))
+ (sha256
+ (base32
+ "0sswn2c9bm8nzcfwba2i3827pbrzi9syihg90kfhay7m5nizb78v"))))
+ (build-system cmake-build-system)
+ ;; TODO: Use installed packages instead of bundled dependencies.
+ (arguments
+ (list #:tests? #f)) ;no test suite
+ (native-inputs (list pkg-config))
+ (inputs (list alsa-lib
+ curl
+ freetype
+ jack-1
+ libx11
+ python
+ webkitgtk-with-libsoup2))
+ (home-page "https://juce.com")
+ (synopsis "Cross-platform C++ application framework")
+ (description
+ "JUCE is a cross-platform C++ application framework for creating
+applications including VST, VST3, AU, AUv3, AAX and LV2 audio plug-ins and
+plug-in hosts.")
+ (license (list license:gpl3 license:isc))))
+
(define-public bsequencer
(package
(name "bsequencer")
--
2.38.0
From 787aac424c777d01937713da3aaab39fd7d7039e Mon Sep 17 00:00:00 2001
From: Sughosha <sughosha@proton.me>
Date: Sun, 16 Oct 2022 16:02:24 +0200
Subject: [PATCH 2/4] gnu: Add tuning-library

* gnu/packages/music.scm (tuning-library): New variable.
---
gnu/packages/music.scm | 38 ++++++++++++++++++++++++++++++++++++++
1 file changed, 38 insertions(+)

Toggle diff (51 lines)
diff --git a/gnu/packages/music.scm b/gnu/packages/music.scm
index 0662ec272d..7619721b04 100644
--- a/gnu/packages/music.scm
+++ b/gnu/packages/music.scm
@@ -1907,6 +1907,44 @@ (define-public juce
plug-in hosts.")
(license (list license:gpl3 license:isc))))
+(define-public tuning-library
+ (package
+ (name "tuning-library")
+ (version "1.1.0")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/surge-synthesizer/tuning-library")
+ (commit (string-append "release_" version))))
+ (file-name (git-file-name name version))
+ (patches (search-patches
+ "tuning-library-1.1.0-fix_missing_include.patch"))
+ (sha256
+ (base32
+ "0f7915xn61sqbdla1zamjd2nkbvdzlm162dmqap2j40yhra73q65"))))
+ (build-system cmake-build-system)
+ (arguments
+ (list #:phases #~(modify-phases %standard-phases
+ (replace 'check
+ (lambda _
+ (invoke "make" "run-all-tests")))
+ (replace 'install
+ (lambda _
+ (install-file (string-append #$source
+ "/include/Tunings.h")
+ (string-append #$output
+ "/include"))
+ (install-file (string-append
+ #$source "/include/TuningsImpl.h")
+ (string-append #$output
+ "/include")))))))
+ (home-page "https://surge-synth-team.org/tuning-library/")
+ (synopsis "C++ Library for micro-tuning and frequency finding")
+ (description
+ "Tuning Library is a header-only C++ library for micro-tuning format
+parsing and frequency finding.")
+ (license license:expat)))
+
(define-public bsequencer
(package
(name "bsequencer")
--
2.38.0
From db060b722592071d350c4fdb0198b05864ad4819 Mon Sep 17 00:00:00 2001
From: Sughosha <sughosha@proton.me>
Date: Sun, 16 Oct 2022 16:02:52 +0200
Subject: [PATCH 3/4] gnu: Add readerwriterqueue

* gnu/packages/music.scm (readerwriterqueue): New variable.
---
gnu/packages/music.scm | 29 +++++++++++++++++++++++++++++
1 file changed, 29 insertions(+)

Toggle diff (43 lines)
diff --git a/gnu/packages/music.scm b/gnu/packages/music.scm
index 7619721b04..96892bb746 100644
--- a/gnu/packages/music.scm
+++ b/gnu/packages/music.scm
@@ -1945,6 +1945,36 @@ (define-public tuning-library
parsing and frequency finding.")
(license license:expat)))
+(define-public readerwriterqueue
+ (package
+ (name "readerwriterqueue")
+ (version "1.0.6")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/cameron314/readerwriterqueue")
+ (commit (string-append "v" version))))
+ (sha256
+ (base32
+ "15yqw51lfmib03rj81vnizpnyf2fi11qk4zfvsq6br158znmgcw3"))))
+ (build-system cmake-build-system)
+ (arguments
+ (list #:tests? #f ;no test suite
+ #:phases
+ #~(modify-phases %standard-phases
+ ;; Exclude license file from include folder
+ (add-after 'unpack 'exclude-license-file
+ (lambda _
+ (substitute* "CMakeLists.txt"
+ (("LICENSE.md ") "")))))))
+ (home-page "https://github.com/cameron314/readerwriterqueue")
+ (synopsis "Single-producer, single-consumer lock-free queue for C++")
+ (description
+ "readerwriterqueue is a Single-producer, single-consumer lock-free queue
+for C++. It only supports a two-thread use case (one consuming, and one
+producing).")
+ (license license:bsd-2)))
+
(define-public bsequencer
(package
(name "bsequencer")
--
2.38.0
From a37d658780866fb72148dac40ac7b7ad6a6ec034 Mon Sep 17 00:00:00 2001
From: Sughosha <sughosha@proton.me>
Date: Sun, 16 Oct 2022 16:04:58 +0200
Subject: [PATCH 4/4] gnu: Add bespokesynth

* gnu/packages/music.scm (bespokesynth): New variable.
(mts-esp): New variable.
---
gnu/packages/music.scm | 89 ++++++++++++++++++++++++++++++++++++++++++
1 file changed, 89 insertions(+)

Toggle diff (103 lines)
diff --git a/gnu/packages/music.scm b/gnu/packages/music.scm
index 96892bb746..53a76cde64 100644
--- a/gnu/packages/music.scm
+++ b/gnu/packages/music.scm
@@ -1974,6 +1974,96 @@ (define-public readerwriterqueue
producing).")
(license license:bsd-2)))
+(define mts-esp
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/ODDSound/MTS-ESP")
+ (commit "3eb56f2452244b343ce738efd067d1082b67f9b4")))
+ (sha256
+ (base32
+ "0qbyspn545cn7jp2j01vxv191nibdsiq12x2xdwlcz3npsflrpxh"))))
+
+(define-public bespokesynth
+ ;; Commit based on the current version of installed JUCE
+ (let ((commit "616ad67c9c7b693aeb4a5cb19d8811baff99854c")
+ (revision "162"))
+ (package
+ (name "bespokesynth")
+ (version (git-version "1.1.0" revision commit))
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/BespokeSynth/BespokeSynth")
+ (commit commit)))
+ (file-name (git-file-name name version))
+ (patches (search-patches
+ "bespokesynth-1.1.0-devendor_ableton_link.patch"))
+ (sha256
+ (base32
+ "1h8cbgsls1qxk3c7wkd8grrvs7bnj6ijhrixxrfnv23198l9gd5q"))))
+ (build-system cmake-build-system)
+ (arguments
+ (list #:tests? #f ;no test suite
+ #:configure-flags #~(list "-DBESPOKE_SYSTEM_ABLETONLINK=ON"
+ "-DBESPOKE_SYSTEM_JSONCPP=ON"
+ "-DBESPOKE_SYSTEM_JUCE=ON"
+ "-DBESPOKE_SYSTEM_PYBIND11=ON"
+ "-DBESPOKE_SYSTEM_TUNING_LIBRARY=ON")
+ #:phases #~(modify-phases %standard-phases
+ (add-after 'unpack 'use-installed-modules
+ (lambda _
+ (let ((mts "libs/oddsound-mts/MTS-ESP"))
+ (rmdir mts)
+ (symlink #$mts-esp mts)
+ (substitute* "libs/CMakeLists.txt"
+ (("add_subdirectory\\(readerwriterqueue EXCLUDE_FROM_ALL\\)")
+ "#"))
+ (substitute* "Source/CMakeLists.txt"
+ (("readerwriterqueue")
+ "#"))
+ (substitute* "Source/NoteOutputQueue.h"
+ (("readerwriterqueue\\.h")
+ "readerwriterqueue/readerwriterqueue.h"))))))))
+ (native-inputs (list ableton-link
+ pkg-config
+ juce
+ libxrandr
+ pybind11
+ readerwriterqueue
+ tuning-library
+ xcb-util
+ xcb-util-keysyms
+ xkbutils))
+ (inputs (list alsa-lib
+ curl
+ gtk+
+ freetype
+ hicolor-icon-theme
+ jack-1
+ jsoncpp
+ libusb
+ libxcb
+ libxcursor
+ libxinerama
+ libxkbfile
+ mesa
+ python
+ webkitgtk-with-libsoup2
+ xcb-util-cursor))
+ (home-page "http://bespokesynth.com")
+ (synopsis "Modular digital audio workstation")
+ (description
+ "Beaspokesynth is a modular synth.
+The features include:
+@itemize
+@item Live-patchable environment
+@item VST hosting
+@item Python livecoding
+@item MIDI controller mapping
+@end itemize")
+ (license license:gpl3+))))
+
(define-public bsequencer
(package
(name "bsequencer")
--
2.38.0
S
S
Sughosha wrote on 16 Oct 2022 21:36
Add missing patches
(name . 58572@debbugs.gnu.org)(address . 58572@debbugs.gnu.org)
Bh0wvvBawEpV2XiH4BD16AhfCFbRQpjNe9WxBZA-pz2-0JvSDeBagCRYpSeeYouXF1PhNddT4nnlXSX4Invg0467cAiJt_vF1zOyOsf98EM=@proton.me
I forgot to add the patchfiles to git before submiting above patches.
From dec3082116fc60389d4095bbfd3cd66332e9ae7c Mon Sep 17 00:00:00 2001
From: Sughosha <sughosha@proton.me>
Date: Sun, 16 Oct 2022 21:32:02 +0200
Subject: [PATCH] gnu: Add patches required for bespokesynth and tuning-library

---
...okesynth-1.1.0-devendor_ableton_link.patch | 29 +++++++++++++++++++
...ng-library-1.1.0-fix_missing_include.patch | 8 +++++
2 files changed, 37 insertions(+)
create mode 100644 gnu/packages/patches/bespokesynth-1.1.0-devendor_ableton_link.patch
create mode 100644 gnu/packages/patches/tuning-library-1.1.0-fix_missing_include.patch

Toggle diff (51 lines)
diff --git a/gnu/packages/patches/bespokesynth-1.1.0-devendor_ableton_link.patch b/gnu/packages/patches/bespokesynth-1.1.0-devendor_ableton_link.patch
new file mode 100644
index 0000000000..1f160fd349
--- /dev/null
+++ b/gnu/packages/patches/bespokesynth-1.1.0-devendor_ableton_link.patch
@@ -0,0 +1,29 @@
+diff --git i/CMakeLists.txt w/CMakeLists.txt
+index 50038d06..7241a0de 100644
+--- i/CMakeLists.txt
++++ w/CMakeLists.txt
+@@ -15,6 +15,7 @@ option(BESPOKE_DEVENDORED_SYSTEM_JUCE "Use system libraries when using system in
+ option(BESPOKE_SYSTEM_PYBIND11 "Use a system installation of pybind11" OFF)
+ option(BESPOKE_SYSTEM_JSONCPP "Use system-wide installation of jsoncpp" OFF)
+ option(BESPOKE_SYSTEM_TUNING_LIBRARY "Use system installation of tuning-library" OFF)
++option(BESPOKE_SYSTEM_ABLETONLINK "Use system installation of ableton-link" OFF)
+ option(BESPOKE_USE_ASAN "Build with ASAN" OFF)
+
+ # Global CMake options
+diff --git i/Source/CMakeLists.txt w/Source/CMakeLists.txt
+index 7714ae7f..67256f1d 100644
+--- i/Source/CMakeLists.txt
++++ w/Source/CMakeLists.txt
+@@ -1,6 +1,11 @@
+ include(cmake/lib.cmake)
+ include(cmake/versiontools.cmake)
+-include(../libs/link/AbletonLinkConfig.cmake)
++if(BESPOKE_SYSTEM_ABLETONLINK)
++ message(STATUS "Using system provided Ableton Link")
++ find_package(AbletonLink NAMES AbletonLink ableton-link link REQUIRED)
++else()
++ include(../libs/link/AbletonLinkConfig.cmake)
++endif()
+
+ juce_add_gui_app(BespokeSynth
+ PRODUCT_NAME BespokeSynth
diff --git a/gnu/packages/patches/tuning-library-1.1.0-fix_missing_include.patch b/gnu/packages/patches/tuning-library-1.1.0-fix_missing_include.patch
new file mode 100644
index 0000000000..e53f32f483
--- /dev/null
+++ b/gnu/packages/patches/tuning-library-1.1.0-fix_missing_include.patch
@@ -0,0 +1,8 @@
+diff -ruN a/commands/parsecheck.cpp b/commands/parsecheck.cpp
+--- a/commands/parsecheck.cpp 2021-07-01 20:32:19.000000000 +0200
++++ b/commands/parsecheck.cpp 2021-10-10 00:44:54.766530190 +0200
+@@ -1,3 +1,4 @@
++#include <cstring>
+ #include <iomanip>
+ #include "Tunings.h"
+ #include "TuningsImpl.h"
--
2.38.0
S
S
Sughosha wrote on 17 Oct 2022 21:28
(name . 58572@debbugs.gnu.org)(address . 58572@debbugs.gnu.org)
fLqmmqVNL7FR9-kuyrZu7GXbO-yQnbdKaQT0AdPbnEuntkos8Nz-YOEf5UvJJepxqsDtNkcNNoi2h3t9QiBifatQwJ3zkPByM94eiRXx_dk=@proton.me
webkitgtk-with-libsoup2 is not needed for bespokesynth. It seems that cmake just looks for it in general for juce based plugins.
From 8a11cf9cb060bc3c49c3177aa23ce44d4787dfa5 Mon Sep 17 00:00:00 2001
From: Sughosha <sughosha@proton.me>
Date: Mon, 17 Oct 2022 21:16:24 +0200
Subject: [PATCH v2] gnu: bespokesynth: Remove unneeded dependency

* gnu/packages/music.scm (bespokesynth)[inputs]: Remove webkitgtk-with-libsoup2.
---
gnu/packages/music.scm | 1 -
1 file changed, 1 deletion(-)

Toggle diff (14 lines)
diff --git a/gnu/packages/music.scm b/gnu/packages/music.scm
index 53a76cde64..ba359bbdc6 100644
--- a/gnu/packages/music.scm
+++ b/gnu/packages/music.scm
@@ -2048,7 +2048,6 @@ (define-public bespokesynth
libxkbfile
mesa
python
- webkitgtk-with-libsoup2
xcb-util-cursor))
(home-page "http://bespokesynth.com")
(synopsis "Modular digital audio workstation")
--
2.38.0
S
S
Sughosha wrote on 26 Oct 2022 22:01
[PATCH v3] gnu: juce: Fix paths
(name . 58572@debbugs.gnu.org)(address . 58572@debbugs.gnu.org)
HSDlf_GyeYmgvQQIAYZM16BGhK-0TaUmf4LoxuFaPR5luuD1TMZGwP3uDbOLpWyS8bJQFlMPWhctnRRKm_U8gGCet3MqYy0FMXVagI4KWUo=@proton.me
* gnu/packages/music.scm (juce)[arguments]: Fix paths.
[inputs]: Add dconf, fontconfig and glib:bin.
[propagated-inputs]: Add xdg-open.
---
gnu/packages/music.scm | 21 ++++++++++++++++++++-
1 file changed, 20 insertions(+), 1 deletion(-)

Toggle diff (41 lines)
diff --git a/gnu/packages/music.scm b/gnu/packages/music.scm
index 6d0fd1e9c0..2fee51ed1f 100644
--- a/gnu/packages/music.scm
+++ b/gnu/packages/music.scm
@@ -1890,14 +1890,33 @@ (define-public juce
(build-system cmake-build-system)
;; TODO: Use installed packages instead of bundled dependencies.
(arguments
- (list #:tests? #f)) ;no test suite
+ (list #:tests? #f ;no test suite
+ #:phases #~(modify-phases %standard-phases
+ (add-after 'unpack 'fix-paths
+ (lambda _
+ (substitute* "extras/Projucer/Source/ProjectSaving/jucer_ProjectExport_CodeBlocks.h"
+ (("/usr/include/freetype2")
+ (string-append #$freetype "/include/freetype")))
+ (substitute* "modules/juce_graphics/native/juce_linux_Fonts.cpp"
+ (("/etc/fonts")
+ (string-append #$fontconfig "/etc/fonts")))
+ (substitute* "modules/juce_gui_basics/native/x11/juce_linux_XWindowSystem.cpp"
+ (("/usr/bin/dconf")
+ (string-append #$dconf "/bin/dconf"))
+ (("/usr/bin/gsettings")
+ (string-append (ungexp glib "bin")
+ "/bin/gsettings"))))))))
(native-inputs (list pkg-config))
(inputs (list alsa-lib
curl
+ dconf
+ fontconfig
freetype
+ `(,glib "bin")
jack-1
libx11
python))
+ (propagated-inputs (list xdg-utils)) ;for xdg-open to open web browser
(home-page "https://juce.com")
(synopsis "Cross-platform C++ application framework")
(description
--
2.38.0
?
Your comment

Commenting via the web interface is currently disabled.

To comment on this conversation send an email to 58572@debbugs.gnu.org

To respond to this issue using the mumi CLI, first switch to it
mumi current 58572
Then, you may apply the latest patchset in this issue (with sign off)
mumi am -- -s
Or, compose a reply to this issue
mumi compose
Or, send patches to this issue
mumi send-email *.patch