bitbake: git: Use merge-base instead of log for testing if a commit is present
authorRichard Purdie <richard.purdie@linuxfoundation.org>
Mon, 18 Nov 2013 17:17:16 +0000 (17:17 +0000)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Mon, 18 Nov 2013 17:19:11 +0000 (17:19 +0000)
commita10c899c542429bd1612f8ad2fffa28b9d8a2ddb
treedc2c9e95abde9ddd98f333275028a489c61f57af
parent5850e3cab8fc207950e1068fb6a9ce4c89e353b9
bitbake: git: Use merge-base instead of log for testing if a commit is present

The current use of git log to check if a given revision is present can be
a little fragile.

For example if revision X was on branch A, and then later added to branch
B, the update checks would not notice this since they just check for X
being in the repository.

We also had some autobuilder corruption where an older packed-refs file
was copied over a new repository containing newer pack files. There
was no update to the refs file since the revision was present but
not accessible in any branch.

The correct fix is to check that the required revisions are present
on the specific branches. This patch does this using merge-base.

(Bitbake rev: 89abfbc1953e3711d6c90aff793ee622c22609b1)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
bitbake/lib/bb/fetch2/git.py