public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
* PING: patch: Update of pep x86_64 support of ld
@ 2007-08-06  7:34 Kai Tietz
  2007-08-06 11:31 ` Christopher Faylor
  0 siblings, 1 reply; 4+ messages in thread
From: Kai Tietz @ 2007-08-06  7:34 UTC (permalink / raw)
  To: binutils; +Cc: Nick Clifton

[-- Attachment #1: Type: text/plain, Size: 1773 bytes --]

Hi,

I recognized some troubles in the pe+ support for x86_64 mingw target. It 
warns about '@xx' stuff passed by gcc, but this can be silently ignored by 
setting 'pep_enable_stdcall_fixup' to true for now. In near future when I 
fix spec definition of gcc, the related around 'pep_enable_stdcall_fixup' 
can be removed completly for this target (There are no '@xx' for this 
target at all). I updated for this target the autofilter_symbollist_i386 
list, too.
 
Further I detected that the test-case of ld-pe : direct fails, because the 
shared object detection wasn't merged from pe to pep.

Tested for x86_64-pc-mingw32 and cygwin without new regressions.

ChangeLog for ld

2007-07-24  Kai Tietz  <kai.tietz@onevision.com>

        * emultempl/pep.em: (pep_enable_stdcall_fixup): Set to value 1.
        gld_xxx_recognized_file: Use pep_bfd_is_dll for detection of 
shared
        objects.
        * pe-dll.c: (autofilter_symbollist_i386): Define set
        for amd64 mingw target.

Cheers,
 i.A. Kai Tietz



|  (\_/)  This is Bunny. Copy and paste Bunny
| (='.'=) into your signature to help him gain
| (")_(") world domination.

------------------------------------------------------------------------------------------
  OneVision Software Entwicklungs GmbH & Co. KG
  Dr.-Leo-Ritter-Straße 9 - 93049 Regensburg
  Tel: +49.(0)941.78004.0 - Fax: +49.(0)941.78004.489 - www.OneVision.com
  Commerzbank Regensburg - BLZ 750 400 62 - Konto 6011050
  Handelsregister: HRA 6744, Amtsgericht Regensburg
  Komplementärin: OneVision Software Entwicklungs Verwaltungs GmbH
  Dr.-Leo-Ritter-Straße 9 – 93049 Regensburg
  Handelsregister: HRB 8932, Amtsgericht Regensburg - Geschäftsführer: 
Ulrike Döhler, Manuela Kluger

[-- Attachment #2: pep_update.txt --]
[-- Type: text/plain, Size: 2524 bytes --]

? scripttempl/pep.sc_new
Index: pe-dll.c
===================================================================
RCS file: /cvs/src/src/ld/pe-dll.c,v
retrieving revision 1.99
diff -b -u -r1.99 pe-dll.c
--- pe-dll.c	6 Jul 2007 14:09:41 -0000	1.99
+++ pe-dll.c	2 Aug 2007 11:40:16 -0000
@@ -203,12 +203,21 @@
   { STRING_COMMA_LEN (".text") },
   /* Entry point symbols, and entry hooks.  */
   { STRING_COMMA_LEN ("cygwin_crt0") },
+#ifdef pe_use_x86_64
+  { STRING_COMMA_LEN ("DllMain") },
+  { STRING_COMMA_LEN ("DllEntryPoint") },
+  { STRING_COMMA_LEN ("DllMainCRTStartup") },
+  { STRING_COMMA_LEN ("_cygwin_dll_entry") },
+  { STRING_COMMA_LEN ("_cygwin_crt0_common") },
+  { STRING_COMMA_LEN ("_cygwin_noncygwin_dll_entry") },
+#else
   { STRING_COMMA_LEN ("DllMain@12") },
   { STRING_COMMA_LEN ("DllEntryPoint@0") },
   { STRING_COMMA_LEN ("DllMainCRTStartup@12") },
   { STRING_COMMA_LEN ("_cygwin_dll_entry@12") },
   { STRING_COMMA_LEN ("_cygwin_crt0_common@8") },
   { STRING_COMMA_LEN ("_cygwin_noncygwin_dll_entry@12") },
+#endif
   { STRING_COMMA_LEN ("cygwin_attach_dll") },
   { STRING_COMMA_LEN ("cygwin_premain0") },
   { STRING_COMMA_LEN ("cygwin_premain1") },
Index: emultempl/pep.em
===================================================================
RCS file: /cvs/src/src/ld/emultempl/pep.em,v
retrieving revision 1.4
diff -b -u -r1.4 pep.em
--- emultempl/pep.em	19 Jul 2007 19:56:10 -0000	1.4
+++ emultempl/pep.em	2 Aug 2007 11:40:16 -0000
@@ -106,7 +106,7 @@
 static lang_assignment_statement_type *image_base_statement = 0;
 
 #ifdef DLL_SUPPORT
-static int    pep_enable_stdcall_fixup = -1; /* 0=disable 1=enable.  */
+static int    pep_enable_stdcall_fixup = 1; /* 0=disable 1=enable (default).  */
 static char * pep_out_def_filename = NULL;
 static char * pep_implib_filename = NULL;
 static int    pep_enable_auto_image_base = 0;
@@ -1305,19 +1305,8 @@
 #ifdef TARGET_IS_i386pep
   pep_dll_id_target ("pei-x86-64");
 #endif
-  if (bfd_get_format (entry->the_bfd) == bfd_object)
-    {
-      char fbuf[LD_PATHMAX + 1];
-      const char *ext;
-
-      if (REALPATH (entry->filename, fbuf) == NULL)
-	strncpy (fbuf, entry->filename, sizeof (fbuf));
-
-      ext = fbuf + strlen (fbuf) - 4;
-
-      if (strcmp (ext, ".dll") == 0 || strcmp (ext, ".DLL") == 0)
-	return pep_implied_import_dll (fbuf);
-    }
+  if (pep_bfd_is_dll (entry->the_bfd))
+    return pep_implied_import_dll (entry->filename);
 #endif
   return FALSE;
 }
=

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: PING: patch: Update of pep x86_64 support of ld
  2007-08-06  7:34 PING: patch: Update of pep x86_64 support of ld Kai Tietz
@ 2007-08-06 11:31 ` Christopher Faylor
  2007-08-06 11:55   ` Kai Tietz
  0 siblings, 1 reply; 4+ messages in thread
From: Christopher Faylor @ 2007-08-06 11:31 UTC (permalink / raw)
  To: Nick Clifton, binutils, Kai Tietz

On Mon, Aug 06, 2007 at 09:33:34AM +0200, Kai Tietz wrote:
>Hi,
>
>I recognized some troubles in the pe+ support for x86_64 mingw target. It 
>warns about '@xx' stuff passed by gcc, but this can be silently ignored by 
>setting 'pep_enable_stdcall_fixup' to true for now. In near future when I 
>fix spec definition of gcc, the related around 'pep_enable_stdcall_fixup' 
>can be removed completly for this target (There are no '@xx' for this 
>target at all). I updated for this target the autofilter_symbollist_i386 
>list, too.
> 
>Further I detected that the test-case of ld-pe : direct fails, because the 
>shared object detection wasn't merged from pe to pep.
>
>Tested for x86_64-pc-mingw32 and cygwin without new regressions.
>
>ChangeLog for ld
>
>2007-07-24  Kai Tietz  <kai.tietz@onevision.com>
>
>        * emultempl/pep.em: (pep_enable_stdcall_fixup): Set to value 1.
>        gld_xxx_recognized_file: Use pep_bfd_is_dll for detection of 
>shared
>        objects.
>        * pe-dll.c: (autofilter_symbollist_i386): Define set
>        for amd64 mingw target.

Looks ok to me.  Go ahead and checkin.

cgf

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: PING: patch: Update of pep x86_64 support of ld
  2007-08-06 11:31 ` Christopher Faylor
