poky/scripts
Richard Purdie c5cc4993f0 sstatesig/sstate: Add support for locked down sstate cache usage
I've been giving things some thought, specifically why sstate doesn't
get used more and why we have people requesting external toolchains. I'm
guessing the issue is that people don't like how often sstate can change
and the lack of an easy way to lock it down.

Locking it down is actually quite easy so patch implements some basics
of how you can do this (for example to a specific toolchain). With an
addition like this to local.conf (or wherever):

SIGGEN_LOCKEDSIGS = "\
gcc-cross:do_populate_sysroot:a8d91b35b98e1494957a2ddaf4598956 \
eglibc:do_populate_sysroot:13e8c68553dc61f9d67564f13b9b2d67 \
eglibc:do_packagedata:bfca0db1782c719d373f8636282596ee \
gcc-cross:do_packagedata:4b601ff4f67601395ee49c46701122f6 \
"

the code at the end of the email will force the hashes to those values
for the recipes mentioned. The system would then find and use those
specific objects from the sstate cache instead of trying to build
anything.

Obviously this is a little simplistic, you might need to put an override
against this to only apply those revisions for a specific architecture
for example. You'd also probably want to put code in the sstate hash
validation code to ensure it really did install these from sstate since
if it didn't you'd want to abort the build.

This patch also implements support to add to bitbake -S which dumps the
locked sstate checksums for each task into a ready prepared include file
locked-sigs.inc (currently placed into cwd). There is a function,
bb.parse.siggen.dump_lockedsigs() which can be called to trigger the
same functionality from task space.

A warning is added to sstate.bbclass through a call back into the siggen
class to warn if objects are not used from the locked cache. The
SIGGEN_ENFORCE_LOCKEDSIGS variable controls whether this is just a warning
or a fatal error.

A script is provided to generate sstate directory from a locked-sigs file.

(From OE-Core rev: 7e14784f2493a19c6bfe3ec3f05a5cf9797a2f22)

