Skip to content

Commit 20d89af

Browse files
authored
Merge pull request #12755 from aabadie/pr/application_dep
make: add possibility to provide board specific application dependencies in a separate Makefile
2 parents ed06df6 + 6d5f64b commit 20d89af

File tree

13 files changed

+40
-22
lines changed

13 files changed

+40
-22
lines changed

Makefile.dep

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,9 @@
22
OLD_USEMODULE := $(sort $(USEMODULE))
33
OLD_USEPKG := $(sort $(USEPKG))
44

5+
# include board specific application dependencies
6+
-include $(APPDIR)/Makefile.board.dep
7+
58
# include board dependencies
69
-include $(RIOTBOARD)/$(BOARD)/Makefile.dep
710

examples/gnrc_border_router/Makefile

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,17 +13,13 @@ BOARD_BLACKLIST += pic32-wifire pic32-clicker ruuvitag thingy52
1313
# use ethos (ethernet over serial) for network communication and stdio over
1414
# UART, but not on native, as native has a tap interface towards the host.
1515
ifeq (,$(filter native,$(BOARD)))
16-
GNRC_NETIF_NUMOF := 2
17-
USEMODULE += stdio_ethos
18-
1916
# ethos baudrate can be configured from make command
2017
ETHOS_BAUDRATE ?= 115200
2118
CFLAGS += -DETHOS_BAUDRATE=$(ETHOS_BAUDRATE)
2219
else
23-
GNRC_NETIF_NUMOF := 2
2420
TERMFLAGS += -z [::1]:17754
25-
USEMODULE += socket_zep
2621
endif
22+
GNRC_NETIF_NUMOF := 2
2723

2824
# SLIP legacy compatibility
2925
# Uncomment the lines below if you want to use SLIP with this example and don't
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
# Put board specific dependencies here
2+
ifeq (,$(filter native,$(BOARD)))
3+
USEMODULE += stdio_ethos
4+
else
5+
USEMODULE += socket_zep
6+
endif

tests/gnrc_ipv6_ext/Makefile

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,12 +9,8 @@ export TAP ?= tap0
99

1010
# use Ethernet as link-layer protocol
1111
ifeq (native,$(BOARD))
12-
USEMODULE += netdev_tap
13-
1412
TERMFLAGS ?= $(TAP)
1513
else
16-
USEMODULE += stdio_ethos
17-
1814
ETHOS_BAUDRATE ?= 115200
1915
CFLAGS += -DETHOS_BAUDRATE=$(ETHOS_BAUDRATE)
2016
TERMDEPS += ethos
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
# Put board specific dependencies here
2+
ifeq (native,$(BOARD))
3+
USEMODULE += netdev_tap
4+
else
5+
USEMODULE += stdio_ethos
6+
endif

tests/gnrc_ipv6_ext_frag/Makefile

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,8 @@ CFLAGS += -DTEST_SUITES="gnrc_ipv6_ext_frag"
1212
CFLAGS += -DGNRC_IPV6_EXT_FRAG_LIMITS_POOL_SIZE=3
1313

1414
ifeq (native,$(BOARD))
15-
USEMODULE += netdev_tap
1615
TERMFLAGS ?= $(TAP)
1716
else
18-
USEMODULE += stdio_ethos
19-
2017
ETHOS_BAUDRATE ?= 115200
2118
CFLAGS += -DETHOS_BAUDRATE=$(ETHOS_BAUDRATE)
2219
TERMDEPS += ethos
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
# Put board specific dependencies here
2+
ifeq (native,$(BOARD))
3+
USEMODULE += netdev_tap
4+
else
5+
USEMODULE += stdio_ethos
6+
endif

tests/gnrc_rpl_srh/Makefile

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,8 @@ CFLAGS += -DOUTPUT=TEXT
1111

1212
# use Ethernet as link-layer protocol
1313
ifeq (native,$(BOARD))
14-
USEMODULE += netdev_tap
15-
1614
TERMFLAGS ?= $(TAP)
1715
else
18-
USEMODULE += stdio_ethos
19-
2016
ETHOS_BAUDRATE ?= 115200
2117
CFLAGS += -DETHOS_BAUDRATE=$(ETHOS_BAUDRATE)
2218
TERMDEPS += ethos
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
# Put board specific dependencies here
2+
ifeq (native,$(BOARD))
3+
USEMODULE += netdev_tap
4+
else
5+
USEMODULE += stdio_ethos
6+
endif

tests/gnrc_sock_dns/Makefile

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,12 +13,8 @@ USEMODULE += gnrc_ipv6_default
1313
USEMODULE += gnrc_ipv6_nib_dns
1414
# use Ethernet as link-layer protocol
1515
ifeq (native,$(BOARD))
16-
USEMODULE += netdev_tap
17-
1816
TERMFLAGS ?= $(TAP)
1917
else
20-
USEMODULE += stdio_ethos
21-
2218
ETHOS_BAUDRATE ?= 115200
2319
CFLAGS += -DETHOS_BAUDRATE=$(ETHOS_BAUDRATE)
2420
TERMDEPS += ethos

0 commit comments

Comments
 (0)