Commit 601fc26e by Steve Ellcey Committed by Steve Ellcey

re PR target/37454 (gcc: unrecognized option '-rdynamic')

2010-01-08  Steve Ellcey  <sje@cup.hp.com>

	PR target/37454
	* configure.ac: Modify -rdynamic check.
	* configure: Regenerate.

From-SVN: r155745
parent e51ded7c
2010-01-08 Steve Ellcey <sje@cup.hp.com>
PR target/37454
* configure.ac: Modify -rdynamic check.
* configure: Regenerate.
2010-01-08 DJ Delorie <dj@redhat.com> 2010-01-08 DJ Delorie <dj@redhat.com>
* config/sh/sh.c (sh_expand_epilogue): Fix interrupt handler * config/sh/sh.c (sh_expand_epilogue): Fix interrupt handler
......
...@@ -25017,39 +25017,22 @@ fi ...@@ -25017,39 +25017,22 @@ fi
pluginlibs= pluginlibs=
if test x"$enable_plugin" = x"yes"; then if test x"$enable_plugin" = x"yes"; then
# Check that the host supports -rdynamic and -ldl
have_rdynamic=no
have_dl=no
saved_LDFLAGS="$LDFLAGS"
saved_LIBS="$LIBS"
LIBS=
# Check -rdynamic
LDFLAGS="$LDFLAGS -rdynamic"
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for -rdynamic" >&5
$as_echo_n "checking for -rdynamic... " >&6; }
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
int { $as_echo "$as_me:${as_lineno-$LINENO}: checking for exported symbols" >&5
main () $as_echo_n "checking for exported symbols... " >&6; }
{ echo "int main() {return 0;} int foobar() {return 0;}" > conftest.c
return 0; ${CC} ${CFLAGS} ${LDFLAGS} conftest.c -o conftest > /dev/null 2>&1
; if $gcc_cv_objdump -T conftest | grep foobar > /dev/null; then
return 0; : # No need to use a flag
} else
_ACEOF { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -rdynamic" >&5
if ac_fn_c_try_link "$LINENO"; then : $as_echo_n "checking for -rdynamic... " >&6; }
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 ${CC} ${CFLAGS} ${LDFLAGS} -rdynamic conftest.c -o conftest > /dev/null 2>&1
$as_echo "yes" >&6; }; have_rdynamic=yes if $gcc_cv_objdump -T conftest | grep foobar > /dev/null; then
else pluginlibs="-rdynamic"
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 else
$as_echo "no" >&6; } enable_plugin=no
fi fi
rm -f core conftest.err conftest.$ac_objext \
conftest$ac_exeext conftest.$ac_ext
if test x"$have_rdynamic" = x"yes" ; then
pluginlibs="-rdynamic"
fi fi
# Check -ldl # Check -ldl
...@@ -25150,9 +25133,6 @@ Building GCC with plugin support requires a host that supports ...@@ -25150,9 +25133,6 @@ Building GCC with plugin support requires a host that supports
-fPIC, -shared, -ldl and -rdynamic." "$LINENO" 5 -fPIC, -shared, -ldl and -rdynamic." "$LINENO" 5
fi fi
fi fi
LDFLAGS="$saved_LDFLAGS"
LIBS="$saved_LIBS"
fi fi
......
...@@ -4297,21 +4297,20 @@ enable_plugin=yes; default_plugin=yes) ...@@ -4297,21 +4297,20 @@ enable_plugin=yes; default_plugin=yes)
pluginlibs= pluginlibs=
if test x"$enable_plugin" = x"yes"; then if test x"$enable_plugin" = x"yes"; then
# Check that the host supports -rdynamic and -ldl
have_rdynamic=no AC_MSG_CHECKING([for exported symbols])
have_dl=no echo "int main() {return 0;} int foobar() {return 0;}" > conftest.c
saved_LDFLAGS="$LDFLAGS" ${CC} ${CFLAGS} ${LDFLAGS} conftest.c -o conftest > /dev/null 2>&1
saved_LIBS="$LIBS" if $gcc_cv_objdump -T conftest | grep foobar > /dev/null; then
LIBS= : # No need to use a flag
else
# Check -rdynamic AC_MSG_CHECKING([for -rdynamic])
LDFLAGS="$LDFLAGS -rdynamic" ${CC} ${CFLAGS} ${LDFLAGS} -rdynamic conftest.c -o conftest > /dev/null 2>&1
AC_MSG_CHECKING([for -rdynamic]) if $gcc_cv_objdump -T conftest | grep foobar > /dev/null; then
AC_TRY_LINK([],[return 0;], pluginlibs="-rdynamic"
[AC_MSG_RESULT([yes]); have_rdynamic=yes], else
[AC_MSG_RESULT([no])]) enable_plugin=no
if test x"$have_rdynamic" = x"yes" ; then fi
pluginlibs="-rdynamic"
fi fi
# Check -ldl # Check -ldl
...@@ -4340,9 +4339,6 @@ Building GCC with plugin support requires a host that supports ...@@ -4340,9 +4339,6 @@ Building GCC with plugin support requires a host that supports
-fPIC, -shared, -ldl and -rdynamic.]) -fPIC, -shared, -ldl and -rdynamic.])
fi fi
fi fi
LDFLAGS="$saved_LDFLAGS"
LIBS="$saved_LIBS"
fi fi
AC_SUBST(pluginlibs) AC_SUBST(pluginlibs)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment