* libbfd-in.h (struct artdata): Added tdata field.

(_bfd_add_bfd_to_archive_cache): Declare.
	(_bfd_snarf_ar_hdr): Renamed from snarf_ar_hdr.
	* libbfd.h: Rebuilt.
	* archive.c: Cleaned up some more.
	(_bfd_generic_mkarchive, bfd_generic_archive_p): Initialize
	pointer elements of artdata.
	(_bfd_add_bfd_to_archive_cache): Renamed from add_bfd_to_cache.
	(_bfd_snarf_ar_hdr): Renamed from snarf_ar_hdr.
	(get_extended_arelt_filename, get_elt_at_filepos,
	bfd_construct_extended_name_table, bfd_ar_hdr_from_filesystem,
	compute_and_write_armap): Made static.
	* ecoff.c: Some comment changes.
	(ecoff_slurp_armap): Handle rename of snarf_ar_hdr.  Set
	ardata->tdata to raw_armap.
	(ecoff_archive_p): Initialize pointer elements of artdata.
	* coff-rs6000.c (rs6000coff_get_elt_at_filepos): Handle rename of
	add_bfd_to_cache.
This commit is contained in:
Ian Lance Taylor
1994-01-03 18:05:19 +00:00
parent b35885f226
commit b59f0276fa
5 changed files with 154 additions and 102 deletions

View File

@ -1,5 +1,24 @@
Mon Jan 3 11:41:45 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com) Mon Jan 3 11:41:45 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
* libbfd-in.h (struct artdata): Added tdata field.
(_bfd_add_bfd_to_archive_cache): Declare.
(_bfd_snarf_ar_hdr): Renamed from snarf_ar_hdr.
* libbfd.h: Rebuilt.
* archive.c: Cleaned up some more.
(_bfd_generic_mkarchive, bfd_generic_archive_p): Initialize
pointer elements of artdata.
(_bfd_add_bfd_to_archive_cache): Renamed from add_bfd_to_cache.
(_bfd_snarf_ar_hdr): Renamed from snarf_ar_hdr.
(get_extended_arelt_filename, get_elt_at_filepos,
bfd_construct_extended_name_table, bfd_ar_hdr_from_filesystem,
compute_and_write_armap): Made static.
* ecoff.c: Some comment changes.
(ecoff_slurp_armap): Handle rename of snarf_ar_hdr. Set
ardata->tdata to raw_armap.
(ecoff_archive_p): Initialize pointer elements of artdata.
* coff-rs6000.c (rs6000coff_get_elt_at_filepos): Handle rename of
add_bfd_to_cache.
* hash.c: Added some documentation. * hash.c: Added some documentation.
Mon Jan 3 11:09:28 1994 Jim Kingdon (kingdon@lioth.cygnus.com) Mon Jan 3 11:09:28 1994 Jim Kingdon (kingdon@lioth.cygnus.com)

View File

