Am 19.12.2016 um 10:47 schrieb Ludovic Courtès:
The result of ‘file-append’ is not a string, but ‘string-append’ expects
two strings, hence the error.

‘file-append’ returns a “string-valued gexp”.  This is to say that, in a
staging context, it will produce a string.  For example:

  (scheme-file "foo" #~(foo bar #$(file-append nginx "/foo/bar")))

leads to a file “foo” containing:

  (foo bar "/gnu/store/…-nginx-1.2.3/foo/bar")

Thanks for the explanation (which to be frank would take me some time to understand).

Please reread you answer from the point of view of an administrator or somebody else who is not a Scheme programmer. Somebody who just wants to get some system up an running. He would answer like this:

Parton? What? "string-valued gexp", "staging context"? I do not care. I simply want to get the path to a file within a package.

Whatever you write above may be correct and may be understandable for every Scheme programmer. But this is discouraging for everybody who does not want to become a Scheme expert for administering his/her systems.

I already wasted about an hour just to try to get this path! This is crap!

-- 
Regards
Hartmut Goebel

| Hartmut Goebel          | h.goebel@crazy-compilers.com               |
| www.crazy-compilers.com | compilers which you thought are impossible |