From e3e2c0848751a318c543bcb51a5880ad5211e18a Mon Sep 17 00:00:00 2001 From: Michael Heimpold Date: Thu, 18 Jan 2018 22:30:19 +0100 Subject: [PATCH] ser2net: fix dynamic config generation (refs #5302) Signed-off-by: Michael Heimpold --- net/ser2net/Makefile | 4 ++-- net/ser2net/files/ser2net.config | 2 +- net/ser2net/files/ser2net.init | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/net/ser2net/Makefile b/net/ser2net/Makefile index c1dad9f3e7..da33832c7e 100644 --- a/net/ser2net/Makefile +++ b/net/ser2net/Makefile @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=ser2net PKG_VERSION:=3.5 -PKG_RELEASE:=2 +PKG_RELEASE:=3 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=@SF/ser2net @@ -46,7 +46,7 @@ define Package/ser2net/install $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/ser2net $(1)/usr/sbin/ $(INSTALL_DIR) $(1)/etc - $(INSTALL_CONF) $(PKG_BUILD_DIR)/ser2net.conf $(1)/etc/ + $(INSTALL_CONF) ./files/ser2net.conf $(1)/etc/ $(INSTALL_DIR) $(1)/etc/config $(INSTALL_CONF) ./files/ser2net.config $(1)/etc/config/ser2net diff --git a/net/ser2net/files/ser2net.config b/net/ser2net/files/ser2net.config index 1e9fcaa833..8ea52163d6 100644 --- a/net/ser2net/files/ser2net.config +++ b/net/ser2net/files/ser2net.config @@ -1,4 +1,4 @@ -config global +config ser2net global option enabled 1 config controlport diff --git a/net/ser2net/files/ser2net.init b/net/ser2net/files/ser2net.init index 59516bee53..2f7a3d5e72 100644 --- a/net/ser2net/files/ser2net.init +++ b/net/ser2net/files/ser2net.init @@ -165,7 +165,7 @@ start_service() { config_load ser2net - config_get_bool enabled ser2net enabled 0 + config_get_bool enabled global enabled 0 [ "$enabled" -gt 0 ] || return 0 cat "$STATICCFGFILE" - 2>/dev/null <<-EOF > "$DYNAMICCFGFILE" -- 2.30.2