Harmonize building of tools from within an example dir
This commit is contained in:
parent
8c347f96d7
commit
37f14efad5
@ -10,6 +10,9 @@ WERROR ?= 1
|
||||
|
||||
include $(CONTIKI)/Makefile.identify-target
|
||||
|
||||
### Include Makefile.tools to pull in targets that allow us to build tools dir
|
||||
include $(CONTIKI)/Makefile.tools
|
||||
|
||||
CONTIKI_NG_TARGET_LIB = contiki-ng-$(TARGET).a
|
||||
|
||||
ifeq ($(DEFINES),)
|
||||
|
11
Makefile.tools
Normal file
11
Makefile.tools
Normal file
@ -0,0 +1,11 @@
|
||||
TOOLS_DIR = $(CONTIKI)/tools
|
||||
TOOL_DEPS = $(TOOLS_DIR)/tools-utils.c $(TOOLS_DIR)/tools-utils.h
|
||||
|
||||
TUNSLIP6 = $(TOOLS_DIR)/tunslip6
|
||||
SERIAL_DUMP_BIN = $(TOOLS_DIR)/serialdump
|
||||
|
||||
$(SERIAL_DUMP_BIN): $(TOOLS_DIR)/serialdump.c $(TOOL_DEPS)
|
||||
make -C $(TOOLS_DIR) serialdump
|
||||
|
||||
$(TUNSLIP6): $(TOOLS_DIR)/tunslip6.c $(TOOL_DEPS)
|
||||
make -C $(TOOLS_DIR) tunslip6
|
@ -299,9 +299,6 @@ serialdumpall:
|
||||
|
||||
UART_BAUDRATE ?= 1000000
|
||||
|
||||
$(CONTIKI)/tools/tunslip6: $(CONTIKI)/tools/tunslip6.c
|
||||
($(MAKE) -C $(CONTIKI)/tools tunslip6 CFLAGS= LDFLAGS= LDLIBS= INCFLAGS=)
|
||||
|
||||
$(SERIALDUMP): $(CONTIKI)/tools/jn516x/serialdump.c
|
||||
(cd $(CONTIKI)/tools/jn516x; ${MAKE} $(notdir $(SERIALDUMP)))
|
||||
|
||||
|
@ -1,9 +1,7 @@
|
||||
$(CONTIKI)/tools/tunslip6: $(CONTIKI)/tools/tunslip6.c
|
||||
(cd $(CONTIKI)/tools && $(MAKE) tunslip6)
|
||||
|
||||
PREFIX ?= fd00::1/64
|
||||
connect-router: $(CONTIKI)/tools/tunslip6
|
||||
sudo $(CONTIKI)/tools/tunslip6 $(PREFIX)
|
||||
|
||||
connect-router-cooja: $(CONTIKI)/tools/tunslip6
|
||||
sudo $(CONTIKI)/tools/tunslip6 -a 127.0.0.1 $(PREFIX)
|
||||
connect-router: $(TUNSLIP6)
|
||||
sudo $(TUNSLIP6) $(PREFIX)
|
||||
|
||||
connect-router-cooja: $(TUNSLIP6)
|
||||
sudo $(TUNSLIP6) -a 127.0.0.1 $(PREFIX)
|
||||
|
Loading…
Reference in New Issue
Block a user