help-guix
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: help with use of %current-target-system parameter and gexps


From: Mathieu Othacehe
Subject: Re: help with use of %current-target-system parameter and gexps
Date: Sun, 15 Aug 2021 08:02:42 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux)

Hello Thiago,

> +                ;; LuaJIT is not ported to powerpc64le* yet.
> +                (if (string-prefix? "powerpc64le"
> +                                    (or (%current-target-system)
> +                                        (%current-system)))
> +                    (substitute* fmtutilcnf
> +                      (((string-append "^(luajittex|luajithbtex|mfluajit)") 
> m)
> +                       (string-append "#! " m))))
>                  ;; Register SHARE as TEXMFROOT in texmf.cnf.
>                  (substitute* texmfcnf
>                    (("TEXMFROOT = \\$SELFAUTOPARENT")
>

The issue here is that the %current-target-system and %current-system
are not defined at build time. You need to force their evaluation by
using "unquote", this way:

--8<---------------cut here---------------start------------->8---
(arguments
 `(#:phases
   ...
   (if (string-prefix? "powerpc64le"
                      ,(or (%current-target-system)
                           (%current-system)))
      ...)))
--8<---------------cut here---------------end--------------->8---
>
> +                #~(let-system (system target)
> +                    ;; LuaJIT is not ported to powerpc64le* yet.

Here also you need to unquote this part, using "ungexp":

--8<---------------cut here---------------start------------->8---
   #$(let-system (system target)
      ...
--8<---------------cut here---------------end--------------->8---

Thanks,

Mathieu



reply via email to

[Prev in Thread] Current Thread [Next in Thread]