public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
From: Jakub Jelinek <jakub@redhat.com>
To: "H. J. Lu" <hjl@lucon.org>, Nick Clifton <nickc@redhat.com>
Cc: binutils@sources.redhat.com
Subject: [PATCH] Fix --dynamic-list
Date: Tue, 10 Oct 2006 15:50:00 -0000	[thread overview]
Message-ID: <20061010154936.GI4556@sunsite.mff.cuni.cz> (raw)
In-Reply-To: <45003A75.3080501@redhat.com>

On Thu, Sep 07, 2006 at 04:27:49PM +0100, Nick Clifton wrote:
> >2006-08-08  H.J. Lu  <hongjiu.lu@intel.com>
...
> >	* ldlang.c (lang_process): Call lang_finalize_version_expr_head
> >	on link_info.dynamic if needed.
> >	(lang_append_dynamic_list): New.
> >	(lang_append_dynamic_list_cpp_typeinfo): New.
> >	* ldlang.h (lang_append_dynamic_list): Likewise.
> >	* ldlang.h (lang_append_dynamic_list_cpp_typeinfo): Likewise.
...

I'm getting
FAIL: Run with libdl2b.so
failure on ppc64.

The problem is that unlike the other arches, ppc64 has for the dl2xxx.list
dynamic-list 2 entries in the list rather than just one (.xxx and xxx) and
lang_append_dynamic_list clearly assumes that the second and following
--dynamic-list's have just a single symbol name in it.

Fixed thusly, ok to commit?

BTW, I have noticed that you have changed info->symbolic to SYMBOLIC_BIND
in a bunch of generic places and i386,x86_64,ia64 ELF backends, but not at
all in the other backends.  Should that be changed in all the other
backends too?  I see the remaining ->symbolic in elflink.c is intentional,
but what about elf32-arm.c, elf32-bfin.c, elf32-cris.c, elf32-hppa.c,
elf32-i370.c, elf32-m32r.c, elf32-m68k.c, elf32-ppc.c, elf32-s390.c,
elf32-score.c, elf32-sh.c, elf32-vax.c, elf64-alpha.c, elf64-hppa.c,
elf64-s390.c, elf64-sh64.c, elf-m10300.c, elfxx-mips.c and elfxx-sparc.c?

2006-10-10  Jakub Jelinek  <jakub@redhat.com>

	* ldlang.c (lang_append_dynamic_list): When appending, add all elements
	of the dynamic list rather than just the first entry.

--- ld/ldlang.c.jj	2006-09-27 19:24:20.000000000 +0200
+++ ld/ldlang.c	2006-10-10 17:35:16.000000000 +0200
@@ -6960,7 +6960,10 @@ lang_append_dynamic_list (struct bfd_elf
 {
   if (link_info.dynamic)
     {
-      dynamic->next = link_info.dynamic->head.list;
+      struct bfd_elf_version_expr *tail;
+      for (tail = dynamic; tail->next != NULL; tail = tail->next)
+	;
+      tail->next = link_info.dynamic->head.list;
       link_info.dynamic->head.list = dynamic;
     }
   else


	Jakub

  parent reply	other threads:[~2006-10-10 15:50 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-07-24 22:27 RFC: Add dynamic list to version script H. J. Lu
2006-07-25 12:53 ` Ulrich Drepper
2006-07-25 13:49   ` H. J. Lu
2006-07-25 14:04     ` Ulrich Drepper
2006-07-25 14:36       ` H. J. Lu
2006-07-25 14:49         ` Ulrich Drepper
2006-07-26 16:42 ` Michael Matz
2006-07-27 17:11   ` H. J. Lu
2006-07-28 13:14     ` Michael Matz
2006-07-28 17:40       ` H. J. Lu
2006-07-28 17:59         ` Ulrich Drepper
2006-07-28 18:05           ` H. J. Lu
2006-08-08 17:22         ` H. J. Lu
2006-08-08 18:49           ` Michael Matz
2006-08-09 20:36             ` PATCH: Add --dynamic-list to ld H. J. Lu
2006-09-07 15:28               ` Nick Clifton
2006-09-07 19:41                 ` H. J. Lu
2006-09-08  8:17                   ` Nick Clifton
2006-10-10 15:50                 ` Jakub Jelinek [this message]
2006-10-11 15:39                   ` [PATCH] Fix --dynamic-list Nick Clifton
2006-10-16 22:45                     ` H. J. Lu
2006-10-18 18:19                       ` Nick Clifton
2006-08-09  2:02           ` RFC: Add dynamic list to version script Alan Modra
2006-08-09 16:05             ` Michael Matz
2006-08-09 16:19               ` Alan Modra
2006-08-09 17:40                 ` H. J. Lu
2006-08-09 16:25               ` H. J. Lu

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20061010154936.GI4556@sunsite.mff.cuni.cz \
    --to=jakub@redhat.com \
    --cc=binutils@sources.redhat.com \
    --cc=hjl@lucon.org \
    --cc=nickc@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).