[oe-commits] Robert Yang : arptables: remove bashism

git at git.openembedded.org git at git.openembedded.org
Tue Sep 23 17:01:25 UTC 2014


Module: meta-openembedded.git
Branch: master-next
Commit: 8e6a79fe1944a04fc8f862bdf221ec752b86beb7
URL:    http://git.openembedded.org/?p=meta-openembedded.git&a=commit;h=8e6a79fe1944a04fc8f862bdf221ec752b86beb7

Author: Robert Yang <liezhi.yang at windriver.com>
Date:   Sun Aug 31 23:22:11 2014 -0700

arptables: remove bashism

Bashism:
possible bashism in arptables/etc/init.d/arptables line 14 (should be '.', not 'source'):
source /etc/init.d/functions
possible bashism in arptables/etc/init.d/arptables line 96 ($"foo" should be eval_gettext "foo"):
        echo $"Usage $0 {start|stop|restart|condrestart|save|status}"

Use "." to replace of "source", and change /bin/bash to /bin/sh, the
echo $"foo" works well in our busybox.

Signed-off-by: Robert Yang <liezhi.yang at windriver.com>

---

 .../arptables-remove-bashism.patch                 | 37 ++++++++++++++++++++++
 .../recipes-support/arptables/arptables_0.0.3-4.bb |  1 +
 2 files changed, 38 insertions(+)

diff --git a/meta-networking/recipes-support/arptables/arptables-0.0.3-4/arptables-remove-bashism.patch b/meta-networking/recipes-support/arptables/arptables-0.0.3-4/arptables-remove-bashism.patch
new file mode 100644
index 0000000..f332658
--- /dev/null
+++ b/meta-networking/recipes-support/arptables/arptables-0.0.3-4/arptables-remove-bashism.patch
@@ -0,0 +1,37 @@
+From cd312bc0e3686404428878d23b8888cba09a20e1 Mon Sep 17 00:00:00 2001
+From: Robert Yang <liezhi.yang at windriver.com>
+Date: Thu, 18 Sep 2014 19:46:58 -0700
+Subject: [PATCH] arptables.sysv: remove bashism
+
+Use "." to replace of "source", and change /bin/bash to /bin/sh, the
+echo $"foo" works well in busybox.
+
+Upstream-Status: Pending
+
+Signed-off-by: Robert Yang <liezhi.yang at windriver.com>
+---
+ arptables.sysv |    4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/arptables.sysv b/arptables.sysv
+index 7a90bd2..7710376 100644
+--- a/arptables.sysv
++++ b/arptables.sysv
+@@ -1,4 +1,4 @@
+-#!/bin/bash
++#!/bin/sh
+ #
+ # init script for arptables
+ #
+@@ -11,7 +11,7 @@
+ #
+ # config: __SYSCONFIG__/arptables
+ 
+-source /etc/init.d/functions
++. /etc/init.d/functions
+ # source /etc/sysconfig/network
+ 
+ # Check that networking is up.
+-- 
+1.7.9.5
+
diff --git a/meta-networking/recipes-support/arptables/arptables_0.0.3-4.bb b/meta-networking/recipes-support/arptables/arptables_0.0.3-4.bb
index 74f81b5..41a55c0 100644
--- a/meta-networking/recipes-support/arptables/arptables_0.0.3-4.bb
+++ b/meta-networking/recipes-support/arptables/arptables_0.0.3-4.bb
@@ -13,6 +13,7 @@ SRC_URI = " \
     file://arptables-compile-install.patch \
     file://arptables-init-busybox.patch \
     file://arptables-arpt-get-target-fix.patch \
+    file://arptables-remove-bashism.patch \
 "
 SRC_URI[arptables.md5sum] = "1d4ab05761f063b0751645d8f2b8f8e5"
 SRC_URI[arptables.sha256sum] = "e529fd465c67d69ad335299a043516e6b38cdcd337a5ed21718413e96073f928"



More information about the Openembedded-commits mailing list