Skip to content

Commit

Permalink
newlib.mk: fix: do not require slash terminated NEWLIB_INCLUDE_DIR
Browse files Browse the repository at this point in the history
When NEWLIB_INCLUDE_DIR is set from other parts than 'COMPILER_INCLUDE_PATHS' it
does not have a trailing slash.
Also, it makes it more problematic when supplying it from the command line.

And anyway having two '/' does not break anything.
  • Loading branch information
cladmi committed Aug 2, 2018
1 parent d4bdac7 commit a946c2c
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions makefiles/libc/newlib.mk
Original file line number Diff line number Diff line change
Expand Up @@ -79,9 +79,9 @@ ifeq ($(TOOLCHAIN),llvm)
endif

ifeq (1,$(USE_NEWLIB_NANO))
NEWLIB_NANO_INCLUDE_DIR ?= $(firstword $(wildcard $(NEWLIB_INCLUDE_DIR)newlib-nano \
$(NEWLIB_INCLUDE_DIR)newlib/nano \
$(NEWLIB_INCLUDE_DIR)nano))
NEWLIB_NANO_INCLUDE_DIR ?= $(firstword $(wildcard $(NEWLIB_INCLUDE_DIR)/newlib-nano \
$(NEWLIB_INCLUDE_DIR)/newlib/nano \
$(NEWLIB_INCLUDE_DIR)/nano))
# newlib-nano overrides newlib.h and its include dir should therefore go before
# the regular system include dirs.
INCLUDES := -isystem $(NEWLIB_NANO_INCLUDE_DIR) $(INCLUDES)
Expand Down

0 comments on commit a946c2c

Please sign in to comment.