summaryrefslogtreecommitdiff
path: root/package/base-files
diff options
context:
space:
mode:
authorSteven Barth <cyrus@openwrt.org>2015-10-02 08:24:32 +0000
committerSteven Barth <cyrus@openwrt.org>2015-10-02 08:24:32 +0000
commitd7023fc0bc4b66c44969276df9cbfe218f931250 (patch)
tree7a9824270ce880149bb84bbda911d101df6a6b7e /package/base-files
parenta24f7305cc743df0f12dde2fb9f72e0fdbbfe97b (diff)
downloadmtk-20170518-d7023fc0bc4b66c44969276df9cbfe218f931250.zip
mtk-20170518-d7023fc0bc4b66c44969276df9cbfe218f931250.tar.gz
mtk-20170518-d7023fc0bc4b66c44969276df9cbfe218f931250.tar.bz2
base-files: sanitize and unify $PATH
Previously init and hotplug paths were different from console. Signed-off-by: Steven Barth <steven@midlink.org> SVN-Revision: 47080
Diffstat (limited to 'package/base-files')
-rw-r--r--package/base-files/Makefile2
-rwxr-xr-xpackage/base-files/files/etc/preinit4
-rw-r--r--package/base-files/files/etc/profile2
-rwxr-xr-xpackage/base-files/files/sbin/hotplug-call2
4 files changed, 5 insertions, 5 deletions
diff --git a/package/base-files/Makefile b/package/base-files/Makefile
index 967d543..40fb093 100644
--- a/package/base-files/Makefile
+++ b/package/base-files/Makefile
@@ -11,7 +11,7 @@ include $(INCLUDE_DIR)/kernel.mk
include $(INCLUDE_DIR)/version.mk
PKG_NAME:=base-files
-PKG_RELEASE:=159
+PKG_RELEASE:=160
PKG_FILE_DEPENDS:=$(PLATFORM_DIR)/ $(GENERIC_PLATFORM_DIR)/base-files/
PKG_BUILD_DEPENDS:=opkg/host usign/host
diff --git a/package/base-files/files/etc/preinit b/package/base-files/files/etc/preinit
index 9cc8a9a..31f861e 100755
--- a/package/base-files/files/etc/preinit
+++ b/package/base-files/files/etc/preinit
@@ -4,7 +4,7 @@
[ -z "$PREINIT" ] && exec /sbin/init
-export PATH=/bin:/sbin:/usr/bin:/usr/sbin
+export PATH=/usr/sbin:/usr/bin:/sbin:/bin
pi_ifname=
pi_ip=192.168.1.1
@@ -20,7 +20,7 @@ fs_failsafe_wait_timeout=2
pi_suppress_stderr="y"
pi_init_suppress_stderr="y"
-pi_init_path="/bin:/sbin:/usr/bin:/usr/sbin"
+pi_init_path="/usr/sbin:/usr/bin:/sbin:/bin"
pi_init_cmd="/sbin/init"
. /lib/functions.sh
diff --git a/package/base-files/files/etc/profile b/package/base-files/files/etc/profile
index 577b63b..bd008a8 100644
--- a/package/base-files/files/etc/profile
+++ b/package/base-files/files/etc/profile
@@ -2,7 +2,7 @@
[ -f /etc/banner ] && cat /etc/banner
[ -e /tmp/.failsafe ] && cat /etc/banner.failsafe
-export PATH=/usr/bin:/usr/sbin:/bin:/sbin
+export PATH=/usr/sbin:/usr/bin:/sbin:/bin
export HOME=$(grep -e "^${USER:-root}:" /etc/passwd | cut -d ":" -f 6)
export HOME=${HOME:-/root}
export PS1='\u@\h:\w\$ '
diff --git a/package/base-files/files/sbin/hotplug-call b/package/base-files/files/sbin/hotplug-call
index 260be0b..743871a 100755
--- a/package/base-files/files/sbin/hotplug-call
+++ b/package/base-files/files/sbin/hotplug-call
@@ -5,7 +5,7 @@ export HOTPLUG_TYPE="$1"
. /lib/functions.sh
-PATH=/bin:/sbin:/usr/bin:/usr/sbin
+PATH=/usr/sbin:/usr/bin:/sbin:/bin
LOGNAME=root
USER=root
export PATH LOGNAME USER