GNU bug report logs -
#32293
wrap-program with non-colon separtor produces incorrect bash substitutions
Previous Next
Reported by: Jelle Licht <jlicht <at> fsfe.org>
Date: Fri, 27 Jul 2018 15:52:01 UTC
Severity: normal
Done: Jelle Licht <jlicht <at> fsfe.org>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
Hi all,
While working to package some lua-related stuff, I need to deal with the
LUA_PATH environment variable. This variable uses `;' as a separator, and
as such, I wanted to wrap one of my programs
--8<---------------cut here---------------start------------->8---
...
(wrap-program (string-append out "/bin/fennel")
`("LUA_PATH" ";" prefix (,path)))
...
--8<---------------cut here---------------end--------------->8---
... which gives me the following snippet for the fennel script:
--8<---------------cut here---------------start------------->8---
export LUA_PATH="/gnu/store/3yjzvzwczi37snccrxbw7xsmbns1qc7a-fennel-1-1.f2a3d3b/share/lua/5.3/?.lua${LUA_PATH;+;}$LUA_PATH"
--8<---------------cut here---------------end--------------->8---
... which is not a correct bash substitution. I _think_ the first `;' in
`{LUA_PATH;+;}' needs to be a colon instead, at least if `wrap-program'
is only used to generate bash-compliant wrappers.
It seems this can be (easily?) fixed around guix/build/utils.scm:1055,
but any changes I made there had me starting to build bash and other
things from scratch.
This bug report was last modified 6 years and 279 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.