diff options
author | Paul Eggleton <paul.eggleton@linux.intel.com> | 2012-06-18 16:50:50 +0100 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2012-06-21 13:03:02 +0100 |
commit | 66123b92557a7c1d63c29e90d9a8ba4ef146fc8a (patch) | |
tree | 188349ddc12fc76b5c7031fe8df358bda67eafa5 /meta | |
parent | e56205257bbb3b1eab352b9d50fc52c920afd9b1 (diff) | |
download | poky-66123b92557a7c1d63c29e90d9a8ba4ef146fc8a.tar.gz |
classes/cml1: ensure -c menuconfig forces a rebuild next time
Ensure the following results in the kernel being rebuilt, repackaged and
re-deployed in the final step:
bitbake virtual/kernel
bitbake -c menuconfig virtual/kernel
[ make changes to the kernel configuration and save ]
bitbake virtual/kernel
If there are no changes to the configuration saved, the rebuild will not
be triggered.
Note that this relies on a function recently added to BitBake and
requires full hashing (i.e. BB_SIGNATURE_HANDLER must be set to a
signature handler that inherits from BasicHash) - if this is not the
case or the function is not available in the version of BitBake being
used this change will do nothing.
Fixes [YOCTO #2256].
(From OE-Core rev: 9bf6b60e1599cf5dd87089d42584583cdfd6807a)
Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta')
-rw-r--r-- | meta/classes/cml1.bbclass | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/meta/classes/cml1.bbclass b/meta/classes/cml1.bbclass index bd253117aa..fd80c18697 100644 --- a/meta/classes/cml1.bbclass +++ b/meta/classes/cml1.bbclass | |||
@@ -15,7 +15,23 @@ HOSTLDFLAGS = "${BUILD_LDFLAGS}" | |||
15 | HOST_LOADLIBES = "-lncurses" | 15 | HOST_LOADLIBES = "-lncurses" |
16 | 16 | ||
17 | python do_menuconfig() { | 17 | python do_menuconfig() { |
18 | try: | ||
19 | mtime = os.path.getmtime(".config") | ||
20 | except OSError: | ||
21 | mtime = 0 | ||
22 | |||
18 | oe_terminal("${SHELL} -c \"make menuconfig; echo 'Pausing for 5 seconds'; sleep 5\"", '${PN} Configuration', d) | 23 | oe_terminal("${SHELL} -c \"make menuconfig; echo 'Pausing for 5 seconds'; sleep 5\"", '${PN} Configuration', d) |
24 | |||
25 | # FIXME this check can be removed when the minimum bitbake version has been bumped | ||
26 | if hasattr(bb.build, 'write_taint'): | ||
27 | try: | ||
28 | newmtime = os.path.getmtime(".config") | ||
29 | except OSError: | ||
30 | newmtime = 0 | ||
31 | |||
32 | if newmtime > mtime: | ||
33 | bb.note("Configuration changed, recompile will be forced") | ||
34 | bb.build.write_taint('do_compile', d) | ||
19 | } | 35 | } |
20 | do_menuconfig[depends] += "ncurses-native:do_populate_sysroot" | 36 | do_menuconfig[depends] += "ncurses-native:do_populate_sysroot" |
21 | do_menuconfig[nostamp] = "1" | 37 | do_menuconfig[nostamp] = "1" |