@ 2007-08-06 11:55   ` Kai Tietz
  2007-08-06 14:33     ` Nick Clifton
  0 siblings, 1 reply; 4+ messages in thread
From: Kai Tietz @ 2007-08-06 11:55 UTC (permalink / raw)
  To: Nick Clifton; +Cc: binutils

Hi Christopher,

> On Mon, Aug 06, 2007 at 09:33:34AM +0200, Kai Tietz wrote:
> >Hi,
> >
> >I recognized some troubles in the pe+ support for x86_64 mingw target. 
It 
> >warns about '@xx' stuff passed by gcc, but this can be silently ignored 
by 
> >setting 'pep_enable_stdcall_fixup' to true for now. In near future when 
I 
> >fix spec definition of gcc, the related around 
'pep_enable_stdcall_fixup' 
> >can be removed completly for this target (There are no '@xx' for this 
> >target at all). I updated for this target the 
autofilter_symbollist_i386 
> >list, too.
> > 
> >Further I detected that the test-case of ld-pe : direct fails, because 
the 
> >shared object detection wasn't merged from pe to pep.
> >
> >Tested for x86_64-pc-mingw32 and cygwin without new regressions.
> >
> >ChangeLog for ld
> >
> >2007-07-24  Kai Tietz  <kai.tietz@onevision.com>
> >
> >        * emultempl/pep.em: (pep_enable_stdcall_fixup): Set to value 1.
> >        gld_xxx_recognized_file: Use pep_bfd_is_dll for detection of 
> >shared
> >        objects.
> >        * pe-dll.c: (autofilter_symbollist_i386): Define set
> >        for amd64 mingw target.
> 
> Looks ok to me.  Go ahead and checkin.

I would, if could ;) But may Nick or you could check it in.

Thanks and cheers,
 i.A. Kai Tietz

|  (\_/)  This is Bunny. Copy and paste Bunny
| (='.'=) into your signature to help him gain
| (")_(") world domination.

------------------------------------------------------------------------------------------
  OneVision Software Entwicklungs GmbH & Co. KG
  Dr.-Leo-Ritter-Straße 9 - 93049 Regensburg
  Tel: +49.(0)941.78004.0 - Fax: +49.(0)941.78004.489 - www.OneVision.com
  Commerzbank Regensburg - BLZ 750 400 62 - Konto 6011050
  Handelsregister: HRA 6744, Amtsgericht Regensburg
  Komplementärin: OneVision Software Entwicklungs Verwaltungs GmbH
  Dr.-Leo-Ritter-Straße 9 – 93049 Regensburg
  Handelsregister: HRB 8932, Amtsgericht Regensburg - Geschäftsführer: 
Ulrike Döhler, Manuela Kluger


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: PING: patch: Update of pep x86_64 support of ld
  2007-08-06 11:55   ` Kai Tietz
@ 2007-08-06 14:33     ` Nick Clifton
  0 siblings, 0 replies; 4+ messages in thread
From: Nick Clifton @ 2007-08-06 14:33 UTC (permalink / raw)
  To: Kai Tietz; +Cc: binutils

Hi Kai,

>> Looks ok to me.  Go ahead and checkin.
> 
> I would, if could ;) But may Nick or you could check it in.

Done :-)

Cheers
   Nick

PS.  If you would like write access please let me know.

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2007-08-06 14:33 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-08-06  7:34 PING: patch: Update of pep x86_64 support of ld Kai Tietz
2007-08-06 11:31 ` Christopher Faylor
2007-08-06 11:55   ` Kai Tietz
2007-08-06 14:33     ` Nick Clifton

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).