[ovs-dev] [PATCH 05/21] openvswitch.m4: Portability improvement

YAMAMOTO Takashi yamamoto at midokura.com
Mon Oct 19 04:28:56 UTC 2015


${parameter/pattern/string} substituion is not portable.
Replace them with $SED equivalent.

Signed-off-by: YAMAMOTO Takashi <yamamoto at midokura.com>
---
 m4/openvswitch.m4 | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/m4/openvswitch.m4 b/m4/openvswitch.m4
index d355811..683a6a7 100644
--- a/m4/openvswitch.m4
+++ b/m4/openvswitch.m4
@@ -109,11 +109,11 @@ AC_DEFUN([OVS_CHECK_WIN32],
             fi
             if test "$cl_cv_x64" = yes; then
                 PTHREAD_WIN32_DIR=$withval/lib/x64
-                PTHREAD_WIN32_DIR_DLL=/${withval/:/}/dll/x64
+                PTHREAD_WIN32_DIR_DLL=/$(echo ${withval} | ${SED} -e '/://')/dll/x64
                 PTHREAD_WIN32_DIR_DLL_WIN_FORM=$withval/dll/x64
             else
                 PTHREAD_WIN32_DIR=$withval/lib/x86
-                PTHREAD_WIN32_DIR_DLL=/${withval/:/}/dll/x86
+                PTHREAD_WIN32_DIR_DLL=/$(echo ${withval} | ${SED} -e '/://')/dll/x64
                 PTHREAD_WIN32_DIR_DLL_WIN_FORM=$withval/dll/x86
             fi
             PTHREAD_INCLUDES=-I$withval/include
-- 
2.3.8 (Apple Git-58)




More information about the dev mailing list