From: <yann.morin@orange.com>
To: Arnout Vandecappelle <arnout@mind.be>
Cc: Thomas Petazzoni <thomas.petazzoni@bootlin.com>, buildroot@buildroot.org
Subject: Re: [Buildroot] [PATCH] package/pkg-download: do not try to vendor _EXTRA_DOWNLOADS
Date: Wed, 11 May 2022 08:00:56 +0200 [thread overview]
Message-ID: <32022_1652248858_627B511A_32022_163_1_20220511060056.GA2862@tl-lnx-nyma7486> (raw)
In-Reply-To: <4634ccff-2b76-5b91-0730-391c53b883b8@mind.be>
Arnout, All,
On 2022-05-10 21:24 +0200, Arnout Vandecappelle spake thusly:
> On 06/05/2022 07:21, yann.morin@orange.com wrote:
> >On 2022-05-05 22:37 +0200, Arnout Vandecappelle spake thusly:
[--SNIP--]
> >> Applied to master, thanks, with a few changes:
> >> - no loop needed for MAIN_DOWNLOAD, it can have only one;
> >In fact, that was on purpose: it can have no main download...
> >Indeed, a package can very well only declare extra downloads...
> >I forgot to explain that in the commit log, sorry.
> OK. However, somehow this seems to work:
Yes, otherwise we could not even install host-skeleton to begin with....
> So I don't think it is needed after all?
Still, I am not happy that we are in a situation that works by accident.
I'd much prefer we understand why exactly this does not break...
> The dl-wrapper script apparently
> doesn't do anything if the filename is empty.
It really works by accident:
1. we pass no URI, so I thought the dlwrapper would fail, as it
basically does:
download_and_check=0
for uri in "${uris[@]}"; do
...
done
if [ "${download_and_check}" -eq 0 ]; then
exit 1
fi
However, it does not even go that far...
2. even though there is no output file, we still pass the path to
the package output directory as the output path. So, as part of
validating the download, the wrapper checks if the output file
exists, and checks its hash:
if [ -e "${output}" ]; then
if support/download/check-hash ${quiet} "${hfile}" "${output}" ...
exit 0
...
fi
3. the output path does exist now, because we explicitly create it just
before calling the wrapper, because that's where we also locate the
lockfile.
So, this is all a bit fragile, and I am not feeling very happy about
that...
So, I'll cook up a fixup patch to revert to the previous behaviour of
not even attempting a download in that case.
Regards,
Yann E. MORIN.
--
____________
.-----------------.--------------------: _ :------------------.
| Yann E. MORIN | Real-Time Embedded | __/ ) | /"\ ASCII RIBBON |
| +33 534.541.179 | Software Designer | _/ - /' | \ / CAMPAIGN |
| +33 638.411.245 '--------------------: (_ `--, | X AGAINST |
| yann.morin (at) orange.com |_=" ,--' | / \ HTML MAIL |
'--------------------------------------:______/_____:------------------'
_________________________________________________________________________________________________________________________
Ce message et ses pieces jointes peuvent contenir des informations confidentielles ou privilegiees et ne doivent donc
pas etre diffuses, exploites ou copies sans autorisation. Si vous avez recu ce message par erreur, veuillez le signaler
a l'expediteur et le detruire ainsi que les pieces jointes. Les messages electroniques etant susceptibles d'alteration,
Orange decline toute responsabilite si ce message a ete altere, deforme ou falsifie. Merci.
This message and its attachments may contain confidential or privileged information that may be protected by law;
they should not be distributed, used or copied without authorisation.
If you have received this email in error, please notify the sender and delete this message and its attachments.
As emails may be altered, Orange is not liable for messages that have been modified, changed or falsified.
Thank you.
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
next prev parent reply other threads:[~2022-05-11 6:01 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-05-05 17:19 [Buildroot] [PATCH] package/pkg-download: do not try to vendor _EXTRA_DOWNLOADS yann.morin
2022-05-05 20:37 ` Arnout Vandecappelle
2022-05-06 5:21 ` yann.morin
2022-05-10 19:24 ` Arnout Vandecappelle
2022-05-11 6:00 ` yann.morin [this message]
2022-05-28 9:00 ` Peter Korsgaard
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=32022_1652248858_627B511A_32022_163_1_20220511060056.GA2862@tl-lnx-nyma7486 \
--to=yann.morin@orange.com \
--cc=arnout@mind.be \
--cc=buildroot@buildroot.org \
--cc=thomas.petazzoni@bootlin.com \
/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 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.