Quote shell variables that may contain whitespace in the configure
file.  I cannot remember exactly whether I actually ran into a
problem, but the patch won't hurt anyway.

ChangeLog
2014-09-05  Dominik Vogt  <v...@linux.vnet.ibm.com>

        * libgo/configure.ac (GO_SYSCALL_OS_ARCH_FILE): Use double quotes around
        path names.
        (GO_SYSCALL_OS_FILE): Ditto.
        (GO_LIBCALL_OS_ARCH_FILE): Ditto.
        (GO_LIBCALL_OS_FILE): Ditto.

Ciao

Dominik ^_^  ^_^

-- 

Dominik Vogt
IBM Germany
>From 11938b5b3303b5b8df8914d59dcceea38c0a0a0c Mon Sep 17 00:00:00 2001
From: Dominik Vogt <v...@linux.vnet.ibm.com>
Date: Fri, 5 Sep 2014 07:31:05 +0100
Subject: [PATCH 9/9] LIBGO: Fix handling of path names with whitespace.

Paths and filenames need to be quoted in case they contain whitespace or other
dangerous characters.
---
 libgo/configure    | 16 ++++++++--------
 libgo/configure.ac | 16 ++++++++--------
 2 files changed, 16 insertions(+), 16 deletions(-)

diff --git a/libgo/configure b/libgo/configure
index 08ddb18..53202e4 100755
--- a/libgo/configure
+++ b/libgo/configure
@@ -13886,17 +13886,17 @@ GO_LIBCALL_OS_FILE=
 GO_LIBCALL_OS_ARCH_FILE=
 GO_SYSCALL_OS_FILE=
 GO_SYSCALL_OS_ARCH_FILE=
-if test -f ${srcdir}/go/syscall/libcall_${GOOS}.go; then
-  GO_LIBCALL_OS_FILE=go/syscall/libcall_${GOOS}.go
+if test -f "${srcdir}/go/syscall/libcall_${GOOS}.go"; then
+  GO_LIBCALL_OS_FILE="go/syscall/libcall_${GOOS}.go"
 fi
-if test -f ${srcdir}/go/syscall/libcall_${GOOS}_${GOARCH}.go; then
-  GO_LIBCALL_OS_ARCH_FILE=go/syscall/libcall_${GOOS}_${GOARCH}.go
+if test -f "${srcdir}/go/syscall/libcall_${GOOS}_${GOARCH}.go"; then
+  GO_LIBCALL_OS_ARCH_FILE="go/syscall/libcall_${GOOS}_${GOARCH}.go"
 fi
-if test -f ${srcdir}/go/syscall/syscall_${GOOS}.go; then
-  GO_SYSCALL_OS_FILE=go/syscall/syscall_${GOOS}.go
+if test -f "${srcdir}/go/syscall/syscall_${GOOS}.go"; then
+  GO_SYSCALL_OS_FILE="go/syscall/syscall_${GOOS}.go"
 fi
-if test -f ${srcdir}/go/syscall/syscall_${GOOS}_${GOARCH}.go; then
-  GO_SYSCALL_OS_ARCH_FILE=go/syscall/syscall_${GOOS}_${GOARCH}.go
+if test -f "${srcdir}/go/syscall/syscall_${GOOS}_${GOARCH}.go"; then
+  GO_SYSCALL_OS_ARCH_FILE="go/syscall/syscall_${GOOS}_${GOARCH}.go"
 fi
 
 
diff --git a/libgo/configure.ac b/libgo/configure.ac
index 5e1e4d9..d29db0c 100644
--- a/libgo/configure.ac
+++ b/libgo/configure.ac
@@ -306,17 +306,17 @@ GO_LIBCALL_OS_FILE=
 GO_LIBCALL_OS_ARCH_FILE=
 GO_SYSCALL_OS_FILE=
 GO_SYSCALL_OS_ARCH_FILE=
-if test -f ${srcdir}/go/syscall/libcall_${GOOS}.go; then
-  GO_LIBCALL_OS_FILE=go/syscall/libcall_${GOOS}.go
+if test -f "${srcdir}/go/syscall/libcall_${GOOS}.go"; then
+  GO_LIBCALL_OS_FILE="go/syscall/libcall_${GOOS}.go"
 fi
-if test -f ${srcdir}/go/syscall/libcall_${GOOS}_${GOARCH}.go; then
-  GO_LIBCALL_OS_ARCH_FILE=go/syscall/libcall_${GOOS}_${GOARCH}.go
+if test -f "${srcdir}/go/syscall/libcall_${GOOS}_${GOARCH}.go"; then
+  GO_LIBCALL_OS_ARCH_FILE="go/syscall/libcall_${GOOS}_${GOARCH}.go"
 fi
-if test -f ${srcdir}/go/syscall/syscall_${GOOS}.go; then
-  GO_SYSCALL_OS_FILE=go/syscall/syscall_${GOOS}.go
+if test -f "${srcdir}/go/syscall/syscall_${GOOS}.go"; then
+  GO_SYSCALL_OS_FILE="go/syscall/syscall_${GOOS}.go"
 fi
-if test -f ${srcdir}/go/syscall/syscall_${GOOS}_${GOARCH}.go; then
-  GO_SYSCALL_OS_ARCH_FILE=go/syscall/syscall_${GOOS}_${GOARCH}.go
+if test -f "${srcdir}/go/syscall/syscall_${GOOS}_${GOARCH}.go"; then
+  GO_SYSCALL_OS_ARCH_FILE="go/syscall/syscall_${GOOS}_${GOARCH}.go"
 fi
 AC_SUBST(GO_LIBCALL_OS_FILE)
 AC_SUBST(GO_LIBCALL_OS_ARCH_FILE)
-- 
1.8.4.2

Reply via email to