GNU bug report logs - #39599
[PATCH 0/2] New build system: copy-build-system

Previous Next

Package: guix-patches;

Reported by: Pierre Neidhardt <mail <at> ambrevar.xyz>

Date: Fri, 14 Feb 2020 12:52:02 UTC

Severity: normal

Tags: patch

Done: Pierre Neidhardt <mail <at> ambrevar.xyz>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Mathieu Othacehe <m.othacehe <at> gmail.com>
To: 39599 <at> debbugs.gnu.org
Subject: [bug#39599] [PATCH 1/4] build-system: Add copy-build-system.
Date: Mon, 17 Feb 2020 12:48:56 +0100
Hey Pierre,

Thanks for this patch! A few remarks below.

> +@item @code{("foo/bar" "share/my-app/baz")}: Install @code{bar}t o @code{share/my-app/baz}.
                                                                   ^
                                                                   typo

> +  (and (not target)                               ;XXX: no cross-compilation

Why don't we support cross-compilation here?

> +    (set! target (if (string-suffix? "/" target)
> +                     (string-append target (basename source))
> +                     target))

We could use let instead of set!, right?

> +  (define* (make-file-predicate matches matches-regexp #:optional (default-value #t))
> +    (if (or matches matches-regexp)
> +        (lambda (file)
> +          (any (lambda (pred) (pred file))
> +               (append
> +                (map (lambda (str)
> +                       (lambda (f) (string-suffix? str f)))
> +                     (or matches '()))
> +                (map (lambda (regexp)
> +                       (lambda (f) (regexp-exec (make-regexp regexp) f)))
> +                     (or matches-regexp '())))))
> +        (const default-value)))

You could maybe explain a bit what this function does. And how 'file'
differs from 'f'.

Thanks,

Mathieu




This bug report was last modified 5 years and 147 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.