aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard Tollerton <rich.tollerton@ni.com>2014-07-17 16:56:56 -0500
committerRichard Purdie <richard.purdie@linuxfoundation.org>2014-07-19 00:08:47 +0100
commitacb8674e498468088d867ffae9a458caa08d95d5 (patch)
tree0c89b7978e2e334104fa559a88278d78975b24f7
parent0a41a7c20316c7d3330233a624d8cf20ea5a81ae (diff)
downloadopenembedded-core-contrib-acb8674e498468088d867ffae9a458caa08d95d5.tar.gz
initscripts: make hostname.sh coreutils-compatible
inetutils and busybox hostname utils support `hostname -F`; coreutils hostname doesn't. So just use `cat` instead. Signed-off-by: Richard Tollerton <rich.tollerton@ni.com> Signed-off-by: Ben Shelton <ben.shelton@ni.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rwxr-xr-xmeta/recipes-core/initscripts/initscripts-1.0/hostname.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/meta/recipes-core/initscripts/initscripts-1.0/hostname.sh b/meta/recipes-core/initscripts/initscripts-1.0/hostname.sh
index 78fb91c409..95287cc139 100755
--- a/meta/recipes-core/initscripts/initscripts-1.0/hostname.sh
+++ b/meta/recipes-core/initscripts/initscripts-1.0/hostname.sh
@@ -16,7 +16,7 @@ fi
# Busybox hostname doesn't support -b so we need implement it on our own
if [ -f /etc/hostname ];then
- hostname -F /etc/hostname
+ hostname `cat /etc/hostname`
elif [ -z "$HOSTNAME" -o "$HOSTNAME" = "(none)" -o ! -z "`echo $HOSTNAME | sed -n '/^[0-9]*\.[0-9].*/p'`" ] ; then
hostname localhost
fi