preinit: use only the image config options
authorMathias Kresin <dev@kresin.me>
Sun, 7 Aug 2016 20:21:34 +0000 (22:21 +0200)
committerJohn Crispin <john@phrozen.org>
Wed, 10 Aug 2016 01:04:08 +0000 (03:04 +0200)
The pi_* variables and the fs_failsafe_wait_timeout variable are set by
the CONFIG_TARGET_PREINIT_* config options. No need to maintain the same
values twice.

All other fs_ variables were never used.

Signed-off-by: Mathias Kresin <dev@kresin.me>
package/base-files/Makefile
package/base-files/files/etc/preinit

index a32f345ea1bc0ebc4bf855952c1fecb30f80b246..25fd9f2588762e629704a040ecef86855cca2afb 100644 (file)
@@ -64,7 +64,6 @@ define Package/base-files/description
  This package contains a base filesystem and system scripts for OpenWrt.
 endef
 
-ifneq ($(CONFIG_PREINITOPT),)
 define ImageConfigOptions
        mkdir -p $(1)/lib/preinit
        echo 'pi_suppress_stderr="$(CONFIG_TARGET_PREINIT_SUPPRESS_STDERR)"' >$(1)/lib/preinit/00_preinit.conf
@@ -81,7 +80,6 @@ define ImageConfigOptions
        echo 'pi_preinit_no_failsafe_netmsg="$(CONFIG_TARGET_PREINIT_SUPPRESS_FAILSAFE_NETMSG)"' >>$(1)/lib/preinit/00_preinit.conf
        echo 'pi_preinit_no_failsafe="$(CONFIG_TARGET_PREINIT_DISABLE_FAILSAFE)"' >>$(1)/lib/preinit/00_preinit.conf
 endef
-endif
 
 define Build/Prepare
        mkdir -p $(PKG_BUILD_DIR)
index 181b332f146912b432c6f5c6dedb77f86b01493d..829574f5f1824fe207fba3d7cece2a391c9bc2a6 100755 (executable)
@@ -6,23 +6,6 @@
 
 export PATH="%PATH%"
 
-pi_ifname=
-pi_ip=192.168.1.1
-pi_broadcast=192.168.1.255
-pi_netmask=255.255.255.0
-
-fs_failsafe_ifname=
-fs_failsafe_ip=192.168.1.1
-fs_failsafe_broadcast=192.168.1.255
-fs_failsafe_netmask=255.255.255.0
-
-fs_failsafe_wait_timeout=2
-
-pi_suppress_stderr="y"
-pi_init_suppress_stderr="y"
-pi_init_path="%PATH%"
-pi_init_cmd="/sbin/init"
-
 . /lib/functions.sh
 . /lib/functions/preinit.sh
 . /lib/functions/system.sh