diff --git a/Makefile.include b/Makefile.include index da39ecaadf..b93ab1d273 100644 --- a/Makefile.include +++ b/Makefile.include @@ -106,6 +106,9 @@ OS := $(shell uname) # set python path, e.g. for tests PYTHONPATH := $(RIOTBASE)/dist/pythonlibs/:$(PYTHONPATH) +# Basic utilities included before anything else +include $(RIOTMAKE)/utils/checks.mk + # Include Docker settings near the top because we need to build the environment # command line before some of the variable origins are overwritten below when # using abspath, strip etc. diff --git a/makefiles/tools/serial.inc.mk b/makefiles/tools/serial.inc.mk index 215a5057e8..84144166e0 100644 --- a/makefiles/tools/serial.inc.mk +++ b/makefiles/tools/serial.inc.mk @@ -1,12 +1,9 @@ # set default port depending on operating system OS := $(shell uname) ifeq ($(OS),Linux) - PORT ?= $(PORT_LINUX) + PORT ?= $(call ensure_value,$(PORT_LINUX),No port set) else ifeq ($(OS),Darwin) - PORT ?= $(PORT_DARWIN) -endif -ifeq ($(PORT),) - $(info Warning: no PORT set!) + PORT ?= $(call ensure_value,$(PORT_DARWIN),No port set) endif export BAUD ?= 115200