From c103b3f6baf38ec4f04f0732f286d44841bb6701 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ga=C3=ABtan=20Harter?= Date: Mon, 18 Jun 2018 15:16:51 +0200 Subject: [PATCH] serial: Do not export PORT. This variable is only used for the term recipe (and maybe for flashing). They should not be evaluated if they are not needed and the user should not see a warning that the port is not set if he does not use port (for example in make all.) --- boards/native/Makefile.include | 4 ++-- makefiles/tools/serial.inc.mk | 1 - makefiles/vars.inc.mk | 2 +- 3 files changed, 3 insertions(+), 4 deletions(-) diff --git a/boards/native/Makefile.include b/boards/native/Makefile.include index 9ee94c3eb3..5c0458ccc7 100644 --- a/boards/native/Makefile.include +++ b/boards/native/Makefile.include @@ -95,9 +95,9 @@ export LINKFLAGS += -ffunction-sections # set the tap interface for term/valgrind ifneq (,$(filter netdev_default gnrc_netdev_default,$(USEMODULE))) - export PORT ?= tap0 + PORT ?= tap0 else - export PORT = + PORT = endif TERMFLAGS := $(PORT) $(TERMFLAGS) diff --git a/makefiles/tools/serial.inc.mk b/makefiles/tools/serial.inc.mk index 8abcf7fe1d..115647d84f 100644 --- a/makefiles/tools/serial.inc.mk +++ b/makefiles/tools/serial.inc.mk @@ -8,7 +8,6 @@ endif ifeq ($(PORT),) $(info Warning: no PORT set!) endif -export PORT export BAUD ?= 115200 diff --git a/makefiles/vars.inc.mk b/makefiles/vars.inc.mk index b46d5f70b5..850476fbe6 100644 --- a/makefiles/vars.inc.mk +++ b/makefiles/vars.inc.mk @@ -74,7 +74,7 @@ export GIT_CACHE_DIR # path to git-cache cache directory export FLASH_ADDR # Define an offset to flash code into ROM memory. # TERMPROG # The command to call on "make term". # TERMFLAGS # Additional parameters to supply to TERMPROG. -export PORT # The port to connect the TERMPROG to. +# PORT # The port to connect the TERMPROG to. export ELFFILE # The unstripped result of the compilation. export HEXFILE # The stripped result of the compilation. # FLASHFILE # The output file used for flashing (transition phase: only if defined)