GNU Binutils with patches for OS216
Revision | f6de3c42a31e268abe5f03ea860742829db2f677 (tree) |
---|---|
Zeit | 2004-10-17 01:18:54 |
Autor | Daniel Jacobowitz <drow@fals...> |
Commiter | Daniel Jacobowitz |
* configure.in: Test for -rdynamic.
* configure: Regenerated.
* Makefile (INTERNAL_LDFLAGS): New.
(gdbserver, gdbreplay): Use it.
@@ -1,3 +1,10 @@ | ||
1 | +2004-10-16 Daniel Jacobowitz <dan@debian.org> | |
2 | + | |
3 | + * configure.in: Test for -rdynamic. | |
4 | + * configure: Regenerated. | |
5 | + * Makefile (INTERNAL_LDFLAGS): New. | |
6 | + (gdbserver, gdbreplay): Use it. | |
7 | + | |
1 | 8 | 2004-09-02 Andrew Cagney <cagney@gnu.org> |
2 | 9 | |
3 | 10 | * Makefile.in (TAGS): Replace TM_FILE with DEPRECATED_TM_FILE. |
@@ -103,6 +103,7 @@ INTERNAL_CFLAGS = $(WARN_CFLAGS) ${CFLAGS} ${GLOBAL_CFLAGS} \ | ||
103 | 103 | # LDFLAGS is specifically reserved for setting from the command line |
104 | 104 | # when running make. |
105 | 105 | LDFLAGS = @LDFLAGS@ |
106 | +INTERNAL_LDFLAGS = $(LDFLAGS) @RDYNAMIC@ | |
106 | 107 | |
107 | 108 | # Perhaps should come from parent Makefile |
108 | 109 | VERSION = gdbserver-4.12.3 |
@@ -171,12 +172,12 @@ clean-info: | ||
171 | 172 | |
172 | 173 | gdbserver: $(OBS) ${ADD_DEPS} ${CDEPS} |
173 | 174 | rm -f gdbserver |
174 | - ${CC-LD} $(GLOBAL_CFLAGS) $(LDFLAGS) -o gdbserver $(OBS) \ | |
175 | + ${CC-LD} $(GLOBAL_CFLAGS) $(INTERNAL_LDFLAGS) -o gdbserver $(OBS) \ | |
175 | 176 | $(GDBSERVER_LIBS) $(XM_CLIBS) |
176 | 177 | |
177 | 178 | gdbreplay: gdbreplay.o |
178 | 179 | rm -f gdbreplay |
179 | - ${CC-LD} $(GLOBAL_CFLAGS) $(LDFLAGS) -o gdbreplay gdbreplay.o \ | |
180 | + ${CC-LD} $(GLOBAL_CFLAGS) $(INTERNAL_LDFLAGS) -o gdbreplay gdbreplay.o \ | |
180 | 181 | $(XM_CLIBS) |
181 | 182 | |
182 | 183 | # Put the proper machine-specific files first, so M-. on a machine |
@@ -1582,6 +1582,28 @@ rm -f conftest* | ||
1582 | 1582 | else |
1583 | 1583 | srv_libs="$srv_cv_thread_db" |
1584 | 1584 | fi |
1585 | + old_LDFLAGS="$LDFLAGS" | |
1586 | + LDFLAGS="$LDFLAGS -rdynamic" | |
1587 | + cat > conftest.$ac_ext <<EOF | |
1588 | +#line 1589 "configure" | |
1589 | +#include "confdefs.h" | |
1590 | + | |
1591 | +int main() { | |
1592 | + | |
1593 | +; return 0; } | |
1594 | +EOF | |
1595 | +if { (eval echo configure:1596: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then | |
1596 | + rm -rf conftest* | |
1597 | + RDYNAMIC=-rdynamic | |
1598 | +else | |
1599 | + echo "configure: failed program was:" >&5 | |
1600 | + cat conftest.$ac_ext >&5 | |
1601 | + rm -rf conftest* | |
1602 | + RDYNAMIC= | |
1603 | +fi | |
1604 | +rm -f conftest* | |
1605 | + | |
1606 | + LDFLAGS="$old_LDFLAGS" | |
1585 | 1607 | fi |
1586 | 1608 | |
1587 | 1609 | if test "$srv_linux_thread_db" = "yes"; then |
@@ -1749,6 +1771,7 @@ s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g | ||
1749 | 1771 | s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g |
1750 | 1772 | s%@INSTALL_DATA@%$INSTALL_DATA%g |
1751 | 1773 | s%@CPP@%$CPP%g |
1774 | +s%@RDYNAMIC@%$RDYNAMIC%g | |
1752 | 1775 | s%@GDBSERVER_DEPFILES@%$GDBSERVER_DEPFILES%g |
1753 | 1776 | s%@GDBSERVER_LIBS@%$GDBSERVER_LIBS%g |
1754 | 1777 | s%@USE_THREAD_DB@%$USE_THREAD_DB%g |
@@ -1,5 +1,5 @@ | ||
1 | 1 | dnl Autoconf configure script for GDB server. |
2 | -dnl Copyright 2000, 2002 Free Software Foundation, Inc. | |
2 | +dnl Copyright 2000, 2002, 2003, 2004 Free Software Foundation, Inc. | |
3 | 3 | dnl |
4 | 4 | dnl This file is part of GDB. |
5 | 5 | dnl |
@@ -114,6 +114,11 @@ if test "$srv_linux_thread_db" = "yes"; then | ||
114 | 114 | else |
115 | 115 | srv_libs="$srv_cv_thread_db" |
116 | 116 | fi |
117 | + old_LDFLAGS="$LDFLAGS" | |
118 | + LDFLAGS="$LDFLAGS -rdynamic" | |
119 | + AC_TRY_LINK([], [], [RDYNAMIC=-rdynamic], [RDYNAMIC=]) | |
120 | + AC_SUBST(RDYNAMIC) | |
121 | + LDFLAGS="$old_LDFLAGS" | |
117 | 122 | fi |
118 | 123 | |
119 | 124 | if test "$srv_linux_thread_db" = "yes"; then |