recutils cross-compilation "fix" breaks bash builtins

  • Done
  • quality assurance status badge
Details
4 participants
  • Liliana Marie Prikler
  • Liliana Marie Prikler
  • Maxime Devos
  • Tobias Geerinckx-Rice
Owner
unassigned
Submitted by
Liliana Marie Prikler
Severity
normal
L
L
Liliana Marie Prikler wrote on 16 May 2022 14:52
(address . bug-guix@gnu.org)(name . Tobias Geerinckx-Rice)(address . me@tobias.gr)
9841253361ff5e3caccd4702518c70bdba8ac622.camel@ist.tugraz.at
Hi Guix,

The fix in commit 20fbd870938e239c038d8524a56729f123f19f80, which lets
recutils cross-compile unfortunately omits support for the bash
builtins in all build modes, as recutils can't actually detect bash
headers there.

Unfortunately, recutils' configure.ac silently swallows this error in
the following check.
AM_CONDITIONAL([BASH_BUILTINS],
[test "x$bash_headers_available" = "xyes" && 
test "x$bash_builtins_enabled" = "xyes"])
I only noticed, because I symlink the builtins to lib/bash, where
they're actually needed, which causes runpath validation to fail
because the symlink points to a file that doesn't exist. I fixed this
locally, but still wanted y'all to know.

Is there a way we can support bash headers in cross-compilation
contexts? I don't think having bash:include as a native input is even
helpful here, is it? WDYT?
T
T
Tobias Geerinckx-Rice wrote on 16 May 2022 15:37
06620D98-9F42-4CFA-987B-A168AF2CAA66@tobias.gr
Yeah, I toyed with the idea of a 'assert-readrec-existence phase but it seemed a bit silly at the time. And look, now it vanished.

Headers being a native input looked and still looks hella sus to me, but presumably done for a reason...? (They said, optimistically.)

Kind regards,

T G-R

Sent on the go. Excuse or enjoy my brevity.
M
M
Maxime Devos wrote on 16 May 2022 17:15
Re: bug#55449: recutils cross-compilation "fix" breaks bash builtins
(name . Tobias Geerinckx-Rice)(address . me@tobias.gr)
34cbb7b148a055191a19e3737e0c19d2dee24b8b.camel@telenet.be
Liliana Marie Prikler schreef op ma 16-05-2022 om 14:52 [+0200]:
Toggle quote (7 lines)
> Is there a way we can support bash headers in cross-compilation
> contexts?  I don't think having bash:include as a native input is even
> helpful here, is it?  WDYT?
>
>


Maybe you can give https://issues.guix.gnu.org/55377 a try ... needs
a rebase though. No idea if it helps here.

Greetings,
Maxime.
-----BEGIN PGP SIGNATURE-----

iI0EABYKADUWIQTB8z7iDFKP233XAR9J4+4iGRcl7gUCYoJqdxccbWF4aW1lZGV2
b3NAdGVsZW5ldC5iZQAKCRBJ4+4iGRcl7jlFAP9oquYFI81vsot2tW2+AzLZRGYY
1EEZWzKCqvEYQZ50MgD7BzkBvjk8RKzNntNn0enPPC/n3r7vL4/5y8aZKnWldg8=
=BL35
-----END PGP SIGNATURE-----


L
L
Liliana Marie Prikler wrote on 4 Jun 2022 10:30
[PATCH] gnu: recutils: Use correct bash headers.
(address . 55449@debbugs.gnu.org)
18b93bc799d759f48d0645f971104277f2a3b066.camel@gmail.com
* gnu/packages/databases.scm (recutils)[arguments]: Convert to G-Expressions.
Drop gratuitous dirname.
[native-inputs]: Drop labels. Move bash:include...
[inputs]: ... here. Also add regular bash.
---
gnu/packages/databases.scm | 19 ++++++++-----------
1 file changed, 8 insertions(+), 11 deletions(-)

Toggle diff (35 lines)
diff --git a/gnu/packages/databases.scm b/gnu/packages/databases.scm
index 09d825af3e..5cd8cc2fa3 100644
--- a/gnu/packages/databases.scm
+++ b/gnu/packages/databases.scm
@@ -1527,20 +1527,17 @@ (define-public recutils
(build-system gnu-build-system)
(arguments
(list #:configure-flags
- '(list "--disable-static"
- (string-append "--with-bash-headers="
- (dirname (search-input-directory
- %build-inputs
- "include/bash"))))))
+ #~(list "--disable-static"
+ (string-append "--with-bash-headers="
+ (search-input-directory %build-inputs
+ "include/bash")))))
(native-inputs
- ;; XXX Without labels, the default 'configure phase picks the wrong "bash".
- `(("bc" ,bc)
- ("bash:include" ,bash "include")
- ("check" ,check-0.14)
- ("pkg-config" ,pkg-config)))
+ (list bc check-0.14 pkg-config))
(inputs
;; TODO: Add more optional inputs.
- (list curl
+ (list bash ; /bin/bash for native compilation
+ `(,bash "include")
+ curl
libgcrypt
`(,util-linux "lib")))
(synopsis "Manipulate plain text files as databases")
--
2.36.1
L
L
Liliana Marie Prikler wrote on 18 Jun 2023 09:39
(address . 55449-done@debbugs.gnu.org)
fbdd6d6533c0550b37bfd66d2c1ae3cef13d8e26.camel@gmail.com
Am Samstag, dem 04.06.2022 um 10:30 +0200 schrieb Liliana Marie
Prikler:
Toggle quote (6 lines)
> * gnu/packages/databases.scm (recutils)[arguments]: Convert to G-
> Expressions.
> Drop gratuitous dirname.
> [native-inputs]: Drop labels.  Move bash:include...
> [inputs]: ... here.  Also add regular bash.
> ---
Hi Guix, I've pushed this now.

There's still a UX issue in that recutils doesn't put these libraries
into lib/bash, but at the very least it works as described in the
manual right now.

Cheers
Closed
?