[oe-commits] Bruce Ashfield : kernel-yocto: checkout known branch before leaving do_validate_branches

git at git.openembedded.org git at git.openembedded.org
Thu Dec 13 15:22:26 UTC 2012


Module: openembedded-core.git
Branch: danny
Commit: 36f4e23d037dae758cd42189f2ab00f22a1cd723
URL:    http://git.openembedded.org/?p=openembedded-core.git&a=commit;h=36f4e23d037dae758cd42189f2ab00f22a1cd723

Author: Bruce Ashfield <bruce.ashfield at windriver.com>
Date:   Thu Nov 29 13:42:22 2012 -0500

kernel-yocto: checkout known branch before leaving do_validate_branches

We should always leave the tree on a BSP branch or master when
do_validate_branches completes to avoid modifying version tracked
files are part of the build process. Modifying these files will lead
to errors when changing branches, since the contents would be lost.

This is evident in the case that a the meta branch is reset to a
known SRCREV and the tree was left on the meta branch. This branch
tracks the meta/meta-series, and other artifacts of the original
tree construction. When the build process runs, it updates these same
files, which creates a conflict when switching branches.

This has been fixed in the tree construction scripts to not track
these files, but a secondary fix is also required of not leaving
the build on these branches, to allow arbitrary trees to be built.

[YOCTO #3413]

Signed-off-by: Bruce Ashfield <bruce.ashfield at windriver.com>
Signed-off-by: Richard Purdie <richard.purdie at linuxfoundation.org>

---

 meta/classes/kernel-yocto.bbclass |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/meta/classes/kernel-yocto.bbclass b/meta/classes/kernel-yocto.bbclass
index f78d63b..528280e 100644
--- a/meta/classes/kernel-yocto.bbclass
+++ b/meta/classes/kernel-yocto.bbclass
@@ -326,6 +326,8 @@ do_validate_branches() {
 	if [ $? -eq 0 ]; then
 		# restore the branch for builds
 		git checkout -q -f ${KBRANCH}
+        else
+	        git checkout -q master
 	fi
 }
 





More information about the Openembedded-commits mailing list