From: Eric Bavier <bavier@posteo.net>
To: 39807@debbugs.gnu.org
Subject: [bug#39807] [PATCH] guix: pack: Only wrap executable files.
Date: Thu, 26 Mar 2020 21:29:56 -0500 [thread overview]
Message-ID: <9e3d0e2f06b5d7994d35d10d687773ac@posteo.net> (raw)
In-Reply-To: <87d09pohrj.fsf@gnu.org>
On 06.03.2020 05:16, Ludovic Courtès wrote:
> Hi,
>
> Eric Bavier <bavier@posteo.net> skribis:
>
>> From: Eric Bavier <bavier@member.fsf.org>
>>
>> I feel like a test should be added to tests/guix-pack-relocatable.sh,
>> but
>> I'm not sure how to do that while keeping the test lightweight.
>> Suggestions
>> welcome.
>
> Not sure how to do that. Since ‘guix pack’ accepts manifests, you
> could
> have a manifest containing a ‘computed-file’ with a file that shouldn’t
> be wrapped, and then you could ensure that’s indeed the case. Or you
> could try with ‘git-minimal’ or some other package that exhibits the
> problem?
I almost have a working test using 'git-minimal', but I'm not happy with
the quantity of code needed to setup, and I'm worried now that that test
would be relying on an implementation detail that could change in the
future without us noticing (e.g. a git subcommand that's currently a
shell script is subsumed into git so the test no longer checks what we
want).
So I think I'll try going the manifest/computed-file route instead.
>
>> * guix/scripts/pack.scm (wrapped-package)<build>: Build wrappers for
>> executable files and symlink others.
>
> [...]
>
>> - (for-each build-wrapper
>> - (append (find-files (string-append input "/bin"))
>> - (find-files (string-append input
>> "/sbin"))
>> - (find-files (string-append input
>> "/libexec")))))))
>> + (receive (executables others)
>
> I’d prefer srfi-11 ‘let-values’. :-)
I tried let-values to begin with, but I found 'receive' to be much
easier on the eyes. For the case of binding values from a single
expression, does let-values offer benefits? And there are no other uses
of let-values in this module, so precedent/consistency doesn't seem to
have weight.
> Otherwise LGTM, thanks!
Thanks for review (and ping)!
--
`~Eric
next prev parent reply other threads:[~2020-03-27 2:31 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-02-27 4:36 [bug#39807] [PATCH] guix: pack: Only wrap executable files Eric Bavier
2020-03-06 11:16 ` Ludovic Courtès
2020-03-24 17:51 ` Ludovic Courtès
2020-03-27 2:53 ` Eric Bavier
2020-03-27 2:29 ` Eric Bavier [this message]
[not found] ` <8d8a2e1209d82e136d36222683967956@posteo.net>
2020-03-29 14:39 ` Ludovic Courtès
2020-07-27 21:42 ` Eric Bavier
2020-10-21 5:09 ` Eric Bavier
2020-10-21 9:07 ` Ludovic Courtès
2020-10-21 15:12 ` Eric Bavier
2020-10-21 15:35 ` Ludovic Courtès
2020-10-21 16:21 ` Eric Bavier
2020-10-21 21:31 ` Ludovic Courtès
2020-10-21 23:51 ` Eric Bavier
2020-10-23 10:48 ` Ludovic Courtès
2020-10-30 15:13 ` bug#39807: " Eric Bavier
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=9e3d0e2f06b5d7994d35d10d687773ac@posteo.net \
--to=bavier@posteo.net \
--cc=39807@debbugs.gnu.org \
/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.