@ -170,28 +170,40 @@ struct ar_cache {
#define arch_eltdata(bfd) ((struct areltdata *)((bfd)->arelt_data)) #define arch_eltdata(bfd) ((struct areltdata *)((bfd)->arelt_data))
#define arch_hdr(bfd) ((struct ar_hdr *)arch_eltdata(bfd)->arch_header) #define arch_hdr(bfd) ((struct ar_hdr *)arch_eltdata(bfd)->arch_header)
/* Forward declarations of functions */ static char *get_extended_arelt_filename PARAMS ((bfd *arch,
const char *name));
boolean static bfd *get_elt_at_filepos PARAMS ((bfd *archive, file_ptr filepos));
compute_and_write_armap PARAMS ((bfd *arch, unsigned int elength)); static boolean do_slurp_bsd_armap PARAMS ((bfd *abfd));
static boolean do_slurp_coff_armap PARAMS ((bfd *abfd));
static boolean static const char *normalize PARAMS ((const char *file));
bsd_update_armap_timestamp PARAMS ((bfd *arch)); static boolean bfd_construct_extended_name_table PARAMS ((bfd *abfd,
char **tabloc,
unsigned int *));
static struct areltdata *bfd_ar_hdr_from_filesystem PARAMS ((bfd *abfd,
const char *));
static boolean compute_and_write_armap PARAMS ((bfd *arch,
unsigned int elength));
static boolean bsd_update_armap_timestamp PARAMS ((bfd *arch));
boolean boolean
_bfd_generic_mkarchive (abfd) _bfd_generic_mkarchive (abfd)
bfd *abfd; bfd *abfd;
{ {
abfd->tdata.aout_ar_data = (struct artdata *)bfd_zalloc(abfd, abfd->tdata.aout_ar_data = ((struct artdata *)
sizeof (struct artdata)); bfd_zalloc (abfd, sizeof (struct artdata)));
if (bfd_ardata (abfd) == NULL) { if (bfd_ardata (abfd) == NULL)
{
bfd_error = no_memory; bfd_error = no_memory;
return false; return false;
} }
bfd_ardata(abfd)->cache = 0;
bfd_ardata (abfd)->cache = NULL;
bfd_ardata (abfd)->archive_head = NULL;
bfd_ardata (abfd)->symdefs = NULL;
bfd_ardata (abfd)->extended_names = NULL;
bfd_ardata (abfd)->tdata = NULL;
return true; return true;
} }
@ -217,10 +229,10 @@ DESCRIPTION
*/ */
symindex symindex
DEFUN(bfd_get_next_mapent,(abfd, prev, entry), bfd_get_next_mapent (abfd, prev, entry)
bfd *abfd AND bfd *abfd;
symindex prev AND symindex prev;
carsym **entry) carsym **entry;
{ {
if (!bfd_has_map (abfd)) { if (!bfd_has_map (abfd)) {
bfd_error = invalid_operation; bfd_error = invalid_operation;
@ -265,9 +277,9 @@ DESCRIPTION
*/ */
boolean boolean
DEFUN(bfd_set_archive_head,(output_archive, new_head), bfd_set_archive_head (output_archive, new_head)
bfd *output_archive AND bfd *output_archive;
bfd *new_head) bfd *new_head;
{ {
output_archive->archive_head = new_head; output_archive->archive_head = new_head;
@ -290,7 +302,7 @@ look_for_bfd_in_cache (arch_bfd, filepos)
/* Kind of stupid to call cons for each one, but we don't do too many */ /* Kind of stupid to call cons for each one, but we don't do too many */
boolean boolean
add_bfd_to_cache (arch_bfd, filepos, new_elt) _bfd_add_bfd_to_archive_cache (arch_bfd, filepos, new_elt)
bfd *arch_bfd, *new_elt; bfd *arch_bfd, *new_elt;
file_ptr filepos; file_ptr filepos;
{ {
@ -317,15 +329,14 @@ add_bfd_to_cache (arch_bfd, filepos, new_elt)
return true; return true;
} }
/* The name begins with space. Hence the rest of the name is an index into /* The name begins with space. Hence the rest of the name is an index into
the string table. */ the string table. */
char *
static char *
get_extended_arelt_filename (arch, name) get_extended_arelt_filename (arch, name)
bfd *arch; bfd *arch;
char *name; const char *name;
{ {
unsigned long index = 0; unsigned long index = 0;
@ -352,7 +363,7 @@ get_extended_arelt_filename (arch, name)
*/ */
struct areltdata * struct areltdata *
snarf_ar_hdr (abfd) _bfd_snarf_ar_hdr (abfd)
bfd *abfd; bfd *abfd;
{ {
#ifndef errno #ifndef errno
@ -475,7 +486,7 @@ snarf_ar_hdr (abfd)
element, since it handles the bookkeeping so nicely for us. element, since it handles the bookkeeping so nicely for us.
*/ */
bfd * static bfd *
get_elt_at_filepos (archive, filepos) get_elt_at_filepos (archive, filepos)
bfd *archive; bfd *archive;
file_ptr filepos; file_ptr filepos;
@ -493,7 +504,7 @@ get_elt_at_filepos (archive, filepos)
return NULL; return NULL;
} }
if ((new_areldata = snarf_ar_hdr (archive)) == NULL) if ((new_areldata = _bfd_snarf_ar_hdr (archive)) == NULL)
return NULL; return NULL;
n_nfd = _bfd_create_empty_archive_element_shell (archive); n_nfd = _bfd_create_empty_archive_element_shell (archive);
@ -507,7 +518,7 @@ get_elt_at_filepos (archive, filepos)
n_nfd->arelt_data = (PTR) new_areldata; n_nfd->arelt_data = (PTR) new_areldata;
n_nfd->filename = new_areldata->filename; n_nfd->filename = new_areldata->filename;
if (add_bfd_to_cache (archive, filepos, n_nfd)) if (_bfd_add_bfd_to_archive_cache (archive, filepos, n_nfd))
return n_nfd; return n_nfd;
/* huh? */ /* huh? */
@ -530,9 +541,9 @@ DESCRIPTION
*/ */
bfd * bfd *
DEFUN(bfd_get_elt_at_index,(abfd, index), bfd_get_elt_at_index (abfd, index)
bfd *abfd AND bfd *abfd;
int index) int index;
{ {
bfd *result = bfd *result =
get_elt_at_filepos get_elt_at_filepos
@ -603,50 +614,60 @@ bfd_generic_archive_p (abfd)
{ {
char armag[SARMAG+1]; char armag[SARMAG+1];
if (bfd_read ((PTR)armag, 1, SARMAG, abfd) != SARMAG) { if (bfd_read ((PTR) armag, 1, SARMAG, abfd) != SARMAG)
bfd_error = wrong_format; {
return 0; bfd_error = wrong_format;
} return NULL;
}
#ifdef GNU960 #ifdef GNU960
if (strncmp (armag, BFD_GNU960_ARMAG(abfd), SARMAG)) return 0; if (strncmp (armag, BFD_GNU960_ARMAG(abfd), SARMAG) != 0)
return 0;
#else #else
if (strncmp (armag, ARMAG, SARMAG) && if (strncmp (armag, ARMAG, SARMAG) != 0 &&
strncmp (armag, ARMAGB, SARMAG)) return 0; strncmp (armag, ARMAGB, SARMAG) != 0)
return 0;
#endif #endif
/* We are setting bfd_ardata(abfd) here, but since bfd_ardata /* We are setting bfd_ardata(abfd) here, but since bfd_ardata
involves a cast, we can't do it as the left operand of assignment. */ involves a cast, we can't do it as the left operand of assignment. */
abfd->tdata.aout_ar_data = (struct artdata *) bfd_zalloc(abfd,sizeof (struct artdata)); abfd->tdata.aout_ar_data = ((struct artdata *)
bfd_zalloc (abfd, sizeof (struct artdata)));
if (bfd_ardata (abfd) == NULL) { if (bfd_ardata (abfd) == NULL)
bfd_error = no_memory; {
return 0; bfd_error = no_memory;
} return NULL;
}
bfd_ardata (abfd)->first_file_filepos = SARMAG; bfd_ardata (abfd)->first_file_filepos = SARMAG;
bfd_ardata (abfd)->cache = NULL;
bfd_ardata (abfd)->archive_head = NULL;
bfd_ardata (abfd)->symdefs = NULL;
bfd_ardata (abfd)->extended_names = NULL;
bfd_ardata (abfd)->tdata = NULL;
if (!BFD_SEND (abfd, _bfd_slurp_armap, (abfd))) { if (! BFD_SEND (abfd, _bfd_slurp_armap, (abfd)))
bfd_release(abfd, bfd_ardata (abfd)); {
abfd->tdata.aout_ar_data = NULL; bfd_release(abfd, bfd_ardata (abfd));
return 0; abfd->tdata.aout_ar_data = NULL;
} return NULL;
}
if (!BFD_SEND (abfd, _bfd_slurp_extended_name_table, (abfd))) { if (! BFD_SEND (abfd, _bfd_slurp_extended_name_table, (abfd)))
bfd_release(abfd, bfd_ardata (abfd)); {
abfd->tdata.aout_ar_data = NULL; bfd_release(abfd, bfd_ardata (abfd));
return 0; abfd->tdata.aout_ar_data = NULL;
} return NULL;
}
return abfd->xvec; return abfd->xvec;
} }
/* Returns false on error, true otherwise */ /* Returns false on error, true otherwise */
static boolean static boolean
DEFUN (do_slurp_bsd_armap, (abfd), do_slurp_bsd_armap (abfd)
bfd *abfd) bfd *abfd;
{ {
struct areltdata *mapdata; struct areltdata *mapdata;
unsigned int counter = 0; unsigned int counter = 0;
@ -655,8 +676,9 @@ DEFUN (do_slurp_bsd_armap, (abfd),
char *stringbase; char *stringbase;
unsigned int parsed_size; unsigned int parsed_size;
mapdata = snarf_ar_hdr (abfd); mapdata = _bfd_snarf_ar_hdr (abfd);
if (mapdata == NULL) return false; if (mapdata == NULL)
return false;
parsed_size = mapdata->parsed_size; parsed_size = mapdata->parsed_size;
bfd_release (abfd, (PTR)mapdata); /* Don't need it any more. */ bfd_release (abfd, (PTR)mapdata); /* Don't need it any more. */
@ -708,8 +730,8 @@ DEFUN (do_slurp_bsd_armap, (abfd),
/* Returns false on error, true otherwise */ /* Returns false on error, true otherwise */
static boolean static boolean
DEFUN (do_slurp_coff_armap, (abfd), do_slurp_coff_armap (abfd)
bfd *abfd) bfd *abfd;
{ {
struct areltdata *mapdata; struct areltdata *mapdata;
int *raw_armap, *rawptr; int *raw_armap, *rawptr;
@ -724,8 +746,9 @@ DEFUN (do_slurp_coff_armap, (abfd),
char int_buf[sizeof(long)]; char int_buf[sizeof(long)];
unsigned int carsym_size, ptrsize, i; unsigned int carsym_size, ptrsize, i;
mapdata = snarf_ar_hdr (abfd); mapdata = _bfd_snarf_ar_hdr (abfd);
if (mapdata == NULL) return false; if (mapdata == NULL)
return false;
parsed_size = mapdata->parsed_size; parsed_size = mapdata->parsed_size;
bfd_release (abfd, (PTR)mapdata); /* Don't need it any more. */ bfd_release (abfd, (PTR)mapdata); /* Don't need it any more. */
@ -865,8 +888,9 @@ bfd_slurp_bsd_armap_f2 (abfd)
return true; return true;
} }
mapdata = snarf_ar_hdr (abfd); mapdata = _bfd_snarf_ar_hdr (abfd);
if (mapdata == NULL) return false; if (mapdata == NULL)
return false;
raw_armap = (int *) bfd_zalloc(abfd,mapdata->parsed_size); raw_armap = (int *) bfd_zalloc(abfd,mapdata->parsed_size);
if (raw_armap == NULL) if (raw_armap == NULL)
@ -952,8 +976,9 @@ _bfd_slurp_extended_name_table (abfd)
return true; return true;
} }
namedata = snarf_ar_hdr (abfd); namedata = _bfd_snarf_ar_hdr (abfd);
if (namedata == NULL) return false; if (namedata == NULL)
return false;
bfd_ardata (abfd)->extended_names = bfd_zalloc(abfd,namedata->parsed_size); bfd_ardata (abfd)->extended_names = bfd_zalloc(abfd,namedata->parsed_size);
if (bfd_ardata (abfd)->extended_names == NULL) { if (bfd_ardata (abfd)->extended_names == NULL) {
@ -999,9 +1024,9 @@ _bfd_slurp_extended_name_table (abfd)
/* Return a copy of the stuff in the filename between any :]> and a /* Return a copy of the stuff in the filename between any :]> and a
semicolon */ semicolon */
static CONST char * static const char *
DEFUN(normalize,(file), normalize (file)
CONST char *file) const char *file;
{ {
CONST char *first; CONST char *first;
CONST char *last; CONST char *last;
@ -1031,9 +1056,9 @@ DEFUN(normalize,(file),
} }
#else #else
static CONST char * static const char *
DEFUN (normalize, (file), normalize (file)
CONST char *file) const char *file;
{ {
CONST char * filename = strrchr(file, '/'); CONST char * filename = strrchr(file, '/');
@ -1053,11 +1078,11 @@ DEFUN (normalize, (file),
Returns true if it ran successfully, false if something went wrong. Returns true if it ran successfully, false if something went wrong.
A successful return may still involve a zero-length tablen! A successful return may still involve a zero-length tablen!
*/ */
boolean static boolean
DEFUN (bfd_construct_extended_name_table, (abfd, tabloc, tablen), bfd_construct_extended_name_table (abfd, tabloc, tablen)
bfd *abfd AND bfd *abfd;
char **tabloc AND char **tabloc;
unsigned int *tablen) unsigned int *tablen;
{ {
unsigned int maxname = abfd->xvec->ar_max_namelen; unsigned int maxname = abfd->xvec->ar_max_namelen;
unsigned int total_namelen = 0; unsigned int total_namelen = 0;
@ -1118,17 +1143,16 @@ DEFUN (bfd_construct_extended_name_table, (abfd, tabloc, tablen),
The filename field of the ar_hdr will NOT be initialized The filename field of the ar_hdr will NOT be initialized
*/ */
struct areltdata * static struct areltdata *
DEFUN(bfd_ar_hdr_from_filesystem, (abfd,filename), bfd_ar_hdr_from_filesystem (abfd,filename)
bfd* abfd AND bfd* abfd;
CONST char *filename) const char *filename;
{ {
struct stat status; struct stat status;
struct areltdata *ared; struct areltdata *ared;
struct ar_hdr *hdr; struct ar_hdr *hdr;
char *temp, *temp1; char *temp, *temp1;
if (stat (filename, &status) != 0) { if (stat (filename, &status) != 0) {
bfd_error = system_call_error; bfd_error = system_call_error;
return NULL; return NULL;
@ -1175,9 +1199,9 @@ DEFUN(bfd_ar_hdr_from_filesystem, (abfd,filename),
*/ */
struct ar_hdr * struct ar_hdr *
DEFUN(bfd_special_undocumented_glue, (abfd, filename), bfd_special_undocumented_glue (abfd, filename)
bfd *abfd AND bfd *abfd;
char *filename) char *filename;
{ {
struct areltdata *ar_elt = bfd_ar_hdr_from_filesystem (abfd, filename); struct areltdata *ar_elt = bfd_ar_hdr_from_filesystem (abfd, filename);
if (ar_elt == NULL) if (ar_elt == NULL)
@ -1269,7 +1293,8 @@ bfd_bsd_truncate_arname (abfd, pathname, arhdr)
length = maxlen; length = maxlen;
} }
if (length < maxlen) (hdr->ar_name)[length] = ar_padchar (abfd); if (length < maxlen)
(hdr->ar_name)[length] = ar_padchar (abfd);
} }
/* Store name into ar header. Truncates the name to fit. /* Store name into ar header. Truncates the name to fit.
@ -1309,7 +1334,8 @@ bfd_gnu_truncate_arname (abfd, pathname, arhdr)
length = maxlen; length = maxlen;
} }
if (length < 16) (hdr->ar_name)[length] = ar_padchar (abfd); if (length < 16)
(hdr->ar_name)[length] = ar_padchar (abfd);
} }
@ -1455,7 +1481,7 @@ _bfd_write_archive_contents (arch)
/* Note that the namidx for the first symbol is 0 */ /* Note that the namidx for the first symbol is 0 */
boolean static boolean
compute_and_write_armap (arch, elength) compute_and_write_armap (arch, elength)
bfd *arch; bfd *arch;
unsigned int elength; unsigned int elength;

View File

@ -1147,7 +1147,7 @@ ecoff_get_symtab_upper_bound (abfd)
return (bfd_get_symcount (abfd) + 1) * (sizeof (ecoff_symbol_type *)); return (bfd_get_symcount (abfd) + 1) * (sizeof (ecoff_symbol_type *));
} }
/* Get the canonicals symbols. */ /* Get the canonical symbols. */
unsigned int unsigned int
ecoff_get_symtab (abfd, alocation) ecoff_get_symtab (abfd, alocation)
@ -2811,10 +2811,10 @@ ecoff_write_object_contents (abfd)
} }
/* Archive handling. ECOFF uses what appears to be a unique type of /* Archive handling. ECOFF uses what appears to be a unique type of
archive header (which I call an armap). The byte ordering of the archive header (armap). The byte ordering of the armap and the
armap and the contents are encoded in the name of the armap itself. contents are encoded in the name of the armap itself. At least for
At least for now, we only support archives with the same byte now, we only support archives with the same byte ordering in the
ordering in the armap and the contents. armap and the contents.
The first four bytes in the armap are the number of symbol The first four bytes in the armap are the number of symbol
definitions. This is always a power of two. definitions. This is always a power of two.
@ -2830,10 +2830,6 @@ ecoff_write_object_contents (abfd)
The symbols are hashed into the armap with a closed hashing scheme. The symbols are hashed into the armap with a closed hashing scheme.
See the functions below for the details of the algorithm. See the functions below for the details of the algorithm.
We could use the hash table when looking up symbols in a library.
This would require a new BFD target entry point to replace the
bfd_get_next_mapent function used by the linker.
After the symbol definitions comes four bytes holding the size of After the symbol definitions comes four bytes holding the size of
the string table, followed by the string table itself. */ the string table, followed by the string table itself. */
@ -2942,7 +2938,7 @@ ecoff_slurp_armap (abfd)
/* Read in the armap. */ /* Read in the armap. */
ardata = bfd_ardata (abfd); ardata = bfd_ardata (abfd);
mapdata = snarf_ar_hdr (abfd); mapdata = _bfd_snarf_ar_hdr (abfd);
if (mapdata == (struct areltdata *) NULL) if (mapdata == (struct areltdata *) NULL)
return false; return false;
parsed_size = mapdata->parsed_size; parsed_size = mapdata->parsed_size;
@ -2962,6 +2958,8 @@ ecoff_slurp_armap (abfd)
return false; return false;
} }
ardata->tdata = (PTR) raw_armap;
count = bfd_h_get_32 (abfd, (PTR) raw_armap); count = bfd_h_get_32 (abfd, (PTR) raw_armap);
ardata->symdef_count = 0; ardata->symdef_count = 0;
@ -3232,6 +3230,11 @@ ecoff_archive_p (abfd)
} }
bfd_ardata (abfd)->first_file_filepos = SARMAG; bfd_ardata (abfd)->first_file_filepos = SARMAG;
bfd_ardata (abfd)->cache = NULL;
bfd_ardata (abfd)->archive_head = NULL;
bfd_ardata (abfd)->symdefs = NULL;
bfd_ardata (abfd)->extended_names = NULL;
bfd_ardata (abfd)->tdata = NULL;
if (ecoff_slurp_armap (abfd) == false if (ecoff_slurp_armap (abfd) == false
|| ecoff_slurp_extended_name_table (abfd) == false) || ecoff_slurp_extended_name_table (abfd) == false)

View File

@ -59,6 +59,7 @@ struct artdata {
archive. */ archive. */
file_ptr armap_datepos; /* Position within archive to seek to file_ptr armap_datepos; /* Position within archive to seek to
rewrite the date field. */ rewrite the date field. */
PTR tdata; /* Backend specific information. */
}; };
#define bfd_ardata(bfd) ((bfd)->tdata.aout_ar_data) #define bfd_ardata(bfd) ((bfd)->tdata.aout_ar_data)
@ -100,8 +101,9 @@ int bfd_stat PARAMS ((bfd *abfd, struct stat *));
bfd * _bfd_create_empty_archive_element_shell PARAMS ((bfd *obfd)); bfd * _bfd_create_empty_archive_element_shell PARAMS ((bfd *obfd));
bfd * look_for_bfd_in_cache PARAMS ((bfd *arch_bfd, file_ptr index)); bfd * look_for_bfd_in_cache PARAMS ((bfd *arch_bfd, file_ptr index));
boolean _bfd_add_bfd_to_archive_cache PARAMS ((bfd *, file_ptr, bfd *));
boolean _bfd_generic_mkarchive PARAMS ((bfd *abfd)); boolean _bfd_generic_mkarchive PARAMS ((bfd *abfd));
struct areltdata * snarf_ar_hdr PARAMS ((bfd *abfd)); struct areltdata * _bfd_snarf_ar_hdr PARAMS ((bfd *abfd));
bfd_target * bfd_generic_archive_p PARAMS ((bfd *abfd)); bfd_target * bfd_generic_archive_p PARAMS ((bfd *abfd));
boolean bfd_slurp_armap PARAMS ((bfd *abfd)); boolean bfd_slurp_armap PARAMS ((bfd *abfd));
boolean bfd_slurp_bsd_armap_f2 PARAMS ((bfd *abfd)); boolean bfd_slurp_bsd_armap_f2 PARAMS ((bfd *abfd));

View File

@ -59,6 +59,7 @@ struct artdata {
archive. */ archive. */
file_ptr armap_datepos; /* Position within archive to seek to file_ptr armap_datepos; /* Position within archive to seek to
rewrite the date field. */ rewrite the date field. */
PTR tdata; /* Backend specific information. */
}; };
#define bfd_ardata(bfd) ((bfd)->tdata.aout_ar_data) #define bfd_ardata(bfd) ((bfd)->tdata.aout_ar_data)
@ -100,8 +101,9 @@ int bfd_stat PARAMS ((bfd *abfd, struct stat *));
bfd * _bfd_create_empty_archive_element_shell PARAMS ((bfd *obfd)); bfd * _bfd_create_empty_archive_element_shell PARAMS ((bfd *obfd));
bfd * look_for_bfd_in_cache PARAMS ((bfd *arch_bfd, file_ptr index)); bfd * look_for_bfd_in_cache PARAMS ((bfd *arch_bfd, file_ptr index));
boolean _bfd_add_bfd_to_archive_cache PARAMS ((bfd *, file_ptr, bfd *));
boolean _bfd_generic_mkarchive PARAMS ((bfd *abfd)); boolean _bfd_generic_mkarchive PARAMS ((bfd *abfd));
struct areltdata * snarf_ar_hdr PARAMS ((bfd *abfd)); struct areltdata * _bfd_snarf_ar_hdr PARAMS ((bfd *abfd));
bfd_target * bfd_generic_archive_p PARAMS ((bfd *abfd)); bfd_target * bfd_generic_archive_p PARAMS ((bfd *abfd));
boolean bfd_slurp_armap PARAMS ((bfd *abfd)); boolean bfd_slurp_armap PARAMS ((bfd *abfd));
boolean bfd_slurp_bsd_armap_f2 PARAMS ((bfd *abfd)); boolean bfd_slurp_bsd_armap_f2 PARAMS ((bfd *abfd));