galileo: Fix build help message in examples
This patch fixes examples/galileo/Makefile so that it actually displays the intended help message when an unrecognized EXAMPLE is selected.
This commit is contained in:
parent
b82d92e373
commit
1f445172ff
1 changed files with 6 additions and 8 deletions
|
@ -2,17 +2,15 @@ TARGET=galileo
|
|||
|
||||
KNOWN_EXAMPLES = gpio-input gpio-output gpio-interrupt i2c-LSM9DS0 i2c-callbacks
|
||||
|
||||
ifneq ($(filter $(EXAMPLE),$(KNOWN_EXAMPLES)),)
|
||||
CONTIKI_PROJECT = $(EXAMPLE)
|
||||
else
|
||||
CONTIKI_PROJECT = help
|
||||
ifeq ($(filter $(EXAMPLE),$(KNOWN_EXAMPLES)),)
|
||||
$(info Set the variable EXAMPLE to one of the following Galileo-specific examples:)
|
||||
$(foreach EXAMPLE,$(KNOWN_EXAMPLES),$(info - $(EXAMPLE)))
|
||||
$(error Unable to proceed)
|
||||
endif
|
||||
|
||||
CONTIKI_PROJECT = $(EXAMPLE)
|
||||
|
||||
all: $(CONTIKI_PROJECT)
|
||||
|
||||
CONTIKI = ../..
|
||||
include $(CONTIKI)/Makefile.include
|
||||
|
||||
help:
|
||||
@echo -e "\nSet the variable EXAMPLE to one of the following Galileo-specific examples:"
|
||||
@for EXAMPLE in $(KNOWN_EXAMPLES); do echo $$EXAMPLE; done
|
||||
|
|
Loading…
Add table
Reference in a new issue