| Summary: | cannot use helper functions | ||
|---|---|---|---|
| Product: | [Build System, Metadata & Runtime] BitBake | Reporter: | Frans Meulenbroeks <fransmeulenbroeks> |
| Component: | bitbake | Assignee: | Richard Purdie <richard.purdie> |
| Status: | RESOLVED NOTABUG | QA Contact: | |
| Severity: | normal | ||
| Priority: | Undecided | CC: | poky.bs.watcher, poky.watcher, ross.burton |
| Version: | unspecified | ||
| Target Milestone: | --- | ||
| Hardware: | x86 | ||
| OS: | Multiple | ||
| Whiteboard: | |||
| OS type for building Yocto: | --- | Type of Regression: | --- |
| Verified: | Documentation change: | Don't know | |
|
Description
Frans Meulenbroeks
2021-07-14 13:29:46 UTC
The problem is that you're using overrides, so what you're entering into the recipe isn't what actually gets evaluated.
do_install_prepend_jetson-nano-emmc means "prepend this body to do_install if jeson-nano-emmc is in OVERRIDES". At no point is there a shell function called do_install_prepend_jetson-nano-emmc. Also, - isn't valid in shell functions so even if it was exposed in shell, it wouldn't have that name.
If you want to refactor your recipe to have common fragments then write explicit shell functions for those:
install_interfaces() {
install -d ${D}/etc
install -d ${D}/etc/network
install -m 0640 ${WORKDIR}/interfaces_nano ${D}/etc/network/interfaces
}
do_install_prepend_jetson-nano-emmc() {
install_interfaces
}
do_install_prepend_jetson-nano-devkit-emmc() {
install_interfaces
}
|