All of lore.kernel.org
 help / color / mirror / Atom feed
From: Richard Purdie <richard.purdie@linuxfoundation.org>
To: Bruce Ashfield <bruce.ashfield@windriver.com>
Cc: openembedded-core@lists.openembedded.org, saul.wold@intel.com
Subject: Re: [PATCH 1/4] linux-yocto: make KBRANCH the exception and not the rule
Date: Sat, 18 Aug 2012 13:07:45 +0100	[thread overview]
Message-ID: <1345291665.27428.36.camel@ted> (raw)
In-Reply-To: <9adc11ebd961b769e39d0ac664998a2de014b058.1345059176.git.bruce.ashfield@windriver.com>

On Wed, 2012-08-15 at 16:06 -0400, Bruce Ashfield wrote:
> The kernel branch is no longer required by the yocto-kern-tools
> to locate BSP feature descriptions (it is the MACHINE:KTYPE
> descriptor), so we no longer require that the BSP branch be
> explicitly set.
> 
> If a kernel branch is explicitly set, it is now used to trigger
> a checks to ensure that the branch really is being built.
> Otherwise the branch that the machine description creates will
> be built (just as it always was).
> 
> This further simplies the use and configuration of a linux-yocto
> based kernel recipe.

[...]

>  
> -	# We have SRCREVs and we have branches so validation can continue!
> -	current=`git branch |grep \*|sed 's/^\* //'`
> -	if [ -n "$target_branch_head" ] && [ "$branch_head" != "$target_branch_head" ] &&
> -           [ "$target_branch_head" != "AUTOINC" ]; then
> -		ref=`git show ${target_branch_head} 2>&1 | head -n1 || true`
> -		if [ "$ref" = "fatal: bad object ${target_meta_head}" ]; then
> -			echo "ERROR ${target_branch_head} is not a valid commit ID."
> -			echo "The kernel source tree may be out of sync"
> -			exit 1
> -		else
> -			echo "Forcing branch $current to ${target_branch_head}"
> -			git branch -m $current $current-orig
> -			git checkout -b $current ${target_branch_head}
> -		fi
> +	containing_branches=`git branch --contains $target_branch_head | sed 's/^..//'`
> +	if [ -z "$containing_branches" ]; then
> +		echo "ERROR: SRCREV was set to \"$target_branch_head\", but no branches"
> +		echo "       contain this commit"
> +		exit 1
> +	fi
> +	ref=`git show ${target_branch_head} 2>&1 | head -n1 || true`
> +	if [ "$ref" = "fatal: bad object ${target_meta_head}" ]; then
> +	    echo "ERROR ${target_branch_head} is not a valid commit ID."
> +	    echo "The kernel source tree may be out of sync"
> +	    exit 1
>  	fi

There is a bit of uncertainty flying around at the moment about why
these changes are failing on the autobuilder. For example:

http://autobuilder.yoctoproject.org:8010/builders/nightly-mips/builds/560/steps/shell_138/logs/stdio

Log data follows:
| DEBUG: Executing shell function do_validate_branches
| ERROR: SRCREV was set to "1c17c082b6ee565acc176cde5be835ac4269817b", but no branches
|        contain this commit
| ERROR: Function failed: do_validate_branches

It looks like:

http://git.yoctoproject.org/cgit.cgi/poky/commit/bitbake/lib/bb/fetch2/git.py?id=64662290d3e7deb0b6093b3959c3f3eddb873893

doesn't totally fix the problem. It allows the correct revisions to be
found and sets alternatives correctly but imports the wrong branch
config.

I don't really want to have to require a patched git binary so we may
end up having to rebuild the branch structure manually.

I guess the older code cared less about the branch name and more about
the revisions being present.

Cheers,

Richard








  reply	other threads:[~2012-08-18 12:19 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-08-15 20:06 [PATCH 0/4] linux-yocto: consolidated update Bruce Ashfield
2012-08-15 20:06 ` [PATCH 1/4] linux-yocto: make KBRANCH the exception and not the rule Bruce Ashfield
2012-08-18 12:07   ` Richard Purdie [this message]
2012-08-18 14:33     ` Bruce Ashfield
2012-08-18 15:29       ` Richard Purdie
2012-08-15 20:06 ` [PATCH 2/4] linux-yocto/3.4: remove explicit KBRANCH designations Bruce Ashfield
2012-08-15 20:06 ` [PATCH 3/4] linux-yocto: explicitly export KMETA to scripts Bruce Ashfield
2012-08-15 20:06 ` [PATCH 4/4] kern-tools: fixes (branching, buildall) + cleanups (checkpoint, cleaner) Bruce Ashfield
2012-08-18 16:57 ` [PATCH 0/4] linux-yocto: consolidated update Richard Purdie
2012-08-18 17:15   ` Bruce Ashfield
2012-08-18 22:18     ` Richard Purdie
2012-08-19  4:44       ` Bruce Ashfield
2012-08-19  9:47         ` Richard Purdie

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1345291665.27428.36.camel@ted \
    --to=richard.purdie@linuxfoundation.org \
    --cc=bruce.ashfield@windriver.com \
    --cc=openembedded-core@lists.openembedded.org \
    --cc=saul.wold@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.