diff --git a/flavours/linux/bblayers.conf.sample b/flavours/linux/bblayers.conf.sample index 42ec1269a56796b7e66eab49267304ceda686811..d8540b015b6cb0e7b90caf40113f602e4f4f616e 100644 --- a/flavours/linux/bblayers.conf.sample +++ b/flavours/linux/bblayers.conf.sample @@ -2,9 +2,10 @@ # # SPDX-License-Identifier: Apache-2.0 -# POKY_BBLAYERS_CONF_VERSION is increased each time build/conf/bblayers.conf -# changes incompatibly -POKY_BBLAYERS_CONF_VERSION = "2" +# Bump this each time bblayers.conf.sample changes incompatibly. For example, +# when integrating new layers. It needs to be in sync with +# ONIRO_REQUIRED_LAYERS_CONF_VERSION for associated sanity check to pass. +ONIRO_LAYERS_CONF_VERSION = "1" BBPATH = "${TOPDIR}" BBFILES ?= "" diff --git a/meta-oniro-core/conf/distro/include/oniro.inc b/meta-oniro-core/conf/distro/include/oniro.inc index 66c8074cd3450db7bdf6e0f731be2007c5f00173..0b78537e5c7d06141b26ae992c4b371c590e14be 100644 --- a/meta-oniro-core/conf/distro/include/oniro.inc +++ b/meta-oniro-core/conf/distro/include/oniro.inc @@ -15,3 +15,13 @@ PREFERRED_PROVIDER_virtual/java-initial-native ?= "cacao-initial-native" PREFERRED_PROVIDER_virtual/java-native ?= "cacao-native" BB_DANGLINGAPPENDS_WARNONLY:forcevariable = "0" + +# Bump this each time bblayers.conf.sample changes incompatibly. For example, +# when integrating new layers. +ONIRO_REQUIRED_LAYERS_CONF_VERSION = "1" +# oe-core's sanity check sanity_check_conffiles function only runs the +# functions in BBLAYERS_CONF_UPDATE_FUNCS when the associated variable is not +# None. Making sure this variable has a default value, we force running the +# check even when ONIRO_LAYERS_CONF_VERSION is not defined - providing the +# relevant error message. +ONIRO_LAYERS_CONF_VERSION ??= "-1"