3 gx*lv2 packages fail to build in the same manner

  • Open
  • quality assurance status badge
Details
3 participants
  • Maxim Cournoyer
  • Maxime Devos
  • Thorsten Wilms
Owner
unassigned
Submitted by
Thorsten Wilms
Severity
normal
T
T
Thorsten Wilms wrote on 27 Dec 2021 17:54
(address . bug-guix@gnu.org)
20211227175416.cf3636cfcd7e837b3e3d3d6b@freenet.de
Hi!

gx-saturator-lv2-0-3m, gx-slow-gear-lv2-0-3, gx-vbass-preamp-lv2-0-2
all fail in the same way, with many repetitons of `error: template
with C linkage` and warnings for deprecated ‘GTypeDebugFlags’ and
‘GTimeVal’.Using gx-saturator as example:

```
In file included from gui/paintbox.cpp:20:
gui/paintbox.h:24:1: note: ‘extern "C"’ linkage started here
24 | extern "C" {
| ^~~~~~~~~~
In file included from /gnu/store/qqs98rxwjrji6aaf6dqwp7q4m545g2sn-glib-2.70.0/include/glib-2.0/glib/glib-typeof.h:39,
from /gnu/store/qqs98rxwjrji6aaf6dqwp7q4m545g2sn-glib-2.70.0/include/glib-2.0/glib/gatomic.h:28,
from /gnu/store/qqs98rxwjrji6aaf6dqwp7q4m545g2sn-glib-2.70.0/include/glib-2.0/glib/gthread.h:32,
from /gnu/store/qqs98rxwjrji6aaf6dqwp7q4m545g2sn-glib-2.70.0/include/glib-2.0/glib/gasyncqueue.h:32,
from /gnu/store/qqs98rxwjrji6aaf6dqwp7q4m545g2sn-glib-2.70.0/include/glib-2.0/glib.h:32,
from /gnu/store/qqs98rxwjrji6aaf6dqwp7q4m545g2sn-glib-2.70.0/include/glib-2.0/gobject/gbinding.h:28,
from /gnu/store/qqs98rxwjrji6aaf6dqwp7q4m545g2sn-glib-2.70.0/include/glib-2.0/glib-object.h:22,
from /gnu/store/qqs98rxwjrji6aaf6dqwp7q4m545g2sn-glib-2.70.0/include/glib-2.0/gio/gioenums.h:28,
from /gnu/store/qqs98rxwjrji6aaf6dqwp7q4m545g2sn-glib-2.70.0/include/glib-2.0/gio/giotypes.h:28,
from /gnu/store/qqs98rxwjrji6aaf6dqwp7q4m545g2sn-glib-2.70.0/include/glib-2.0/gio/gio.h:26,
from /gnu/store/2sw8v141r6hjsv0mq7cwxxp6m2499y4v-gtk+-2.24.33/include/gtk-2.0/gdk/gdkapplaunchcontext.h:30,
from /gnu/store/2sw8v141r6hjsv0mq7cwxxp6m2499y4v-gtk+-2.24.33/include/gtk-2.0/gdk/gdk.h:32,
from /gnu/store/2sw8v141r6hjsv0mq7cwxxp6m2499y4v-gtk+-2.24.33/include/gtk-2.0/gtk/gtk.h:32,
from gui/paintbox.h:27,
from gui/paintbox.cpp:20:
/gnu/store/vakvgvrb839igv16jkif4lmx11d25jqb-gcc-10.3.0/include/c++/type_traits:2930:3: error: template with C linkage
2930 | template<typename _Fn, typename... _Args>
| ^~~~~~~~
In file included from gui/paintbox.cpp:20:
gui/paintbox.h:24:1: note: ‘extern "C"’ linkage started here
24 | extern "C" {
| ^~~~~~~~~~
In file included from /gnu/store/2sw8v141r6hjsv0mq7cwxxp6m2499y4v-gtk+-2.24.33/include/gtk-2.0/gtk/gtkobject.h:37,
from /gnu/store/2sw8v141r6hjsv0mq7cwxxp6m2499y4v-gtk+-2.24.33/include/gtk-2.0/gtk/gtkwidget.h:36,
from /gnu/store/2sw8v141r6hjsv0mq7cwxxp6m2499y4v-gtk+-2.24.33/include/gtk-2.0/gtk/gtkcontainer.h:35,
from /gnu/store/2sw8v141r6hjsv0mq7cwxxp6m2499y4v-gtk+-2.24.33/include/gtk-2.0/gtk/gtkbin.h:35,
from /gnu/store/2sw8v141r6hjsv0mq7cwxxp6m2499y4v-gtk+-2.24.33/include/gtk-2.0/gtk/gtkwindow.h:36,
from /gnu/store/2sw8v141r6hjsv0mq7cwxxp6m2499y4v-gtk+-2.24.33/include/gtk-2.0/gtk/gtkdialog.h:35,
from /gnu/store/2sw8v141r6hjsv0mq7cwxxp6m2499y4v-gtk+-2.24.33/include/gtk-2.0/gtk/gtkaboutdialog.h:32,
from /gnu/store/2sw8v141r6hjsv0mq7cwxxp6m2499y4v-gtk+-2.24.33/include/gtk-2.0/gtk/gtk.h:33,
from gui/paintbox.h:27,
from gui/paintbox.cpp:20:
/gnu/store/2sw8v141r6hjsv0mq7cwxxp6m2499y4v-gtk+-2.24.33/include/gtk-2.0/gtk/gtktypeutils.h:236:64: warning: ‘GTypeDebugFlags’ is deprecated [-Wdeprecated-declarations]
236 | void gtk_type_init (GTypeDebugFlags debug_flags);
| ^
In file included from /gnu/store/qqs98rxwjrji6aaf6dqwp7q4m545g2sn-glib-2.70.0/include/glib-2.0/gobject/gobject.h:24,
from /gnu/store/qqs98rxwjrji6aaf6dqwp7q4m545g2sn-glib-2.70.0/include/glib-2.0/gobject/gbinding.h:29,
from /gnu/store/qqs98rxwjrji6aaf6dqwp7q4m545g2sn-glib-2.70.0/include/glib-2.0/glib-object.h:22,
from /gnu/store/qqs98rxwjrji6aaf6dqwp7q4m545g2sn-glib-2.70.0/include/glib-2.0/gio/gioenums.h:28,
from /gnu/store/qqs98rxwjrji6aaf6dqwp7q4m545g2sn-glib-2.70.0/include/glib-2.0/gio/giotypes.h:28,
from /gnu/store/qqs98rxwjrji6aaf6dqwp7q4m545g2sn-glib-2.70.0/include/glib-2.0/gio/gio.h:26,
from /gnu/store/2sw8v141r6hjsv0mq7cwxxp6m2499y4v-gtk+-2.24.33/include/gtk-2.0/gdk/gdkapplaunchcontext.h:30,
from /gnu/store/2sw8v141r6hjsv0mq7cwxxp6m2499y4v-gtk+-2.24.33/include/gtk-2.0/gdk/gdk.h:32,
from /gnu/store/2sw8v141r6hjsv0mq7cwxxp6m2499y4v-gtk+-2.24.33/include/gtk-2.0/gtk/gtk.h:32,
from gui/paintbox.h:27,
from gui/paintbox.cpp:20:
/gnu/store/qqs98rxwjrji6aaf6dqwp7q4m545g2sn-glib-2.70.0/include/glib-2.0/gobject/gtype.h:704:3: note: declared here
704 | } GTypeDebugFlags GLIB_DEPRECATED_TYPE_IN_2_36;
| ^~~~~~~~~~~~~~~
In file included from /gnu/store/2sw8v141r6hjsv0mq7cwxxp6m2499y4v-gtk+-2.24.33/include/gtk-2.0/gtk/gtktoolitem.h:31,
from /gnu/store/2sw8v141r6hjsv0mq7cwxxp6m2499y4v-gtk+-2.24.33/include/gtk-2.0/gtk/gtktoolbutton.h:30,
from /gnu/store/2sw8v141r6hjsv0mq7cwxxp6m2499y4v-gtk+-2.24.33/include/gtk-2.0/gtk/gtkmenutoolbutton.h:30,
from /gnu/store/2sw8v141r6hjsv0mq7cwxxp6m2499y4v-gtk+-2.24.33/include/gtk-2.0/gtk/gtk.h:126,
from gui/paintbox.h:27,
from gui/paintbox.cpp:20:
/gnu/store/2sw8v141r6hjsv0mq7cwxxp6m2499y4v-gtk+-2.24.33/include/gtk-2.0/gtk/gtktooltips.h:73:12: warning: ‘GTimeVal’ is deprecated: Use 'GDateTime' instead [-Wdeprecated-declarations]
73 | GTimeVal last_popdown;
| ^~~~~~~~~~~~
In file included from /gnu/store/qqs98rxwjrji6aaf6dqwp7q4m545g2sn-glib-2.70.0/include/glib-2.0/glib/galloca.h:32,
from /gnu/store/qqs98rxwjrji6aaf6dqwp7q4m545g2sn-glib-2.70.0/include/glib-2.0/glib.h:30,
from /gnu/store/qqs98rxwjrji6aaf6dqwp7q4m545g2sn-glib-2.70.0/include/glib-2.0/gobject/gbinding.h:28,
from /gnu/store/qqs98rxwjrji6aaf6dqwp7q4m545g2sn-glib-2.70.0/include/glib-2.0/glib-object.h:22,
from /gnu/store/qqs98rxwjrji6aaf6dqwp7q4m545g2sn-glib-2.70.0/include/glib-2.0/gio/gioenums.h:28,
from /gnu/store/qqs98rxwjrji6aaf6dqwp7q4m545g2sn-glib-2.70.0/include/glib-2.0/gio/giotypes.h:28,
from /gnu/store/qqs98rxwjrji6aaf6dqwp7q4m545g2sn-glib-2.70.0/include/glib-2.0/gio/gio.h:26,
from /gnu/store/2sw8v141r6hjsv0mq7cwxxp6m2499y4v-gtk+-2.24.33/include/gtk-2.0/gdk/gdkapplaunchcontext.h:30,
from /gnu/store/2sw8v141r6hjsv0mq7cwxxp6m2499y4v-gtk+-2.24.33/include/gtk-2.0/gdk/gdk.h:32,
from /gnu/store/2sw8v141r6hjsv0mq7cwxxp6m2499y4v-gtk+-2.24.33/include/gtk-2.0/gtk/gtk.h:32,
from gui/paintbox.h:27,
from gui/paintbox.cpp:20:
/gnu/store/qqs98rxwjrji6aaf6dqwp7q4m545g2sn-glib-2.70.0/include/glib-2.0/glib/gtypes.h:545:26: note: declared here
545 | typedef struct _GTimeVal GTimeVal GLIB_DEPRECATED_TYPE_IN_2_62_FOR(GDateTime);
| ^~~~~~~~
make: *** [Makefile:98: gx_saturate] Error 1
error: in phase 'build': uncaught exception:
%exception #<&invoke-error program: "make" arguments: ("-j" "8" "DESTDIR=/gnu/store/ykys0igh8wgf4psdnpmw0y7zf5jqzadq-gx-saturator-lv2-0-3.605330f43") exit-status: 2 term-signal: #f stop-signal: #f>
phase `build' failed after 2.5 seconds
command "make" "-j" "8" "DESTDIR=/gnu/store/ykys0igh8wgf4psdnpmw0y7zf5jqzadq-gx-saturator-lv2-0-3.605330f43" failed with status 2
builder for `/gnu/store/j51q8fqyhd949w2biyp5pwx6cl0f90zi-gx-saturator-lv2-0-3.605330f43.drv' failed with exit code 1
build of /gnu/store/j51q8fqyhd949w2biyp5pwx6cl0f90zi-gx-saturator-lv2-0-3.605330f43.drv failed
View build log at '/var/log/guix/drvs/j5/1q8fqyhd949w2biyp5pwx6cl0f90zi-gx-saturator-lv2-0-3.605330f43.drv.bz2'.
guix build: error: build of `/gnu/store/j51q8fqyhd949w2biyp5pwx6cl0f90zi-gx-saturator-lv2-0-3.605330f43.drv' failed
```

--
Thorsten Wilms <t_w_@freenet.de>
M
M
Maxim Cournoyer wrote on 14 Jul 2022 05:59
(name . Thorsten Wilms)(address . t_w_@freenet.de)(address . 52823@debbugs.gnu.org)
87k08gxs22.fsf@gmail.com
Hello Thorsten,

Thorsten Wilms <t_w_@freenet.de> writes:

Toggle quote (7 lines)
> Hi!
>
> gx-saturator-lv2-0-3m, gx-slow-gear-lv2-0-3, gx-vbass-preamp-lv2-0-2
> all fail in the same way, with many repetitons of `error: template
> with C linkage` and warnings for deprecated ‘GTypeDebugFlags’ and
> ‘GTimeVal’.Using gx-saturator as example:

It looks like they need to be updated (if updates for them exist), as
they seem to rely on deprecated glib functions.

Would you like to give it a try?

Thanks,

Maxim
T
T
Thorsten Wilms wrote on 14 Jul 2022 19:49
(name . Maxim Cournoyer)(address . maxim.cournoyer@gmail.com)(address . 52823@debbugs.gnu.org)
20220714194909.93ed2f2b325e9f671cadfa22@freenet.de
On Wed, 13 Jul 2022 23:59:49 -0400
Maxim Cournoyer <maxim.cournoyer@gmail.com> wrote:

Toggle quote (5 lines)
> It looks like they need to be updated (if updates for them exist), as
> they seem to rely on deprecated glib functions.
>
> Would you like to give it a try?

Hi Maxim! Well, I may look into it in the coming days.


--
Thorsten Wilms <t_w_@freenet.de>
T
T
Thorsten Wilms wrote on 17 Jul 2022 19:56
[PATCH 0/2] gnu: update gx plugins that failed to build.
(address . 52823@debbugs.gnu.org)
20220717195635.20876ade1ec2b16da97cff14@freenet.de
Hi!

gx-slow-gear-lv2 already works in the current tree. Updates for
gx-saturator-lv2 and gx-vbass-preamp-lv2 that make them build again
follow.

--
Thorsten Wilms <t_w_@freenet.de>
T
T
Thorsten Wilms wrote on 17 Jul 2022 20:00
[PATCH 1/2] gnu: gx-vbass-preamp-lv2: Update to latest commit to fix build issue.
(address . 52823@debbugs.gnu.org)(name . Thorsten Wilms)(address . t_w_@freenet.de)
20220717180017.6850-1-t_w_@freenet.de
* gnu/packages/music.scm (gx-vbass-preamp-lv2): Update to latest commit to fix build issue.
---
gnu/packages/music.scm | 10 +++++++---
1 file changed, 7 insertions(+), 3 deletions(-)

Toggle diff (38 lines)
diff --git a/gnu/packages/music.scm b/gnu/packages/music.scm
index 5bc5724370..a529d8de8d 100644
--- a/gnu/packages/music.scm
+++ b/gnu/packages/music.scm
@@ -49,6 +49,7 @@
;;; Copyright © 2022 Maxim Cournoyer <maxim.cournoyer@gmail.com>
;;; Copyright © 2022 Wamm K. D. <jaft.r@outlook.com>
;;; Copyright © 2022 Jose G Perez Taveras <josegpt27@gmail.com>
+;;; Copyright © 2022 Thorsten Wilms <t_w_@freenet.de>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -4100,8 +4101,8 @@ (define-public gx-guvnor-lv2
(license license:gpl3+)))
(define-public gx-vbass-preamp-lv2
- (let ((commit "eb999b0ca0ef4da40a59e458a9ab6e7042b96c99")
- (revision "2"))
+ (let ((commit "a7613f91a12d46a7a08a13461e526353ede7def0")
+ (revision "3"))
(package (inherit gx-guvnor-lv2)
(name "gx-vbass-preamp-lv2")
(version (string-append "0-" revision "." (string-take commit 9)))
@@ -4112,8 +4113,11 @@ (define-public gx-vbass-preamp-lv2
(commit commit)))
(sha256
(base32
- "0firap073ldw4nrykkd7jvyyj0jbl1nslxyzjj4kswazp99x7d9h"))
+ "00yj1v3pdry2ns9gv11zcap7prg0yix2vr66rljjpx3nz94fqk4b"))
(file-name (string-append name "-" version "-checkout"))))
+ (arguments
+ (substitute-keyword-arguments (package-arguments gx-guvnor-lv2)
+ ((#:make-flags flags) `(cons (string-append "CC=" ,(cxx-for-target)) ,flags))))
(inputs
(list lv2 gtk+-2))
(native-inputs
--
2.36.1
T
T
Thorsten Wilms wrote on 17 Jul 2022 20:00
[PATCH 2/2] gnu: gx-saturator-lv2: Update to latest commit to fix build issue.
(address . 52823@debbugs.gnu.org)(name . Thorsten Wilms)(address . t_w_@freenet.de)
20220717180017.6850-2-t_w_@freenet.de
* gnu/packages/music.scm (gx-saturator-lv2): Update to latest commit to fix build issue.
---
gnu/packages/music.scm | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)

