]> xenbits.xensource.com Git - unikraft/unikraft.git/commitdiff
build: Hint about GNU make with `gmake` on Darwin
authorSimon Kuenzer <simon@unikraft.io>
Wed, 26 Jul 2023 11:55:29 +0000 (13:55 +0200)
committerUnikraft <monkey@unikraft.io>
Fri, 11 Aug 2023 10:21:30 +0000 (10:21 +0000)
Add a hint on Darwin how to install a newer GNU make version if the
detected make version is too old (< 4.1).

Signed-off-by: Simon Kuenzer <simon@unikraft.io>
Reviewed-by: Alexander Jung <alex@unikraft.io>
Approved-by: Razvan Deaconescu <razvand@unikraft.io>
Tested-by: Unikraft CI <monkey@unikraft.io>
GitHub-Closes: #1034

Makefile

index 1e0abe4b8a1654b9216cbf0a0303af51b20deab0..2bf2a1e19ed22f3b96fefdb31412dd43f42c305b 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -58,7 +58,11 @@ RUNNING_MAKE_VERSION := $(MAKE_VERSION)
 # Check for minimal make version (note: this check will break at make 10.x)
 MIN_MAKE_VERSION = 4.1
 ifneq ($(firstword $(sort $(RUNNING_MAKE_VERSION) $(MIN_MAKE_VERSION))),$(MIN_MAKE_VERSION))
+ifneq ($(HOSTOSENV),Darwin)
 $(error You have make '$(RUNNING_MAKE_VERSION)' installed. GNU make >= $(MIN_MAKE_VERSION) is required)
+else
+$(error We need GNU make >= $(MIN_MAKE_VERSION). It can be installed with 'brew install make'. Retry with: 'gmake $(MAKECMDGOALS)')
+endif
 endif
 
 # Strip quotes and then whitespaces