GNU bug report logs - #58681
[PATCH] gnu: Add synthpod

Previous Next

Package: guix-patches;

Reported by: Sughosha <Sughosha <at> proton.me>

Date: Fri, 21 Oct 2022 11:20:02 UTC

Severity: normal

Tags: moreinfo, patch

Done: Ricardo Wurmus <rekado <at> elephly.net>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 58681 in the body.
You can then email your comments to 58681 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to guix-patches <at> gnu.org:
bug#58681; Package guix-patches. (Fri, 21 Oct 2022 11:20:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Sughosha <Sughosha <at> proton.me>:
New bug report received and forwarded. Copy sent to guix-patches <at> gnu.org. (Fri, 21 Oct 2022 11:20:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Sughosha <Sughosha <at> proton.me>
To: "guix-patches <at> gnu.org" <guix-patches <at> gnu.org>
Subject: [PATCH] gnu: Add synthpod
Date: Fri, 21 Oct 2022 11:19:24 +0000
* gnu/packages/music.scm (synthpod): New variable.
---
 gnu/packages/music.scm | 45 +++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 45 insertions(+)

diff --git a/gnu/packages/music.scm b/gnu/packages/music.scm
index 6b37c79..6ff2c99 100644
--- a/gnu/packages/music.scm
+++ b/gnu/packages/music.scm
@@ -173,6 +173,7 @@
   #:use-module (gnu packages sqlite)
   #:use-module (gnu packages stb)
   #:use-module (gnu packages tcl)
+  #:use-module (gnu packages terminals)
   #:use-module (gnu packages texinfo)
   #:use-module (gnu packages tex)
   #:use-module (gnu packages time)
@@ -3456,6 +3457,50 @@ analogue-like user interface.")
 socket or command line.")
       (license license:gpl3+))))

