public inbox for openembedded-core@lists.openembedded.org
 help / color / mirror / Atom feed
* [master][PATCH 0/5] Allow PR Service and hash equiv together
@ 2020-08-24 23:29 Mark Hatle
  2020-08-24 23:29 ` [master][PATCH 1/5] package_tar.bbclass: Sync to the other package_* classes Mark Hatle
                   ` (5 more replies)
  0 siblings, 6 replies; 18+ messages in thread
From: Mark Hatle @ 2020-08-24 23:29 UTC (permalink / raw)
  To: openembedded-core

Before PR service didn't work reliably with hash equivalency.  Generally
you ended up with results that may not be reproducible, even if you
started with the same PR service database and hash equivalency database.

Overtime, intermediate PR values would be created that would cause thing
to get out of sync in the case of certain rebuilds or other corner cases.

The set refactors the PR service to work along side the new hash equiv
system.  It moves the PR and AUTOINC lookup to AFTER the do_package task
is complete.  This allows us to use the do_package unihash for lookup.

Additionally this fixed a small issue with the kernel, where the PR value
could get incremented twice.  The fix is an artifact of the other changes
that cause us to only run the PR service work once per recipe.

This has been tested with the following workflow, which covers one of
the critical corner cases for me:

configure local.conf with:

   BB_HASHSERVE = "auto"
   BB_SIGNATURE_HANDLER = "OEEquivHash"
   
   PRSERV_HOST ??= "localhost:0"
   
   INHERIT += "reproducible_build"
   INHERIT += "buildhistory"

bitbake glibc linux-yocto

# Modify meta/recipes-core/glibc/glibc_2.32.bb, add a comment
# to the do_patch_append().  This will taint the hash of this
# function.

bitbake glibc linux-yocto

# The system should have detected the output was the same, and
# no proceed past do_package in glibc.  The kernel should not
# have built at all.

# Store/mv the tmp and sstate-cache from that build elsewhere
# repeat the run

bitbake glibc linux-yocto

# Compare the results of tmp/deploy/<package>/* between last
# and current run.
#
# The contents should be the same (filenames specifically).
#
# Also the kernel should be r0.0, not r0.1.

Note: if the hash equivalency database or PR server database (located
in the cache directory) is removed, the values may not be the same
as the previous run.

Additionally while testing the various package_*.bbclass files, it
was noted that package_tar.bbclass was not working the same way as
the others.  This was correct as a standalone patch.

Mark Hatle (5):
  package_tar.bbclass: Sync to the other package_* classes
  hash equivalency and pr service
  package.bbclass: Move package_get_auto_pr to packagedata.bbclass
  package / packagedata bbclass: Change the way PRAUTO and AUTOINC are
    handled
  buildhistory.bbclass: Rework to use read_subpackage_metadata

 meta/classes/buildhistory.bbclass |  49 ++++++------
 meta/classes/kernel.bbclass       |   4 +-
 meta/classes/nopackages.bbclass   |   1 +
 meta/classes/package.bbclass      | 120 +++++++++++++++---------------
 meta/classes/package_tar.bbclass  |  11 +--
 meta/classes/packagedata.bbclass  |  69 +++++++++++++++++
 meta/conf/bitbake.conf            |   1 +
 meta/lib/oe/packagedata.py        |   8 +-
 meta/lib/oe/sstatesig.py          |   2 +
 9 files changed, 169 insertions(+), 96 deletions(-)

-- 
2.17.1


^ permalink raw reply	[flat|nested] 18+ messages in thread

end of thread, other threads:[~2020-08-25 22:10 UTC | newest]

Thread overview: 18+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-08-24 23:29 [master][PATCH 0/5] Allow PR Service and hash equiv together Mark Hatle
2020-08-24 23:29 ` [master][PATCH 1/5] package_tar.bbclass: Sync to the other package_* classes Mark Hatle
2020-08-25 10:49   ` [OE-core] " Richard Purdie
2020-08-24 23:29 ` [master][PATCH 2/5] hash equivalency and pr service Mark Hatle
2020-08-25 12:50   ` [OE-core] " Joshua Watt
2020-08-25 14:16     ` Mark Hatle
2020-08-25 18:36       ` Richard Purdie
2020-08-24 23:29 ` [master][PATCH 3/5] package.bbclass: Move package_get_auto_pr to packagedata.bbclass Mark Hatle
2020-08-24 23:29 ` [master][PATCH 4/5] package / packagedata bbclass: Change the way PRAUTO and AUTOINC are handled Mark Hatle
2020-08-25 10:56   ` [OE-core] " Richard Purdie
2020-08-25 14:14     ` Mark Hatle
     [not found]     ` <162E885FFA00831B.12036@lists.openembedded.org>
2020-08-25 16:52       ` Mark Hatle
2020-08-25 17:04         ` Richard Purdie
2020-08-25 22:10           ` Mark Hatle
2020-08-25 11:00   ` Richard Purdie
2020-08-24 23:29 ` [master][PATCH 5/5] buildhistory.bbclass: Rework to use read_subpackage_metadata Mark Hatle
2020-08-24 23:32 ` ✗ patchtest: failure for Allow PR Service and hash equiv together Patchwork
2020-08-25  1:17   ` Mark Hatle

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox