blob: 373c6a6d384e504a706ec67c52b30f1cd9e1e567 [file] [log] [blame]
b.liue9582032025-04-17 19:18:16 +08001From 444991b95ed25d58c3cd1646fa823620380b6ce6 Mon Sep 17 00:00:00 2001
2From: Yousong Zhou <yszhou4tech@gmail.com>
3Date: Wed, 14 Mar 2018 16:44:13 +0800
4Subject: [PATCH] ovs-lib: fix install_dir()
5
6The command "install" is not available in OpenWrt by default
7
8Signed-off-by: Yousong Zhou <yszhou4tech@gmail.com>
9---
10 utilities/ovs-lib.in | 5 ++++-
11 1 file changed, 4 insertions(+), 1 deletion(-)
12
13--- a/utilities/ovs-lib.in
14+++ b/utilities/ovs-lib.in
15@@ -159,7 +159,10 @@ install_dir () {
16 [ "${OVS_USER##*:}" != "" ] && INSTALL_GROUP="${OVS_USER##*:}"
17
18 if test ! -d "$DIR"; then
19- install -d -m "$INSTALL_MODE" -o "$INSTALL_USER" -g "$INSTALL_GROUP" "$DIR"
20+ mkdir -p "$DIR"
21+ chmod "$INSTALL_MODE" "$DIR"
22+ chown "$INSTALL_USER" "$DIR"
23+ chgrp "$INSTALL_GROUP" "$DIR"
24 restorecon "$DIR" >/dev/null 2>&1
25 fi
26 }