Details
Description
Newt automatically creates a few macros on the command line when it builds a target:
- ARCH_<arch-name>
- ARCH_NAME="<arch-name>"
- APP_<arch-name>
- APP_NAME="<arch-name>"
- BSP_<arch-name>
- BSP_NAME="<arch-name>"
There is a problem with the two APP defines. A split image consists of two apps (the "loader" and the "app"), so there is not a single correct value to specify during compilation.
There are two issues here:
- Code cannot rely on consistent values for the APP defines when it is part of a split image
- Newt performs unnecessary compiling and linking operations for repeat builds of split targets. This is because the command-line invocation changes between builds, as the APP name is not consistent.