From 7e7e19dfc26006b934204f3464f7a3e3a0f11804 Mon Sep 17 00:00:00 2001 From: skrll Date: Thu, 29 Jun 2006 19:27:41 +0000 Subject: [PATCH] Pull in fix from binutils-current that allows -shared and -static to be used together again. This is something that ld.elf_so did/will use. --- gnu/dist/binutils/ld/ChangeLog | 5 +++++ gnu/dist/binutils/ld/ld.texinfo | 6 +++++- gnu/dist/binutils/ld/ldmain.c | 3 --- 3 files changed, 10 insertions(+), 4 deletions(-) diff --git a/gnu/dist/binutils/ld/ChangeLog b/gnu/dist/binutils/ld/ChangeLog index ad5176ed5cba..51ede36036fe 100644 --- a/gnu/dist/binutils/ld/ChangeLog +++ b/gnu/dist/binutils/ld/ChangeLog @@ -1,3 +1,8 @@ +2005-07-29 Nick Clifton + + * ldmain.c (main): Allow -shared and -static to be used together. + * ld.texinfo (-static): Mention that it is allowed with -shared. + 2005-06-12 Daniel Jacobowitz * ld.texinfo (Command Line Options): Add @item for --hash-size. diff --git a/gnu/dist/binutils/ld/ld.texinfo b/gnu/dist/binutils/ld/ld.texinfo index 29f637fe5e5a..635ba4209d0f 100644 --- a/gnu/dist/binutils/ld/ld.texinfo +++ b/gnu/dist/binutils/ld/ld.texinfo @@ -1049,7 +1049,11 @@ platforms for which shared libraries are supported. The different variants of this option are for compatibility with various systems. You may use this option multiple times on the command line: it affects library searching for @option{-l} options which follow it. This -option also implies @option{--unresolved-symbols=report-all}. +option also implies @option{--unresolved-symbols=report-all}. This +option can be used with @option{-shared}. Doing so means that a +shared library is being created but that all of the library's external +references must be resolved by pulling in entries from static +libraries. @kindex -Bsymbolic @item -Bsymbolic diff --git a/gnu/dist/binutils/ld/ldmain.c b/gnu/dist/binutils/ld/ldmain.c index 165ec0ed7068..f738afd854fd 100644 --- a/gnu/dist/binutils/ld/ldmain.c +++ b/gnu/dist/binutils/ld/ldmain.c @@ -343,9 +343,6 @@ main (int argc, char **argv) einfo (_("%P%F: -r and -shared may not be used together\n")); } - if (!config.dynamic_link && link_info.shared) - einfo (_("%P%F: -static and -shared may not be used together\n")); - if (! link_info.shared) { if (command_line.filter_shlib)