[yocto] externalsrc + sstate why is not compatible?

Koehler, Yannick yannick.koehler at hpe.com
Wed Dec 6 06:13:26 PST 2017


When you say "subdirs", are you referring to submodules or something along those line?  We have used attempted to use submodules and it still required 20 + 1 repo and the overhead is similar to yocto + 20 repo but then you have yocto + 20 repos + 1 main repos, as such, this is not acceptable for us.  We also looked at other combination of multiple repos supported or in work for git and none are satisfying or supported in a way I could propose to use it in our project.

If you mean 1 repo, which subdirs representing each package, I would be interested, but how would it work with yocto SRC_URI?

In regards to file fetcher, I will go check the code, I thought the unpack would only occurs for tarball, not subdir.

--
Yannick Koehler

-----Message d'origine-----
De : Alexander Kanavin [mailto:alexander.kanavin at linux.intel.com] 
Envoyé : 6 décembre 2017 03:47
À : Koehler, Yannick <yannick.koehler at hpe.com>; yocto at yoctoproject.org
Objet : Re: [yocto] externalsrc + sstate why is not compatible?

On 12/06/2017 04:15 AM, Koehler, Yannick wrote:
> In our situation, we have many packages that are in-house, as such we  
> use a local folder for the several in-house modules.  To do so, we 
> need to use externalsrc to point to the local code so that the git 
> repo contains both the code + recipe, instead of 20 repos (1 per
> packages) and 1 more for yocto recipe which complicates things when 
> you want to submit a change.

You don't have to have 20 repos. You can place the modules into a single repo with subdirs.

> Yet, the externalsrc disable the setscene tasks and set the 
> BB_DONTCACHE variable.  I altered the script to remove those but then 
> a change to the externalsrc folder is not detected. I wonder if it is 
> because the S variable is set past the sstate algorithm and is then 
> unable to consider the externalsrc folder as the real source location.  
> Any expert on this matter that can guide me to either make sstate 
> works for external src or teach me how to have code + recipe in a 
> single git repo.  I am certainly not the only case using such a 
> pattern.

The bitbake documentation claims you can specify a directory in the
file: fetcher, and then all of it will be unpacked to workdir. I've never seen or tried it myself, but maybe you can investigate in that direction, and make it work if it doesn't.

Alex



More information about the yocto mailing list