[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Minios-devel] [UNIKRAFT PATCH 06/13] build: Add a makefile function to warn user when GCC is too old
Some GCC flags, like processor flags have minimum GCC version requirement. Add this makefile function to stop build and print a error message to notify user that their GCC is too old. Signed-off-by: Wei Chen <Wei.Chen@xxxxxxx> --- support/build/Makefile.rules | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/support/build/Makefile.rules b/support/build/Makefile.rules index cc9b522..2ac729a 100644 --- a/support/build/Makefile.rules +++ b/support/build/Makefile.rules @@ -35,6 +35,13 @@ define test_gcc_version = $(shell echo 'if($(CC_VER_MAJOR).$(CC_VER_MINOR)>=$(1).$(2)) print "y"'| bc) endef +# print error when GCC version doesn't meet the minimum requirement +# check_valid_gcc_version $gcc_major,$gcc_minor. +define check_valid_gcc_version = +$(if $(call test_gcc_version,$(1),$(2)),,\ + $(error Require GCC version >= $(1).$(2) found $(CC_VER_MAJOR).$(CC_VER_MINOR))) +endef + ################################################################################ # # Paths and Filenames -- 2.7.4 _______________________________________________ Minios-devel mailing list Minios-devel@xxxxxxxxxxxxxxxxxxxx https://lists.xenproject.org/mailman/listinfo/minios-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |