The Yocto Project Layer Structure: Best Known Methods (BKM) Clarifications, or WHAT
1. Standard Layer Placement
For many official examples, tutorials, and `layerindex-fetch` workflows,
layers are indeed placed inside the `poky` directory.**
This structure looks like:
poky/
├── meta-my-bsp/
├── meta-my-distro/
├── meta-my-software/
├── meta-openembedded/
└── meta-other-third-party/
Why this structure?
- Simple and Standard:
Easy to set up and maintain, especially for new users and small projects. - Tool Compatibility:
Tools like `layerindex-fetch` and yocto-check-layer expect to find layers in the `poky` directory. - Documentation Alignment:
Official Yocto Project document Best Known Methods and examples use this layout.
3. What Does the Official BKM Say?
- The Yocto Project documentation is not always 100% prescriptive about
layer placement. - For simplicity and tool compatibility, the BKM often suggest placing layers inside
`poky/`.
4. Best Practice Summary
For most users and standard setups:
Place layers **inside the `poky` directory.
poky/
├── meta-my-bsp/
├── meta-my-distro/
├── meta-my-software/
├── meta-openembedded/
└── meta-other-third-party/
5. Layer Management Tips
- Use `bitbake-layers` to add, remove, and inspect layers.
- Keep layer dependencies clear** using `LAYERDEPENDS` in `layer.conf`.
- Document your structure** so team members understand where to find each
layer. - Test new layers** before integrating them into your build.
- Use bootstrap layers to manage your projects/products
6. Conclusion
- Official BKM and many examples show layers inside `poky/`.
- Your structure is correct for standard, tool-compatible setups.
- Advanced users may place layers outside `poky/` for larger projects, but
this is not the default or simplest path.
Final Structure Example (Official BKM-style)
poky/
├── meta-my-bsp/
├── meta-my-distro/
├── meta-my-software/
├── meta-openembedded/
└── meta-other-third-party/
This is the recommended structure for most Yocto Project users following the
Best Known Methods.