all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* [bug#58572] gnu: Add bespokesynth
@ 2022-10-16 19:23 Sughosha via Guix-patches via
  2022-10-16 19:36 ` [bug#58572] Add missing patches Sughosha via Guix-patches via
  2022-10-26 20:01 ` [bug#58572] [PATCH v3] gnu: juce: Fix paths Sughosha via Guix-patches via
  0 siblings, 2 replies; 4+ messages in thread
From: Sughosha via Guix-patches via @ 2022-10-16 19:23 UTC (permalink / raw)
  To: 58572

[-- Attachment #1: Type: text/plain, Size: 13 bytes --]

Empty Message

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0001-gnu-Add-juce.patch --]
[-- Type: text/x-patch; name=0001-gnu-Add-juce.patch, Size: 1798 bytes --]

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(+)

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


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #3: 0002-gnu-Add-tuning-library.patch --]
[-- Type: text/x-patch; name=0002-gnu-Add-tuning-library.patch, Size: 2515 bytes --]

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(+)

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


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #4: 0003-gnu-Add-readerwriterqueue.patch --]
[-- Type: text/x-patch; name=0003-gnu-Add-readerwriterqueue.patch, Size: 1925 bytes --]

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(+)

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


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #5: 0004-gnu-Add-bespokesynth.patch --]
[-- Type: text/x-patch; name=0004-gnu-Add-bespokesynth.patch, Size: 4478 bytes --]

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(+)

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


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [bug#58572] Add missing patches
  2022-10-16 19:23 [bug#58572] gnu: Add bespokesynth Sughosha via Guix-patches via
@ 2022-10-16 19:36 ` Sughosha via Guix-patches via
  2022-10-17 19:28   ` Sughosha via Guix-patches via
  2022-10-26 20:01 ` [bug#58572] [PATCH v3] gnu: juce: Fix paths Sughosha via Guix-patches via
  1 sibling, 1 reply; 4+ messages in thread
From: Sughosha via Guix-patches via @ 2022-10-16 19:36 UTC (permalink / raw)
  To: 58572@debbugs.gnu.org

[-- Attachment #1: Type: text/plain, Size: 69 bytes --]

I forgot to add the patchfiles to git before submiting above patches.

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: gnu-Add-patches-required-for-bespokesynth-and-tuning.patch --]
[-- Type: text/x-patch; name=gnu-Add-patches-required-for-bespokesynth-and-tuning.patch, Size: 2715 bytes --]

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

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


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [bug#58572] Add missing patches
  2022-10-16 19:36 ` [bug#58572] Add missing patches Sughosha via Guix-patches via
@ 2022-10-17 19:28   ` Sughosha via Guix-patches via
  0 siblings, 0 replies; 4+ messages in thread
From: Sughosha via Guix-patches via @ 2022-10-17 19:28 UTC (permalink / raw)
  To: 58572@debbugs.gnu.org

[-- Attachment #1: Type: text/plain, Size: 128 bytes --]

webkitgtk-with-libsoup2 is not needed for bespokesynth. It seems that cmake just looks for it in general for juce based plugins.

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: v2-0001-gnu-bespokesynth-Remove-unneeded-dependency.patch --]
[-- Type: text/x-patch; name=v2-0001-gnu-bespokesynth-Remove-unneeded-dependency.patch, Size: 845 bytes --]

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(-)

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


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [bug#58572] [PATCH v3] gnu: juce: Fix paths
  2022-10-16 19:23 [bug#58572] gnu: Add bespokesynth Sughosha via Guix-patches via
  2022-10-16 19:36 ` [bug#58572] Add missing patches Sughosha via Guix-patches via
@ 2022-10-26 20:01 ` Sughosha via Guix-patches via
  1 sibling, 0 replies; 4+ messages in thread
From: Sughosha via Guix-patches via @ 2022-10-26 20:01 UTC (permalink / raw)
  To: 58572@debbugs.gnu.org

* 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(-)

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





^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2022-10-26 20:03 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-10-16 19:23 [bug#58572] gnu: Add bespokesynth Sughosha via Guix-patches via
2022-10-16 19:36 ` [bug#58572] Add missing patches Sughosha via Guix-patches via
2022-10-17 19:28   ` Sughosha via Guix-patches via
2022-10-26 20:01 ` [bug#58572] [PATCH v3] gnu: juce: Fix paths Sughosha via Guix-patches via

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.