This is the mail archive of the binutils@sources.redhat.com mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: GNU ld question


On Fri, Jul 05, 2002 at 02:01:19PM +0200, Bruno De Bus wrote:
> Everyting used to fine, but recently I switched to binutils 2.12. The
> patterns that are defined in the linkerscript are not correct when the
> link-map is written out (print_wild_statement does not insert spaces at
> ldlang.c:2570 in current CVS).

Hmm, yes, they're printed like:
*(.bss.bss.*.gnu.linkonce.b.*)
rather than
*(.bss .bss.* .gnu.linkonce.b.*)

EXCLUDE_FILE was getting extra spaces too, that other similar tokens
like SORT didn't.

	* ldlang.c (print_wild_statement): Fix output formatting.

Committed.

Index: ld/ldlang.c
===================================================================
RCS file: /cvs/src/src/ld/ldlang.c,v
retrieving revision 1.92
diff -u -p -r1.92 ldlang.c
--- ld/ldlang.c	4 Jul 2002 14:41:01 -0000	1.92
+++ ld/ldlang.c	5 Jul 2002 12:52:50 -0000
@@ -2561,10 +2561,10 @@ print_wild_statement (w, os)
       if (sec->spec.exclude_name_list != NULL)
 	{
 	  name_list *tmp;
-	  minfo ("EXCLUDE_FILE ( %s", sec->spec.exclude_name_list->name);
+	  minfo ("EXCLUDE_FILE(%s", sec->spec.exclude_name_list->name);
 	  for (tmp = sec->spec.exclude_name_list->next; tmp; tmp = tmp->next)
-	    minfo (", %s", tmp->name);
-	  minfo (")");
+	    minfo (" %s", tmp->name);
+	  minfo (") ");
 	}
       if (sec->spec.name != NULL)
 	minfo ("%s", sec->spec.name);
@@ -2572,6 +2572,8 @@ print_wild_statement (w, os)
 	minfo ("*");
       if (sec->spec.sorted)
 	minfo (")");
+      if (sec->next)
+	minfo (" ");
     }
   minfo (")");
 

-- 
Alan Modra
IBM OzLabs - Linux Technology Centre


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]