[bitbake-devel] How to detect change on a repo manifest.git and rebuild the recipe with "repo://"

GUAN Ben (ST-FIR/ENG1-Zhu) Ben.Guan at cn.bosch.com
Fri Aug 25 02:06:31 UTC 2017


The source code of my SW consist of multiple components from different repository, which is managed by a repo manifest repository. So I want to use "repo://" for the repo manifest repository instead of multiple "git://" to include all repositories in the SRC_URI.

I add the following to MyRecipe_git.bb:
```
SRC_URI = "repo://git@<MY_HOST>/manifest.git;protocol=ssh;branch=master"

S = "${WORKDIR}/repo/MyRecipe"
```

And in my local.conf, I add the following:
```
# Use this setting because I don't have internet connection to external Android repo.git, I mirror one in the internal host
REPO_URL = "git@<My_HOST>/repo.git"
# Use "repo" command in the host
HOSTTOOLS += "repo"
# Because the my Yocto meta-layers are managed by repo also, use a different directory for my recipe
REPODIR = "/home/benguan/projects/MyRecipeRepo"
```

Now I can build my recipe with Yocto, but there is an issue:  When there is any change required in the repositories of my application, I will change the code and update the tags in default.xml of manifest.git. I want Yocto could detect this change, fetch the change, them rebuild the recipe.

With "git://", it is easy to achieve via setting "${AUTOREV}" to "SRCREV". But the fetch2.repo doesn't support SRCREV. I have go through the existing recipe within meta-oe and oe-core, no recipe is using "repo://".

Does anybody have experience about it and help? Thank you in advance.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openembedded.org/pipermail/bitbake-devel/attachments/20170825/d072f6b2/attachment-0002.html>


More information about the bitbake-devel mailing list