re PR target/26792 (need to use autoconf when using newly-added libgcc functions)

PR target/26792
	* configure.ac: Use GCC_CHECK_UNWIND_GETIPINFO to
	define HAVE_GETIPINFO.
	* aclocal.m4: Add include of ../config/unwind_ipinfo.m4.
	* config.h.in: Regenerate.
	* configure: Regenerate.
	* Makefile.in: Regenerate.
	* libmath/Makefile.in: Regenerate.
	* include/Makefile.in: Regenerate.
	* src/Makefile.in: Regenerate.
	* libsupc++/Makefile.in: Regenerate.
	* testsuite/Makefile.in: Regenerate.
	* po/Makefile.in: Regenerate.
	* libsupc++/eh_personality.cc: Check HAVE_GETIPINFO.

From-SVN: r115654
This commit is contained in:
Steve Ellcey 2006-07-21 21:11:46 +00:00 committed by Steve Ellcey
parent 511464e382
commit 2e5757965d
13 changed files with 134 additions and 0 deletions

View File

@ -1,3 +1,20 @@
2006-07-21 Steve Ellcey <sje@cup.hp.com>
PR target/26792
* configure.ac: Use GCC_CHECK_UNWIND_GETIPINFO to
define HAVE_GETIPINFO.
* aclocal.m4: Add include of ../config/unwind_ipinfo.m4.
* config.h.in: Regenerate.
* configure: Regenerate.
* Makefile.in: Regenerate.
* libmath/Makefile.in: Regenerate.
* include/Makefile.in: Regenerate.
* src/Makefile.in: Regenerate.
* libsupc++/Makefile.in: Regenerate.
* testsuite/Makefile.in: Regenerate.
* po/Makefile.in: Regenerate.
* libsupc++/eh_personality.cc: Check HAVE_GETIPINFO.
2006-07-21 Jason Merrill <jason@redhat.com>
* libsupc++/eh_personality.cc: Wrap extern "C" function

View File

@ -48,6 +48,7 @@ ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/../config/enable.m4 \
$(top_srcdir)/../config/lead-dot.m4 \
$(top_srcdir)/../config/no-executables.m4 \
$(top_srcdir)/../config/unwind_ipinfo.m4 \
$(top_srcdir)/../libtool.m4 $(top_srcdir)/crossconfig.m4 \
$(top_srcdir)/linkage.m4 $(top_srcdir)/acinclude.m4 \
$(top_srcdir)/../config/tls.m4 $(top_srcdir)/configure.ac

View File

@ -641,6 +641,7 @@ AC_SUBST([am__untar])
m4_include([../config/enable.m4])
m4_include([../config/lead-dot.m4])
m4_include([../config/no-executables.m4])
m4_include([../config/unwind_ipinfo.m4])
m4_include([../libtool.m4])
m4_include([crossconfig.m4])
m4_include([linkage.m4])

View File

@ -111,6 +111,9 @@
/* Define to 1 if you have the <gconv.h> header file. */
#undef HAVE_GCONV_H
/* Define if _Unwind_GetIPInfo is available. */
#undef HAVE_GETIPINFO
/* Define to 1 if you have the `getpagesize' function. */
#undef HAVE_GETPAGESIZE

View File

