shouldn't ECOFF ar archives to SVR4 extended name table ?

Donald Buczek buczek@molgen.mpg.de
Fri Nov 15 04:47:00 GMT 2002


Hi,

on osf ( aka True64 aka Digital Unix) when compiling mozilla
with gcc I hit a compatibility problem between 'ar' from
binutils 2.13.1 and the linker from the operating system.

The problem is, that the object archives generated
by binutils 'ar', have long filenames mangled the
bsd-style "ARFILENAMES/"," index"), but OSFs ECOFF
uses the svr4-style ("//" and "/index").

binutils generated ar archives
mangle long filenames in the archive the SVR4-style
("ARFILENAMES/"," index"), but osfs ecoff uses the
bsd ('coff')-style ("//" and "/index").

The osf linker doesn't recognize the file 'ARFILENAMES/'
in the archive as special. When linking a shared library
from the object library with -all, the extended name
table file is wrongly regarded an object file.

The reference for ECOFF is here:

  http://www.google.de/search?hl=de&ie=ISO-8859-1&q=DigitalUnixV5-ObjectFileSpec.pdf&meta=

binutils were configured with the guessed target 'alphaev67-dec-osf4.0f'.

'ar --help' says
  [...]
  ../binutils/ar: supported targets: ecoff-littlealpha srec symbolsrec tekhex binary ihex osf-core

I tried the following patch

===================================================================
RCS file: bfd/libecoff.h,v
retrieving revision 1.1
diff -r1.1 bfd/libecoff.h
289c289
<   _bfd_archive_bsd_construct_extended_name_table
---
>   _bfd_archive_coff_construct_extended_name_table
===================================================================
RCS file: bfd/coff-alpha.c,v
retrieving revision 1.1
diff -r1.1 bfd/coff-alpha.c
2374c2374
<   ' ',                                /* ar_pad_char */
---
>   '/',                                /* ar_pad_char */
===================================================================

and it seems to fix the problem.


Who is wrong here ?

Ciao
  Donald

--
Donald Buczek
buczek@molgen.mpg.de
+49 30 8413 1433



More information about the Binutils mailing list