Closed vanrein closed 4 years ago
The non-declared variables should also be available in the cache, but as strings with an empty value. This allows overrides to be made.
Cache values overriding the above definitions in the scripts will lead to a warning message.
Note: CMake might crash on empty strings. Sigh. So let's use (set_by_mkhere)
instead and replace that with an empty string when it comes up.
Strikken: The following was a temporary sign of lack of fanatasy.
It's pretty impossible to postfix with simple CMake logic. So, instead, let's prefix:
rootfs_packages(
VERSION=0.3 FLAVOUR=arpa2dns arpa2shell
VERSION=0.7.3 twin
)
Finished with commit c0213333bf7996c6fcc451ec0e645ed9325a215b.
We currently let
mkhere
decide about the versions to use. That, however, makes the environments less stable than desirable formkroot
operation.Instead, allow the setup of
VERSION=xxx
andVARIANT=yyy
andFLAVOUR=zzz
directly before or after a package name. (After reads nicer, and seems most consistent.)Example:
These should probably be cached variables, or possibly overridden in the cache. If the above was for component
arpa2dns
, there would be a few variables to complement this setup:arpa2dns_VERSION_arpa2shell=0.3
arpa2dns_FLAVOUR_arpa2shell=arpa2dns
arpa2dns_VERSION_twin=0.7.3
When building for the component
arpa2dns
, these variables would be made available asVERSION_arpa2shell
,FLAVOUR_arpa2shell
andVERSION_twin
to the builds ofarpa2shell
andtwin
, as apropriate.