@ -31370,6 +31370,96 @@ _ACEOF
fi
# For _Unwind_GetIPInfo.
ac_ext=cc
ac_cpp='$CXXCPP $CPPFLAGS'
ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
ac_save_CXXFLAGS="$CXXFLAGS"
CXXFLAGS="$CXXFLAGS -fno-exceptions"
echo "$as_me:$LINENO: checking for _Unwind_GetIPInfo" >&5
echo $ECHO_N "checking for _Unwind_GetIPInfo... $ECHO_C" >&6
if test "${gcc_cv_getipinfo+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
if test x$gcc_no_link = xyes; then
{ { echo "$as_me:$LINENO: error: Link tests are not allowed after GCC_NO_EXECUTABLES." >&5
echo "$as_me: error: Link tests are not allowed after GCC_NO_EXECUTABLES." >&2;}
{ (exit 1); exit 1; }; }
fi
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
extern "C" { extern void _Unwind_GetIPInfo(); }
int
main ()
{
_Unwind_GetIPInfo();
;
return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
(eval $ac_link) 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } &&
{ ac_try='test -z "$ac_cxx_werror_flag"
|| test ! -s conftest.err'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; } &&
{ ac_try='test -s conftest$ac_exeext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
gcc_cv_getipinfo=yes
else
echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
gcc_cv_getipinfo=no
fi
rm -f conftest.err conftest.$ac_objext \
conftest$ac_exeext conftest.$ac_ext
fi
if test $gcc_cv_getipinfo = yes; then
cat >>confdefs.h <<\_ACEOF
#define HAVE_GETIPINFO 1
_ACEOF
fi
echo "$as_me:$LINENO: result: $gcc_cv_getipinfo" >&5
echo "${ECHO_T}$gcc_cv_getipinfo" >&6
CXXFLAGS="$ac_save_CXXFLAGS"
ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
ac_compiler_gnu=$ac_cv_c_compiler_gnu
if test "${ac_cv_header_locale_h+set}" = set; then
echo "$as_me:$LINENO: checking for locale.h" >&5
@ -108776,6 +108866,12 @@ _ACEOF
fi
# Assume we have _Unwind_GetIPInfo for cross-compiles.
cat >>confdefs.h <<\_ACEOF
#define HAVE_GETIPINFO 1
_ACEOF
fi
# This depends on GLIBCXX CHECK_LINKER_FEATURES, but without it assumes no.

View File

@ -167,6 +167,9 @@ if $GLIBCXX_IS_NATIVE; then
# For TLS support.
GCC_CHECK_TLS
# For _Unwind_GetIPInfo.
GCC_CHECK_UNWIND_GETIPINFO
AC_LC_MESSAGES
AC_TRY_COMPILE(
@ -283,6 +286,9 @@ else
AC_DEFINE(HAVE_TANHL)
fi
# Assume we have _Unwind_GetIPInfo for cross-compiles.
AC_DEFINE(HAVE_GETIPINFO)
fi
# This depends on GLIBCXX CHECK_LINKER_FEATURES, but without it assumes no.

View File

@ -43,6 +43,7 @@ ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/../config/enable.m4 \
$(top_srcdir)/../config/lead-dot.m4 \
$(top_srcdir)/../config/no-executables.m4 \
$(top_srcdir)/../config/unwind_ipinfo.m4 \
$(top_srcdir)/../libtool.m4 $(top_srcdir)/crossconfig.m4 \
$(top_srcdir)/linkage.m4 $(top_srcdir)/acinclude.m4 \
$(top_srcdir)/../config/tls.m4 $(top_srcdir)/configure.ac

View File

@ -43,6 +43,7 @@ ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/../config/enable.m4 \
$(top_srcdir)/../config/lead-dot.m4 \
$(top_srcdir)/../config/no-executables.m4 \
$(top_srcdir)/../config/unwind_ipinfo.m4 \
$(top_srcdir)/../libtool.m4 $(top_srcdir)/crossconfig.m4 \
$(top_srcdir)/linkage.m4 $(top_srcdir)/acinclude.m4 \
$(top_srcdir)/../config/tls.m4 $(top_srcdir)/configure.ac

View File

@ -45,6 +45,7 @@ ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/../config/enable.m4 \
$(top_srcdir)/../config/lead-dot.m4 \
$(top_srcdir)/../config/no-executables.m4 \
$(top_srcdir)/../config/unwind_ipinfo.m4 \
$(top_srcdir)/../libtool.m4 $(top_srcdir)/crossconfig.m4 \
$(top_srcdir)/linkage.m4 $(top_srcdir)/acinclude.m4 \
$(top_srcdir)/../config/tls.m4 $(top_srcdir)/configure.ac

View File

@ -434,7 +434,11 @@ PERSONALITY_FUNCTION (int version,
// Parse the LSDA header.
p = parse_lsda_header (context, language_specific_data, &info);
info.ttype_base = base_of_encoded_value (info.ttype_encoding, context);
#ifdef HAVE_GETIPINFO
ip = _Unwind_GetIPInfo (context, &ip_before_insn);
#else
ip = _Unwind_GetIP (context);
#endif
if (! ip_before_insn)
--ip;
landing_pad = 0;

View File

@ -43,6 +43,7 @@ ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/../config/enable.m4 \
$(top_srcdir)/../config/lead-dot.m4 \
$(top_srcdir)/../config/no-executables.m4 \
$(top_srcdir)/../config/unwind_ipinfo.m4 \
$(top_srcdir)/../libtool.m4 $(top_srcdir)/crossconfig.m4 \
$(top_srcdir)/linkage.m4 $(top_srcdir)/acinclude.m4 \
$(top_srcdir)/../config/tls.m4 $(top_srcdir)/configure.ac

View File

@ -43,6 +43,7 @@ ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/../config/enable.m4 \
$(top_srcdir)/../config/lead-dot.m4 \
$(top_srcdir)/../config/no-executables.m4 \
$(top_srcdir)/../config/unwind_ipinfo.m4 \
$(top_srcdir)/../libtool.m4 $(top_srcdir)/crossconfig.m4 \
$(top_srcdir)/linkage.m4 $(top_srcdir)/acinclude.m4 \
$(top_srcdir)/../config/tls.m4 $(top_srcdir)/configure.ac

View File

@ -43,6 +43,7 @@ ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/../config/enable.m4 \
$(top_srcdir)/../config/lead-dot.m4 \
$(top_srcdir)/../config/no-executables.m4 \
$(top_srcdir)/../config/unwind_ipinfo.m4 \
$(top_srcdir)/../libtool.m4 $(top_srcdir)/crossconfig.m4 \
$(top_srcdir)/linkage.m4 $(top_srcdir)/acinclude.m4 \
$(top_srcdir)/../config/tls.m4 $(top_srcdir)/configure.ac