Toggle diff (24 lines)
diff --git a/gnu/packages/music.scm b/gnu/packages/music.scm
index a529d8de8d..498f4b8deb 100644
--- a/gnu/packages/music.scm
+++ b/gnu/packages/music.scm
@@ -4208,7 +4208,7 @@ (define-public gx-suppa-tone-bender-lv2
pedal.")))
(define-public gx-saturator-lv2
- (let ((commit "605330f432c94b6eb3f8203cbe472befae959532")
+ (let ((commit "e8a4aecd8098752a924fac5e7464b78538e12bec")
(revision "3"))
(package (inherit gx-vbass-preamp-lv2)
(name "gx-saturator-lv2")
@@ -4220,7 +4220,7 @@ (define-public gx-saturator-lv2
(commit commit)))
(sha256
(base32
- "1w4nvh0rmxrv3s3hmh4fs74f3hc0jn31v00j769j7v68mqr7kawy"))
+ "1zdcmjy62cp57y2xh8lx9s4z1vbpb1ljq0sw0ii8r7k54lbc7czl"))
(file-name (string-append name "-" version "-checkout"))))
(home-page "https://github.com/brummer10/GxSaturator.lv2")
(synopsis "Saturation effect")
--
2.36.1
M
M
Maxime Devos wrote on 23 Jul 2022 15:29
Re: bug#52823: [PATCH 1/2] gnu: gx-vbass-preamp-lv2: Update to latest commit to fix build issue.
f21875c9-f674-fa40-9df4-3d937805ff15@telenet.be
On 17-07-2022 20:00, Thorsten Wilms wrote:
Toggle quote (3 lines)
> + (arguments
> + (substitute-keyword-arguments (package-arguments gx-guvnor-lv2)
> + ((#:make-flags flags) `(cons (string-append "CC=" ,(cxx-for-target)) ,flags))))
This presumably works but is fragile -- if at some point in time,
gx-guvnor-lv2 decides to change to a G-exp, this won't compile anymore.
Instead, you can do #~(cons (string-append "CC=" #$(cxx-for-target))
#$flags), which works whether or not gx-guvnor-lv2 uses S-exps or G-exps.
Also, I don't understand why you are doing CC=g++. CC stands for
c-compiler, not C++ compiler, so I would have expected "CC="
#$(cc-for-target) or "CXX=" #$(cxx-for-target) instead, unless
gx-vbass-preamp-lv2 is not following these conventions.
Otherwise, these patches look reasonable to me, though TBC, I did not
test them, I only looked at the patches theirselves.
Greetings,
Maxime.
Attachment: OpenPGP_signature
T
T
Thorsten Wilms wrote on 24 Jul 2022 12:19
(name . Maxime Devos)(address . maximedevos@telenet.be)(address . 52823@debbugs.gnu.org)
20220724121940.305cef17dfd3b36f9376ef70@freenet.de
On Sat, 23 Jul 2022 15:29:31 +0200
Maxime Devos <maximedevos@telenet.be> wrote:

Toggle quote (11 lines)
>
> On 17-07-2022 20:00, Thorsten Wilms wrote:
> > + (arguments
> > + (substitute-keyword-arguments (package-arguments gx-guvnor-lv2)
> > + ((#:make-flags flags) `(cons (string-append "CC=" ,(cxx-for-target)) ,flags))))
>
> This presumably works but is fragile -- if at some point in time,
> gx-guvnor-lv2 decides to change to a G-exp, this won't compile anymore.
> Instead, you can do #~(cons (string-append "CC=" #$(cxx-for-target))
> #$flags), which works whether or not gx-guvnor-lv2 uses S-exps or G-exps.

I admit that whole construct is from the helpful people in #guix,
answering my question on how to still inherit, but add to the arguments.
Also, what I used to know about quoting in Scheme, I have forgotten!


Toggle quote (5 lines)
> Also, I don't understand why you are doing CC=g++. CC stands for
> c-compiler, not C++ compiler, so I would have expected "CC="
> #$(cc-for-target) or "CXX=" #$(cxx-for-target) instead, unless
> gx-vbass-preamp-lv2 is not following these conventions.

Well, CC=gcc was the intention, no idea how I mixed that up. BTW, where
does cc-for-target come from and why doesn’t a simple string suffice?

Thank you Maxime, for having a look and pointing out the issues!

What should I send, where, now? Here’s the patch that has to change:


* gnu/packages/music.scm (gx-vbass-preamp-lv2): Update to latest commit to fix build issue.
---
gnu/packages/music.scm | 10 +++++++---
1 file changed, 7 insertions(+), 3 deletions(-)

Toggle diff (41 lines)
diff --git a/gnu/packages/music.scm b/gnu/packages/music.scm
index 697fae8fc0..9174320ce0 100644
--- a/gnu/packages/music.scm
+++ b/gnu/packages/music.scm
@@ -49,6 +49,7 @@
;;; Copyright © 2022 Maxim Cournoyer <maxim.cournoyer@gmail.com>
;;; Copyright © 2022 Wamm K. D. <jaft.r@outlook.com>
;;; Copyright © 2022 Jose G Perez Taveras <josegpt27@gmail.com>
+;;; Copyright © 2022 Thorsten Wilms <t_w_@freenet.de>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -4100,8 +4101,8 @@ (define-public gx-guvnor-lv2
(license license:gpl3+)))
(define-public gx-vbass-preamp-lv2
- (let ((commit "eb999b0ca0ef4da40a59e458a9ab6e7042b96c99")
- (revision "2"))
+ (let ((commit "a7613f91a12d46a7a08a13461e526353ede7def0")
+ (revision "3"))
(package (inherit gx-guvnor-lv2)
(name "gx-vbass-preamp-lv2")
(version (string-append "0-" revision "." (string-take commit 9)))
@@ -4112,8 +4113,11 @@ (define-public gx-vbass-preamp-lv2
(commit commit)))
(sha256
(base32
- "0firap073ldw4nrykkd7jvyyj0jbl1nslxyzjj4kswazp99x7d9h"))
+ "00yj1v3pdry2ns9gv11zcap7prg0yix2vr66rljjpx3nz94fqk4b"))
(file-name (string-append name "-" version "-checkout"))))
+ (arguments
+ (substitute-keyword-arguments (package-arguments gx-guvnor-lv2)
+ ((#:make-flags flags) #~(cons (string-append "CC=" #$(cc-for-target)) #$flags))))
(inputs
(list lv2 gtk+-2))
(native-inputs
--
2.37.0

--
Thorsten Wilms <t_w_@freenet.de>
M
M
Maxime Devos wrote on 24 Jul 2022 12:57
(name . Thorsten Wilms)(address . t_w_@freenet.de)(address . 52823@debbugs.gnu.org)
5d0c0b03-bced-f168-359b-7ffc0999c190@telenet.be
On 24-07-2022 12:19, Thorsten Wilms wrote:
Toggle quote (2 lines)
> Well, CC=gcc was the intention, no idea how I mixed that up. BTW, where
> does cc-for-target come from and why doesn’t a simple string suffice?
It comes from (guix utils). It suffices when compiling natively, but not
when cross-compiling, because when cross-compiling to TARGET, you need
the cross-compiler TARGET-gcc to produce the right binaries.
(cc-for-target) emits "gcc" when compiling natively and "TARGET-gcc"
when cross-compiling.
Not hardcoding a particular compiler (gcc or clang) would also help to
allow --with-c-toolchain to override the compiler to use (see
right bits are in the right places yet for that to work.
Greetings,
Maxime
Attachment: OpenPGP_signature
?