Reza Housseini <[email protected]> writes: > I am trying to use g-expressions in nativ-search-paths field, but it fails > with > an error message, what is the issue her: > > (native-search-paths > (list (search-path-specification > (variable "CFDEM_SRC_DIR") > (files #~'((string-append "share/" #$name "-" #$version))))))
There's two issues here: One, you can't use a gexp in FILES. This will work fine: (files (list (string-append "share/" name "-" version))) Two, this: '(string-append "share/" name "-" version) does *not* evaluate to what you think it does; in fact, it becomes this: (list 'string-append "share/" 'name "-" 'version) a list of strings and symbols, because it's quoted. If you want to use an expression within a quoted form, you can use quasiquote: `(,(string-append …)) LIST works fine most of the time, though. -- (
