From: Yann E. MORIN <yann.morin.1998@free.fr>
To: buildroot@busybox.net
Subject: [Buildroot] [PATCH 4/8 v4] support/download: add possibility to not fail on missing hash
Date: Sun, 19 Apr 2015 11:42:08 +0200 [thread overview]
Message-ID: <20150419094208.GF4313@free.fr> (raw)
In-Reply-To: <552C54AC.9050905@mind.be>
Arnout, All,
On 2015-04-14 01:43 +0200, Arnout Vandecappelle spake thusly:
> On 08/04/15 18:57, Yann E. MORIN wrote:
> > In very constrained cases, it might be needed to not fail if a hash is
> > missing. This is notably the case for custom external toolchains to be
> > downloaded, because we do have a .hash file for external toolchains,
> > but we oviously can not have hashes for all existing cutom toolchains
> obviously custom
>
> > (he, "custom"!).
>
> So what is it going to be cutom or custom? :-)
I pondered using 'coton', but that had no meaning. So I've decided for
'custom' instead. ;-)
All typoes fixed. Well, at least the ones you pointed out! ;-)
[--SNIP--]
> > diff --git a/support/download/check-hash b/support/download/check-hash
> > index d37f1cd..ca81f00 100755
> > --- a/support/download/check-hash
> > +++ b/support/download/check-hash
> > @@ -99,6 +99,11 @@ while read t h f; do
> > done <"${h_file}"
> >
> > if [ ${nb_checks} -eq 0 ]; then
> > + for f in ${BR_NO_CHECK_HASH_FOR}; do
> > + if [ "${f}" = "${base}" ]; then
> > + exit 0
> > + fi
> > + done
>
> I can't stop myself from micro-optimising :-)
>
> if [ ${nb_checks} -eq 0 ]; then
> case " ${BR_NO_CHECK_HASH_FOR} " in
> "* ${base} *")
> exit 0
> ;;
> esac
> printf "ERROR: No hash found for %s\n" "${base}" >&2
> exit 0
> fi
>
> But maybe that's not really more readable...
Yeah, I can read that no problem. I don't care which to use, so I'll
switch over to using case.
Regards,
Yann E. MORIN.
--
.-----------------.--------------------.------------------.--------------------.
| Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ |
| +33 223 225 172 `------------.-------: X AGAINST | \e/ There is no |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. |
'------------------------------^-------^------------------^--------------------'
next prev parent reply other threads:[~2015-04-19 9:42 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-04-08 16:57 [Buildroot] [PATCH 0/8 v4] toolchain: better handle hashes (branch yem/dl-hash-toolchains) Yann E. MORIN
2015-04-08 16:57 ` [Buildroot] [PATCH 1/8 v4] package/gcc: add hashes Yann E. MORIN
2015-04-13 23:32 ` Arnout Vandecappelle
2015-04-19 9:13 ` Yann E. MORIN
2015-04-08 16:57 ` [Buildroot] [PATCH 2/8 v4] package/binutils: " Yann E. MORIN
2015-04-13 23:35 ` Arnout Vandecappelle
2015-04-08 16:57 ` [Buildroot] [PATCH 3/8 v4] package/uclibc: add missing hash for eXtensa Yann E. MORIN
2015-04-13 23:36 ` Arnout Vandecappelle
2015-04-08 16:57 ` [Buildroot] [PATCH 4/8 v4] support/download: add possibility to not fail on missing hash Yann E. MORIN
2015-04-13 23:43 ` Arnout Vandecappelle
2015-04-19 9:42 ` Yann E. MORIN [this message]
2015-04-08 16:57 ` [Buildroot] [PATCH 5/8 v4] toolchain/external: ignore missing hash for custom downloaded toolchain Yann E. MORIN
2015-04-13 23:44 ` Arnout Vandecappelle
2015-04-08 16:57 ` [Buildroot] [PATCH 6/8 v4] package/uclibc: ignore missing hash for snapshots Yann E. MORIN
2015-04-13 23:45 ` Arnout Vandecappelle
2015-04-08 16:57 ` [Buildroot] [PATCH 7/8 v4] support/download: restore mandatory check of hashes Yann E. MORIN
2015-04-13 23:46 ` Arnout Vandecappelle
2015-04-08 16:57 ` [Buildroot] [PATCH 8/8 v4] support/download: do not accept exlcuded files with ashes Yann E. MORIN
2015-04-13 23:56 ` Arnout Vandecappelle
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=20150419094208.GF4313@free.fr \
--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