(From OE-Core rev: 884d4fa3e77cf32836f14a113c11489076f4a84d)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-09-17 22:00:25 +01:00
..
contrib scripts/contrib/build-perf-test: Update eglibc -> glibc 2014-09-03 11:09:04 +01:00
jhbuild
lib wic: Completely remove all urlgrabber references 2014-09-10 11:33:25 +01:00
native-intercept
postinst-intercepts gdk-pixbuf: pass GDK_PIXBUF_FATAL_LOADER where relevant 2014-04-01 23:39:14 +01:00
pybootchartgui pybootchartgui: Add option -T to allways use the full time 2014-01-23 10:17:36 +00:00
tiny scripts: Add ksize.py and dirsize.py 2013-10-29 10:41:39 +00:00
bitbake-prserv-tool bitbake-prserv-tool: make help text show .conf suffix 2014-02-17 15:37:17 +00:00
bitbake-whatchanged scripts: consolidate code to find bitbake path 2014-06-25 13:51:45 +01:00
buildhistory-collect-srcrevs buildhistory-collect-srcrevs: match new buildhistory-diff command line parsing 2013-08-16 11:44:17 +01:00
buildhistory-diff scripts: consolidate code to find bitbake path 2014-06-25 13:51:45 +01:00
cleanup-workdir cleanup-workdir: Fix crosssdk reference after addition of PN 2014-05-05 09:05:42 +01:00
combo-layer combo-layer: fix revlist taking into account file_filter 2014-06-01 14:29:30 +01:00
combo-layer-hook-default.sh
combo-layer.conf.example
cp-noerror scripts/cp-noerror: Avoid a race 2014-02-02 11:23:45 +00:00
create-pull-request create-pull-request: Error message on missing -u 2013-02-08 14:50:36 +00:00
create-recipe scripts/create-recipe: minor fixes 2014-09-03 11:09:03 +01:00
crosstap crosstap: handle hyphenated x86_64 target arch 2013-02-05 15:22:45 +00:00
gen-lockedsig-cache sstatesig/sstate: Add support for locked down sstate cache usage 2014-09-17 22:00:25 +01:00
gen-site-config
help2man
hob scripts/hob: enable additional arguments 2013-05-14 14:57:27 +03:00
lnr scripts: add lnr (link relative) 2014-03-07 14:58:45 +00:00
multilib_header_wrapper.h
oe-buildenv-internal oe-buildenv-internal: Ensure error messages got to stderr 2013-06-18 17:33:15 +01:00
oe-find-native-sysroot oe-find-native-sysroot: minor optimization 2013-08-03 10:33:12 +01:00
oe-git-proxy oe-git-proxy: Use socat instead of BSD nc 2013-02-11 22:54:04 +00:00
oe-pkgdata-util oe-pkgdata-util: fix help text 2014-06-25 13:51:45 +01:00
oe-selftest scripts/oe-selftest: add command-line parsing and options 2014-07-19 00:09:00 +01:00
oe-setup-builddir oe-setup-builddir: small rework 2014-03-12 06:04:53 -07:00
oe-setup-rpmrepo oe-setup-rpmrepo: add native sysroot so nativepython can be found by env 2013-08-30 18:06:31 +01:00
oe-trim-schemas
oepydevshell-internal.py devshell: Add interactive python shell 2014-05-28 08:27:00 +01:00
opkg-query-helper.py classes/image: write image manifest 2013-11-26 23:01:32 +00:00
README
relocate_sdk.py relocate_sdk: Skip to do relocation if the file size is less than 64 byte 2014-06-17 08:59:21 +01:00
rootfs_rpm-extract-postinst.awk
rpm2cpio.sh
runqemu scripts/runqemu: avoid pipe with sed 2014-05-08 13:00:33 +01:00
runqemu-addptable2image
runqemu-export-rootfs runqemu-export-rootfs: Fix missing # in comment 2014-02-20 12:04:44 +00:00
runqemu-extract-sdk runqemu-extract-sdk: normalize paths to improve output 2014-07-03 17:41:16 +01:00
runqemu-gen-tapdevs runqemu: Replace use of ifconfig with ip 2013-05-16 00:09:47 +03:00
runqemu-ifdown runqemu-ifdown: clean up the remaining iptables rules 2013-08-30 16:23:47 +01:00
runqemu-ifup runqemu-ifup: when tunctl can't be found, say what package builds it 2013-08-26 11:47:17 +01:00
runqemu-internal runqemu-internal: add "console=ttyS0" to ramfs image kernel parameters 2014-05-21 09:09:02 +01:00
runqemu.README
send-error-report scripts/send-error-report: fetch /Errors/ instead of /. 2014-08-06 10:23:39 +01:00
send-pull-request send-pull-request: add extra CC argument 2013-02-06 09:37:22 +00:00
sstate-cache-management.sh sstate-cache-management: Minor cleanup of help text 2014-04-29 17:20:11 +01:00
sstate-diff-machines.sh sstate-diff-machines.sh: Return non-zero return code when there was some failure detected 2014-06-29 09:04:22 +01:00
sstate-sysroot-cruft.sh sstate-sysroot-cruft.sh: Improve to use it from CI 2014-08-11 12:30:51 +01:00
swabber-strace-attach
sysroot-relativelinks.py image/populate_sdk: Ensure symlinks in target sysroot are relative 2013-09-11 11:05:05 +01:00
test-dependencies.sh test-dependencies, insane.bbclass: improve the message 2014-08-11 11:27:32 +01:00
test-reexec
test-remote-image scripts/test-remote-image: use the scriptpath module 2014-07-19 00:09:01 +01:00
wic wic: Add kickstart reference to help system 2014-07-16 10:20:48 +01:00
wipe-sysroot wipe-sysroot: explain what is being deleted, and check for arguments 2014-01-02 13:08:40 +00:00
yocto-bsp yocto-bsp: add basic git connectivity check 2013-01-16 12:08:01 +00:00
yocto-kernel yocto-kernel: add support for destroying recipe-space kernel features 2013-03-17 23:10:28 +00:00
yocto-layer yocto-layer: add optional layer priority param 2013-01-20 13:05:39 +00:00

This directory contains Various useful scripts for working with OE builds