7

In my project, I want to take an existing Yocto setup for the Automotive Grade Linux distribution and add some layers with recipes for our own components.

There exists a manifest file, publicly available, on their gerrit site. What I'd like to do is basically

<manifest>
    <include url="<url of AGL manifest>" />
    <remote name="mysite" fetch="ssh://gerrit.mysite.com" />
    <project name="mylayer1" path="mylayer1" />
    <project name="mylayer2" path="mylayer2" />
</manifest>

The aim being that a repo init command pointed to my manifest first fetches all the repositories mentioned in the "included" manifest, then proceeds to fetch all my own meta layers.

The problem is that the include element is meant for including other manifests within the same repository specified on the repo init command line.

I could simply copy their manifest into my own repository, with a different name, and create my own manifest along side it. Or I could just reproduce their file and edit it.

But maintaining it will be a pain and extremely error prone. Especially as the upstream manifest is used not only to specify the repositories, but to pin each one to specific commits as a form of version control within Yocto.

I can't believe such an obvious use-case hasn't been considered and addressed.

So, at the risk of being closed as "too broad" or for requesting recommendations, has anyone already solved this problem? If so, how?

kdopen
  • 8,032
  • 7
  • 44
  • 52
  • did you ever find a solution to this? It still appears there is no clean way to do this. local_manifests doesn't really appear to do what I want, maybe I need to continue looking into that. – user_ABCD Apr 29 '21 at 20:13
  • @user_ABCD Nope - never did – kdopen May 03 '21 at 13:56

2 Answers2

1

I highly doubt there is a way to do this using the repo tool.

Wind River has a solution, and there has been talk of moving this into oecore:

https://github.com/Wind-River/wr-lx-setup

I'm not sure if this will do exactly what you are looking for, but it solves the problem that you are describing.

Historically, people have used repo (freescale-community-bsp), combo-layers (Ostro), or simply rolled their own solution. This setup tool is an attempt to standardize the way layers are assembled.

Stephano
  • 5,716
  • 7
  • 41
  • 57
1

You can use local_manifest.xml. Under .repo/ create a directory named local_manifests/. You can add a file local_manifest.xml

You can add you own remote, default and projects that are to be fetched from that remote.

I have used this feature with repo 1.23

sob
  • 982
  • 11
  • 31