* Official policy to list checksums
@ 2010-01-23 20:06 Paul Menzel
2010-01-24 7:06 ` Denys Dmytriyenko
0 siblings, 1 reply; 22+ messages in thread
From: Paul Menzel @ 2010-01-23 20:06 UTC (permalink / raw)
To: openembedded-devel
[-- Attachment #1: Type: text/plain, Size: 530 bytes --]
Dear OE hackers,
does [1] still describe the official policy to add checksums? Or is
putting them into the recipes preferred nowadays?
For example
SRC_URI[whois.md5sum] = "18d74a07d711262b75f04a1c319bc833"
SRC_URI[whois.sha256sum] = "fb13316c09ff9f98bd9af659d0789c9a09b97757f5c6c3dbfbc790250d5c5abc"
from [2].
Thanks,
Paul
[1] http://wiki.openembedded.net/index.php/Checksums
[2] http://cgit.openembedded.org/cgit.cgi/openembedded/commit/?id=310b2cd8919a13280b445537893c109b66c5275c
[-- Attachment #2: Dies ist ein digital signierter Nachrichtenteil --]
[-- Type: application/pgp-signature, Size: 205 bytes --]
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: Official policy to list checksums
2010-01-23 20:06 Official policy to list checksums Paul Menzel
@ 2010-01-24 7:06 ` Denys Dmytriyenko
2010-01-24 10:29 ` Koen Kooi
0 siblings, 1 reply; 22+ messages in thread
From: Denys Dmytriyenko @ 2010-01-24 7:06 UTC (permalink / raw)
To: openembedded-devel
On Sat, Jan 23, 2010 at 09:06:13PM +0100, Paul Menzel wrote:
> does [1] still describe the official policy to add checksums? Or is
No
> putting them into the recipes preferred nowadays?
Yes
> For example
>
> SRC_URI[whois.md5sum] = "18d74a07d711262b75f04a1c319bc833"
> SRC_URI[whois.sha256sum] = "fb13316c09ff9f98bd9af659d0789c9a09b97757f5c6c3dbfbc790250d5c5abc"
Please read "Death by checksums" thread here:
http://thread.gmane.org/gmane.comp.handhelds.openembedded/27465
--
Denys
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: Official policy to list checksums
2010-01-24 7:06 ` Denys Dmytriyenko
@ 2010-01-24 10:29 ` Koen Kooi
2010-01-24 11:08 ` Frans Meulenbroeks
2010-01-25 1:56 ` Denys Dmytriyenko
0 siblings, 2 replies; 22+ messages in thread
From: Koen Kooi @ 2010-01-24 10:29 UTC (permalink / raw)
To: openembedded-devel
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On 24-01-10 08:06, Denys Dmytriyenko wrote:
> On Sat, Jan 23, 2010 at 09:06:13PM +0100, Paul Menzel wrote:
>> does [1] still describe the official policy to add checksums? Or is
>
> No
>
>> putting them into the recipes preferred nowadays?
>
> Yes
I think not! The new format:
* is not documented
* it has no tools to autogenerate it
* has not been agreed on in any way.
As an experiment I tried to use it for a branch at work and I
*absolutely* hate the workflow needed for the new format.
With checksums.ini it's a matter of:
either
cat /OE/tmp/checksums.ini >> conf/checksums.ini ; python
contrib/source-checker/oe-checksum-sorter -i conf/checksums.ini
or
Verbatimly copy/paste the *output* OE gives you into conf/checksums.ini.
These concerns have been raised time after time and still haven't been
addressed, so for now:
checksums.ini is the way to go
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.5 (Darwin)
iD8DBQFLXCEkMkyGM64RGpERAsSuAKCL8RKc/w03gNou79d3HXJbf8wqtACgnkrn
0jZ/RL/sSIoBxyLT4vGaMdc=
=K1O3
-----END PGP SIGNATURE-----
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: Official policy to list checksums
2010-01-24 10:29 ` Koen Kooi
@ 2010-01-24 11:08 ` Frans Meulenbroeks
2010-01-24 11:13 ` Koen Kooi
2010-01-25 1:56 ` Denys Dmytriyenko
1 sibling, 1 reply; 22+ messages in thread
From: Frans Meulenbroeks @ 2010-01-24 11:08 UTC (permalink / raw)
To: openembedded-devel
> With checksums.ini it's a matter of:
>
> either
>
> cat /OE/tmp/checksums.ini >> conf/checksums.ini ; python
> contrib/source-checker/oe-checksum-sorter -i conf/checksums.ini
What I do is have a local script in my openebedded dir which just does:
#!/bin/bash
git checkout conf/checksums.ini ; cat ../tmp/checksums.ini
conf/checksums.ini >tmp_sums
python contrib/source-checker/oe-checksums-sorter.py tmp_sums
>conf/checksums.ini
rm tmp_sums
after that when adding if the # of lines added is different from what
I expect (typically I expect 4 for one new entry) I verify while
adding.
Pretty straightforward.
Actually maybe I should even extend the script by doing a git pull
--rebase first and invoke git add -i after that (because typically I
add the checksum when I want to commit a new recipe).
Frans
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: Official policy to list checksums
2010-01-24 11:08 ` Frans Meulenbroeks
@ 2010-01-24 11:13 ` Koen Kooi
2010-01-24 11:25 ` Paul Menzel
0 siblings, 1 reply; 22+ messages in thread
From: Koen Kooi @ 2010-01-24 11:13 UTC (permalink / raw)
To: openembedded-devel
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On 24-01-10 12:08, Frans Meulenbroeks wrote:
>> With checksums.ini it's a matter of:
>>
>> either
>>
>> cat /OE/tmp/checksums.ini >> conf/checksums.ini ; python
>> contrib/source-checker/oe-checksum-sorter -i conf/checksums.ini
>
> What I do is have a local script in my openebedded dir which just does:
>
> #!/bin/bash
> git checkout conf/checksums.ini ; cat ../tmp/checksums.ini
> conf/checksums.ini >tmp_sums
> python contrib/source-checker/oe-checksums-sorter.py tmp_sums
>> conf/checksums.ini
> rm tmp_sums
the sorter now understands '-i', so it can sort the file 'in place',
which avoids the need for the tmp_sums file.
regards,
Koen
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.5 (Darwin)
iD8DBQFLXCtJMkyGM64RGpERAgfOAJ4zZKncAHHmugLycj0rAvQIP/cqwACcDOWE
i8JTIN1qKu6d58rbQ1e+iUw=
=iDcD
-----END PGP SIGNATURE-----
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: Official policy to list checksums
2010-01-24 11:13 ` Koen Kooi
@ 2010-01-24 11:25 ` Paul Menzel
0 siblings, 0 replies; 22+ messages in thread
From: Paul Menzel @ 2010-01-24 11:25 UTC (permalink / raw)
To: openembedded-devel
[-- Attachment #1: Type: text/plain, Size: 318 bytes --]
Am Sonntag, den 24.01.2010, 12:13 +0100 schrieb Koen Kooi:
> the sorter now understands '-i', so it can sort the file 'in place',
> which avoids the need for the tmp_sums file.
I updated the Wiki page [1].
Thanks,
Paul
[1] http://wiki.openembedded.net/index.php?title=Checksums&diff=prev&oldid=2161
[-- Attachment #2: Dies ist ein digital signierter Nachrichtenteil --]
[-- Type: application/pgp-signature, Size: 205 bytes --]
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: Official policy to list checksums
2010-01-24 10:29 ` Koen Kooi
2010-01-24 11:08 ` Frans Meulenbroeks
@ 2010-01-25 1:56 ` Denys Dmytriyenko
2010-01-25 1:59 ` [PATCH 0/2] simplify switch to new SRC_URI-based checksums Denys Dmytriyenko
` (4 more replies)
1 sibling, 5 replies; 22+ messages in thread
From: Denys Dmytriyenko @ 2010-01-25 1:56 UTC (permalink / raw)
To: openembedded-devel
On Sun, Jan 24, 2010 at 11:29:56AM +0100, Koen Kooi wrote:
> On 24-01-10 08:06, Denys Dmytriyenko wrote:
> > On Sat, Jan 23, 2010 at 09:06:13PM +0100, Paul Menzel wrote:
> >> does [1] still describe the official policy to add checksums? Or is
> >
> > No
> >
> >> putting them into the recipes preferred nowadays?
> >
> > Yes
>
> I think not! The new format:
>
> * is not documented
I think there were plenty of emails describing the new format. Need to put it
all in a Wiki page, agree.
> * it has no tools to autogenerate it
Give me few minutes - I'll send something to address this point.
> * has not been agreed on in any way.
Actually, specifying checksums in corresponding recipes was agreed on during
the OEDEM in November. Using additional variable flags in base.bbclass was
added by Phil, since bitbake cannot handle SHA256 sums in SRC_URI. Although,
Richard mentioned he'd like to get it implemented in bitbake at some point:
http://thread.gmane.org/gmane.comp.sysutils.bitbake.devel/1089/focus=1115
> As an experiment I tried to use it for a branch at work and I
> *absolutely* hate the workflow needed for the new format.
You should have warned me! :) I thought you completely switched to the new
method and liked it... :)
--
Denys
^ permalink raw reply [flat|nested] 22+ messages in thread
* [PATCH 0/2] simplify switch to new SRC_URI-based checksums
2010-01-25 1:56 ` Denys Dmytriyenko
@ 2010-01-25 1:59 ` Denys Dmytriyenko
2010-01-25 1:59 ` [PATCH 1/2] base.bbclass: pre-create SRC_URI checksums to include in the recipe Denys Dmytriyenko
` (3 subsequent siblings)
4 siblings, 0 replies; 22+ messages in thread
From: Denys Dmytriyenko @ 2010-01-25 1:59 UTC (permalink / raw)
To: openembedded-devel
The first patch adds the code to pre-generate SRC_URI-based checksums in
TMPDIR, allowing easy addition of those checksums in the recipe with
minimal editing.
The second patch removes the old code to generate missing checksums.ini
entries - can be applied later, once the switch to the new method is
complete and proven.
Denys Dmytriyenko (2):
base.bbclass: pre-create SRC_URI checksums to include in the recipe
base.bbclass: don't pre-generate checksums.ini entries any longer
classes/base.bbclass | 23 ++++++++++++++---------
1 files changed, 14 insertions(+), 9 deletions(-)
^ permalink raw reply [flat|nested] 22+ messages in thread
* [PATCH 1/2] base.bbclass: pre-create SRC_URI checksums to include in the recipe
2010-01-25 1:56 ` Denys Dmytriyenko
2010-01-25 1:59 ` [PATCH 0/2] simplify switch to new SRC_URI-based checksums Denys Dmytriyenko
@ 2010-01-25 1:59 ` Denys Dmytriyenko
2010-01-25 7:17 ` Khem Raj
2010-01-25 7:19 ` Frans Meulenbroeks
2010-01-25 1:59 ` [PATCH 2/2] base.bbclass: don't pre-generate checksums.ini entries any longer Denys Dmytriyenko
` (2 subsequent siblings)
4 siblings, 2 replies; 22+ messages in thread
From: Denys Dmytriyenko @ 2010-01-25 1:59 UTC (permalink / raw)
To: openembedded-devel
Signed-off-by: Denys Dmytriyenko <denis@denix.org>
---
classes/base.bbclass | 18 ++++++++++++++++++
1 files changed, 18 insertions(+), 0 deletions(-)
diff --git a/classes/base.bbclass b/classes/base.bbclass
index 384a67d..8465286 100644
--- a/classes/base.bbclass
+++ b/classes/base.bbclass
@@ -151,9 +151,27 @@ def base_chk_file(parser, pn, pv, src_uri, localpath, data):
file.write("[%s]\nmd5=%s\nsha256=%s\n\n" % (src_uri, md5data, shadata))
file.close()
+
+ from string import maketrans
+ trtable = maketrans("", "")
+ uname = src_uri.split("/")[-1].translate(trtable, "-+._")
+
+ try:
+ ufile = open("%s/%s.sum" % (bb.data.getVar("TMPDIR", data, 1), uname), "wt")
+ except:
+ return False
+
+ if not ufile:
+ raise Exception("Creating %s.sum failed" % uname)
+
+ ufile.write("SRC_URI = \"%s;name=%s\"\nSRC_URI[%s.md5sum] = \"%s\"\nSRC_URI[%s.sha256sum] = \"%s\"\n" % (src_uri, uname, uname, md5data, uname, shadata))
+ ufile.close()
+
if not bb.data.getVar("OE_STRICT_CHECKSUMS",data, True):
bb.note("This package has no entry in checksums.ini, please add one")
bb.note("\n[%s]\nmd5=%s\nsha256=%s" % (src_uri, md5data, shadata))
+ bb.note("This package has no checksums in corresponding recipe, please add")
+ bb.note("SRC_URI = \"%s;name=%s\"\nSRC_URI[%s.md5sum] = \"%s\"\nSRC_URI[%s.sha256sum] = \"%s\"\n" % (src_uri, uname, uname, md5data, uname, shadata))
return True
else:
bb.note("Missing checksum")
--
1.6.3.3
^ permalink raw reply related [flat|nested] 22+ messages in thread
* [PATCH 2/2] base.bbclass: don't pre-generate checksums.ini entries any longer
2010-01-25 1:56 ` Denys Dmytriyenko
2010-01-25 1:59 ` [PATCH 0/2] simplify switch to new SRC_URI-based checksums Denys Dmytriyenko
2010-01-25 1:59 ` [PATCH 1/2] base.bbclass: pre-create SRC_URI checksums to include in the recipe Denys Dmytriyenko
@ 2010-01-25 1:59 ` Denys Dmytriyenko
2010-01-25 7:18 ` Khem Raj
2010-01-25 7:24 ` Official policy to list checksums Khem Raj
2010-01-25 8:19 ` Koen Kooi
4 siblings, 1 reply; 22+ messages in thread
From: Denys Dmytriyenko @ 2010-01-25 1:59 UTC (permalink / raw)
To: openembedded-devel
Signed-off-by: Denys Dmytriyenko <denis@denix.org>
---
classes/base.bbclass | 15 +--------------
1 files changed, 1 insertions(+), 14 deletions(-)
diff --git a/classes/base.bbclass b/classes/base.bbclass
index 8465286..8e14636 100644
--- a/classes/base.bbclass
+++ b/classes/base.bbclass
@@ -140,18 +140,7 @@ def base_chk_file(parser, pn, pv, src_uri, localpath, data):
except OSError:
raise Exception("Executing shasum failed")
- if no_checksum == True: # we do not have conf/checksums.ini entry
- try:
- file = open("%s/checksums.ini" % bb.data.getVar("TMPDIR", data, 1), "a")
- except:
- return False
-
- if not file:
- raise Exception("Creating checksums.ini failed")
-
- file.write("[%s]\nmd5=%s\nsha256=%s\n\n" % (src_uri, md5data, shadata))
- file.close()
-
+ if no_checksum == True: # we do not have SRC_URI checksums
from string import maketrans
trtable = maketrans("", "")
uname = src_uri.split("/")[-1].translate(trtable, "-+._")
@@ -168,8 +157,6 @@ def base_chk_file(parser, pn, pv, src_uri, localpath, data):
ufile.close()
if not bb.data.getVar("OE_STRICT_CHECKSUMS",data, True):
- bb.note("This package has no entry in checksums.ini, please add one")
- bb.note("\n[%s]\nmd5=%s\nsha256=%s" % (src_uri, md5data, shadata))
bb.note("This package has no checksums in corresponding recipe, please add")
bb.note("SRC_URI = \"%s;name=%s\"\nSRC_URI[%s.md5sum] = \"%s\"\nSRC_URI[%s.sha256sum] = \"%s\"\n" % (src_uri, uname, uname, md5data, uname, shadata))
return True
--
1.6.3.3
^ permalink raw reply related [flat|nested] 22+ messages in thread
* Re: [PATCH 1/2] base.bbclass: pre-create SRC_URI checksums to include in the recipe
2010-01-25 1:59 ` [PATCH 1/2] base.bbclass: pre-create SRC_URI checksums to include in the recipe Denys Dmytriyenko
@ 2010-01-25 7:17 ` Khem Raj
2010-01-25 7:19 ` Frans Meulenbroeks
1 sibling, 0 replies; 22+ messages in thread
From: Khem Raj @ 2010-01-25 7:17 UTC (permalink / raw)
To: openembedded-devel
On Sun, Jan 24, 2010 at 5:59 PM, Denys Dmytriyenko <denis@denix.org> wrote:
> Signed-off-by: Denys Dmytriyenko <denis@denix.org>
> ---
> classes/base.bbclass | 18 ++++++++++++++++++
> 1 files changed, 18 insertions(+), 0 deletions(-)
>
> diff --git a/classes/base.bbclass b/classes/base.bbclass
> index 384a67d..8465286 100644
> --- a/classes/base.bbclass
> +++ b/classes/base.bbclass
> @@ -151,9 +151,27 @@ def base_chk_file(parser, pn, pv, src_uri, localpath, data):
>
> file.write("[%s]\nmd5=%s\nsha256=%s\n\n" % (src_uri, md5data, shadata))
> file.close()
> +
> + from string import maketrans
> + trtable = maketrans("", "")
> + uname = src_uri.split("/")[-1].translate(trtable, "-+._")
> +
> + try:
> + ufile = open("%s/%s.sum" % (bb.data.getVar("TMPDIR", data, 1), uname), "wt")
> + except:
> + return False
> +
> + if not ufile:
> + raise Exception("Creating %s.sum failed" % uname)
> +
> + ufile.write("SRC_URI = \"%s;name=%s\"\nSRC_URI[%s.md5sum] = \"%s\"\nSRC_URI[%s.sha256sum] = \"%s\"\n" % (src_uri, uname, uname, md5data, uname, shadata))
> + ufile.close()
> +
> if not bb.data.getVar("OE_STRICT_CHECKSUMS",data, True):
> bb.note("This package has no entry in checksums.ini, please add one")
> bb.note("\n[%s]\nmd5=%s\nsha256=%s" % (src_uri, md5data, shadata))
> + bb.note("This package has no checksums in corresponding recipe, please add")
> + bb.note("SRC_URI = \"%s;name=%s\"\nSRC_URI[%s.md5sum] = \"%s\"\nSRC_URI[%s.sha256sum] = \"%s\"\n" % (src_uri, uname, uname, md5data, uname, shadata))
> return True
> else:
> bb.note("Missing checksum")
> --
> 1.6.3.3
looks good to me.
Acked-by: Khem Raj <raj.khem@gmail.com>
>
>
> _______________________________________________
> Openembedded-devel mailing list
> Openembedded-devel@lists.openembedded.org
> http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-devel
>
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: [PATCH 2/2] base.bbclass: don't pre-generate checksums.ini entries any longer
2010-01-25 1:59 ` [PATCH 2/2] base.bbclass: don't pre-generate checksums.ini entries any longer Denys Dmytriyenko
@ 2010-01-25 7:18 ` Khem Raj
2010-01-25 7:24 ` Frans Meulenbroeks
0 siblings, 1 reply; 22+ messages in thread
From: Khem Raj @ 2010-01-25 7:18 UTC (permalink / raw)
To: openembedded-devel
On Sun, Jan 24, 2010 at 5:59 PM, Denys Dmytriyenko <denis@denix.org> wrote:
> Signed-off-by: Denys Dmytriyenko <denis@denix.org>
> ---
> classes/base.bbclass | 15 +--------------
> 1 files changed, 1 insertions(+), 14 deletions(-)
>
> diff --git a/classes/base.bbclass b/classes/base.bbclass
> index 8465286..8e14636 100644
> --- a/classes/base.bbclass
> +++ b/classes/base.bbclass
> @@ -140,18 +140,7 @@ def base_chk_file(parser, pn, pv, src_uri, localpath, data):
> except OSError:
> raise Exception("Executing shasum failed")
>
> - if no_checksum == True: # we do not have conf/checksums.ini entry
> - try:
> - file = open("%s/checksums.ini" % bb.data.getVar("TMPDIR", data, 1), "a")
> - except:
> - return False
> -
> - if not file:
> - raise Exception("Creating checksums.ini failed")
> -
> - file.write("[%s]\nmd5=%s\nsha256=%s\n\n" % (src_uri, md5data, shadata))
> - file.close()
> -
> + if no_checksum == True: # we do not have SRC_URI checksums
> from string import maketrans
> trtable = maketrans("", "")
> uname = src_uri.split("/")[-1].translate(trtable, "-+._")
> @@ -168,8 +157,6 @@ def base_chk_file(parser, pn, pv, src_uri, localpath, data):
> ufile.close()
>
> if not bb.data.getVar("OE_STRICT_CHECKSUMS",data, True):
> - bb.note("This package has no entry in checksums.ini, please add one")
> - bb.note("\n[%s]\nmd5=%s\nsha256=%s" % (src_uri, md5data, shadata))
> bb.note("This package has no checksums in corresponding recipe, please add")
> bb.note("SRC_URI = \"%s;name=%s\"\nSRC_URI[%s.md5sum] = \"%s\"\nSRC_URI[%s.sha256sum] = \"%s\"\n" % (src_uri, uname, uname, md5data, uname, shadata))
> return True
> --
OK
Acked-by: Khem Raj <raj.khem@gmail.com>
> 1.6.3.3
>
>
> _______________________________________________
> Openembedded-devel mailing list
> Openembedded-devel@lists.openembedded.org
> http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-devel
>
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: [PATCH 1/2] base.bbclass: pre-create SRC_URI checksums to include in the recipe
2010-01-25 1:59 ` [PATCH 1/2] base.bbclass: pre-create SRC_URI checksums to include in the recipe Denys Dmytriyenko
2010-01-25 7:17 ` Khem Raj
@ 2010-01-25 7:19 ` Frans Meulenbroeks
1 sibling, 0 replies; 22+ messages in thread
From: Frans Meulenbroeks @ 2010-01-25 7:19 UTC (permalink / raw)
To: openembedded-devel
2010/1/25 Denys Dmytriyenko <denis@denix.org>:
> Signed-off-by: Denys Dmytriyenko <denis@denix.org>
> ---
> classes/base.bbclass | 18 ++++++++++++++++++
> 1 files changed, 18 insertions(+), 0 deletions(-)
>
> diff --git a/classes/base.bbclass b/classes/base.bbclass
> index 384a67d..8465286 100644
> --- a/classes/base.bbclass
> +++ b/classes/base.bbclass
> @@ -151,9 +151,27 @@ def base_chk_file(parser, pn, pv, src_uri, localpath, data):
>
> file.write("[%s]\nmd5=%s\nsha256=%s\n\n" % (src_uri, md5data, shadata))
> file.close()
> +
> + from string import maketrans
> + trtable = maketrans("", "")
> + uname = src_uri.split("/")[-1].translate(trtable, "-+._")
> +
> + try:
> + ufile = open("%s/%s.sum" % (bb.data.getVar("TMPDIR", data, 1), uname), "wt")
> + except:
> + return False
> +
> + if not ufile:
> + raise Exception("Creating %s.sum failed" % uname)
> +
> + ufile.write("SRC_URI = \"%s;name=%s\"\nSRC_URI[%s.md5sum] = \"%s\"\nSRC_URI[%s.sha256sum] = \"%s\"\n" % (src_uri, uname, uname, md5data, uname, shadata))
> + ufile.close()
> +
> if not bb.data.getVar("OE_STRICT_CHECKSUMS",data, True):
> bb.note("This package has no entry in checksums.ini, please add one")
> bb.note("\n[%s]\nmd5=%s\nsha256=%s" % (src_uri, md5data, shadata))
> + bb.note("This package has no checksums in corresponding recipe, please add")
> + bb.note("SRC_URI = \"%s;name=%s\"\nSRC_URI[%s.md5sum] = \"%s\"\nSRC_URI[%s.sha256sum] = \"%s\"\n" % (src_uri, uname, uname, md5data, uname, shadata))
> return True
> else:
> bb.note("Missing checksum")
> --
> 1.6.3.3
Nice!
Acked-by: Frans meulenbroeks <fransmeulenbroeks@gmail.com>
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: Official policy to list checksums
2010-01-25 1:56 ` Denys Dmytriyenko
` (2 preceding siblings ...)
2010-01-25 1:59 ` [PATCH 2/2] base.bbclass: don't pre-generate checksums.ini entries any longer Denys Dmytriyenko
@ 2010-01-25 7:24 ` Khem Raj
2010-01-25 8:19 ` Koen Kooi
4 siblings, 0 replies; 22+ messages in thread
From: Khem Raj @ 2010-01-25 7:24 UTC (permalink / raw)
To: openembedded-devel
On Sun, Jan 24, 2010 at 5:56 PM, Denys Dmytriyenko <denis@denix.org> wrote:
> On Sun, Jan 24, 2010 at 11:29:56AM +0100, Koen Kooi wrote:
>> On 24-01-10 08:06, Denys Dmytriyenko wrote:
>> > On Sat, Jan 23, 2010 at 09:06:13PM +0100, Paul Menzel wrote:
>> >> does [1] still describe the official policy to add checksums? Or is
>> >
>> > No
>> >
>> >> putting them into the recipes preferred nowadays?
>> >
>> > Yes
>>
>> I think not! The new format:
>>
>> * is not documented
>
> I think there were plenty of emails describing the new format. Need to put it
> all in a Wiki page, agree.
>
>> * it has no tools to autogenerate it
>
> Give me few minutes - I'll send something to address this point.
>
>> * has not been agreed on in any way.
>
> Actually, specifying checksums in corresponding recipes was agreed on during
> the OEDEM in November. Using additional variable flags in base.bbclass was
> added by Phil, since bitbake cannot handle SHA256 sums in SRC_URI. Although,
> Richard mentioned he'd like to get it implemented in bitbake at some point:
> http://thread.gmane.org/gmane.comp.sysutils.bitbake.devel/1089/focus=1115
>
>> As an experiment I tried to use it for a branch at work and I
>> *absolutely* hate the workflow needed for the new format.
>
> You should have warned me! :) I thought you completely switched to the new
> method and liked it... :)
I think it saves unneeded complete parse just for adding
one checksum to the checksum.ini file. While the old method
has tools and workflow in place. Same could be
done for new method too.
>
> --
> Denys
>
> _______________________________________________
> Openembedded-devel mailing list
> Openembedded-devel@lists.openembedded.org
> http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-devel
>
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: [PATCH 2/2] base.bbclass: don't pre-generate checksums.ini entries any longer
2010-01-25 7:18 ` Khem Raj
@ 2010-01-25 7:24 ` Frans Meulenbroeks
2010-01-25 8:00 ` Denys Dmytriyenko
0 siblings, 1 reply; 22+ messages in thread
From: Frans Meulenbroeks @ 2010-01-25 7:24 UTC (permalink / raw)
To: openembedded-devel
2010/1/25 Khem Raj <raj.khem@gmail.com>:
> On Sun, Jan 24, 2010 at 5:59 PM, Denys Dmytriyenko <denis@denix.org> wrote:
>> Signed-off-by: Denys Dmytriyenko <denis@denix.org>
>> ---
>> classes/base.bbclass | 15 +--------------
>> 1 files changed, 1 insertions(+), 14 deletions(-)
>>
>> diff --git a/classes/base.bbclass b/classes/base.bbclass
>> index 8465286..8e14636 100644
>> --- a/classes/base.bbclass
>> +++ b/classes/base.bbclass
>> @@ -140,18 +140,7 @@ def base_chk_file(parser, pn, pv, src_uri, localpath, data):
>> except OSError:
>> raise Exception("Executing shasum failed")
>>
>> - if no_checksum == True: # we do not have conf/checksums.ini entry
>> - try:
>> - file = open("%s/checksums.ini" % bb.data.getVar("TMPDIR", data, 1), "a")
>> - except:
>> - return False
>> -
>> - if not file:
>> - raise Exception("Creating checksums.ini failed")
>> -
>> - file.write("[%s]\nmd5=%s\nsha256=%s\n\n" % (src_uri, md5data, shadata))
>> - file.close()
>> -
>> + if no_checksum == True: # we do not have SRC_URI checksums
>> from string import maketrans
>> trtable = maketrans("", "")
>> uname = src_uri.split("/")[-1].translate(trtable, "-+._")
>> @@ -168,8 +157,6 @@ def base_chk_file(parser, pn, pv, src_uri, localpath, data):
>> ufile.close()
>>
>> if not bb.data.getVar("OE_STRICT_CHECKSUMS",data, True):
>> - bb.note("This package has no entry in checksums.ini, please add one")
>> - bb.note("\n[%s]\nmd5=%s\nsha256=%s" % (src_uri, md5data, shadata))
>> bb.note("This package has no checksums in corresponding recipe, please add")
>> bb.note("SRC_URI = \"%s;name=%s\"\nSRC_URI[%s.md5sum] = \"%s\"\nSRC_URI[%s.sha256sum] = \"%s\"\n" % (src_uri, uname, uname, md5data, uname, shadata))
>> return True
>> --
>
> OK
>
> Acked-by: Khem Raj <raj.khem@gmail.com>
Do we want to do this at this point? Or say in a week (or two) after
people got acquainted to the new format.
Btw: I'm not really a script kiddie, but I guess it should not be too
difficult to cook up a script to update the recipes so we can abandon
checksums.ini
(two mechanisms does not seem to be the right way).
Any takers?
Frans
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: [PATCH 2/2] base.bbclass: don't pre-generate checksums.ini entries any longer
2010-01-25 7:24 ` Frans Meulenbroeks
@ 2010-01-25 8:00 ` Denys Dmytriyenko
0 siblings, 0 replies; 22+ messages in thread
From: Denys Dmytriyenko @ 2010-01-25 8:00 UTC (permalink / raw)
To: openembedded-devel
On Mon, Jan 25, 2010 at 08:24:11AM +0100, Frans Meulenbroeks wrote:
> 2010/1/25 Khem Raj <raj.khem@gmail.com>:
> > On Sun, Jan 24, 2010 at 5:59 PM, Denys Dmytriyenko <denis@denix.org> wrote:
> >> Signed-off-by: Denys Dmytriyenko <denis@denix.org>
> > OK
> >
> > Acked-by: Khem Raj <raj.khem@gmail.com>
>
> Do we want to do this at this point? Or say in a week (or two) after
> people got acquainted to the new format.
Understandable, hence my comment in the summary message:
http://thread.gmane.org/gmane.comp.handhelds.openembedded/29487/focus=29560
The second patch removes the old code to generate missing checksums.ini
entries - can be applied later, once the switch to the new method is
complete and proven.
> Btw: I'm not really a script kiddie, but I guess it should not be too
> difficult to cook up a script to update the recipes so we can abandon
> checksums.ini
> (two mechanisms does not seem to be the right way).
> Any takers?
While it's possible to script, the migration path was defined as to only allow
deletion from the central checksums.ini file, while adding new checksums in
the corresponding recipes. Still, converting all the entries from the
checksums.ini at once would have been a fastest approach.
--
Denys
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: Official policy to list checksums
2010-01-25 1:56 ` Denys Dmytriyenko
` (3 preceding siblings ...)
2010-01-25 7:24 ` Official policy to list checksums Khem Raj
@ 2010-01-25 8:19 ` Koen Kooi
2010-01-25 8:43 ` Denys Dmytriyenko
4 siblings, 1 reply; 22+ messages in thread
From: Koen Kooi @ 2010-01-25 8:19 UTC (permalink / raw)
To: openembedded-devel
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On 25-01-10 02:56, Denys Dmytriyenko wrote:
> On Sun, Jan 24, 2010 at 11:29:56AM +0100, Koen Kooi wrote:
>> On 24-01-10 08:06, Denys Dmytriyenko wrote:
>>> On Sat, Jan 23, 2010 at 09:06:13PM +0100, Paul Menzel wrote:
>>>> does [1] still describe the official policy to add checksums? Or is
>>>
>>> No
>>>
>>>> putting them into the recipes preferred nowadays?
>>>
>>> Yes
>>
>> I think not! The new format:
>>
>> * is not documented
>
> I think there were plenty of emails describing the new format. Need to put it
> all in a Wiki page, agree.
>> * it has no tools to autogenerate it
>
> Give me few minutes - I'll send something to address this point.
>
>> * has not been agreed on in any way.
>
> Actually, specifying checksums in corresponding recipes was agreed on during
> the OEDEM in November. Using additional variable flags in base.bbclass was
> added by Phil, since bitbake cannot handle SHA256 sums in SRC_URI. Although,
> Richard mentioned he'd like to get it implemented in bitbake at some point:
> http://thread.gmane.org/gmane.comp.sysutils.bitbake.devel/1089/focus=1115
Ah yes, stuff agreed at OEDEM, I see. I also remember that nearly
everything that was 'agreed' there got dis-agreed on the mailinglist here.
And I also remember that I said that to be consistent sane-srcrevs
should cease to exist as well :)
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.5 (Darwin)
iD8DBQFLXVP7MkyGM64RGpERAuV7AJ9ReCKJDujV+1VS0IErq+Ne5sUF/ACdGYID
3/0DqfPuC8O5KmvQORdsipw=
=ukSY
-----END PGP SIGNATURE-----
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: Official policy to list checksums
2010-01-25 8:19 ` Koen Kooi
@ 2010-01-25 8:43 ` Denys Dmytriyenko
2010-01-25 8:52 ` Graeme Gregory
2010-01-25 9:55 ` Koen Kooi
0 siblings, 2 replies; 22+ messages in thread
From: Denys Dmytriyenko @ 2010-01-25 8:43 UTC (permalink / raw)
To: openembedded-devel
On Mon, Jan 25, 2010 at 09:19:07AM +0100, Koen Kooi wrote:
> >> * it has no tools to autogenerate it
> >
> > Give me few minutes - I'll send something to address this point.
Do you have any feedback on the patch I sent? Does it make things any better?
> >> * has not been agreed on in any way.
> >
> > Actually, specifying checksums in corresponding recipes was agreed on during
> > the OEDEM in November. Using additional variable flags in base.bbclass was
> > added by Phil, since bitbake cannot handle SHA256 sums in SRC_URI. Although,
> > Richard mentioned he'd like to get it implemented in bitbake at some point:
> > http://thread.gmane.org/gmane.comp.sysutils.bitbake.devel/1089/focus=1115
>
> Ah yes, stuff agreed at OEDEM, I see. I also remember that nearly
> everything that was 'agreed' there got dis-agreed on the mailinglist here.
> And I also remember that I said that to be consistent sane-srcrevs
> should cease to exist as well :)
This way we won't get anywhere... :) I thought (maybe I'm wrong) everybody
agrees at least with the fact that central checksums.ini is not the best
approach. Keeping checksums in the metadata inside SRC_URI seemed like a
viable solution. Are there any fundamental flaws with this method, besides
lacking some tools?
BTW, I agree with you on the sane-srcrevs topic, if it's any consolation... :)
--
Denys
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: Official policy to list checksums
2010-01-25 8:43 ` Denys Dmytriyenko
@ 2010-01-25 8:52 ` Graeme Gregory
2010-01-27 22:09 ` Denys Dmytriyenko
2010-01-25 9:55 ` Koen Kooi
1 sibling, 1 reply; 22+ messages in thread
From: Graeme Gregory @ 2010-01-25 8:52 UTC (permalink / raw)
To: openembedded-devel
On Mon, Jan 25, 2010 at 03:43:40AM -0500, Denys Dmytriyenko wrote:
> This way we won't get anywhere... :) I thought (maybe I'm wrong) everybody
> agrees at least with the fact that central checksums.ini is not the best
> approach. Keeping checksums in the metadata inside SRC_URI seemed like a
> viable solution. Are there any fundamental flaws with this method, besides
> lacking some tools?
I dont think there is any fundamental flaws, but there is still quite
a lot of cleanup work. Patches like
http://www.xora.org.uk/cgi-bin/cgit.cgi/openembedded/commit/?h=xora/gnome-update&id=d2074190e711eb70a0bd26d2ac5b89b4988044b5
Will need to be applied in some places.
Graeme
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: Official policy to list checksums
2010-01-25 8:43 ` Denys Dmytriyenko
2010-01-25 8:52 ` Graeme Gregory
@ 2010-01-25 9:55 ` Koen Kooi
1 sibling, 0 replies; 22+ messages in thread
From: Koen Kooi @ 2010-01-25 9:55 UTC (permalink / raw)
To: openembedded-devel
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On 25-01-10 09:43, Denys Dmytriyenko wrote:
> On Mon, Jan 25, 2010 at 09:19:07AM +0100, Koen Kooi wrote:
>>>> * it has no tools to autogenerate it
>>>
>>> Give me few minutes - I'll send something to address this point.
>
> Do you have any feedback on the patch I sent? Does it make things any better?
It seems to automate things a bit more, but I haven't tested them yet.
>
>>>> * has not been agreed on in any way.
>>>
>>> Actually, specifying checksums in corresponding recipes was agreed on during
>>> the OEDEM in November. Using additional variable flags in base.bbclass was
>>> added by Phil, since bitbake cannot handle SHA256 sums in SRC_URI. Although,
>>> Richard mentioned he'd like to get it implemented in bitbake at some point:
>>> http://thread.gmane.org/gmane.comp.sysutils.bitbake.devel/1089/focus=1115
>>
>> Ah yes, stuff agreed at OEDEM, I see. I also remember that nearly
>> everything that was 'agreed' there got dis-agreed on the mailinglist here.
>> And I also remember that I said that to be consistent sane-srcrevs
>> should cease to exist as well :)
>
> This way we won't get anywhere... :) I thought (maybe I'm wrong) everybody
> agrees at least with the fact that central checksums.ini is not the best
> approach.
It's not the best approach in a perfect world, but with the current
state of OE it is the best (or least bad) of the options out there.
> Keeping checksums in the metadata inside SRC_URI seemed like a
> viable solution.
Yes, but there wasn't any agreement on this. The only thing that came
out of this is that Phil coded some stuff and committed it.
What started all this was that some people found using checksums.ini too
hard. We can argue about that, but anyway. Now we seem to end up with a
system that's actually harder to use (at least without your patches)
*and* is lacking the most basic docs. It's not in the wiki nor in the
in-tree docs.
> Are there any fundamental flaws with this method, besides
> lacking some tools?
Complete lack of docs, e.g. what does the 'name' do? And why are people
doing http://foo.com/bar.c;name=tarball?
In ti/staging I've been giving them all unique names. Do I need to do
that? I 'name' even needed? I don't know and I suspect everyone minus
Phil doesn't either.
> BTW, I agree with you on the sane-srcrevs topic, if it's any consolation... :)
Good :) I want to be able to 'move' recipes between overlays and having
the checksums in the recipe itself is a step in the right direction,
having SRCREVs in the recipes themselves would be even better.
regards,
Koen
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.5 (Darwin)
iD8DBQFLXWqLMkyGM64RGpERAlHHAJ0ZrH+Q7vBIrxmQNbN1CpdETpRIEgCdGFSM
HoAqu5kPJ+8AEhruFIEq9Jg=
=hF0z
-----END PGP SIGNATURE-----
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: Official policy to list checksums
2010-01-25 8:52 ` Graeme Gregory
@ 2010-01-27 22:09 ` Denys Dmytriyenko
2010-02-21 10:37 ` Frans Meulenbroeks
0 siblings, 1 reply; 22+ messages in thread
From: Denys Dmytriyenko @ 2010-01-27 22:09 UTC (permalink / raw)
To: openembedded-devel
On Mon, Jan 25, 2010 at 08:52:46AM +0000, Graeme Gregory wrote:
> On Mon, Jan 25, 2010 at 03:43:40AM -0500, Denys Dmytriyenko wrote:
> > This way we won't get anywhere... :) I thought (maybe I'm wrong) everybody
> > agrees at least with the fact that central checksums.ini is not the best
> > approach. Keeping checksums in the metadata inside SRC_URI seemed like a
> > viable solution. Are there any fundamental flaws with this method, besides
> > lacking some tools?
>
> I dont think there is any fundamental flaws, but there is still quite
> a lot of cleanup work. Patches like
>
> http://www.xora.org.uk/cgi-bin/cgit.cgi/openembedded/commit/?h=xora/gnome-update&id=d2074190e711eb70a0bd26d2ac5b89b4988044b5
>
> Will need to be applied in some places.
Hmm, I haven't noticed there were SRC_URIs in classes... On the other hand,
the same needs to be done for .inc files.
BTW, I have applied the first patch - let me know when we are ready for the
second part. :)
--
Denys
^ permalink raw reply [flat|nested] 22+ messages in thread
* Re: Official policy to list checksums
2010-01-27 22:09 ` Denys Dmytriyenko
@ 2010-02-21 10:37 ` Frans Meulenbroeks
0 siblings, 0 replies; 22+ messages in thread
From: Frans Meulenbroeks @ 2010-02-21 10:37 UTC (permalink / raw)
To: openembedded-devel
2010/1/27 Denys Dmytriyenko <denis@denix.org>:
> On Mon, Jan 25, 2010 at 08:52:46AM +0000, Graeme Gregory wrote:
>> On Mon, Jan 25, 2010 at 03:43:40AM -0500, Denys Dmytriyenko wrote:
>> > This way we won't get anywhere... :) I thought (maybe I'm wrong) everybody
>> > agrees at least with the fact that central checksums.ini is not the best
>> > approach. Keeping checksums in the metadata inside SRC_URI seemed like a
>> > viable solution. Are there any fundamental flaws with this method, besides
>> > lacking some tools?
>>
>> I dont think there is any fundamental flaws, but there is still quite
>> a lot of cleanup work. Patches like
>>
>> http://www.xora.org.uk/cgi-bin/cgit.cgi/openembedded/commit/?h=xora/gnome-update&id=d2074190e711eb70a0bd26d2ac5b89b4988044b5
>>
>> Will need to be applied in some places.
>
> Hmm, I haven't noticed there were SRC_URIs in classes... On the other hand,
> the same needs to be done for .inc files.
>
> BTW, I have applied the first patch - let me know when we are ready for the
> second part. :)
What is the status of this?
I see that currently both the entries in checksums.ini and the format
for recipes are generated.
Of all possible scenarios this seems to be among the least desirable ones.
Are we ready for the 2nd patch as proposed by Denys ? (so no
generation of checksums.ini entries in the log if none exist)
And maybe some friendly encouragement (like we did with the commit
messages) towards those that still keep updating checksums.ini ?
Frans.
^ permalink raw reply [flat|nested] 22+ messages in thread
end of thread, other threads:[~2010-02-21 10:40 UTC | newest]
Thread overview: 22+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-01-23 20:06 Official policy to list checksums Paul Menzel
2010-01-24 7:06 ` Denys Dmytriyenko
2010-01-24 10:29 ` Koen Kooi
2010-01-24 11:08 ` Frans Meulenbroeks
2010-01-24 11:13 ` Koen Kooi
2010-01-24 11:25 ` Paul Menzel
2010-01-25 1:56 ` Denys Dmytriyenko
2010-01-25 1:59 ` [PATCH 0/2] simplify switch to new SRC_URI-based checksums Denys Dmytriyenko
2010-01-25 1:59 ` [PATCH 1/2] base.bbclass: pre-create SRC_URI checksums to include in the recipe Denys Dmytriyenko
2010-01-25 7:17 ` Khem Raj
2010-01-25 7:19 ` Frans Meulenbroeks
2010-01-25 1:59 ` [PATCH 2/2] base.bbclass: don't pre-generate checksums.ini entries any longer Denys Dmytriyenko
2010-01-25 7:18 ` Khem Raj
2010-01-25 7:24 ` Frans Meulenbroeks
2010-01-25 8:00 ` Denys Dmytriyenko
2010-01-25 7:24 ` Official policy to list checksums Khem Raj
2010-01-25 8:19 ` Koen Kooi
2010-01-25 8:43 ` Denys Dmytriyenko
2010-01-25 8:52 ` Graeme Gregory
2010-01-27 22:09 ` Denys Dmytriyenko
2010-02-21 10:37 ` Frans Meulenbroeks
2010-01-25 9:55 ` Koen Kooi
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.