+(define-public synthpod
+  (package
+    (name "synthpod")
+    (version "0.1.6505")
+    (source (origin
+              (method git-fetch)
+              (uri (git-reference
+                     (url "https://git.open-music-kontrollers.ch/lv2/synthpod")
+                     ;; Version is not tagged but mentioned in VERSION file.
+                     (commit "8273142cd702583cb3662fbe0e2fd5d4075ee703")))
+              (sha256
+                (base32
+                 "120qsd090pwkc21g9a5mm0pjb0rqn1iy4rs5lx3fs0qf3wa7k6ri"))))
+    (build-system meson-build-system)
+    ;; Fontconfig error: No writable cache directories
+    (arguments (list #:tests? #f))
+    (inputs (list alsa-lib
+                  cairo
+                  eudev
+                  freetype
+                  fontconfig
+                  glew
+                  glu
+                  jack-1
+                  libevdev
+                  libinput
+                  libvterm
+                  lilv
+                  lv2
+                  pixman
+                  sratom
+                  xcb-util
+                  xcb-util-wm
+                  xcb-util-xrm
+                  zita-alsa-pcmi))
+    (native-inputs (list ;lv2lint     ; needed for tests
+                         pkg-config))
+    (home-page "https://open-music-kontrollers.ch/lv2/synthpod/")
+    (synopsis "Nonlinear LV2 plugin container")
+    (description
+     "Synthpod is an LV2 host.  It can be run as a standalone app and be used
+as a tool for live performances or general audio and event filtering.")
+    (license (list license:artistic2.0 license:gpl3+))))
+
 (define-public curseradio
   (let ((commit "1bd4bd0faeec675e0647bac9a100b526cba19f8d")
         (revision "1"))
--
libgit2 1.4.3





Information forwarded to guix-patches <at> gnu.org:
bug#58681; Package guix-patches. (Tue, 25 Oct 2022 09:29:01 GMT) Full text and rfc822 format available.

Message #8 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Christopher Baines <mail <at> cbaines.net>
To: Sughosha <Sughosha <at> proton.me>
Cc: 58681 <at> debbugs.gnu.org, guix-patches <at> gnu.org
Subject: Re: [bug#58681] [PATCH] gnu: Add synthpod
Date: Tue, 25 Oct 2022 10:25:30 +0100
[Message part 1 (text/plain, inline)]
Sughosha via Guix-patches via <guix-patches <at> gnu.org> writes:

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

Hey, thanks for the patch.

> +    (source (origin
> +              (method git-fetch)
> +              (uri (git-reference
> +                     (url "https://git.open-music-kontrollers.ch/lv2/synthpod")
> +                     ;; Version is not tagged but mentioned in VERSION file.
> +                     (commit "8273142cd702583cb3662fbe0e2fd5d4075ee703")))
> +              (sha256
> +                (base32
> +                 "120qsd090pwkc21g9a5mm0pjb0rqn1iy4rs5lx3fs0qf3wa7k6ri"))))

The linter should be telling you something about the source file not
containing the package name. I'd take a look at the file-name bit in
other package sources that also use git-fetch.

> +    (build-system meson-build-system)
> +    ;; Fontconfig error: No writable cache directories
> +    (arguments (list #:tests? #f))

The cache directory bit is a hint, as that's often within the users home
directory. The build environment uses a non-existent home directory, but
you can change that. Quite a few packages have (setenv "HOME" "/tmp")
for the tests. Adding that looks like:

    (arguments
     (list
      #:phases
      #~(modify-phases %standard-phases
          (add-before 'check 'fix-home-directory
            (lambda _
              ;; Tests fail with: Fontconfig error: No writable cache
              ;; directories
              (setenv "HOME" "/tmp"))))))

If you do that though, the tests still fail, seems like there's a
missing font?

starting phase `check'
ninja: Entering directory `/tmp/guix-build-synthpod-0.1.6505.drv-0/build'
ninja: no work to do.
1/9 d2tk / Test core            OK              0.09s
2/9 d2tk / Test base            OK              0.48s
3/9 d2tk / FiraSans-Bold.ttf    FAIL            0.02s   exit status 1
>>> MALLOC_PERTURB_=67 /tmp/guix-build-synthpod-0.1.6505.drv-0/source/subprojects/d2tk/check_for_font FiraSans-Bold.ttf

4/9 d2tk / FiraCode-Light.ttf   FAIL            0.03s   exit status 1
>>> MALLOC_PERTURB_=109 /tmp/guix-build-synthpod-0.1.6505.drv-0/source/subprojects/d2tk/check_for_font FiraCode-Light.tt

5/9 d2tk / FiraCode-Regular.ttf FAIL            0.03s   exit status 1
>>> MALLOC_PERTURB_=46 /tmp/guix-build-synthpod-0.1.6505.drv-0/source/subprojects/d2tk/check_for_font FiraCode-Regular.ttf

6/9 d2tk / FiraCode-Medium.ttf  FAIL            0.02s   exit status 1
>>> MALLOC_PERTURB_=41 /tmp/guix-build-synthpod-0.1.6505.drv-0/source/subprojects/d2tk/check_for_font FiraCode-Medium.ttf

7/9 d2tk / FiraCode-Bold.ttf    FAIL            0.02s   exit status 1
>>> MALLOC_PERTURB_=10 /tmp/guix-build-synthpod-0.1.6505.drv-0/source/subprojects/d2tk/check_for_font FiraCode-Bold.ttf

8/9 synthpod / LV2 validate     OK              0.07s
9/9 synthpod / LV2 validate     OK              0.07s

Summary of Failures:

3/9 d2tk / FiraSans-Bold.ttf    FAIL            0.02s   exit status 1
4/9 d2tk / FiraCode-Light.ttf   FAIL            0.03s   exit status 1
5/9 d2tk / FiraCode-Regular.ttf FAIL            0.03s   exit status 1
6/9 d2tk / FiraCode-Medium.ttf  FAIL            0.02s   exit status 1
7/9 d2tk / FiraCode-Bold.ttf    FAIL            0.02s   exit status 1


Ok:                 4   
Expected Fail:      0   
Fail:               5   
Unexpected Pass:    0   
Skipped:            0   
Timeout:            0   
[signature.asc (application/pgp-signature, inline)]

Information forwarded to guix-patches <at> gnu.org:
bug#58681; Package guix-patches. (Tue, 25 Oct 2022 09:29:02 GMT) Full text and rfc822 format available.

Added tag(s) moreinfo. Request was from Christopher Baines <mail <at> cbaines.net> to control <at> debbugs.gnu.org. (Thu, 03 Nov 2022 16:15:01 GMT) Full text and rfc822 format available.

Information forwarded to guix-patches <at> gnu.org:
bug#58681; Package guix-patches. (Fri, 06 Jan 2023 14:28:01 GMT) Full text and rfc822 format available.

Message #16 received at 58681 <at> debbugs.gnu.org (full text, mbox):

From: Sughosha <Sughosha <at> proton.me>
To: "58681 <at> debbugs.gnu.org" <58681 <at> debbugs.gnu.org>
Subject: [PATCH v2] gnu: Add synthpod.
Date: Fri, 06 Jan 2023 14:27:08 +0000
Sorry for the delay. Here is the fix with tests enabled and updated to newer version.

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

diff --git a/gnu/packages/music.scm b/gnu/packages/music.scm
index 5be767a138..3d0722274c 100644
--- a/gnu/packages/music.scm
+++ b/gnu/packages/music.scm
@@ -174,6 +174,7 @@ (define-module (gnu packages music)
   #:use-module (gnu packages sqlite)
   #:use-module (gnu packages stb)
   #:use-module (gnu packages tcl)
+  #:use-module (gnu packages terminals)
   #:use-module (gnu packages texinfo)
   #:use-module (gnu packages tex)
   #:use-module (gnu packages time)
@@ -3517,6 +3518,59 @@ (define-public mod-host
 socket or command line.")
       (license license:gpl3+))))
 
+(define-public synthpod
+  (package
+    (name "synthpod")
+    (version "0.1.6507")
+    (source (origin
+              (method git-fetch)
+              (uri (git-reference
+                     (url "https://git.open-music-kontrollers.ch/lv2/synthpod")
+                     ;; Version is not tagged but mentioned in VERSION file.
+                     (commit "6e84a075ea8fea95094dcbc2b30f968717a81960")))
+              (file-name (git-file-name name version))
+              (sha256
+                (base32
+                 "1chazkdxjgjzfxqmlk4ywhilkj9l3bybd9xghjg9r67df2diqhbs"))))
+    (build-system meson-build-system)
+    (arguments
+     (list
+      #:phases
+      #~(modify-phases %standard-phases
+          (add-before 'check 'fix-home-directory
+            (lambda _
+              ;; Tests fail with: Fontconfig error: No writable cache
+              ;; directories
+              (setenv "HOME" "/tmp"))))))
+    (propagated-inputs (list lilv)) ;required for lv2info
+    (inputs (list alsa-lib
+                  cairo
+                  eudev
+                  freetype
+                  font-fira-code
+                  font-fira-sans
+                  fontconfig
+                  glew
+                  glu
+                  jack-1
+                  libevdev
+                  libinput
+                  libvterm
+                  lv2
+                  pixman
+                  sratom
+                  xcb-util
+                  xcb-util-wm
+                  xcb-util-xrm
+                  zita-alsa-pcmi))
+    (native-inputs (list pkg-config))
+    (home-page "https://open-music-kontrollers.ch/lv2/synthpod/")
+    (synopsis "Nonlinear LV2 plugin container")
+    (description
+     "Synthpod is an LV2 host.  It can be run as a standalone app and be used
+as a tool for live performances or general audio and event filtering.")
+    (license (list license:artistic2.0 license:gpl3+))))
+
 (define-public curseradio
   (let ((commit "1bd4bd0faeec675e0647bac9a100b526cba19f8d")
         (revision "1"))
-- 
2.38.1





Information forwarded to guix-patches <at> gnu.org:
bug#58681; Package guix-patches. (Sun, 22 Jan 2023 23:04:01 GMT) Full text and rfc822 format available.

Message #19 received at 58681 <at> debbugs.gnu.org (full text, mbox):

From: Ricardo Wurmus <rekado <at> elephly.net>
To: 58681 <at> debbugs.gnu.org
Cc: Sughosha <Sughosha <at> proton.me>
Subject: [PATCH v2] gnu: Add synthpod.
Date: Sun, 22 Jan 2023 23:58:25 +0100
[Message part 1 (text/plain, inline)]
Hi,

I made these changes:

[synthpod.diff (text/x-patch, inline)]
diff --git a/gnu/packages/music.scm b/gnu/packages/music.scm
index ca058638f2..f2f5289dba 100644
--- a/gnu/packages/music.scm
+++ b/gnu/packages/music.scm
@@ -44,7 +44,7 @@
 ;;; Copyright © 2021 Simon Streit <simon <at> netpanic.org>
 ;;; Copyright © 2021 Xinglu Chen <public <at> yoctocell.xyz>
 ;;; Copyright © 2021 Thomas Albers Raviola <thomas <at> thomaslabs.org>
-;;; Copyright © 2022 Sughosha <sughosha <at> disroot.org>
+;;; Copyright © 2022, 2023 Sughosha <sughosha <at> disroot.org>
 ;;; Copyright © 2022 Remco van 't Veer <remco <at> remworks.net>
 ;;; Copyright © 2022 Maxim Cournoyer <maxim.cournoyer <at> gmail.com>
 ;;; Copyright © 2022 Wamm K. D. <jaft.r <at> outlook.com>
@@ -3566,44 +3566,53 @@ (define-public synthpod
     (source (origin
               (method git-fetch)
               (uri (git-reference
-                     (url "https://git.open-music-kontrollers.ch/lv2/synthpod")
-                     ;; Version is not tagged but mentioned in VERSION file.
-                     (commit "6e84a075ea8fea95094dcbc2b30f968717a81960")))
+                    (url "https://git.open-music-kontrollers.ch/lv2/synthpod")
+                    ;; Version is not tagged but mentioned in VERSION file.
+                    (commit "6e84a075ea8fea95094dcbc2b30f968717a81960")))
               (file-name (git-file-name name version))
               (sha256
-                (base32
-                 "1chazkdxjgjzfxqmlk4ywhilkj9l3bybd9xghjg9r67df2diqhbs"))))
+               (base32
+                "1chazkdxjgjzfxqmlk4ywhilkj9l3bybd9xghjg9r67df2diqhbs"))))
     (build-system meson-build-system)
     (arguments
      (list
       #:phases
       #~(modify-phases %standard-phases
-          (add-before 'check 'fix-home-directory
+          (add-after 'unpack 'patch-references
+            (lambda* (#:key inputs #:allow-other-keys)
+              (substitute* '("bin/synthpod_ui"
+                             "bin/synthpod_d2tk")
+                (("lv2info") (search-input-file inputs "/bin/lv2info"))
+                ((" synthpod_sandbox_x11")
+                 (string-append " " #$output "/bin/synthpod_sandbox_x11")))))
+          (add-before 'check 'set-home-directory
             (lambda _
               ;; Tests fail with: Fontconfig error: No writable cache
               ;; directories
               (setenv "HOME" "/tmp"))))))
-    (propagated-inputs (list lilv)) ;required for lv2info
-    (inputs (list alsa-lib
-                  cairo
-                  eudev
-                  freetype
-                  font-fira-code
-                  font-fira-sans
-                  fontconfig
-                  glew
-                  glu
-                  jack-1
-                  libevdev
-                  libinput
-                  libvterm
-                  lv2
-                  pixman
-                  sratom
-                  xcb-util
-                  xcb-util-wm
-                  xcb-util-xrm
-                  zita-alsa-pcmi))
+    (inputs
+     (list alsa-lib
+           cairo
+           eudev
+           freetype
+           font-fira-code
+           font-fira-sans
+           fontconfig
+           glew
+           glu
+           grep
+           jack-2
+           libevdev
+           libinput
+           libvterm
+           lilv ;for lv2info
+           lv2
+           pixman
+           sratom
+           xcb-util
+           xcb-util-wm
+           xcb-util-xrm
+           zita-alsa-pcmi))
     (native-inputs (list pkg-config))
     (home-page "https://open-music-kontrollers.ch/lv2/synthpod/")
     (synopsis "Nonlinear LV2 plugin container")
[Message part 3 (text/plain, inline)]
It avoids propagation of lilv and patches synthpod_ui to look for other
executables in a known location.

We should probably also wrap the scripts to set PATH to where “grep”,
“coreutils”, “sed”, and “gawk” are found, but I wasn’t able to add (gnu
packages gawk) to the imports of (gnu packages music).

Unfortunately, the program crashes because it can’t find the LV2 files
for Synthpod itself:

--8<---------------cut here---------------start------------->8---
$ /gnu/store/pp3rysfcssf3kigh01mrz7jc16dgp51p-synthpod-0.1.6507/bin/synthpod_ui
error: failed to open file /home/rekado/.lv2/Synthpod_default.preset.lv2/manifest.ttl (No such file or directory)
lilv_world_load_file(): error: Error loading file `file:///home/rekado/.lv2/Synthpod_default.preset.lv2/manifest.ttl'
lilv_world_load_bundle(): error: Error reading file:///home/rekado/.lv2/Synthpod_default.preset.lv2/manifest.ttl
Plugin not found.
Synthpod 0.1.6507
Copyright (c) 2015-2016 Hanspeter Portner (dev <at> open-music-kontrollers.ch)
Released under Artistic License 2.0 by Open Music Kontrollers
error: failed to open file /home/rekado/dev/gx/branches/master/manifest.ttl (No such file or directory)
lilv_world_load_file(): error: Error loading file `file:///home/rekado/dev/gx/branches/master/manifest.ttl'
lilv_world_load_bundle(): error: Error reading file:///home/rekado/dev/gx/branches/master/manifest.ttl
lilv_plugins_get_by_uri failed
Segmentation fault
--8<---------------cut here---------------end--------------->8---

These probably should be looked up in $out/lib/synthpod/lv2 instead of
searching the LV2 path.

-- 
Ricardo

Information forwarded to guix-patches <at> gnu.org:
bug#58681; Package guix-patches. (Mon, 23 Jan 2023 21:11:01 GMT) Full text and rfc822 format available.

Message #22 received at 58681 <at> debbugs.gnu.org (full text, mbox):

From: Sughosha <Sughosha <at> proton.me>
To: 58681 <at> debbugs.gnu.org
Cc: rekado <at> elephly.net
Subject: Re: [PATCH v2] gnu: Add synthpod.
Date: Mon, 23 Jan 2023 21:10:22 +0000
[Message part 1 (text/plain, inline)]
Thanks for reviewing the patch and improving it.

> We should probably also wrap the scripts to set PATH to where “grep”,
“coreutils”, “sed”, and “gawk” are found, but I wasn’t able to add (gnu
packages gawk) to the imports of (gnu packages music).

This is not the only package requiring such basic programs like "sed",
"grep" etc but not wrapped or listed in inputs. The other such package that
I am aware of is ardour, which also requires these programs. I tried
running ardour in a guix shell with --emulate-fhs, then found that ardour
could not start because these programs were not found in the PATH. So I am
not sure if it is required to add these programs to inputs or to wrap them.

> Unfortunately, the program crashes because it can’t find the LV2 files
for Synthpod itself:

I fixed it partially. The binaries are confusing. `synthpod_ui` seems like
not to be run manually. The way that I found to run the ui is
`synthpod_alsa -g` or `synthpod_jack -g`.

Strangely, with the attatched new v3 patch, the program starts only if
installed to guix profile (or maybe something else like guix home, not
tested). Just by building, the program searches for "manifest.ttl" file
in the current working directory and fails to start.


Sughosha
[v3-0001-gnu-Add-synthpod.patch (text/x-patch, attachment)]

Reply sent to Ricardo Wurmus <rekado <at> elephly.net>:
You have taken responsibility. (Tue, 24 Jan 2023 23:27:01 GMT) Full text and rfc822 format available.

Notification sent to Sughosha <Sughosha <at> proton.me>:
bug acknowledged by developer. (Tue, 24 Jan 2023 23:27:02 GMT) Full text and rfc822 format available.

Message #27 received at 58681-done <at> debbugs.gnu.org (full text, mbox):

From: Ricardo Wurmus <rekado <at> elephly.net>
To: Sughosha <Sughosha <at> proton.me>
Cc: 58681-done <at> debbugs.gnu.org
Subject: Re: [PATCH v2] gnu: Add synthpod.
Date: Wed, 25 Jan 2023 00:24:12 +0100
Sughosha <Sughosha <at> proton.me> writes:

> Thanks for reviewing the patch and improving it.
>
>> We should probably also wrap the scripts to set PATH to where “grep”,
> “coreutils”, “sed”, and “gawk” are found, but I wasn’t able to add (gnu
> packages gawk) to the imports of (gnu packages music).
>
> This is not the only package requiring such basic programs like "sed",
> "grep" etc but not wrapped or listed in inputs. The other such package that
> I am aware of is ardour, which also requires these programs. I tried
> running ardour in a guix shell with --emulate-fhs, then found that ardour
> could not start because these programs were not found in the PATH. So I am
> not sure if it is required to add these programs to inputs or to wrap them.

To me this means that we should also fix ardour, not that we should
ignore the problem in other packages :)

>> Unfortunately, the program crashes because it can’t find the LV2 files
> for Synthpod itself:
>
> I fixed it partially. The binaries are confusing. `synthpod_ui` seems like
> not to be run manually. The way that I found to run the ui is
> `synthpod_alsa -g` or `synthpod_jack -g`.
>
> Strangely, with the attatched new v3 patch, the program starts only if
> installed to guix profile (or maybe something else like guix home, not
> tested). Just by building, the program searches for "manifest.ttl" file
> in the current working directory and fails to start.

That’s odd, but perhaps it’s the default of an LV2 library that synthpod
uses.

The patch looks good enough to me, so I applied it.  Feel free to
revisit it at a later point to address the remaining minor issues.

Thank you!

-- 
Ricardo




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Wed, 22 Feb 2023 12:24:07 GMT) Full text and rfc822 format available.

This bug report was last modified 1 year and 35 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.