all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Ivan Sokolov <ivan-p-sokolov@ya.ru>
To: Bruno Victal <mirai@makinata.eu>
Cc: 62754@debbugs.gnu.org
Subject: [bug#62754] [PATCH] doc: Use G-Expressions for package definition example.
Date: Mon, 10 Apr 2023 22:00:41 +0300	[thread overview]
Message-ID: <873557r292.fsf@ya.ru> (raw)
In-Reply-To: <f895ae0c822a33051cdd9bb23e43a8fda412d962.1681139577.git.mirai@makinata.eu> (Bruno Victal's message of "Mon, 10 Apr 2023 16:13:30 +0100")

Bruno Victal <mirai@makinata.eu> writes:

> * doc/guix.texi (Build Phases): Use G-Expressions for example.
> ---
>  doc/guix.texi | 29 +++++++++++++++++------------
>  1 file changed, 17 insertions(+), 12 deletions(-)
>
> diff --git a/doc/guix.texi b/doc/guix.texi
> index ed42488882..100ad93a3e 100644
> --- a/doc/guix.texi
> +++ b/doc/guix.texi
> @@ -10131,21 +10131,26 @@ Build Phases
>      ;; other fields omitted
>      (build-system gnu-build-system)
>      (arguments
> -     '(#:phases (modify-phases %standard-phases
> -                  (delete 'configure)
> -                  (add-before 'build 'set-prefix-in-makefile
> -                    (lambda* (#:key outputs #:allow-other-keys)
> -                      ;; Modify the makefile so that its
> -                      ;; 'PREFIX' variable points to "out".
> -                      (let ((out (assoc-ref outputs "out")))
> -                        (substitute* "Makefile"
> -                          (("PREFIX =.*")
> -                           (string-append "PREFIX = "
> -                                          out "\n")))))))))))
> +     (list
> +      #:phases
> +      #~(modify-phases %standard-phases
> +          (delete 'configure)
> +          (add-before 'build 'set-prefix-in-makefile
> +            (lambda* (#:key inputs #:allow-other-keys)
> +              ;; Modify the makefile so that its
> +              ;; 'PREFIX' variable points to "out" and
> +              ;; 'XMLLINT' points to the correct path.
> +              (substitute* "Makefile"
> +                (("PREFIX =.*")
> +                 (string-append "PREFIX = " #$output "\n"))
> +                (("XMLLINT =.*")
> +                 (string-append "XMLLINT = "
> +                                (search-input-file inputs "/bin/xmllint")
> +                                "\n"))))))))))
>  @end lisp
>  
>  The new phase that is inserted is written as an anonymous procedure,
> -introduced with @code{lambda*}; it honors the @code{outputs} parameter
> +introduced with @code{lambda*}; it honors the @code{inputs} parameter
>  we have seen before.  @xref{Build Utilities}, for more about the helpers
>  used by this phase, and for more examples of @code{modify-phases}.
>  
>
> base-commit: b78d6ceaa07be3c7582627cd28712b67102e521c

inputs parameter has not previously appeared in the documentation, the
sentence before last does not make sense anymore.




  reply	other threads:[~2023-04-10 19:01 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-04-10 15:13 [bug#62754] [PATCH] doc: Use G-Expressions for package definition example Bruno Victal
2023-04-10 19:00 ` Ivan Sokolov [this message]
2023-04-11 12:19 ` [bug#62754] [PATCH v2] " Bruno Victal
2023-04-21  8:21   ` Nicolas Goaziou
2023-05-05 14:06     ` Simon Tournier
2023-05-06 14:19   ` [bug#62754] [PATCH v3] " Bruno Victal
2023-05-06 16:08     ` bug#62754: [PATCH] " Ludovic Courtès

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=873557r292.fsf@ya.ru \
    --to=ivan-p-sokolov@ya.ru \
    --cc=62754@debbugs.gnu.org \
    --cc=mirai@makinata.eu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.