Message ID | 52c57042714d524c092002e64dfd53e4ebde5b02.camel@telenet.be |
---|---|
State | New |
Headers | show |
Series | [bug#49437,core-updates] build-system/qt: Fix build failures when | expand |
Context | Check | Description |
---|---|---|
cbaines/applying patch | fail | View Laminar job |
cbaines/issue | success | View issue |
Hey, > One of the features of 'qt-build-system' is that it automatically > creates wrappers, but it needs 'bash' (or 'bash-minimal') to do > so. If "bin/bash" doesn't exist among the 'inputs', then > 'search-input-file' (used by 'wrap-all-programs') will raise an > exception. Address this exception by adding "bash-minimal" to > 'host-inputs' when cross-compiling. I'd like to test it but it looks like qt-build-system drags glib which uses the meson-build-system that doesn't support cross-compilation. Did you test this patch, on top of your meson series? Otherwise, it looks fine to me. Thanks, Mathieu
Mathieu Othacehe schreef op do 08-07-2021 om 21:37 [+0200]: > Hey, > > > One of the features of 'qt-build-system' is that it automatically > > creates wrappers, but it needs 'bash' (or 'bash-minimal') to do > > so. If "bin/bash" doesn't exist among the 'inputs', then > > 'search-input-file' (used by 'wrap-all-programs') will raise an > > exception. Address this exception by adding "bash-minimal" to > > 'host-inputs' when cross-compiling. > > I'd like to test it but it looks like qt-build-system drags glib which > uses the meson-build-system that doesn't support cross-compilation. > > Did you test this patch, on top of your meson series? I had started "./pre-inst-env guix build qtsvg" but that's no cross-compilation. I'll rebase the meson series and test it! Greetings, Maxime.
Hello, Maxime Devos <maximedevos@telenet.be> writes: > Mathieu Othacehe schreef op do 08-07-2021 om 21:37 [+0200]: >> Hey, >> >> > One of the features of 'qt-build-system' is that it automatically >> > creates wrappers, but it needs 'bash' (or 'bash-minimal') to do >> > so. If "bin/bash" doesn't exist among the 'inputs', then >> > 'search-input-file' (used by 'wrap-all-programs') will raise an >> > exception. Address this exception by adding "bash-minimal" to >> > 'host-inputs' when cross-compiling. >> >> I'd like to test it but it looks like qt-build-system drags glib which >> uses the meson-build-system that doesn't support cross-compilation. >> >> Did you test this patch, on top of your meson series? > > I had started "./pre-inst-env guix build qtsvg" but that's no > cross-compilation. I'll rebase the meson series and test it! Did it test fine? Thanks, Maxim
Maxim Cournoyer schreef op wo 22-09-2021 om 23:53 [-0400]: > Hello, > > Maxime Devos <maximedevos@telenet.be> writes: > > > Mathieu Othacehe schreef op do 08-07-2021 om 21:37 [+0200]: > > > Hey, > > > > > > > One of the features of 'qt-build-system' is that it automatically > > > > creates wrappers, but it needs 'bash' (or 'bash-minimal') to do > > > > so. If "bin/bash" doesn't exist among the 'inputs', then > > > > 'search-input-file' (used by 'wrap-all-programs') will raise an > > > > exception. Address this exception by adding "bash-minimal" to > > > > 'host-inputs' when cross-compiling. > > > > > > I'd like to test it but it looks like qt-build-system drags glib which > > > uses the meson-build-system that doesn't support cross-compilation. > > > > > > Did you test this patch, on top of your meson series? > > > > I had started "./pre-inst-env guix build qtsvg" but that's no > > cross-compilation. I'll rebase the meson series and test it! > > Did it test fine? Didn't test it yet, because I first wanted the meson series merged. Now the meson series and the gtk+ cross-compilation fixes are merged, I'll take a look again. > Thanks, > > Maxim
From b9e46156e1f35303b56fbe2ed4694385b6104214 Mon Sep 17 00:00:00 2001 From: Maxime Devos <maximedevos@telenet.be> Date: Tue, 6 Jul 2021 10:57:49 +0200 Subject: [PATCH core-updates] build-system/qt: Fix build failures when cross-compiling. One of the features of 'qt-build-system' is that it automatically creates wrappers, but it needs 'bash' (or 'bash-minimal') to do so. If "bin/bash" doesn't exist among the 'inputs', then 'search-input-file' (used by 'wrap-all-programs') will raise an exception. Address this exception by adding "bash-minimal" to 'host-inputs' when cross-compiling. This change does not impact native compilation; the derivations for natively-compiled packages remain identical. * guix/build-system/qt.scm (bash-for-wrappers): New procedure. (lower): Add 'bash-minimal' to 'host-inputs' when cross-compiling. --- guix/build-system/qt.scm | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/guix/build-system/qt.scm b/guix/build-system/qt.scm index ccee89d5ef..9fa90baeeb 100644 --- a/guix/build-system/qt.scm +++ b/guix/build-system/qt.scm @@ -3,6 +3,7 @@ ;;; Copyright © 2013 Cyril Roelandt <tipecaml@gmail.com> ;;; Copyright © 2017 Ricardo Wurmus <rekado@elephly.net> ;;; Copyright © 2019 Hartmut Goebel <h.goebel@crazy-compilers.com> +;;; Copyright © 2021 Maxime Devos <maximedevos@telenet.be> ;;; ;;; This file is part of GNU Guix. ;;; @@ -63,6 +64,13 @@ (let ((module (resolve-interface '(gnu packages cmake)))) (module-ref module 'cmake-minimal))) +(define (bash-for-wrappers) + "Return the bash package to use for wrappers." + + ;; Do not use `@' to avoid introducing circular dependencies. + (let ((module (resolve-interface '(gnu packages bash)))) + (module-ref module 'bash-minimal))) + ;; This barely is a copy from (guix build-system cmake), only adjusted to use ;; the variables defined here. (define* (lower name @@ -91,7 +99,12 @@ '()) ;; Keep the standard inputs of 'gnu-build-system'. ,@(standard-packages))) - (host-inputs inputs) + ;; Make sure the 'qt-wrap' phase has a cross-compiled bash + ;; for wrappers when cross-compiling. + (host-inputs `(,@(if target + `(("bash-minimal" ,(bash-for-wrappers))) + '()) + ,@inputs)) ;; The cross-libc is really a target package, but for bootstrapping ;; reasons, we can't put it in 'host-inputs'. Namely, 'cross-gcc' is a -- 2.32.0