fff-network: Group network files by arch, not by target

OpenWrt only builds and installs a packet for each architecture.
If a package is already fully built and installed for a architecture,
it is not rebuilt.

Because we have two different BSPs building two different targets (BOARDs)
using the same architecture (ath79 and ar71xx, mips), the fff-network package
is not reinstalled when switching between those.

However, we have defined an install step, which copies the necessary network
files seperated by board. But because the package is not rebuilt when switching
targets, the wrong network files might be present in the package.

To resolve this issue, the network files are now seperated by ARCH instead of
the target (i.e. the BOARD variable).

Signed-off-by: Fabian Bläse <fabian@blaese.de>
Acked-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
Acked-by: Robert Langhammer <rlanghammer@web.de>
[bump PKG_RELEASE]
Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
This commit is contained in:
Fabian Bläse 2020-06-14 12:49:34 +02:00 committed by Adrian Schmutzler
parent 1cf4d762ff
commit 1faaec432a
49 changed files with 2 additions and 32 deletions

View File

@ -1,7 +1,7 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=fff-network
PKG_RELEASE:=21
PKG_RELEASE:=22
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)
@ -33,7 +33,7 @@ endef
define Package/$(PKG_NAME)/install
$(CP) ./files/* $(1)/
test -d ./$(BOARD) && $(CP) ./$(BOARD)/* $(1)/etc/
test -d ./$(ARCH) && $(CP) ./$(ARCH)/* $(1)/etc/
endef
$(eval $(call BuildPackage,$(PKG_NAME)))

View File

@ -1,30 +0,0 @@
################
## This file is used to configure the behavior of network interfaces
## if the routers interfaces differ from the standard WAN+4LAN-Ports
## +2Wireless APs.
## If you want to change their behavior, you should edit the file
## /etc/network.config
## After that you have to reboot the router with following command.
#reboot
#
### The canonical syntax of this file is:
#SPECIFIER="MODE"
### MODES
## Generally there are 3 operating modes for network interfaces in fff.
#BATMAN: The interface is used to mesh with other fff-nodes
#WAN: The interface is used to connect to supernodes via vpn and
# ordinary internet.
#CLIENT: The interface is used to connect clients to the fff-net
##
### SPECIFIER
## For devices only including one ethernet port the specifier is called
## ETHMODE. The default mode for these devices is "BATMAN".
## For example this is the case for: gl-ar150, tl-mr3020-v1, tl-wa850re-v1,
## tl-wa860re-v1, tl-wa901nd-v2, ubnt-bullet-m, ubnt-loco-m-xw, ubnt-nano-m,
## ubnt-unifi
ETHMODE="CLIENT"
## Devices featuring 2 ethernet ports are configured by SPECIFIERs ressembling
## the labels on the PORT itself. For the cpe210 these are called LAN0 and LAN1.
## Therefore they are configured as follows:
LAN0MODE="WAN"
LAN1MODE="CLIENT"