From: Yann E. MORIN <yann.morin.1998@free.fr>
To: buildroot@busybox.net
Subject: [Buildroot] [PATCH] package/rustc: allow cargo sub packages to download using 'git'
Date: Sun, 21 Feb 2021 09:20:35 +0100 [thread overview]
Message-ID: <20210221082035.GX2276@scaer> (raw)
In-Reply-To: <20210221075134.11739-1-guillaume.bressaix@gmail.com>
Guillaume, All,
+Thomas for reference to his series
+Thomas +Arnout +Peter for their insight, toward the end
On 2021-02-21 08:51 +0100, guillaume.bressaix at gmail.com spake thusly:
> From: "Guillaume W. Bres" <guillaume.bressaix@gmail.com>
>
> Adding this simple command to the general cargo configuration
> will allow sub packages (with their own cargo.toml file)
> to resolve dependencies using 'git'. Without this,
> we only support builtin packages or manually downloaded
> packages refered to with a local full path.
In fact, we explicitly do not want that to happen, because this means
that downloads happen during the build, not during the actual download
step. This prevents reproducible archives and thus reproducible builds,
and means that the output of legal-info is missing pieces.
There is a work in progress to support vendoring in the various
language-specific package managers like cargo, see this series from
Thomas:
http://lists.busybox.net/pipermail/buildroot/2020-December/298802.html
The idea is that we manage the vendoring as part of the download step,
so that we can get totally off-line builds, and so that we can have
(slightly more) reproducible builds (as long as the archive is cached
locally or on a site-local mirror), and so that we can do a exhaustive
legal-info.
However, we have found a major roadblock for this, and we still have no
clear idea how to solve it.
The aforementioned series works pretty well, if one does not use primary
or backup mirrors. This is because the archive is (most probably) named
after the package and its version, but its content will be different when
we download it from the mirrors, compared to when we download it from
upstream: the upstream one will not be vendored, while the mirrored one
will.
This would cause quite a conflict, and we still do not see how to fix
that. Yet. I have a few ideas floating around in my head for now, but
that's not ready for primetime yet...
Of course, until this is solved, I don't know how to workaround the
vendoring problem imposed on us by those damn language-specific package
managers...
Maybe we could allow such a hack as yours for now, but really I have
little sympathy for those language-specific package managers. :-(
Regards,
Yann E. MORIN.
> Signed-off-by: Guillaume W. Bres <guillaume.bressaix@gmail.com>
> ---
> package/rustc/cargo-config.in | 3 +++
> 1 file changed, 3 insertions(+)
>
> diff --git a/package/rustc/cargo-config.in b/package/rustc/cargo-config.in
> index 47fad026be..be4c401f97 100644
> --- a/package/rustc/cargo-config.in
> +++ b/package/rustc/cargo-config.in
> @@ -1,2 +1,5 @@
> [target. at RUSTC_TARGET_NAME@]
> linker = "@CROSS_PREFIX at gcc"
> +
> +[net]
> +git-fetch-with-cli = true
> --
> 2.20.1
>
> _______________________________________________
> buildroot mailing list
> buildroot at busybox.net
> http://lists.busybox.net/mailman/listinfo/buildroot
--
.-----------------.--------------------.------------------.--------------------.
| Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ |
| +33 561 099 427 `------------.-------: X AGAINST | \e/ There is no |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. |
'------------------------------^-------^------------------^--------------------'
next prev parent reply other threads:[~2021-02-21 8:20 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-02-21 7:51 [Buildroot] [PATCH] package/rustc: allow cargo sub packages to download using 'git' guillaume.bressaix at gmail.com
2021-02-21 8:20 ` Yann E. MORIN [this message]
2021-02-21 15:01 ` Guillaume Bres
2021-02-21 16:07 ` Yann E. MORIN
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=20210221082035.GX2276@scaer \
--to=yann.morin.1998@free.fr \
--cc=buildroot@busybox.net \
/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.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox