From 31002a0c0a5c2efe3ed3861a012a44e4888bf3d2 Mon Sep 17 00:00:00 2001 From: Alexey Neyman Date: Mon, 25 Mar 2019 14:05:25 -0700 Subject: Add an ability to mark a configuration as invalid ... so that the build will fail early and predictably. Signed-off-by: Alexey Neyman --- maintainer/kconfig-versions.template | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) (limited to 'maintainer') diff --git a/maintainer/kconfig-versions.template b/maintainer/kconfig-versions.template index 3db512e2..4ac81bea 100644 --- a/maintainer/kconfig-versions.template +++ b/maintainer/kconfig-versions.template @@ -276,6 +276,25 @@ config @@fork|@@_VERY_OLD #!end-foreach endchoice + +# A flag indicating that no valid selections exist for the version. +# This may happen if there are conflicting requirements set by +# the host system and/or other packages. +config @@fork|@@_NO_VERSIONS + def_bool y + select INVALID_CONFIGURATION + depends on !@@fork|@@_VERY_NEW +#!foreach version + depends on !@@fork|@@_V_@@ver_sel|@@ +#!end-foreach + depends on !@@fork|@@_VERY_OLD + +if @@fork|@@_NO_VERSIONS +comment "WARNING!" +comment "| The @@master@@ package has no viable versions" +comment "| due to conflicting constraints." +endif + #!end-if #!if [ -n "@@versionlocked@@" ] -- cgit v1.2.3 From d4fd69d5f1348613c22c88031de84d7dafd7301f Mon Sep 17 00:00:00 2001 From: Alexey Neyman Date: Wed, 27 Mar 2019 00:46:59 -0700 Subject: Change the "no viable version" check ... to make it easier to trace from `ct-ng menuconfig`. Signed-off-by: Alexey Neyman --- maintainer/kconfig-versions.template | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'maintainer') diff --git a/maintainer/kconfig-versions.template b/maintainer/kconfig-versions.template index 4ac81bea..61414f50 100644 --- a/maintainer/kconfig-versions.template +++ b/maintainer/kconfig-versions.template @@ -281,13 +281,14 @@ endchoice # This may happen if there are conflicting requirements set by # the host system and/or other packages. config @@fork|@@_NO_VERSIONS - def_bool y + bool select INVALID_CONFIGURATION - depends on !@@fork|@@_VERY_NEW + default n if @@fork|@@_VERY_NEW #!foreach version - depends on !@@fork|@@_V_@@ver_sel|@@ + default n if @@fork|@@_V_@@ver_sel|@@ #!end-foreach - depends on !@@fork|@@_VERY_OLD + default n if @@fork|@@_VERY_OLD + default y if @@fork|@@_NO_VERSIONS comment "WARNING!" -- cgit v1.2.3