-6f0ac34e139755c319368757fe2a093f1e5bde49
+eac8b31fec761c8da0606a70ae0547ff0b12e8db
The first line of this file holds the git revision number of the last
merge done from the gofrontend repository.
LTLDFLAGS = $(shell $(SHELL) $(top_srcdir)/../libtool-ldflags $(LDFLAGS))
GOCFLAGS = $(CFLAGS)
-AM_GOCFLAGS = $(STRINGOPS_FLAG)
+AM_GOCFLAGS = $(STRINGOPS_FLAG) $(GO_SPLIT_STACK)
GOCOMPILE = $(GOC) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_GOCFLAGS) $(GOCFLAGS)
LTGOCOMPILE = $(LIBTOOL) --tag GO --mode=compile $(GOC) $(INCLUDES) \
GOOS = @GOOS@
GO_LIBCALL_OS_ARCH_FILE = @GO_LIBCALL_OS_ARCH_FILE@
GO_LIBCALL_OS_FILE = @GO_LIBCALL_OS_FILE@
+GO_SPLIT_STACK = @GO_SPLIT_STACK@
GO_SYSCALL_OS_ARCH_FILE = @GO_SYSCALL_OS_ARCH_FILE@
GO_SYSCALL_OS_FILE = @GO_SYSCALL_OS_FILE@
GREP = @GREP@
libnetgo_a_SOURCES = $(go_netgo_files)
libnetgo_a_LIBADD = netgo.o
LTLDFLAGS = $(shell $(SHELL) $(top_srcdir)/../libtool-ldflags $(LDFLAGS))
-AM_GOCFLAGS = $(STRINGOPS_FLAG)
+AM_GOCFLAGS = $(STRINGOPS_FLAG) $(GO_SPLIT_STACK)
GOCOMPILE = $(GOC) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_GOCFLAGS) $(GOCFLAGS)
LTGOCOMPILE = $(LIBTOOL) --tag GO --mode=compile $(GOC) $(INCLUDES) \
$(AM_GOCFLAGS) $(GOCFLAGS)
MATH_LIBS
GOC_IS_LLGO_FALSE
GOC_IS_LLGO_TRUE
+GO_SPLIT_STACK
USING_SPLIT_STACK_FALSE
USING_SPLIT_STACK_TRUE
SPLIT_STACK
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<_LT_EOF
-#line 11126 "configure"
+#line 11127 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<_LT_EOF
-#line 11232 "configure"
+#line 11233 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
fi
+if test "$libgo_cv_c_split_stack_supported" = yes -a "$libgo_cv_c_linker_split_non_split" = no; then
+ GO_SPLIT_STACK=-fno-split-stack
+else
+ GO_SPLIT_STACK=
+fi
+
+
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether linker supports split stack" >&5
$as_echo_n "checking whether linker supports split stack... " >&6; }
if test "${libgo_cv_c_linker_supports_split_stack+set}" = set; then :
AM_CONDITIONAL(USING_SPLIT_STACK,
test "$libgo_cv_c_split_stack_supported" = yes -a "$libgo_cv_c_linker_split_non_split" = yes)
+dnl If the compiler supports split-stack but the linker does not, then
+dnl we need to explicitly disable split-stack for Go.
+if test "$libgo_cv_c_split_stack_supported" = yes -a "$libgo_cv_c_linker_split_non_split" = no; then
+ GO_SPLIT_STACK=-fno-split-stack
+else
+ GO_SPLIT_STACK=
+fi
+AC_SUBST(GO_SPLIT_STACK)
+
dnl Check whether the linker does stack munging when calling from
dnl split-stack into non-split-stack code. We check this by looking
dnl at the --help output. FIXME: This is only half right: it's
GOOS = @GOOS@
GO_LIBCALL_OS_ARCH_FILE = @GO_LIBCALL_OS_ARCH_FILE@
GO_LIBCALL_OS_FILE = @GO_LIBCALL_OS_FILE@
+GO_SPLIT_STACK = @GO_SPLIT_STACK@
GO_SYSCALL_OS_ARCH_FILE = @GO_SYSCALL_OS_ARCH_FILE@
GO_SYSCALL_OS_FILE = @GO_SYSCALL_OS_FILE@
GREP = @GREP@