]> Git Repo - binutils.git/blame - bfd/ChangeLog
* config/obj-coff.c (coff_frob_symbol): Don't merge a symbol with
[binutils.git] / bfd / ChangeLog
CommitLineData
c9f5444e
JL
1Fri May 3 13:07:35 1996 Jeffrey A Law ([email protected])
2
3 * coff-h8300.c (reloc_howto_type): Add howto entry for
4 R_PCRWORD_B.
5 (rtype2howto): Handle R_PCRWORD_B.
6 (h8300_reloc16_extra_cases): Handle R_PCRWORD_B.
7 (h8300_reloc_16_estimate): Likewise. Try to turn a 16bit
8 pc-relative branch (R_PCRWORD) into an 8bit pc-relative
9 branch (R_PCWORD_B).
10
4ad842aa
ILT
11Fri May 3 10:47:41 1996 Ian Lance Taylor <[email protected]>
12
340d654f
ILT
13 * aoutx.h (translate_from_native_sym_flags): Set the section for
14 BSF_CONSTRUCTOR symbols.
15
4ad842aa
ILT
16 * cofflink.c (_bfd_coff_link_input_bfd): Correct setting of
17 last_bf_index.
18
9c7a5748
DE
19Wed May 1 18:39:32 1996 Doug Evans <[email protected]>
20
21 * coffcode.h (coff_write_object_contents): In comdat section lookup,
22 stop looking when section is found.
23
622c93a3
ILT
24Wed May 1 14:17:57 1996 Ian Lance Taylor <[email protected]>
25
e8f3bb64 26 * coffcode.h (STRING_SIZE_SIZE): Define.
9aac8e83
ILT
27 (styp_to_sec_flags): Handle long symbol names when looking for the
28 section symbol.
e8f3bb64
ILT
29 (bfd_coff_backend_data): Add _bfd_coff_long_section_names field.
30 (bfd_coff_long_section_names): Define.
31 (coff_write_object_contents): Handle long section names.
32 (bfd_coff_std_swap_table): Initialize new field.
33 * libcoff.h: Rebuild.
34 * coffgen.c (make_a_section_from_file): Handle long section
35 names.
36 (coff_write_symbols): Handle long section names.
37 * coff-alpha.c (alpha_ecoff_backend_data): Initialize new field.
38 * coff-mips.c (mips_ecoff_backend_data): Likewise.
39 * pe-arm.c (COFF_LONG_SECTION_NAMES): Define.
40 * pei-arm.c (COFF_LONG_SECTION_NAMES): Define.
41 * pe-i386.c (COFF_LONG_SECTION_NAMES): Define.
42 * pei-i386.c (COFF_LONG_SECTION_NAMES): Define.
43 * pe-ppc.c (COFF_LONG_SECTION_NAMES): Define.
44 * pei-ppc.c (COFF_LONG_SECTION_NAMES): Define.
45
622c93a3
ILT
46 * bout.c (b_out_callback): Set lma of sections.
47 (b_out_bfd_get_relocated_section_contents): Rename in_abfd
48 parameter to output_bfd. Used input_bfd instead of output_bfd in
49 several places.
50
6b725f83
ILT
51Tue Apr 30 17:56:39 1996 Ian Lance Taylor <[email protected]>
52
b7d1158a
ILT
53 * aoutx.h (translate_from_native_sym_flags): Don't create
54 SEC_CONSTRUCTOR sections.
55 * ecoff.c (ecoff_set_symbol_info): Likewise.
56
6b725f83
ILT
57 * elf32-mips.c (mips_elf_copy_private_bfd_data): Copy elf_gp.
58 From Don Bowman <[email protected]>.
59
e28a1e77
DE
60Tue Apr 30 17:06:32 1996 Doug Evans <[email protected]>
61
62 * coff-arm.c (armcoff_little_vec): If COFF_WITH_PE is defined, add
63 SEC_LINK_ONCE and SEC_LINK_DUPLICATES to section_flags.
64
abec70b9
ILT
65Mon Apr 29 13:15:17 1996 Ian Lance Taylor <[email protected]>
66
67 * elf32-mips.c (struct mips_elf_link_hash_entry): Add
68 mips_32_relocs field.
69 (mips_elf_link_hash_newfunc): Initialize mips_32_relocs field.
70 (mips_elf_relocate_section): Copy R_MIPS_REL32 and R_MIPS_32
71 relocs against a global symbol which is not defined in a regular
72 file.
73 (mips_elf_check_relocs): For a R_MIPS_REL32 or R_MIPS_32 reloc
74 against a global symbol, increment mips_32_relocs.
75 (mips_elf_adjust_dynamic_symbol): If mips_32_relocs is set, and
76 the symbol is not defined in a regular file, make room in the
77 .rel.dyn section.
78
ecba7a3a
ILT
79Fri Apr 26 18:00:37 1996 Ian Lance Taylor <[email protected]>
80
656c5b6d
ILT
81 * ecoff.c (ecoff_compute_section_file_positions): Track the real
82 file position and the virtual file position separately. Set
83 filepos information bsaed on the real file position.
84 (_bfd_ecoff_set_section_contents): Handle .lib sections like the
85 Jan 23 change to coffcode.h.
86
ecba7a3a
ILT
87 * som.c (som_slurp_symbol_table): Set the symbol count to the
88 number of BFD symbols created.
89
e25a7988
MM
90Fri Apr 26 12:34:29 1996 Michael Meissner <[email protected]>
91
92 * elf32-ppc.c (ppc_elf_check_relocs): Forward relocations to the
93 output file if linking shared objects. Loop to check all relocs,
94 rather than returning false on first error.
95
5c28a96e
MM
96Thu Apr 25 13:25:12 1996 Michael Meissner <[email protected]>
97
3f7ca26b
MM
98 * elf32-ppc.c (ppc_elf_create_linker_section): Add PLT case.
99 (ppc_elf_additional_program_headers): If .interp section, bump #
100 of program headers by 1.
101 (ppc_elf_adjust_dynamic_symbol): Flesh out support.
102 (ppc_elf_size_dynamic_sections): Add support for .plt section.
103 (ppc_elf_check_relocs): Print out filename in debug code. Enable
104 PLT support.
105 (ppc_elf_finish_dynamic_symbol): Add support for PLT's, beef up
106 debug output.
107 (ppc_elf_relocate_section): If the output section isn't defined,
108 don't abort, just give an error message.
109
5c28a96e
MM
110 * elflink.c (_bfd_elf_create_dynamic_sections): If the section
111 being created is .sdata or .sdata2, don't make the symbol dynamic.
112
f5d65485
ILT
113Wed Apr 24 14:04:07 1996 Ian Lance Taylor <[email protected]>
114
115 * xcofflink.c (_bfd_xcoff_bfd_link_add_symbols): Look through the
116 members of an archive for dynamic objects with no symbols, and
117 pass them directly to check_archive_element.
118 (xcoff_link_check_ar_symbols): Pass dynamic objects to
119 xcoff_link_check_dynamic_ar_symbols.
120 (xcoff_link_check_dynamic_ar_symbols): New static function.
121
122 * coff-rs6000.c (rs6000coff_vec): Change BFD_JUMP_TABLE_DYNAMIC
123 from _bfd_nodynamic to _bfd_xcoff.
124 * libcoff-in.h (_bfd_xcoff_get_dynamic_symtab_upper_bound):
125 Declare.
126 (_bfd_xcoff_canonicalize_dynamic_symtab): Declare.
127 (_bfd_xcoff_get_dynamic_reloc_upper_bound): Declare.
128 (_bfd_xcoff_canonicalize_dynamic_reloc): Declare.
129 * libcoff.h: Rebuild.
130 * xcofflink.c (xcoff_swap_ldrel_in): New static function.
131 (xcoff_get_section_contents): New static function.
132 (_bfd_xcoff_get_dynamic_symtab_upper_bound): New function.
133 (_bfd_xcoff_canonicalize_dynamic_symtab): New function.
134 (_bfd_xcoff_get_dynamic_reloc_upper_bound): New function.
135 (xcoff_dynamic_reloc): New static variable.
136 (_bfd_xcoff_canonicalize_dynamic_reloc): New function.
137 (xcoff_link_add_dynamic_symbols): Use xcoff_get_section_contents.
138
139Tue Apr 23 12:48:42 1996 Ian Lance Taylor <[email protected]>
140
141 * coff-sparc.c (bfd_coff_generic_reloc): Return bfd_reloc_ok even
142 if reloc_entry->addend is not 0.
143 (CALC_ADDEND): Just set the addend to reloc.r_offset.
144
34249b2f
DE
145Mon Apr 22 18:29:01 1996 Doug Evans <[email protected]>
146
147 * elf32-sparc.c (_bfd_sparc_elf_howto_table): Fix spelling of
148 R_SPARC_GLOB_JMP.
149 * elf64-sparc.c (sparc64_elf_howto_table): Likewise.
150 Add entries for R_SPARC_[56].
151 (sparc_reloc_map): Add entries for R_SPARC_[56].
152
af50cd91
ILT
153Mon Apr 22 15:07:24 1996 Ian Lance Taylor <[email protected]>
154
1726b8f0
ILT
155 Optimize linking of stabs in sections as used in ELF and COFF.
156 * stabs.c: New file.
157 * libbfd-in.h (_bfd_link_section_stabs): Declare.
158 (_bfd_write_section_stabs): Declare.
159 (_bfd_write_stab_strings): Declare.
160 * libbfd.h: Rebuild.
161 * libcoff-in.h (struct coff_section_tdata): Add stab_info field.
162 (struct coff_link_hash_table): Add stab_info field.
163 * libcoff.h: Rebuild.
164 * cofflink.c (_bfd_coff_link_hash_table_init): Initialize
165 stab_info field.
166 (coff_link_add_symbols): Call _bfd_link_section_stabs if
167 appropriate.
168 (_bfd_coff_final_link): Write out stab strings hash table.
169 (_bfd_coff_link_input_bfd): Handle optimized stabs sections.
170 * coff-ppc.c (ppc_bfd_coff_final_link): Write out stab strings
171 hash table.
172 * elf-bfd.h (struct elf_link_hash_table): Add stab_info field.
173 (struct bfd_elf_section_data): Add stab_info field.
174 * elf.c (_bfd_elf_link_hash_table_init): Initialize stab_info
175 field.
176 * elflink.h (elf_link_add_object_symbols): If appropriate, call
177 _bfd_link_section_stabs.
178 (elf_bfd_final_link): Write out stab strings hash table.
179 (elf_link_input_bfd): Handle optimized stabs sections.
180 * reloc.c (_bfd_final_link_relocate): Check address against
181 _raw_size rather than _cooked_size.
182 * Makefile.in: Rebuild dependencies.
183 (BFD_LIBS): Add stabs.o
184 (BFD_LIBS_CFILES): Add stabs.c.
185
186 * VERSION: Increment for bfdlink.h change.
187
af50cd91
ILT
188 * coffgen.c (coff_renumber_symbols): Correct handling of
189 BSF_NOT_AT_END common symbols.
190
f9fa5df3
ILT
191Fri Apr 19 19:21:56 1996 Ian Lance Taylor <[email protected]>
192
193 * coff-ppc.c (record_toc): Add cast to avoid warning.
194 (ppc_allocate_toc_section): Likewise.
195 (coff_ppc_relocate_section): Remove ANSI C string concatenation.
196 (ppc_coff_reloc_type_lookup): Remove unreached code.
197 * coffcode.h (coff_write_object_contents): Don't take the address
198 of an array.
199 * peicode.h (pe_print_idata): Add casts to avoid warning.
200 (pe_print_edata): Likewise.
201 (pe_print_reloc): Remove ANSI C string concatenation.
202
d6e0e2f7
ILT
203Thu Apr 18 18:51:18 1996 Ian Lance Taylor <[email protected]>
204
205 * libcoff-in.h (struct coff_final_link_info): Add last_bf_index
206 and last_bf fields.
207 * libcoff.h: Rebuild.
208 * coffswap.h (coff_swap_aux_in): Swap endndx field for C_FCN
209 symbols.
210 (coff_swap_aux_out): Likewise.
211 * peicode.h (coff_swap_aux_in): Likewise.
212 (coff_swap_aux_out): Likewise.
213 * coffgen.c (coff_pointerize_aux): Check endndx field for C_FCN
214 symbols.
215 * cofflink.c (_bfd_coff_final_link): Initialize last_bf_index
216 field.
217 (_bfd_coff_link_input_bfd): Check endndx field for C_FCN symbols.
218 Fix up .bf endndx link fields.
219 * coff-ppc.c (ppc_bfd_coff_final_link): Initialize last_bf_index
220 field.
221 * xcofflink.c (xcoff_link_input_bfd): Check endndx field for C_FCN
222 symbols.
223
221d1e19
MM
224Wed Apr 17 12:08:24 1996 Michael Meissner <[email protected]>
225
226 * pe{,i}-ppc.c (PPC_PE): Define instead of PPC, so that compiling
227 on Solaris PowerPC systems doesn't get confused.
228
229 * ccffcode.h (coff_write_object_contents): Use #ifdef PPC_PE, not
230 #ifdef PPC.
231
232 * elfcore.h (bfd_prstatus, bfd_fpregset): Add thread argument.
233 (elf_corefile_note): If HAVE_SYS_PROCFS_H is not defined, don't
234 update did_reg and did_reg2.
235
8f9a56c6
ILT
236Wed Apr 17 13:07:37 1996 Ian Lance Taylor <[email protected]>
237
f97fca78
ILT
238 * xcofflink.c (xcoff_link_input_bfd): Check for TOC overflow.
239
8f9a56c6
ILT
240 * linker.c (_bfd_generic_link_add_one_symbol): When calling the
241 callback routines, pass h->root.string rather than name, in case
242 copy is true and name is transient.
243
603fdf16
SG
244Tue Apr 16 16:36:38 1996 Stu Grossman ([email protected])
245
246 * elfcore.h: Add support for core files with multiple threads.
247 (Primarily for Solaris.)
248
a2d914e1
ILT
249Tue Apr 16 13:44:08 1996 Ian Lance Taylor <[email protected]>
250
cdf23557
ILT
251 * aoutx.h (NAME(aout,squirt_out_relocs)): Don't do anything if
252 section->orelocation is NULL.
253
a2d914e1
ILT
254 * coffgen.c (bfd_coff_get_syment): New function.
255 (bfd_coff_get_auxent): New function.
256 * bfd-in.h (bfd_coff_get_syment): Declare.
257 (bfd_coff_get_auxent): Declare.
258 * bfd-in2.h: Rebuild.
259
5cf36a32
ILT
260Mon Apr 15 19:06:59 1996 Ian Lance Taylor <[email protected]>
261
262 * elf32-mips.c (struct mips_hi16): Define.
263 (mips_hi16_addr, mips_hi16_addend): Remove.
264 (mips_hi16_list): New static variable.
265 (mips_elf_hi16_reloc): Maintain a list of unmatched HI16 relocs.
266 (mips_elf_lo16_reloc): Process mips_hi16_list.
267 (mips_elf_relocate_section): Permit an arbitrary number of HI16
268 relocs before the associated LO16 reloc.
269
b7fce5be
ILT
270Wed Apr 10 00:23:53 1996 Ian Lance Taylor <[email protected]>
271
176512da
ILT
272 * versados.c (versados_scan): Check bfd_alloc return value.
273 (versados_object_p): Check all bfd_read return values. Require
274 that lang field be less than 10, to avoid confusion with Intel Hex
275 files.
276
18de3f19
ILT
277 * libaout.h (WRITE_HEADERS): Write out the relocs even if there
278 aren't any symbols.
279 * aoutx.h (NAME(aout,swap_std_reloc_out)): Set r_index to N_ABS,
280 not 0, for an absolute symbol.
281 (NAME(aout,swap_ext_reloc_out)): Likewise.
282
66ab4152
ILT
283 * ihex.c (ihex_scan): Accept a length of 4 for record type 5.
284 (ihex_write_object_contents): For a large start address, output
285 the full 32 bit address in record type 5.
286
b7fce5be
ILT
287 * ieee.c (ieee_write_byte): Change second parameter from bfd_byte
288 to int to avoid promotion problems in prototype.
289
f1b45745
ILT
290Tue Apr 9 11:44:21 1996 Ian Lance Taylor <[email protected]>
291
f400f358
ILT
292 * configure.host: Use ${srcdir} when looking for picfrag.
293
3d9a5986
ILT
294 * configure.host: Switch on ${libdir}, not $(libdir). From
295 [email protected] (Alan Modra).
296
f1b45745
ILT
297 * aoutx.h (aout_link_add_symbols): Always call add_dynamic_symbols
298 entry point, not just for DYNAMIC objects.
299 * sunos.c (sunos_add_dynamic_symbols): Always call
300 sunos_create_dynamic_sections. If called with a non DYNAMIC
301 object, don't do anything else.
302 (sunos_add_one_symbol): Don't call sunos_create_dynamic_sections.
303
6f21f2e3
ILT
304Mon Apr 8 12:09:36 1996 Ian Lance Taylor <[email protected]>
305
639b5a09
ILT
306 * configure.in: Permit --enable-shared to specify a list of
307 directories.
308 * configure: Rebuild.
309
6f21f2e3
ILT
310 * configure.host: Set HLDFLAGS and SHLIB_CFLAGS for *-dec-osf*
311 host when configuring with --enable-shard.
312
3f5f565b
ILT
313Fri Apr 5 12:24:13 1996 Ian Lance Taylor <[email protected]>
314
1ac75f5c
ILT
315 * config.bfd: Add i[345]86-*-freebsdelf* target; from John Polstra
316 <[email protected]>.
317
1a9951a9
ILT
318 * linker.c (link_action): For WARN_ROW/warn, use MWARN, not CYCLE,
319 to avoid crashing in bfd_hash_replace.
320
f1ac3acb 321 * sysdep.h: Use #ifdef, not #if.
3f5f565b 322
eb5f58e0
ILT
323Thu Apr 4 23:32:23 1996 Ian Lance Taylor <[email protected]>
324
325 * config.in: Rebuild.
326
ab1aa5cd
FF
327Thu Apr 4 18:49:09 1996 Fred Fish <[email protected]>
328
329 * configure.in (mips-sony-bsd*): Fix typo in AC_DEFINE.
330 (AC_CHECK_HEADERS): Check for sys/time.h
331 (AC_HEADER_TIME): Add macro.
332 * configure: Rebuild.
333 * sysdep.h: Use TIME_WITH_SYS_TIME and HAVE_SYS_TIME_H
334 to control what combination of <time> and <sys/time.h>
335 get included.
336
d1f74cd2
DE
337Tue Apr 2 13:11:53 1996 Doug Evans <[email protected]>
338
339 * aoutf1.h (sunos_32_set_arch_mach): Handle M_SPARCLET.
340 (aout_32_sunos4_write_object_contents): Likewise.
341 * aoutx.h (NAME(aout,machine_type)): Handle
342 bfd_mach_sparc_{sparclet,sparclite}.
343 * archures.c (bfd_mach_sparc_{sparclet,sparclite}): Define.
344 (bfd_mach_sparc_v9_p): Update.
345 * cpu-sparc.c (arch_info_struct): Add entries for sparclet,sparclite.
346 * libaout.h (enum machine_type): Add M_SPARCLET.
347 * sunos.c (MACHTYPE_OK): Define.
348 * bfd-in2.h: Regenerated.
349
1dad72bd
ILT
350Tue Apr 2 00:33:18 1996 Ian Lance Taylor <[email protected]>
351
19bfbcbe
ILT
352 * elf-bfd.h (struct elf_link_hash_table): Add hgot field.
353 * elf.c (_bfd_elf_link_hash_table_init): Initialize hgot field.
354 * elflink.c (_bfd_elf_create_got_section): Store the
355 _GLOBAL_OFFSET_TABLE_ hash table entry in the hgot field.
356 * elf32-sparc.c (elf32_sparc_check_relocs): If the size of the
357 global offset table goes over 0x1000, set the value of
358 _GLOBAL_OFFSET_TABLE_ to 0x1000 into the section.
359 (elf32_sparc_relocate_section): Subtract the offset of
360 _GLOBAL_OFFSET_TABLE_ when handling GOT relocations.
361
1dad72bd
ILT
362 * elfcode.h: Don't include <string.h>.
363
ca4e2190
JL
364Mon Apr 1 10:39:24 1996 Jeffrey A Law ([email protected])
365
366 * linker.c (_bfd_generic_link_hash_newfunc): Renamed from
367 generic_link_hash_newfunc. All references changed.
368 * genlink.h (_bfd_generic_link_hash_newfunc): Declaration
369 moved here from libbfd-in.h.
370 * libbfd-in.h: Corresponding changes.
371 * libbfd.h: Regenerated.
372
ce6a7731
ILT
373Mon Apr 1 12:35:36 1996 Ian Lance Taylor <[email protected]>
374
aad53b0d
ILT
375 * aoutx.h (aout_link_input_section_std): When reporting an
376 overflow error, use the name of the symbol in the hash table if
377 available.
378 (aout_link_input_section_ext): Likewise.
379
ce6a7731
ILT
380 * elflink.h (elf_adjust_dynamic_symbol): If a common symbol got
381 defined in a regular file, set ELF_LINK_HASH_DEF_REGULAR.
382
323b430f
SC
383Sun Mar 31 01:58:41 1996 steve chamberlain <[email protected]>
384
385 * peicode.h (coff_swap_aouthdr_out): Delete test for .junk.
386 * coffcode.h (coff_compute_section_file_positions): Likewise.
387 (coff_write_object_contents): Likewise.
388
7fc1cd16
ILT
389Fri Mar 29 12:44:36 1996 Ian Lance Taylor <[email protected]>
390
5a28331f
ILT
391 * section.c (SEC_LINK_ONCE): Define.
392 (SEC_LINK_DUPLICATES): Define.
393 (SEC_LINK_DUPLICATES_DISCARD): Define.
394 (SEC_LINK_DUPLICATES_ONE_ONLY): Define.
395 (SEC_LINK_DUPLICATES_SAME_SIZE): Define.
396 (SEC_LINK_DUPLICATES_SAME_CONTENTS): Define.
397 * bfd-in2.h: Rebuild.
398 * coffcode.h (sec_to_styp_flags): If COFF_WITH_PE, turn
399 SEC_LINK_ONCE into IMAGE_SCN_LNK_COMDAT.
400 (styp_to_sec_flags): If COFF_WITH_PE, turn IMAGE_SCN_LNK_REMOVE
401 into SEC_EXCLUDE. If IMAGE_SCN_LNK_COMDAT is set, set
402 SEC_LINK_ONCE, and look through the symbol table for the setting
403 for SEC_LINK_DUPLICATES.
404 (coff_write_object_contents): If COFF_WITH_PE, if SEC_LINK_ONCE is
405 set for a section, find the section symbol in the symbol table,
406 and set the aux entry based on SEC_LINK_DUPLICATES.
407 * coffgen.c (coff_print_symbol): Add a space before "checksum".
408 * coff-arm.c (armcoff_big_vec): If COFF_WITH_PE is defined, add
409 SEC_LINK_ONCE and SEC_LINK_DUPLICATES to section_flags.
410 * coff-i386.c (i386coff_vec): Likewise.
411 * coff-ppc.c (TARGET_LITTLE_SYM, TARGET_BIG_SYM): Likewise.
412
7fc1cd16
ILT
413 * VERSION: Bump to 2.6.1.
414 * Makefile.in (stamp-h): Depend upon VERSION.
415
9399a257
JL
416Thu Mar 28 23:48:49 1996 Jeffrey A Law ([email protected])
417
418 * libbfd-in.h (generic_link_hash_newfunc): Add declaration.
419 * libbfd.h: Rebuilt.
420 * linker.c (generic_link_hash_newfunc): No longer static.
421 * coffcode.h (coff_bfd_link_hash_create): Allow specific targets
422 to override.
423 * coff-h8300.c: Add two derived hash tables and their associated
424 funtions and #defines for use by the h8300 linker.
425 (h8300_reloc16_extra_cases, case R_MEM_INDIRECT): Create entries in
426 the function vector as needed. Place the address of the function
427 vector entry in the location specified by the R_MEM_INDIRECT reloc.
428 Rewrite the vectors section contents as necessary.
429 (h8300_bfd_link_add_symbols): New function for the h8300 linker.
430 (coff_bfd_link_add_symbols): Define to use h8300 specific version.
431 (coff_bfd_link_hash_table_create): Likewise.
432
506f2bb4
ILT
433Thu Mar 28 17:44:08 1996 Ian Lance Taylor <[email protected]>
434
435 * libhppa.h: If gcc 2.7 or higher, declare all the functions with
436 __attribute__ ((__unused__)) so that -Wall doesn't warn about
437 them.
438 (hppa_rebuild_insn): Pass pointer to correct type to
439 low_sign_unext and dis_assemble_21.
440
05a84ae1
DE
441Thu Mar 28 11:00:36 1996 Doug Evans <[email protected]>
442
443 * config.bfd (sparc64-{sysv4*,solaris2*}): Delete.
444 Stick with sparc-*-{sysv4*,solaris2*}.
445
919cf4b5
ILT
446Wed Mar 27 10:43:34 1996 Ian Lance Taylor <[email protected]>
447
8230f31c
ILT
448 * peicode.h (coff_swap_aux_in): Swap in extra PE x_scn fields.
449 (coff_swap_aux_out): Swap out extra PE x_scn fields.
450 * coffswap.h (coff_swap_aux_in): Zero out extra PE x_scn fields.
451 * coffgen.c (coff_print_symbol): If any of the extra PE x_scn
452 fields is non-zero, print them.
453
9addd1d4
ILT
454 * coff-ppc.c (ppc_record_toc_entry): Put inside COFF_IMAGE_WITH_PE
455 ifdef. Remove unused variables.
456 (ppc_record_data_in_toc_entry): Ifdef out. Removed unused
457 variables.
458 (ppc_mark_symbol_as_glue): Put inside COFF_IMAGE_WITH_PE ifdef.
459 (get_symbol_value): Ifdef out.
460 (pe_ppc_reloc): Ifdef out. Remove unused variables.
461 (coff_ppc_relocate_section): Remove unused variables. Make
462 fprintf strings and argument types correspond. Put before_addr in
463 DEBUG_RELOC ifdef.
ff0e4a93
ILT
464 (dump_toc): Make fprintf strings and argument types correspond.
465 (ppc_process_before_allocation): Remove unused variables. Always
466 return a value.
9addd1d4
ILT
467 (ppc_reflo_reloc): Ifdef out.
468 (ppc_addr32nb_reloc): Ifdef out.
469 (ppc_coff_rtype2howto): Make fprintf strings and argument types
470 correspond.
471 (coff_ppc_rtype_to_howto): Likewise.
472 (ppc_coff_swap_sym_in_hook): Remove unused variables.
473
474 * peicode.h (pe_print_idata): Move otherwise unused variables into
475 the #ifdef where they are used. Always return a value.
ff0e4a93
ILT
476 (pe_print_edata): Make fprintf strings and argument types
477 correspond. Always return a value.
9addd1d4
ILT
478 (pe_print_pdata): Removed unused variable addr_value. Always
479 return a value.
480 (pe_print_reloc): Remove unused variable onaline. Make fprintf
ff0e4a93 481 strings and argument types correspond. Always return a value.
9addd1d4
ILT
482
483 * elf32-ppc.c (ppc_elf_fake_sections): Return true.
484 (ppc_elf_finish_dynamic_symbol): Move definition of unused
485 variable rela inside #if 0 section where it is used.
486
c877bdf1
ILT
487 * ns32k.h: New file.
488 * cpu-ns32k.h: Include ns32k.h. Rename externally visible
489 functions to start with _bfd_.
490 * aout-ns32k.c: Include ns32k.h. Change references to renamed
491 functions in cpu-ns32k.h.
492 * Makefile.in: Rebuild dependencies.
493 (HFILES): Add ns32k.h.
494
ff0e4a93
ILT
495 * section.c (struct sec): Add linker_mark field. Change
496 user_set_vma and reloc_done to be single bit fields.
497 (STD_SECTION): Update accordingly.
7ec49f91
ILT
498 * bfd-in2.h: Rebuild.
499 * aoutx.h (NAME(aout,final_link)): Mark sections included in the
500 link.
501 (aout_link_input_bfd): Don't link unmarked sections.
502 * cofflink.c (_bfd_coff_final_link): Mark sections included in the
503 link.
504 (_bfd_coff_link_input_bfd): Don't link unmarked sections.
505 * coff-ppc.c (ppc_bfd_coff_final_link): Mark sections included in
506 the link.
507 * elflink.h (elf_bfd_final_link): Mark sections included in the
508 link.
509 (elf_link_input_bfd): Don't link unmarked sections.
510 * xcofflink.c (_bfd_xcoff_bfd_final_link): Mark sections included
511 in the link.
512 (xcoff_link_input_bfd): Don't link unmarked sections.
513
919cf4b5
ILT
514 * coffswap.h (coff_swap_scnhdr_out): Include section name in
515 overflow error messages.
516
986cf3b8
ILT
517Tue Mar 26 15:46:18 1996 Ian Lance Taylor <[email protected]>
518
fd681dcd
ILT
519 * bfd.c (_bfd_default_error_handler): If _bfd_error_program_name
520 is not set, print "BFD: " before the error message.
521
986cf3b8
ILT
522 * configure.in: Use AC_CHECK_TOOL to find ar and ranlib. From
523 Miles Bader <[email protected]>.
524 * configure: Rebuild.
525
3998d526
ILT
526Fri Mar 22 12:17:00 1996 Ian Lance Taylor <[email protected]>
527
c3dffbd7
ILT
528 * xcofflink.c (xcoff_link_input_bfd): Fix scan for C_BINCL/C_EINCL
529 symbols.
530
3998d526
ILT
531 * config.bfd: Add ieee_vec to targ_selvecs for i960 targets and
532 m68k-aout, m68k-coff, and m68k-elf targets.
533
e4d27380
ILT
534Fri Mar 22 11:33:44 1996 Martin Anantharaman <[email protected]>
535
536 * ieee.c: Changed #ifdef KEEPMINUSPCININST to #if KEEPMINUSPCININST.
537 (ieee_generic_stat_arch_elt): Restructured to prevent
538 ieee_object_p from being called repeatedly.
539
51776a11
SC
540Thu Mar 21 11:00:47 1996 steve chamberlain <[email protected]>
541
542 * coffcode.h (coff_write_object_contents): Allocate
543 buffers large enough for any FILEHDR or AOUTHDR.
544
545Thu Mar 21 16:28:17 1996 David Mosberger-Tang <[email protected]>
546
547 * ecofflink.c (lookup_line): New static function, renamed and
548 slighly changed from old _bfd_ecoff_locate_line.
549 (_bfd_ecoff_locate_line): Cache line number information. Use
550 lookup_line for actual lookup.
551
9e4ebb1b
MM
552Thu Mar 21 14:59:11 1996 Michael Meissner <[email protected]>
553
554 * peicode.h (pe_print_pdata): Warn if the .pdata section is not a
555 multiple of 20 bytes.
556
9e7427a4
ILT
557Thu Mar 21 13:54:40 1996 Ian Lance Taylor <[email protected]>
558
51776a11
SC
559 * ecoff.c (_bfd_ecoff_find_nearest_line): Use bfd_zalloc to
560 allocate ecoff_find_line, and don't initialize by hand.
561 * elf32-mips.c (mips_elf_find_nearest_line): Use bfd_zalloc for
562 mips_elf_find_line, and don't call memset.
563
9e7427a4
ILT
564 * coffcode.h (coff_compute_section_file_positions): If not
565 producing a final executable, don't consider sofar when aligning
566 the section to the correct size.
567
568Wed Mar 20 16:53:12 1996 Ian Lance Taylor <[email protected]>
569
570 * coffcode.h (coff_add_missing_symbols): Ifdef out.
571 (coff_write_object_contents): Don't call coff_add_missing_symbols.
572 * coffgen.c (coff_section_symbol): Ifdef out.
573
e7f9ba4f
ILT
574Mon Mar 18 12:54:41 1996 Ian Lance Taylor <[email protected]>
575
576 * elf32-mips.c (mips_elf_gprel32_reloc): Initialize gp if
577 output_bfd is not NULL.
578
34c4d647
DE
579Thu Mar 14 17:12:06 1996 Doug Evans <[email protected]>
580
581 * coffgen.c (coff_get_normalized_symtab): Call bfd_zalloc instead
582 of bfd_alloc (fixes fix_line not being initialized).
583 Delete zeroing of fix_{value,tag,end,scnlen} fields.
584
4e054247
JL
585Thu Mar 14 16:06:06 1996 Jeffrey A Law ([email protected])
586
57289b5c
JL
587 * coffcode.h: Allow specific backends to override the
588 bfd_link_add_symbols routine.
589
4e054247
JL
590 * coff-h8300.c: Include genlink.h.
591 (howto_table): Add R_MEM_INDIRECT.
592 (rtype2howto): Support R_MEM_INDIRECT.
593 (h8300_reloc16_extra_cases): Handle R_MEM_INDIRECT like R_RELBYTE
594 for now.
595
a10d3dec
ILT
596Tue Mar 12 12:41:17 1996 David Mosberger-Tang <[email protected]>
597
598 * coff-alpha.c (alpha_relocate_section): Use
599 info->callbacks_warning, rather than _bfd_error_handler, for
600 "multiple gp" warning.
601
ea2488ad
ILT
602Tue Mar 12 12:10:55 1996 Ian Lance Taylor <[email protected]>
603
8881b321
ILT
604 * linker.c (bfd_wrapped_link_hash_lookup): New function.
605 (_bfd_generic_link_add_one_symbol): Remove BFD_ASSERT on hash
606 table string. Use bfd_wrapped_link_hash_lookup.
607 (_bfd_generic_link_write_global_symbol): Remove BFD_ASSERT on hash
608 table string.
609 * aoutx.h (aout_link_write_symbols): Use the name from the hash
610 table, if any, when writing out symbols.
611 (aout_link_input_section_std): Use the name from the hash table,
612 if any, when reporting undefined symbols.
613 (aout_link_input_section_ext): Likewise.
614 (aout_link_reloc_link_order): Use bfd_wrapped_link_hash_lookup.
615 * bout.c (get_value): Likewise.
616 * cofflink.c (_bfd_coff_reloc_link_order): Likewise.
617 * ecoff.c (ecoff_reloc_link_order): Likewise.
618 * elflink.h (elf_link_add_object_symbols): Likewise.
619 (elf_reloc_link_order): Likewise.
620 * linker.c (_bfd_generic_link_output_symbols): Likewise.
621 (_bfd_generic_reloc_link_order): Likewise.
622 (default_indirect_link_order): Likewise.
623 * reloc16.c (bfd_coff_reloc16_get_value): Likewise.
624 * sunos.c (sunos_add_one_symbol): Likewise.
625 * xcofflink.c (xcoff_link_add_symbols): Likewise.
626 (bfd_xcoff_link_count_reloc): Likewise.
627 (xcoff_reloc_link_order): Likewise.
628
629 * ecoffswap.h (ecoff_swap_fdr_in): If ECOFF_64, turn 0xffffffff
630 into -1 for intern->rss.
631
ea2488ad
ILT
632 * configure: Rebuild with autoconf 2.8.
633
c189fdfb
ILT
634Mon Mar 11 12:28:31 1996 Ian Lance Taylor <[email protected]>
635
636 * stab-syms.c (__define_stab_duplicate): Define.
637 (bfd_get_stab_name): Rename from aout_stab_name. Rewrite to use a
638 switch.
639 * bfd-in.h (bfd_get_stab_name): Declare.
640 * bfd-in2.h: Rebuild.
641 * Makefile.in: Rebuild dependencies.
642 (BFD_LIBS): Add stab-syms.o.
643 (BFD_LIBS_CFILES): Add stab-syms.c.
644 (BFD32_BACKENDS): Remove stab-syms.o.
645 (BFD32_BACKENDS_CFILES): Remove stab-syms.c.
646 * configure.in: Don't list stab-syms.o in bfd_backends.
647 * configure: Rebuild.
648 * libaout.h (aout_stab_name): Don't declare.
649 * aoutx.h (NAME(aout,get_symbol_info)): Call bfd_get_stab_name,
650 not aout_stab_name.
651
652Fri Mar 8 11:26:20 1996 Ian Lance Taylor <[email protected]>
653
654 * elf.c (assign_file_positions_for_segments): Adjust file offset
655 for section alignment even if SEC_LOAD is not set.
656
c5bde1ef
ILT
657Tue Mar 5 12:02:23 1996 Ian Lance Taylor <[email protected]>
658
8f218e05
ILT
659 * configure.in: Don't set SHLIB or SHLINK to an empty string,
660 since they appear as targets in Makefile.in.
661 * configure: Rebuild.
662
c5bde1ef
ILT
663 * sunos.c (sunos_scan_ext_relocs): If not making a shared library,
664 don't fiddle with a symbol which is not defined anywhere.
665
cb84f028
ILT
666Mon Mar 4 12:49:16 1996 Ian Lance Taylor <[email protected]>
667
4e59f523
ILT
668 * xcofflink.c (xcoff_mark): Treat undefined imported symbols as
669 though they are defined in a shared library.
670 (xcoff_build_ldsyms): Likewise.
671
ea2504d5
ILT
672 * coffgen.c (coff_find_nearest_line): Don't look at the line
673 numbers for the section if section->lineno is NULL.
674
cb84f028
ILT
675 * elf.c (_bfd_elf_symbol_from_bfd_symbol): Print a useful error
676 message rather than calling BFD_ASSERT.
677 * elfcode.h (write_relocs): Check return value of
678 _bfd_elf_symbol_from_bfd_symbol.
679
6e036cf7
MM
680Fri Mar 1 09:42:59 1996 Michael Meissner <[email protected]>
681
682 * elf32-ppc.c (ppc_elf_add_symbol_hook): Don't set SEC_LOAD flag
683 for .sbss section.
684
d08435de
JL
685Wed Feb 28 11:25:47 1996 Jeffrey A Law ([email protected])
686
687 * libhppa.h (hppa_reloc_field_selector_type): Add R_HPPA_NLSEL
688 and R_HPPA_NLRSEL.
689 (e_nsel, e_nlsel, e_nlrsel): Undefine. Add to
690 hppa_reloc_field_selector_type_alt.
691 (hppa_field_adjust): Handle e_nlsel, e_nlrsel. Fix e_nsel handling.
692 * som.c (hppa_som_gen_reloc_type): Handle N', NL' NLR' field
693 selectors.
694 (som_write_fixups): Finish handling of R_N0SEL and R_N1SEL.
695
09609415
ILT
696Wed Feb 28 11:00:24 1996 Ian Lance Taylor <[email protected]>
697
698 * elf.c (assign_file_positions_for_segments): Adjust the segment
699 memory size for the alignment of a SEC_ALLOC section, not just a
700 SEC_LOAD section.
701
55626bf0
ILT
702Tue Feb 27 14:17:31 1996 Andreas Schwab <[email protected]>
703
704 * m68klinux.c: New file.
705 * hosts/m68klinux.h: New file.
706 * config.bfd (m68*-*-linuxaout*, m68*-*-linux*): New targets.
707 * configure.in (m68*-*-linux*): New native host.
708 (m68klinux_vec): New vector.
709 * configure: Rebuild.
710 * targets.c (m68klinux_vec): Declare.
711 * i386linux.c (bfd_i386linux_size_dynamic_sections): Renamed from
712 bfd_linux_size_dynmic_sections to avoid clash with m68klinux.c.
713 * bfd-in.h (bfd_i386linux_size_dynamic_sections): Rename
714 declaration from bfd_linux_size_dynamic_sections.
715 (bfd_m68klinux_size_dynamic_sections): Declare.
716 * bfd-in2.h: Rebuild.
717 * Makefile.in: Rebuild dependencies.
718 (BFD32_BACKENDS): Add m68klinux.o.
719 (BFD32_BACKENDS_CFILES): Add m68klinux.c.
720
6c7b3090
JL
721Tue Feb 27 11:31:34 1996 Jeffrey A Law ([email protected])
722
723 * libhppa.h (pa_arch): Add pa20.
724 (hppa_reloc_field_selector_type): Add R_HPPA_NSEL.
725 (e_nsel): Undefine. Add to hppa_reloc_field_selector_type_alt.
726 (hppa_field_adjust): Handle e_nsel.
727 * som.c: Provide default definitions for many new relocs found only
728 in hpux10 include files.
729 (som_fixup_formats): Add several new relocs from hpux10.
730 (som_hppa_howto_table): Add hpux10 relocs.
731 (som_write_fixups): Handle R_N0SEL and R_N1SEL hpux10 relocs.
732
14fd4616
SS
733Mon Feb 26 12:52:48 1996 Stan Shebs <[email protected]>
734
735 * mpw-make.sed: Edit out recent shared library support, and
736 rules to rebuild .h files using doc/chew.
737
3d9f042c
ILT
738Mon Feb 26 14:48:39 1996 David Mosberger-Tang <[email protected]>
739
740 * ecoff.c (ecoff_compute_section_file_positions): Adjust the file
741 size even of sections with no contents.
742
bdec6228
ILT
743Mon Feb 26 14:01:13 1996 Ian Lance Taylor <[email protected]>
744
88358469
ILT
745 * cofflink.c (_bfd_coff_link_input_bfd): When merging, skip names
746 starting with '$' the way we skip names starting with '.'. When
747 updating x_endndx, don't be fooled by an index which has been
748 merged.
749
bdec6228
ILT
750 * cofflink.c (_bfd_coff_link_input_bfd): Don't try to optimize a
751 struct/union/enum type with no elements.
752
053ae1d7
ILT
753Sat Feb 24 11:38:58 1996 Ian Lance Taylor <[email protected]>
754
15f4406c
ILT
755 * bfd.c (bfd_errmsg): Handle a NULL return from strerror.
756
c8435133
ILT
757 * archive.c (bfd_generic_archive_p): If the first file in the
758 archive can not be recognized as an object, don't assume that this
759 is the wrong format.
760
053ae1d7
ILT
761 * elf.c (bfd_elf_set_dt_needed_name): Don't do anything if the
762 format is not bfd_object.
763 (bfd_elf_get_dt_soname): Likewise.
764
ea74d979
ILT
765Wed Feb 21 13:58:04 1996 Ian Lance Taylor <[email protected]>
766
767 * coff-sh.c (sh_relax_delete_bytes): Correct range of R_SH_USES
768 reloc.
769
871a3f3b
C
770Tue Feb 20 16:22:44 1996 J.T. Conklin <[email protected]>
771
772 * bfd.c (tdata): Add netbsd_core_data.
773 * bfd-in2.h: Regenerated.
774
775Tue Feb 20 16:50:02 1996 Ian Lance Taylor <[email protected]>
776
fe6fc35f
ILT
777 * sunos.c (SUNOS_CONSTRUCTOR): Define.
778 (sunos_add_one_symbol): Don't let a symbol from a dynamic object
779 override a constructor symbol. Set SUNOS_CONSTRUCTOR when
780 appropriate.
781
871a3f3b
C
782 * bout.c (b_out_squirt_out_relocs): Use udata.i rather than flags
783 to get the symbol index, matching 14 Jul 95 change.
784
d3785301
FF
785Tue Feb 20 08:26:27 1996 Fred Fish <[email protected]>
786
787 * coff-alpha.c (alpha_ecoff_get_relocated_section_contents):
788 Remove duplicate definition of gp.
789
60a49e7f
ILT
790Mon Feb 19 12:37:41 1996 Ian Lance Taylor <[email protected]>
791
81bdcecf
ILT
792 * coff-alpha.c (alpha_ecoff_get_relocated_section_contents): Don't
793 assume that we can set the GP value and then get the same value,
794 since it won't be true if the output file is neither ELF nor
795 ECOFF.
796 * coff-mips.c (mips_adjust_reloc_in): Don't bother to use
797 _bfd_get_gp_value here.
798 (mips_gprel_reloc): Don't assume we can set and get the GP value.
799 * elf32-mips.c (mips_elf_hi16_reloc): Get gp value from
800 mips_elf_final_gp.
801 (mips_elf_lo16_reloc): Likewise.
802 (mips_elf_final_gp): Add pgp parameter. Set it to the GP value.
803 Don't require that the BFD be ELF.
804 (mips_elf_gprel16_reloc): Get gp value from mips_elf_final_gp.
805 (mips_elf_gprel32_reloc): Likewise.
806 (mips_elf_relocate_section): Don't assume we can set and get the
807 GP value.
808 (mips_elf_finish_dynamic_symbol): Don't bother to use
809 _bfd_get_gp_value here.
810
811 * elf32-mips.c (mips_elf_create_procedure_table): Initialize sv.
812 Don't change epdr between malloc and free. Be careful not to free
813 NULL pointers. Zero out the first RPDR.
814
7b61165a
ILT
815 * configure.host: On Linux, only pass -rpath option if $(libdir)
816 is neither /lib nor /usr/lib. From Alan Modra
817 <[email protected]>.
818
60a49e7f
ILT
819 * elf-bfd.h (struct elf_obj_tdata): Rename dt_needed_name to
820 dt_name.
821 (elf_dt_name): Rename from elf_dt_needed_name.
822 * elf.c (bfd_elf_set_dt_needed_name): Use elf_dt_name, not
823 elf_dt_needed_name.
824 (bfd_elf_get_dt_soname): New function.
825 * elflink.h (elf_link_add_object_symbols): Use elf_dt_name, not
826 elf_dt_needed_name. Save the SONAME back in elf_dt_name.
827 * bfd-in.h (bfd_elf_get_dt_soname): Declare.
828 * bfd-in2.h: Rebuild.
829
b268e261
DE
830Mon Feb 19 02:50:23 1996 Doug Evans <[email protected]>
831
832 * elf32-sparc.c (elf32_sparc_reloc_type_lookup): Renamed from
833 _bfd_sparc_elf_reloc_type_lookup.
834 (bfd_elf32_bfd_reloc_type_lookup): Update.
835 * elf64-sparc.c (SPARC64_OLD_RELOCS): Define.
836 (sparc64_elf_howto_table): Define.
837 (sparc_reloc_map): Define.
838 (sparc64_elf_reloc_type_lookup): New function.
839 (sparc_elf_wdisp16_reloc): New function.
840 (elf_info_to_howto): Use sparc64_elf_howto_table.
841 (sparc64_elf_relocate_section): Likewise.
842 (bfd_elf64_bfd_reloc_type_lookup): Update.
843
9e2ef098
ILT
844Sun Feb 18 15:02:25 1996 Ian Lance Taylor <[email protected]>
845
846 * configure.host: Check for 'do not mix' from native linker before
847 trying to use -rpath.
848
4c70373f
ILT
849Fri Feb 16 12:46:18 1996 Ian Lance Taylor <[email protected]>
850
cba3f8a9
ILT
851 * bfd.c (_bfd_get_gp_value): New function.
852 (_bfd_set_gp_value): New function.
853 * libbfd-in.h (_bfd_get_gp_value): Declare.
854 (_bfd_set_gp_value): Declare.
855 * libbfd.h: Rebuild.
856 * coff-alpha.c (alpha_ecoff_get_relocated_section_contents): Use
857 _bfd_get_gp_value and _bfd_set_gp_value rather than referring
858 directly to the fields in the tdata information.
859 (alpha_relocate_section): Likewise.
860 * coff-mips.c (mips_adjust_reloc_in): Likewise.
861 (mips_gprel_reloc): Likewise.
862 (mips_relocate_section): Likewise.
863 * elf32-mips.c (mips_elf_hi16_reloc): Likewise.
864 (mips_elf_lo16_reloc): Likewise.
865 (mips_elf_final_gp): Likewise.
866 (mips_elf_gprel16_reloc): Likewise.
867 (mips_elf_gprel32_reloc): Likewise.
868 (mips_elf_relocate_section): Likewise.
869 (mips_elf_finish_dynamic_symbol): Likewise.
870
4c70373f
ILT
871 * bout.c (b_out_set_arch_mach): Recognize bfd_mach_i960_jx.
872
a0a2dd54
ILT
873Thu Feb 15 11:29:13 1996 Ian Lance Taylor <[email protected]>
874
f54c7482 875 * configure.in: Call AC_PROG_CC before configure.host.
65eed095
ILT
876 * configure: Rebuild.
877 * configure.host: Don't set information which autoconf should
878 figure out, namely CC, CFLAGS, LDFLAGS, AR, and RANLIB.
65eed095 879
14293419
ILT
880 * configure.host: Remove go32 and win32 host information, since it
881 should no longer be needed.
882
edf3fe48
ILT
883 * elf.c (map_sections_to_segments): If we have a .dynamic section,
884 then start a new segment rather than put a writable section in a
885 readonly segment.
886
b5e4f369
ILT
887 * configure.host: Set RPATH_ENVVAR.
888
f2e33e27
ILT
889 * Makefile.in: Rebuild dependencies.
890
a0a2dd54
ILT
891 * elflink.c (_bfd_elf_create_linker_section): Remove unused
892 zero_section variable.
893
52c6bc4d
ILT
894Thu Feb 15 10:39:17 1996 H.J. Lu <[email protected]>
895
896 * Makefile.in ($(srcdir)/bfd-in2.h): Rename target from bfd-in2.h.
897 ($(srcdir)/libbfd.h): Rename from libbfd.h.
898 ($(srcdir)/libcoff.h): Rename from libcoff.h.
899
c9e5279f
ILT
900Wed Feb 14 16:29:07 1996 Martin Anantharaman <[email protected]>
901
cb50baea
ILT
902 * ieee.c (ieee_write_expression): Only use an R variable for a
903 local symbol. Don't output a zero offset. Handle a zero address.
904 (SRC_MASK, PCREL_OFFSET): Define based on KEEPMINUSPCININST.
905 (rel32_howto, rel16_howto, rel8_howto): Use SRC_MASK and
906 PCREL_OFFSET.
907 (parse_expression): Don't try to handle multiple occurrences of a
908 P variable. Handle I variables differently from X variables. Fix
909 the order of minus expressions.
910 (ieee_slurp_external_symbols): Generate an I variable for an NN
911 record. Fix handling of ATI and ATX records.
912 (ieee_slurp_sections): Only set minimal section attributes.
913 Adjust them later, based on the section contents.
914 (ieee_object_p): Read in the file until just after the ME record.
915 Call ieee_slurp_section_data to set the section flags.
916 (do_one): Add iterations parameter. Only repeat the first load
917 item. Set the section and file reloc flags.
918 (ieee_slurp_section_data): Set section flags. Pass iterations to
919 do_one.
920 (ieee_canonicalize_reloc): Handle I variables.
921 (do_with_relocs): Only emit relocation size when necessary.
922 Increase MAXRUN to 127. Change ov to be assigned, and take
923 src_mask and pcrel_offset into account.
924 (ieee_write_data_part): Skip sections that are not loaded.
925 (ieee_write_external_part): Don't output optional last entry of WX
926 records.
927 (ieee_write_me_part): Make setting of me_record neater.
928 (ieee_generic_stat_arch_elt): Get the size of an archive element.
929
c9e5279f
ILT
930 * syms.c (stt): Add entries for zerovars, vars, and code.
931
932 * elfcode.h (validate_reloc): New static function.
933 (write_relocs): Call validate_reloc for non ELF relocs.
934
935 * elfxx-target.h (elf_symbol_leading_char): Define if not defined.
936 (TARGET_BIG_SYM): Use elf_symbol_leading_char.
937 (TARGET_LITTLE_SYM): Likewise.
938
939 * config.bfd (m68*-*-psos*): New target.
940
d9d65be6
ILT
941Tue Feb 13 15:56:22 1996 Bryan Ford <[email protected]>
942
943 * i386msdos.c: Remove some #if 0 code.
944 (msdos_write_object_contents): Don't include empty sections in the
945 size computation, regardless of their address.
946
947Tue Feb 13 15:36:37 1996 Michael Meissner <[email protected]>
948
949 * elf32-ppc.c (ppc_elf_relocate_section): Don't segfault if dynboj
950 is NULL, ie, the -r switch is used.
951
db5970c7
ILT
952Tue Feb 13 14:35:15 1996 Ian Lance Taylor <[email protected]>
953
e9f03cd4
ILT
954 * reloc.c (BFD_RELOC_MIPS_GOT_HI16): Define.
955 (BFD_RELOC_MIPS_GOT_LO16): Define.
b7384d22 956 (BFD_RELOC_MIPS_CALL_HI16, BFD_RELOC_MIPS_CALL_LO16): Define.
e9f03cd4
ILT
957 * bfd-in2.h, libbfd.h: Rebuild.
958 * elf32-mips.c (mips_reloc_map): Map new relocs.
959
fe7c066a
ILT
960 * configure.host: Set HDLFLAGS for *-*-hpux with --enable-shared.
961
1ab628e4
ILT
962 * Makefile.in ($(SHLINK)): Check ts against $(SHLIB), not
963 $(SHLINK).
964
db5970c7
ILT
965 * ieee.c (get_symbol): Set the section to bfd_abs_section.
966 (do_with_relocs): If EXEC_P is set and there are no relocs, use a
967 simple number for the section address, rather than an expression.
968 Limit the number of bytes between relocs to MAXRUN.
969 (ieee_write_me_part): Set me_record to the file offset after the
970 start address.
971 (ieee_write_processor): New static function.
972 (ieee_write_object_contents): Use ieee_write_processor.
973
318b7c18
ILT
974Fri Feb 9 10:53:00 1996 Ian Lance Taylor <[email protected]>
975
db5970c7
ILT
976 * configure.host: Use ${CC-gcc} when testing for -rpath on SunOS.
977
978 * coff-aux.c: Change include of aux.h to aux-coff.h.
318b7c18 979
56b64690
ILT
980Thu Feb 8 14:01:03 1996 Andreas Schwab <[email protected]>
981
982 * elf32-m68k.c (elf_m68k_relocate_section): For a R_68K_RELATIVE
983 relocation put the addend both in the reloc entry and the data.
984 (elf_m68k_finish_dynamic_symbol): Likewise. Mask out marker in
985 GOT offset value.
986
987 * elf32-m68k.c (elf_m68k_relocate_section): If -Bsymbolic, resolve
988 a R_68K_PCxx reloc against a defined global symbol directly.
989 (elf_m68k_check_relocs): Don't count such a reloc.
990
991 * elf32-m68k.c (elf_m68k_check_relocs): Don't record a symbol with
992 a PLTxx reloc as dynamic. Disallow PLTxxO reloc against a local
993 symbol for now, otherwise always record the symbol as dynamic.
994 (elf_m68k_adjust_dynamic_symbol): If a symbol with a PLTxx reloc
995 is not referenced by a dynamic object, and we are not making a
996 shared object, then don't make a PLT entry. If we do make a PLT
997 entry, make sure the symbol has been recorded as dynamic.
998
5d649ca8
ILT
999Wed Feb 7 13:56:06 1996 Ian Lance Taylor <[email protected]>
1000
1001 * configure.host: When making a shared library, set HLDFLAGS to
1002 pass an appropriate -rpath option. Use the make variable SONAME
1003 as the shared library soname, rather than computing it here. On
1004 SunOS, build stamp-tshlink in place of $(SHLINK).
1005 * Makefile.in (SONAME): New variable.
1006 ($(SHLINK)): Make a link to the transformed name, as well.
1007 (stamp-tshlink): New target.
1008 (install): Skip stamp-tshlink during install.
1009
8cc98cd5
MM
1010Wed Feb 7 13:37:39 1996 Michael Meissner <[email protected]>
1011
56b64690
ILT
1012 * elf32-ppc.c (ppc_elf_add_symbol_hook): Do not assume that the
1013 linker sections have been set up yet.
1014
8cc98cd5
MM
1015 * elf.c (make_mapping): Add an additional argument to suppress
1016 making the first section include the program headers.
1017 (map_sections_to_segments): If the user used -Ttext such that the
1018 program headers are on a different page, do not set the flags
1019 saying that this section includes the program headers.
1020
fe16107d
C
1021Tue Feb 6 14:04:49 1996 J.T. Conklin <[email protected]>
1022
1023 * configure.in (*-*-netbsd*): Set COREFILE to netbsd-core.c.
1024 don't define TRAD_HEADER.
1025 * configure: Rebuild.
1026
1027 * netbsd-core.c: New file, support for NetBSD core files.
1028 * hosts/*nbsd.h: Removed.
1029
f1783016
DE
1030Tue Feb 6 11:47:49 1996 Doug Evans <[email protected]>
1031
1032 * reloc.c (BFD_RELOC_SPARC_[567]): New reloc types.
1033 (BFD_RELOC_SPARC_LO7 reloc type): Deleted.
1034 * libbfd.h, bfd-in2.h: Regenerated.
1035 * elf32-sparc.c (_bfd_sparc_elf_reloc_type_lookup): Renamed from
1036 bfd_elf32_bfd_reloc_type_lookup.
1037 (reloc_type{,_names}): Deleted.
1038 (_bfd_sparc_elf_howto_table): Renamed from elf_sparc_howto_table.
1039 Add sparc64 relocs.
1040 (sparc_reloc_map): Add sparc64 relocs.
1041 (sparc_elf_notsupported_reloc): New static function.
1042 (sparc_elf_wdisp16_reloc): New static function.
1043 (elf32_sparc_check_relocs): Handle R_SPARC_WDISP{16,19}.
1044 (elf32_sparc_relocate_section): Likewise.
1045 (bfd_elf32_bfd_reloc_type_lookup): Define.
1046 * elf64-sparc.c (sparc64_elf_wdisp16_reloc): Deleted.
1047 (reloc_type{,_names}): Deleted.
1048 (elf_sparc_howto_table): Deleted.
1049 (sparc_reloc_map): Deleted.
1050 (_bfd_sparc_elf_howto_table): Renamed from elf_sparc_howto_table.
1051 (bfd_elf64_bfd_reloc_type_lookup): Change from function to #define.
1052
48fd00b6
ILT
1053Tue Feb 6 12:12:22 1996 Ian Lance Taylor <[email protected]>
1054
2300e217
ILT
1055 * configure.host: Make SHLIB_CFLAGS include $(PICFLAG) on a
1056 *-*-hpux* host.
1057
48fd00b6
ILT
1058 * Makefile.in (program_transform_name): New variable.
1059 (install): Transform library name before installing it.
1060
8adca582
ILT
1061Mon Feb 5 10:38:27 1996 Ian Lance Taylor <[email protected]>
1062
cbe75cb6
ILT
1063 * archures.c (bfd_mach_i960_hx): Define.
1064 * bfd-in2.h: Rebuild.
1065 * cpu-i960.c (scan_960_mach): Accept machine "hx".
1066 (MATRIX): Expand entries for HX.
1067 (arch_info_struct): Add i960:hx entry.
1068 * bout.c (b_out_set_arch_mach): Handle bfd_mach_i960_hx.
1069 * coffcode.h (coff_set_arch_mach_hook): Handle F_I960HX.
1070 (coff_set_flags): Handle bfd_mach_i960_hx.
1071
44f795f7
ILT
1072 Support for building as a shared library, based on patches from
1073 Alan Modra <[email protected]>:
1074 * configure.in: Add AC_ARG_ENABLE for shared and commonbfdlib.
1075 New substitutions: ALLLIBS, PICFLAG, SHLIB, SHLIB_CC,
1076 SHLIB_CFLAGS, COMMON_SHLIB, PICLIST, SHLINK.
1077 * configure: Rebuild.
1078 * configure.host: If --enable-shared, adjust shared library stuff
1079 based on the host. If the host is SunOS, and the linker supports
1080 -rpath, set HLDFLAGS to use it.
1081 * Makefile.in (ALLLIBS): New variable.
1082 (PICFLAG, SHLIB, SHLIB_CC, SHLIB_CFLAGS): New variables.
1083 (COMMON_SHLIB, SHLINK): New variables.
1084 (.c.o): If PICFLAG is set, compile twice, once PIC, once normal.
1085 (STAGESTUFF): Remove variable.
1086 (all): Depend upon $(ALLLIBS) and @PICLIST@ rather than
1087 $(TARGETLIB).
1088 (stamp-ofiles): New target, like old ofiles target, but build
1089 using a temporary file and move-if-change, and touch stamp-ofiles
1090 when done.
1091 (ofiles): Just depend upon stamp-ofiles.
1092 (stamp-piclist, piclist): New targets.
1093 ($(SHLIB), $(SHLINK)): New targets.
1094 (targets.o, archures.o): Build twice if PICFLAG is set.
1095 (do_mostlyclean): Remove pic/*.o.
1096 (do_clean): Remove stamp-ofiles, $(SHLIB), $(SHLINK), piclist, and
1097 stamp-piclist.
1098 (do_distclean): Remove pic and stamp-picdir.
1099 (install): Install shared libraries.
1100 ($(OFILES)): Depend upon stamp-picdir.
1101 (stamp-picdir): New target.
1102
cb62d2bc
ILT
1103 * libcoff-in.h: Add comment reminding people that libcoff.h is a
1104 generated file.
1105 * libcoff.h: Rebuild.
1106
8adca582
ILT
1107 * elflink.h (elf_adjust_dynamic_symbol): Don't try to get the
1108 flavour of a section with no owner.
1109
1110 * elf32-mips.c (mips_elf_create_dynamic_sections): Clear
1111 ELF_LINK_NON_ELF flag.
1112 (mips_elf_create_got_section): Likewise.
1113
1114 * elf.c: Revert last change, since it breaks dynamic linking.
1115 * elf-bfd.h (struct elf_backend_data): Remove want_hdr_in_seg
1116 field.
1117 * elf32-mips.c (elf_backend_want_hdr_in_seg): Don't define.
1118 * elfxx-target.h (elf_backend_want_hdr_in_seg): Don't define.
1119 (elfNN_bed): Don't initialize want_hdr_in_seg field.
1120
1121Sun Feb 4 20:45:13 1996 Michael Meissner <[email protected]>
1122
1123 * elf.c (assign_file_positions_for_segments): If the backend does
1124 not want the elf header or the program headers in the address
1125 space, do not include them in the calculations.
1126
1127 * elf32-ppc.c (ppc_elf_additional_program_headers): New hook
1128 function to determine if we need additional program headers.
1129 (ppc_elf_modify_segment_map): Define as a NOP function for now.
1130 (ppc_elf_create_linker_section): .sdata2 is a read-only section.
1131
0f09ddd4
ILT
1132Sat Feb 3 23:00:03 1996 Ian Lance Taylor <[email protected]>
1133
1134 * coffcode.h: Move today's libcoff.h change into coffcode.h.
1135
b48f10ba
FF
1136Sat Feb 3 15:43:44 1996 Fred Fish <[email protected]>
1137
0f09ddd4
ILT
1138 * libcoff.h (bfd_coff_link_add_one_symbol): Combine macro args
1139 back into one line. Some compilers (sunos 4.1.3 for example)
1140 won't accept args split across more than one line.
b48f10ba 1141
50761d3b
SC
1142Fri Feb 2 11:42:15 1996 Steve Chamberlain <[email protected]>
1143
1144 * aclocal.m4 (BFD_BINARY_FOPEN): Understand cygwin32.
1145 * configure: Regenerate.
1146
9dce8260
JL
1147Fri Feb 2 12:12:16 1996 Jeffrey A Law ([email protected])
1148
1149 * elf32-hppa.c (elf32_hppa_backend_symbol_table_processing): Don't
1150 try to do arithmetic on a void *, cast it to a unsigned char * first.
1151
6c55897c
ILT
1152Thu Feb 1 16:04:06 1996 Ian Lance Taylor <[email protected]>
1153
869b7d80
ILT
1154 * elf-bfd.h (ELF_LINK_NON_ELF): Define.
1155 * elf.c (_bfd_elf_link_hash_newfunc): Set elf_link_hash_flags to
1156 ELF_LINK_NON_ELF.
1157 * elflink.h (elf_link_add_object_symbols): Reset ELF_LINK_NON_ELF
1158 flag for a newly defined symbol.
1159 (NAME(bfd_elf,record_link_assignment)): Likewise.
1160 (elf_adjust_dynamic_symbol): If ELF_LINK_NON_ELF is set, try to
1161 set the DEF or REF_REGULAR flags correctly.
1162
6f6956c6
ILT
1163 * Makefile.in (bfd-in2.h): Make bfd.h, not protos, in docdir.
1164 (libbfd.h, libcoff.h): Corresponding change.
1165
6c55897c
ILT
1166 * elf32-i386.c (elf_i386_check_relocs): Don't record a symbol with
1167 a PLT32 reloc as dynamic.
1168 (elf_i386_adjust_dynamic_symbol): If a symbol with a PLT32 reloc
1169 is not referenced by a dynamic object, and we are not making a
1170 shared object, then don't make a PLT entry. If we do make a PLT
1171 entry, make sure the symbol has been recorded as dynamic.
1172
b06136f2
SC
1173Wed Jan 31 17:23:32 1996 Steve Chamberlain <[email protected]>
1174
1175 * coff-i386.c (coff_i386_reloc_type_lookup): Add BFD_RELOC_32_PCREL.
1176 * config.bfd (i[345]86-*-win32): Becomes i[345]86-*-cygwin32.
1177 (powerpcle-*-cygwin32): New.
1178 * peicode.h (add_data_entry): Get address from vma.
1179
5c867ecd
MM
1180Wed Jan 31 16:23:57 1996 Michael Meissner <[email protected]>
1181
1182 * elflink.c (_bfd_elf_create_linker_section): If the symbol
1183 attached to the section has already been created as an undefined
1184 symbol, treat it as if it hasn't been created yet.
1185
28c16b55
ILT
1186Wed Jan 31 16:16:53 1996 Ian Lance Taylor <[email protected]>
1187
1188 * elflink.h (elf_bfd_final_link): Don't output initial dummy
1189 symbol or section symbols if stripping all symbols and this is not
1190 a relocateable link. Don't output the symbol string table if
1191 there are no symbols.
1192 (elf_link_flush_output_syms): Don't do anything if there are no
1193 symbols to flush.
1194
d19df9b5
ILT
1195Wed Jan 31 12:55:49 1996 Richard Henderson <[email protected]>
1196
1197 * coff-aux.c: New file.
1198 * hosts/m68kaux.h: New file.
1199 * config.bfd (m68*-apple-aux*): New target.
1200 * configure.in (m68*-apple-aux*): New native host.
1201 (m68kaux_coff_vec): New vector.
1202 * configure: Rebuild.
1203 * targets.c (m68kaux_coff_vec): Declare.
1204 * coffcode.h (bfd_coff_backend_data): Add field
1205 _bfd_coff_link_add_one_symbol.
1206 (bfd_coff_link_add_one_symbol): Define.
1207 (compare_arelent_ptr): New static function if TARG_AUX.
1208 (coff_write_relocs): If TARG_AUX, sort the relocs.
1209 (coff_write_object_contents): Set A/UX aouthdr magic number.
1210 (coff_link_add_one_symbol): Define if not defined.
1211 (bfd_coff_std_swap_table): Initialize new field.
1212 * libcoff.h: Rebuild.
1213 * cofflink.c (coff_link_add_symbols): Call
1214 bfd_coff_link_add_one_symbol rather than
1215 _bfd_generic_link_add_one_symbol.
1216 * coff-m68k.c (COFF_PAGE_SIZE): Don't define if already defined.
1217 * coff-alpha.c (alpha_ecoff_backend_data): Initialize new field.
1218 * coff-mips.c (mips_ecoff_backend_data): Likewise.
1219 * Makefile.in: Rebuild dependencies.
1220 (BFD32_BACKENDS): Add coff-aux.o.
1221 (BFD32_BACKENDS_CFILES): Add coff-aux.c.
1222
a796aafd
ILT
1223Wed Jan 31 11:37:46 1996 Andreas Schwab <[email protected]>
1224
1225 * elf32-m68k.c (elf_m68k_relocate_section): Fix R_68K_GOT*
1226 relocation; ignore addend with R_68K_{GOT,PLT}*O relocation.
1227
a8763553
ILT
1228Tue Jan 30 12:09:04 1996 Ian Lance Taylor <[email protected]>
1229
66761e59
ILT
1230 * Makefile.in (do_maintainer_clean): Remove $(srcdir)/bfd-in2.h,
1231 $(srcdir)/libbfd.h and $(srcdir)/libcoff.h.
1232 (maintainer-clean): Warn about deleting special files.
1233 (bfd-in2.h, libbfd.h, libcoff.h): New targets.
1234
cf5138e3
ILT
1235 * elf32-hppa.c (elf32_hppa_relocate_section): Handle indirect and
1236 warning symbols correctly.
1237 * elf32-i386.c (elf_i386_relocate_section): Likewise.
1238 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
1239 * elf32-mips.c (mips_elf_relocate_section): Likewise.
1240 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
1241 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
1242 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
1243
a8763553
ILT
1244 * syms.c (_bfd_stab_section_find_nearest_line): Add casts to avoid
1245 warnings.
1246
bdd2e7f1
KK
1247Mon Jan 29 14:27:24 1996 Kim Knuttila <[email protected]>
1248
1249 * libcoff-in.h: aligned newly exported names with bfd naming
1250 conventions. Removed an erroneous define of POWERPC_LE_PE.
1251 * libcoff.h: Rebuild.
1252 * cofflink.c, coff-ppc.c: the above function name changes
1253
d2bb6c79
ILT
1254Mon Jan 29 13:06:28 1996 Ian Lance Taylor <[email protected]>
1255
eb5bc1f3
ILT
1256 From Basim Kadhim <[email protected]>:
1257 * ecoff.c (struct extsym_info): Define.
1258 (_bfd_ecoff_bfd_final_link): Pass a pointer to struct extsym_info
1259 to ecoff_link_write_external.
1260 (ecoff_link_write_external): Accept a struct extsym_info pointer.
1261 Strip symbols when appropriate.
1262
052b35d2
ILT
1263 Based on patches from Ronald F. Guilmette <[email protected]>:
1264 * syms.c (BSF_OBJECT): Define.
1265 (bfd_print_symbol_vandf): Print 'O' for BSF_OBJECT.
1266 * bfd-in2.h: Rebuild.
1267 * elfcode.h (elf_slurp_symbol_table): Set BSF_OBJECT for an
1268 STT_OBJECT symbol.
1269 * elf.c (swap_out_syms): Only set type to STT_OBJECT if BSF_OBJECT
1270 is set.
1271
53787b23
ILT
1272 * elf32-i386.c (elf_i386_relocate_section): If -Bsymbolic, when
1273 copying relocs into a shared object, treat a defined global symbol
1274 as a local symbol.
1275 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
1276 * elf32-mips.c (mips_elf_relocate_section): Likewise.
1277 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
1278
d2bb6c79
ILT
1279 * elflink.h (elf_link_add_object_symbols): Only set weakdef to a
1280 real defined symbol, not to a weak defined symbol.
1281
13d1a4dd
KK
1282Mon Jan 29 11:34:36 1996 Kim Knuttila <[email protected]>
1283
1284 * cofflink.c: removed the POWERPC_LE_PE hack, promoted some types
1285 and made a few static functions externs.
1286
1287 * coff-ppc.c (ppc_bfd_coff_final_link): new function, replaces the
1288 POWERPC_LE_PE hack in cofflink.
1289
1290 * libcoff-in.h: promoted the following from cofflink.c to allow
1291 _bfd_coff_final_link to be overridden - STRING_SIZE_SIZE,
1292 coff_debug_merge_element, struct coff_debug_merge_type,
1293 coff_debug_merge_hash_entry, coff_debug_merge_hash_table,
1294 coff_debug_merge_hash_table_init, coff_debug_merge_hash_table_free,
1295 coff_debug_merge_hash_lookup, coff_link_section_info,
1296 coff_final_link_info, coff_debug_merge_hash_newfunc,
1297 coff_write_global_sym, coff_link_input_bfd, coff_reloc_link_order.
1298
1299 * libcoff.h: re-gen'd
1300
86aac8ea
ILT
1301Fri Jan 26 18:33:35 1996 Ian Lance Taylor <[email protected]>
1302
1303 * syms.c: Include "bfdlink.h".
1304 (struct stab_find_info): Define.
1305 (_bfd_stab_section_find_nearest_line): New function.
1306 * libbfd-in.h (_bfd_stab_section_find_nearest_line): Declare.
1307 * libbfd.h: Rebuild.
1308 * elf-bfd.h (struct elf_obj_tdata): Add line_info field.
1309 * elf.c (_bfd_elf_find_nearest_line): Try calling
1310 _bfd_stab_section_find_nearest_line before searching the ELF
1311 symbol table. Find the closest STT_FUNC symbol, not the last one.
1312 * libcoff-in.h (coff_data_type): Add line_info field.
bdd2e7f1 1313 * libcoff.h: Rebuild.
86aac8ea
ILT
1314 * coffgen.c (coff_find_nearest_line): Try calling
1315 _bfd_stab_section_find_nearest_line before searching the COFF
1316 symbol table.
1317 * Makefile.in: Rebuild dependencies.
1318
1319Fri Jan 26 16:11:19 1996 Michael Meissner <[email protected]>
1320
1321 * elf32-ppc.c (R_PPC_EMB_SDA21 relocations): Make relocation size
1322 4 bytes, so we get the correct value when updating the register
1323 field in little endian mode.
1324
43d36aad
ILT
1325Thu Jan 25 12:14:16 1996 Ian Lance Taylor <[email protected]>
1326
f0a97077
ILT
1327 * libcoff-in.h (struct xcoff_tdata): Remove toc_section and
1328 entry_section fields. Add sntoc and snentry fields.
1329 * libcoff.h: Rebuild.
1330 * coffcode.h (coff_mkobject_hook): Initialize sntoc and snentry,
1331 not toc_section and entry_section (the COFF file does not have any
1332 sections at this point).
1333 (coff_write_object_contents): Set o_snentry and o_sntoc from
1334 snentry and sntoc rather than entry_section and toc_section.
1335 * coff-rs6000.c (xcoff_copy_private_bfd_data): Copy sntoc and
1336 snentry, not toc_section and entry_section.
1337 * xcofflink.c (bfd_xcoff_size_dynamic_sections): Don't set
1338 entry_section from hentry.
1339 (xcoff_link_input_bfd): If a defined symbol has XCOFF_ENTRY set,
ea2504d5 1340 set snenty.
f0a97077
ILT
1341 (xcoff_link_input_bfd): Set sntoc, not toc_section.
1342 (xcoff_write_global_symbol): Get toc_section from sntoc, rather
1343 than using toc_section directly.
1344
9b4598d0
ILT
1345 * archures.c: Add missing `.' in enum bfd_architecture.
1346 * bfd-in2.h: Rebuild.
1347
43d36aad
ILT
1348 * config.bfd (i[345]86-*-sco*elf*): Use bfd_elf32_i386_vec. From
1349 Robert Lipe <[email protected]>.
1350
eb82bc60
MM
1351Thu Jan 25 12:08:51 1996 Michael Meissner <[email protected]>
1352
1353 * elf32-ppc.c (ppc_elf_size_dynamic_sections): Add .rela.sdata{,2}
1354 to sections we allocate. Use bfd_zalloc to allocate initialial
1355 sections, not bfd_alloc.
1356 (ppc_elf_check_relocs): Remove BFD_ASSERTs for !shared from
1357 SDA{,2}I16 relocations.
1358 (ppc_elf_add_symbol_hook): Use the value of -G nn to determine
1359 whether to put something in .sbss or not.
1360 (ppc_elf_relocate_section): Add support for more relocations. Add
c1e65e24
MM
1361 in sec->output_offset where appropriate. Make error messages
1362 include the symbol name.
eb82bc60
MM
1363
1364 * elflink.c (_bfd_elf_create_linker_section): Lookup symbol before
1365 trying to add it to the symbol table, so _GLOBAL_OFFSET_TABLE_
1366 doesn't get redefined messages if -shared.
1367
1368 * elflink.h (elf_create_pointer_linker_section) Only bump RELA
1369 section if the rel_section field has been set up.
1370
9d621c7d
MM
1371Wed Jan 24 20:40:26 1996 Michael Meissner <[email protected]>
1372
1373 * elf32-ppc.c (ppc_elf_relocate_section): Fix typo in eabi
1374 relocations.
1375
75c9ddc9
DE
1376Wed Jan 24 10:38:34 1996 Doug Evans <[email protected]>
1377
1378 * elf32-sparc.c (elf32_sparc_merge_private_bfd_data): Delete checking
1379 of flags, only flags used are controlled by mach number. Bump up
1380 output file mach number to highest of input file mach numbers.
1381 (elf32_sparc_object_p): Watch for EF_SPARC_SUN_US1.
1382 (elf32_sparc_final_write_processing): Set EF_SPARC_SUN_US1 if v8plusa.
1383
72c513bc
DE
1384 * config.bfd (sparc64-*-{sysv4*,solaris2*}): Comment out
1385 bfd_elf64_sparc_vec support.
1386
3cbe19d2
MM
1387Tue Jan 23 14:33:05 1996 Michael Meissner <[email protected]>
1388
1389 * elf32-ppc.c (ppc_elf_copy_private_bfd_data): Don't complain if
1390 the embedded bit is set on some objects and not on others. Just
1391 or it together.
d8fd85ad
MM
1392 (ppc_elf_relocate_section): Implement R_PPC_EMB_{SDA21,RELSDA}
1393 relocations.
3cbe19d2 1394
5eb83ede
ILT
1395Tue Jan 23 14:22:45 1996 Ian Lance Taylor <[email protected]>
1396
4a3d3b42
ILT
1397 * coffcode.h (coff_new_section_hook): Don't try to align the
1398 .stabstr section.
1399
5eb83ede
ILT
1400 * coffcode.h (coff_set_section_contents): Fix the handling of the
1401 .lib section to work even if the entire section contents are
1402 written at once. From Gvran Uddeborg <[email protected]> and
1403 Robert Lipe <[email protected]>.
1404
05f927dd
MM
1405Mon Jan 22 18:45:51 1996 Michael Meissner <[email protected]>
1406
1407 * elflink.h (elf_finish_pointer_linker_section): Don't allocate
1408 memory here for contents.
1409
1410 * elf32-ppc.c (ppc_elf_relocate_section): Bump up _SDA_BASE_ and
1411 _SDA2_BASE_ by 32768.
1412 (ppc_elf_size_dynamic_sections): #if out PLT code which we haven't
1413 started using. Allocate contents for .sdata and .sdata2 sections
1414 also.
1415 (ppc_elf_check_relocs): Use bfd_get_section_name in debug message,
1416 rather than _name.
1417 (ppc_elf_finish_dynamic_symbol): Remove code that attempted to
1418 size _SDA{,2}_BASE_.
1419 (ppc_elf_relocate_section): Change how sdata{,2} relocations are
1420 done.
1421
5bc513b4
DE
1422Mon Jan 22 08:52:04 1996 Doug Evans <[email protected]>
1423
5a5bac64
DE
1424 * elflink.h (elf_finish_pointer_linker_section): Fix typo.
1425
5bc513b4 1426 * archures.c (bfd_mach_sparc_v9): Renamed from bfd_mach_sparc64.
5bc513b4 1427 (bfd_mach_sparc_{v8plus,v8plusa}): Define.
5bc513b4 1428 (bfd_mach_sparc_v9a): Define.
049f3d4c 1429 (bfd_mach_sparc_v9_p): Define.
5bc513b4
DE
1430 * bfd-in2.h: Regenerated.
1431 * aoutx.h (aout,machine_type): bfd_mach_sparc64 renamed to
1432 bfd_mach_sparc_v9.
d3366d23 1433 * elf64-sparc.c (sparc64_elf_object_p): Likewise.
5bc513b4
DE
1434 * config.bfd (sparc64-*-sysv4*,sparc64-*-solaris2*): Set targ_defvec
1435 to bfd_elf32_sparc_vec.
1436 * cpu-sparc.c (arch_info_struct): Renamed from sparc_arch_info.
5bc513b4 1437 Add v8plus{,a} support.
5bc513b4 1438 Add v9a support.
768b8ade 1439 (sparc_compatible): New function.
5bc513b4 1440 * elf32-sparc.h: #include "elf/sparc.h".
75c9ddc9 1441 (elf32_sparc_merge_private_bfd_data, elf32_sparc_object_p,
5bc513b4 1442 elf32_sparc_final_write_processing): New functions.
75c9ddc9 1443 (bfd_elf32_bfd_merge_private_bfd_data, elf_backend_object_p,
5bc513b4 1444 elf_backend_final_write_processing): Define.
5bc513b4 1445
3b3753b8
MM
1446Mon Jan 22 11:21:51 1996 Michael Meissner <[email protected]>
1447
1448 * elf-bfd.h (struct elf_link_hash_entry): Add
1449 linker_section_pointer field.
1450 (enum elf_linker_section_enum): Enumeration for new way of
1451 creating linker dynamic sections and symbols.
1452 (elf_linker_section{,_pointers}): New structures for creating
1453 dynamic sections and symbols.
1454 (elf_obj_tdata): Add linker_section_pointers and linker_section
1455 fields.
1456 (elf_local_ptr_offsets,elf_linker_section): New accessor macros.
1457 (_bfd_elf_create_linker_section): New declarations.
1458 (_bfd_elf_find_pointer_linker_section): Ditto.
1459 (bfd_elf{32,64}_{create,finish}_pointer_linker_section): Ditto.
1460 (_bfd_elf_make_linker_section_rela): Ditto.
1461
1462 * elf.c (_bfd_elf_link_hash_newfunc): Initialize new fields.
1463
1464 * elf32-ppc.c (ppc_elf_create_dynamic_sections): Delete.
1465 (ppc_elf_create_linker_section): New function to create the
1466 sections .got, .sdata, and .sdata2.
1467 (ppc_elf_size_dynamic_sections): Zap .rela.{sdata,sdata2} if
1468 needed.
1469 (ppc_elf_check_relocs): Support more of the eabi relocations.
1470 (ppc_elf_relocate_section): Ditto.
1471 (ppc_elf_finish_dynamic_symbols): Adjust _SDA{,2}_BASE_ by 32768
1472 if the .sdata{,2} + .sbss{,2} section size is > 32k.
1473
1474 * elflink.h (elf_create_pointer_linker_section): New function to
1475 create initialized pointers in dynamic linker sections.
1476 (elf_finish_pointer_linker_section): Actually intialize the
1477 pointers created above.
1478
1479 * elfcode.h (bfd_elf{32,64}_create_pointer_linker_section): New
1480 macros to provide both 32 and 64 bit versions of
1481 elf_create_pointer_linker_section.
1482 (bfd_elf{32,64}_finish_pointer_linker_section): New macros to
1483 provide both 32 and 64 bit versions of
1484 elf_finish_pointer_linker_section.
1485
1486 * elflink.c (_bfd_elf_create_linker_section): New function to
1487 create a linker section.
1488 (_bfd_elf_find_pointer_linker_section): Find a unique pointer to a
1489 given address in the linker pointer offsets created for a given
1490 symbol.
1491 (_bfd_elf_make_linker_section_rela): Make a RELA section
1492 corresponding to the generated linker section.
1493
6b3eb07e
DE
1494Sat Jan 20 08:36:10 1996 Doug Evans <[email protected]>
1495
1496 * elf32-sparc.c (ELF_MACHINE_ALT1): Define.
1497
e7894f6b
KK
1498Thu Jan 18 18:25:34 1996 Kim Knuttila <[email protected]>
1499
1500 * coff-ppc.c (coff_ppc_relocate_section): changed TOCDEFN relocs.
1501 (coff_ppc_relocate_section): Handle special values for gcc built dlls.
1502 (dump_toc): fix diagnosing code to identify out-of-toc-bounds entries.
1503 Also begin the toc at 4 as an eye catcher ('31313131' marks the first
1504 toc entry in an objdump) for now.
1505 (ppc_do_last, ppc_get_last): New function - needed to save processing
1506 the toc owner to the end.
1507 (ppc_coff_swap_sym_in_hook): Removed an incorrect hack for doing the
1508 toc owner last.
1509
1510 * cofflink.c (_bfd_coff_final_link): Added a new hack to keep the
1511 toc owner from being done till last. Must define POWERPC_LE_PC
1512 to enable it.
1513
1514 * coffcode.h (coff_set_alignment_hook): alignment setting for .stab
1515
1516 * peicode.h (coff_swap_scnhdr_out): set section flags for stab/str
1517 to INFO.
1518 (coff_swap_aouthdr_out): Removed a non-working hack for computing the
1519 SizeOfImage for PowerPC. Ignore the size of the .junk section.
1520
80b99ca0
ILT
1521Thu Jan 18 17:42:12 1996 Ian Lance Taylor <[email protected]>
1522
1523 * elfcore.h: Include <signal.h> before <sys/procfs.h>.
1524
df96df4c
ILT
1525Wed Jan 17 12:40:14 1996 Ian Lance Taylor <[email protected]>
1526
1527 * cpu-powerpc.c (arch_info_struct): Change last entry to not point
1528 back to first.
1529 (bfd_powerpc_arch): Point at first entry in arch_info_struct.
1530
d49ddb85
ILT
1531Tue Jan 16 15:10:49 1996 Ian Lance Taylor <[email protected]>
1532
1533 * elf.c (assign_file_positions_for_segments): Don't increment file
1534 offset for a segment which contains no loadable sections.
1535
4500a112
MM
1536Mon Jan 15 17:46:27 1996 Michael Meissner <[email protected]>
1537
1538 * reloc.c: Add new PowerPC relocations.
1539 * {bfd-in2,libbfd}.h: Regenerate.
1540
1541 * elf32-ppc.c (ppc_elf_howto_raw): Add more PPC relocations.
1542 (ppc_elf_reloc_type_lookup): Lookup new relocations.
1543
252239f8
ILT
1544Mon Jan 15 14:29:44 1996 Ian Lance Taylor <[email protected]>
1545
20ab764e
ILT
1546 * aoutx.h (howto_table_ext): Fix RELOC_BASE10 and RELOC_BASE22
1547 entries.
1548
0a4ffa2d
ILT
1549 * sunos.c (sunos_scan_ext_relocs): Don't fail assert if
1550 info->shared.
1551
45ca3195
ILT
1552 * coffgen.c (coff_find_nearest_line): Don't try to cache
1553 information in sections that are not owned by a BFD. From Richard
1554 Henderson <[email protected]>.
1555
252239f8
ILT
1556 * elf32-mips.c: Numerous changes to dynamic linking code, mostly
1557 from Kazumoto Kojima <[email protected]>.
1558 * elflink.h (elf_link_output_extsym): Remove special check for
1559 _rld_new_interface.
1560
1561 * ecoffswap.h: Add prototypes for static functions.
1562
bd2d10c0
MM
1563Sun Jan 14 21:36:08 1996 Michael Meissner <[email protected]>
1564
1565 * elf32-ppc.c (ppc_elf_{unsupported,std}_reloc): Remove functions.
1566 (ppc_elf_howto_raw): Remove ppc_elf_{unsupported,std}_reloc
1567 references.
1568 (ppc_elf_relocate_section): No longer allow .sdata/.sbss sections
1569 to satisfy a TOC16 relocation. Rewrite unsupported relocation
1570 support. Begin support for R_PPC_SDA{2,}REL.
1571
1c3a295b
MM
1572Sat Jan 13 09:36:52 1996 Michael Meissner <[email protected]>
1573
1574 * elf32-ppc.c (ppc_elf_create_dynamic_sections): New function to
1575 create the .got and .got.neg sections.
1576 (ppc_elf_size_dynamic_sections): Call it.
1577 (ppc_elf_check_relocs): Call it.
1578 (ppc_elf_size_dynamic_sections): Support .got.neg, just like .got.
1579 (ppc_elf_check_relocs): Add error messages for relocations we
1580 don't yet support. Do not include R_PPC_SDAREL16 like a GOT
1581 relocation.
1582
57081126
MM
1583Fri Jan 12 15:27:59 1996 Michael Meissner <[email protected]>
1584
1585 * elf32-ppc.c (ppc_elf_fake_sections): Define, and handle the new
1586 section flags for V.4 and eabi.
1587
3c38b3df
ILT
1588Fri Jan 12 13:59:16 1996 Ian Lance Taylor <[email protected]>
1589
14899eb7
ILT
1590 * elf.c (assign_file_positions_for_segments): If a segment
1591 contains no sections, don't mark it as readable.
1592
98bb57ad
ILT
1593 * elf-bfd.h (_bfd_elf_section_from_bfd_section): Declare.
1594 * elfcode.h (_bfd_elf_section_from_bfd_section): Don't declare.
1595
02fcd126
ILT
1596 * elf.c (_bfd_elf_print_private_bfd_data): Dump contents of
1597 dynamic section, if there is one.
1598 * elf-bfd.h (struct elf_size_info): Add swap_dyn_in field.
1599 (bfd_elf32_swap_dyn_in): Change type of second parameter to PTR.
1600 (bfd_elf64_swap_dyn_in): Likewise.
1601 * elfcode.h (elf_swap_dyn_in): Change type of second parameter to
1602 PTR.
1603 (NAME(_bfd_elf,size_info)): Initialize swap_dyn_in field.
1604
3c38b3df
ILT
1605 * elf32-i386.c (elf_i386_size_dynamic_sections): Don't create a
1606 DT_TEXTREL entry because of .rel.plt. From Martin Pirker
1607 <[email protected]>.
1608
83f4323e
MM
1609Thu Jan 11 17:06:14 1996 Michael Meissner <[email protected]>
1610
1611 * section.c (SEC_{EXCLUDE,SORT_ENTRIES}): New section flags for
1612 PowerPC V.4 and eabi.
1613 * bfd-in2.h: Regenerate.
1614 * libfd.h: Regenerate.
1615
1616 * elfxx-target.h (TARGET_{BIG,LITTLE}_SYM): Add new flags.
1617
1618 * elf32-ppc.c (ppc_elf_section_from_shdr): Support SHT_ORDERED
1619 section type and SHF_EXCLUDE section flag, turning them into the
1620 appropriate bfd section flag.
1621
a0271667
ILT
1622Thu Jan 11 11:23:30 1996 Ian Lance Taylor <[email protected]>
1623
c9746fb6
ILT
1624 * xcofflink.c (xcoff_link_add_symbols): Create the special
1625 sections if we see a DYNAMIC object, in case that is the only
1626 XCOFF input object we see.
1627
5b3b9ff6
ILT
1628 * elf32-mips.c: Extensive changes for a start at dynamic linking
1629 support, from Kazumoto Kojima <[email protected]>.
1630
1631 * elf-bfd.h (struct elf_backend_data): Add type_change_ok field.
1632 (struct elf_backend_data): Remove
1633 elf_backend_create_program_headers field. Add
1634 elf_backend_additional_program_headers and
1635 elf_backend_modify_segment_map fields.
1636 * elfxx-target.h (elf_backend_type_change_ok): Define if not
1637 defined.
1638 (elf_backend_additional_program_headers): Likewise.
1639 (elf_backend_modify_segment_map): Likewise.
1640 (elf_backend_create_program_headers): Don't define.
1641 (elfNN_bed): Change to account for field changes.
1642 * elf.c (assign_file_positions_for_segments): Call new
1643 modify_segment_map backend function. Don't call old
1644 create_program_headers backend function.
1645 (get_program_header_size): Call additional_program_headers rather
1646 than create_program_headers.
1647 * elflink.h (elf_link_add_object_symbols): Initialize
1648 type_change_ok from new backend field.
1649 (elf_link_output_extsym): Don't warn if _rld_new_interface is
1650 defined.
1651 (elf_reloc_link_order): Treat a reloc against a defined symbol as
1652 a reloc against the appropriate section.
1653
761f377f
ILT
1654 * elf-bfd.h (struct bfd_elf_section_data): Add tdata field.
1655 (struct elf_obj_tdata): Rename ppc_flags_init field to flags_init.
1656 (elf_flags_init): Rename from elf_ppc_flags_init.
1657 * elf32-ppc.c (ppc_elf_set_private_flags): Use elf_flags_init, not
1658 elf_ppc_flags_init.
1659 (ppc_elf_copy_private_bfd_data): Likewise.
1660 (ppc_elf_merge_private_bfd_data): Likewise.
1661
a0271667
ILT
1662 * elf32-m68k.c (howto_table): Change src_mask to 0 for all
1663 relocation entries.
1664
64d5f5d0
ILT
1665Tue Jan 9 15:22:53 1996 David Mosberger-Tang <[email protected]>
1666
1667 * coff-alpha.c (alpha_relocate_section): During final link, allow
1668 output .lita section to be bigger than 64k by adjusting gp value
1669 on a per-input section basis.
1670 * libecoff.h (struct ecoff_tdata): Add issued_multiple_gp_warning
1671 field.
1672 (struct ecoff_section_tdata): Add gp field.
1673
c40d9c77
ILT
1674Tue Jan 9 12:00:36 1996 Ian Lance Taylor <[email protected]>
1675
64d5f5d0
ILT
1676 Handle Alpha ECOFF changes in OSF/1 3.2.
1677 * libecoff.h (struct ecoff_backend_data): Add get_elt_at_filepos
1678 field.
1679 * coff-alpha.c: Include "aout/ar.h".
1680 (alpha_ecoff_get_relocated_section_contents): Don't require an
1681 ALPHA_R_IGNORE reloc after an ALPHA_R_GPDISP reloc, since OSF/1
1682 3.2 doesn't generate one.
1683 (alpha_relocate_section): Likewise.
1684 (alpha_ecoff_slurp_armap): Define.
1685 (alpha_ecoff_slurp_extended_name_table): Define.
1686 (alpha_ecoff_construct_extended_name_table): Define.
1687 (alpha_ecoff_truncate_arname): Define.
1688 (alpha_ecoff_write_armap): Define.
1689 (alpha_ecoff_generic_stat_arch_elt): Define.
1690 (alpha_ecoff_update_armap_timestamp): Define.
1691 (ARFZMAG): Define.
1692 (alpha_ecoff_read_ar_hdr): New static function.
1693 (alpha_ecoff_get_elt_at_filepos): New static function.
1694 (alpha_ecoff_openr_next_archived_file): New static function.
1695 (alpha_ecoff_get_elt_at_index): New static function.
1696 (alpha_ecoff_backend_data): Initialize get_elt_at_filepos field.
1697 (ecoffalpha_little_vec): Change BFD_JUMP_TABLE_ARCHIVE from
1698 _bfd_ecoff to alpha_ecoff.
1699 * ecoff.c (ecoff_link_add_archive_symbols): Use get_elt_at_filepos
1700 field from backend structure, rather than always calling
1701 _bfd_get_elt_at_filepos.
1702 * coff-mips.c (mips_ecoff_backend_data): Initialize
1703 get_elt_at_filepos field.
1704 * archive.c (_bfd_generic_read_ar_hdr_mag): New function, copied
1705 from _bfd_generic_read_ar_hdr with minor changes.
1706 (_bfd_generic_read_ar_hdr): Use _bfd_generic_read_ar_hdr_mag.
1707 * libbfd-in.h (_bfd_generic_read_ar_hdr_mag): Declare.
1708 * libbfd.h: Rebuild.
1709
1710 * bfd-in.h (BFD_IN_MEMORY): Define.
1711 * libbfd-in.h (struct bfd_in_memory): Define.
1712 * libbfd.c (bfd_read): Handle BFD_IN_MEMORY flag.
1713 (bfd_get_file_window): Don't try to map a BFD_IN_MEMORY file.
1714 (bfd_write, bfd_stat): Abort if BFD_IN_MEMORY is set.
1715 (bfd_tell, bfd_flush, bfd_seek): Handle BFD_IN_MEMORY flag.
1716 * bfd.c (struct _bfd): Change iostream field from char * to PTR.
1717 (bfd_get_size): Handle BFD_IN_MEMORY flag.
1718 * cache.c (bfd_cache_close): Ignore BFD_IN_MEMORY files.
1719 (bfd_open_file): Cast to PTR, not char *, when setting iostream.
1720 (bfd_cache_lookup_worker): Abort if BFD_IN_MEMORY is set.
1721 * opncls.c (bfd_fdopenr): Cast to PTR, not char *, when setting
1722 iostream.
1723 (bfd_openstreamr): Likewise.
1724 * aoutx.h (NAME(aout,some_aout_object_p)): Only fstat iostream if
1725 BFD_IN_MEMORY is not set.
1726 * riscix.c (riscix_some_aout_object_p): Likewise.
1727 * bfd-in2.h, libbfd.h: Rebuild.
1728
1729 * targets.c (bfd_target): Add _bfd_get_elt_at_index field.
1730 (BFD_JUMP_TABLE_ARCHIVE): Add _get_elt_at_index.
1731 (bfd_get_elt_at_index): Define.
1732 * archive.c (_bfd_generic_get_elt_at_index): Rename from
1733 bfd_get_elt_at_index. Change index parameter from int to
1734 symindex.
1735 * libbfd-in.h (_bfd_generic_get_elt_at_index): Declare.
1736 (_bfd_noarchive_get_elt_at_index): Define.
1737 (_bfd_archive_bsd_get_elt_at_index): Define.
1738 (_bfd_archive_coff_get_elt_at_index): Define.
1739 * bfd-in2.h, libbfd.h: Rebuild.
1740 * aout-target.h (MY_get_elt_at_index): Define if not defined.
1741 * coff-rs6000.c (xcoff_get_elt_at_index): Define.
1742 * ieee.c (ieee_get_elt_at_index): Define.
1743 * libecoff.h (_bfd_ecoff_get_elt_at_index): Define.
1744 * oasys.c (oasys_get_elt_at_index): Define.
1745 * som.c (som_get_elt_at_index): Define.
1746
c40d9c77
ILT
1747 * ecoff.c (_bfd_ecoff_find_nearest_line): Don't restrict line
1748 numbers to the .text section.
1749
efa77952
ILT
1750Mon Jan 8 17:00:57 1996 Ian Lance Taylor <[email protected]>
1751
1752 * ieee.c (ieee_write_debug_part): Change return type to boolean.
1753 If there is a SEC_DEBUGGING section, get the contents of the debug
1754 information part from it.
1755 (ieee_set_section_contents): Store the contents of a SEC_DEBUGGING
1756 section in memory.
1757 (ieee_write_object_contents): Check ieee_write_debug_part return.
1758
767f22d5
FF
1759Thu Jan 4 17:12:37 1996 Fred Fish <[email protected]>
1760
1761 * config.bfd (i[345]86-*-freebsd*): Add target.
1762 * configure.in (i386freebsd_vec): Add vec.
1763 * configure: Regenerate.
1764 * Makefile.in (BFD32_BACKENDS): Add i386freebsd.o.
1765 (BFD32_BACKENDS_CFILES): Add i386freebsd.c.
1766 Rebuild dependencies..
1767 * freebsd.h: New file.
1768 * i386freebsd.c: New file.
1769 * targets.c (i386freebsd_vec): Declare.
1770 (bfd_target_vector): Add i386freebsd_vec.
1771 * i386linux.c (SEGMENT_SIZE): Define as TARGET_PAGE_SIZE
1772 * i386netbsd.c (SEGMENT_SIZE): Define as TARGET_PAGE_SIZE
1773
f8254a3c
ILT
1774Thu Jan 4 16:27:46 1996 Ian Lance Taylor <[email protected]>
1775
1776 * ieee.c (ieee_slurp_debug): New static function.
1777 (ieee_object_p): Call it.
1778 (ieee_slurp_section_data): Skip debugging sections.
1779 (ieee_get_reloc_upper_bound): Likewise.
1780 (ieee_get_section_contents): Likewise.
1781 (ieee_canonicalize_reloc): Likewise.
1782 (ieee_write_section_part): Likewise.
1783 (ieee_write_debug_part): Likewise.
1784 (ieee_write_data_part): Likewise.
1785 (init_for_output): Likewise.
1786
07a159db
MM
1787Wed Jan 3 19:42:47 1996 Michael Meissner <[email protected]>
1788
1789 * elf32-ppc.c (ppc_elf_relocate_section): Make @GOT relocations
1790 work.
1791 (ppc_elf_howto_raw): Just use bfd_elf_generic_reloc for all howto
1792 relocs, since ppc_elf_relocate_section handles the linker case.
1793 (ppc_elf_{addr16_ha,got16,toc16,brtaken}_reloc): Delete, no longer
1794 used.
1795 (ppc_elf_{addr16_ha,got16,toc16,brtaken}_inner): Merge these into
1796 ppc_elf_relocate_section since that is now the only caller.
1797 (ppc_elf_relocate_section): Ditto.
1798
d812945a
ILT
1799Wed Jan 3 15:11:30 1996 Ian Lance Taylor <[email protected]>
1800
1801 * coffcode.h (coff_write_object_contents): If we don't know the
1802 section of the entry point for an XCOFF executable, always set the
1803 entry address to -1.
1804
3a56d0b4
MM
1805Tue Jan 2 14:17:15 1996 Michael Meissner <[email protected]>
1806
1807 * elf.c (bfd_section_from_shdr): Add support for note sections.
1808
c4406e50
ILT
1809Tue Jan 2 13:10:25 1996 Ian Lance Taylor <[email protected]>
1810
d812945a
ILT
1811 * bfd-in.h (struct _symbol_info): Add stab_type field.
1812 * bfd-in2.h: Rebuild.
1813 * aoutx.h (NAME(aout,get_symbol_info)): Set stab_type.
1814
c4406e50
ILT
1815 * elf32-ppc.c: Remove trailing newline from calls to
1816 _bfd_error_handler.
1817 (ppc_elf_merge_private_bfd_data): Only warn about endianness
1818 difference if target endianness is known.
1819
08556813
MM
1820Thu Dec 21 12:43:49 1995 Michael Meissner <[email protected]>
1821
1822 * elf32-ppc.c (ppc_elf_howto_raw): Add a phony reloc to handle the
1823 old style TOC16 references without using R_PPC_GOT.
1824 (ppc_reloc_type): Ditto.
1825 (ppc_elf_reloc_type_lookup): Add support for TOC16.
1826 (ppc_elf_toc16_inner): Renamed from ppc_elf_got16_inner.
1827 (ppc_elf_toc16_reloc): Renamed from ppc_elf_toc16_reloc.
1828 (ppc_elf_got16_{inner,reloc}): Stubs for real GOT support.
1829 (ppc_elf_check_relocs): New function for GOT/PLT support that is
1830 work in progress.
1831 (ppc_elf_adjust_dynamic_symbol): Ditto.
1832 (ppc_elf_adjust_dynindx): Ditto.
1833 (ppc_elf_size_dynamic_sections): Ditto.
1834 (ppc_elf_finish_dynamic_symbol): Ditto.
1835 (ppc_elf_finish_dynamic_sections): Ditto.
1836 (ELF_DYNAMIC_INTERPRETER): Define.
1837
86587dd4
KR
1838Wed Dec 20 19:14:18 1995 Ken Raeburn <[email protected]>
1839
1840 * elf.c (copy_private_bfd_data): When attaching sections to
1841 segments ignore sections that won't be allocated. Patch from
1842 Andreas Schwab.
1843
bf7f243f
KR
1844Tue Dec 19 20:01:43 1995 Ken Raeburn <[email protected]>
1845
1846 * config.bfd: Match on m68k-cbm-* only if OS doesn't match
1847 anything else.
1848
d9518e2e
ILT
1849Tue Dec 19 16:38:59 1995 Ian Lance Taylor <[email protected]>
1850
1851 * coff-i960.c (CALC_ADDEND): Define.
1852 (coff_i960_relocate_section): Add the input section VMA to the
1853 addend for PC relative relocs.
1854
1855Sun Dec 17 20:11:55 1995 Kim Knuttila <[email protected]>
1856
1857 * peicode.h (pe_print_pdata): Must test the entire entry for zero
1858 to correctly terminate.
1859
010a405a
ILT
1860Fri Dec 15 12:05:57 1995 Ian Lance Taylor <[email protected]>
1861
dc092b6b
ILT
1862 * targets.c (enum bfd_endian): Define.
1863 (bfd_target): Rename byteorder_big_p to byteorder, and change it
1864 from boolean to enum bfd_endian. Change header_byteorder_big_p
1865 correspondingly.
1866 * bfd-in.h (bfd_big_endian, bfd_little_endian): New macros.
1867 (bfd_header_big_endian, bfd_header_little_endian): New macros.
1868 * bfd-in2.h: Rebuild.
1869 * All targets: Change initialization of byteorder and
1870 header_byteorder to use enum bfd_endian values rather than
1871 booleans.
1872 * All files: Change all references to byteorder_big_p and
1873 header_byteorder_big_p to use new bfd_*_endian macros.
1874
010a405a
ILT
1875 * coffgen.c (make_a_section_from_file): Set lma to s_paddr, not
1876 s_vaddr.
1877 * coffcode.h (coff_write_object_contents): Set s_paddr to lma, not
1878 vma.
1879 * ecoff.c (_bfd_ecoff_write_object_contents): Likewise.
1880
fcb43906
SC
1881Fri Dec 15 07:32:09 1995 steve chamberlain <[email protected]>
1882
1883 * pe[i]-i386.c (TARGET_UNDERSCORE): Define to '_'.
1884
0d709d31
ILT
1885Thu Dec 14 13:45:37 1995 Ian Lance Taylor <[email protected]>
1886
14578105
ILT
1887 * ieee.c: Lots of minor cleanups. Make many functions return
1888 errors rather than calling abort. Also:
1889 (ieee_write_twobyte): Remove; change callers to call existing
1890 ieee_write_2bytes function.
1891 (ieee_write_expression): Don't output the section twice when
1892 outputting a local symbol. Don't emit an extraneous zero if there
1893 is only one term.
1894 (ieee_slurp_sections): Set the lma as well as the vma.
1895 (ieee_archive_p): Use bfd_alloc_grow rather than an obstack.
1896
0d709d31
ILT
1897 * ihex.c (ihex_set_arch_mach): Don't accept any architecture, just
1898 a recognized one or bfd_arch_unknown.
1899 (ihex_get_symtab_upper_bound): Define as bfd_0l, to permit objcopy
1900 to succeed.
1901 (ihex_get_symtab): Likewise.
1902
14dc2f77
ILT
1903Wed Dec 13 15:44:06 1995 Ian Lance Taylor <[email protected]>
1904
1905 * aoutx.h: Include <ctype.h>.
1906 (struct aout_link_includes_table): Define.
1907 (struct aout_link_includes_totals): Define.
1908 (struct aout_link_includes_entry): Define.
1909 (aout_link_includes_lookup): Define macro.
1910 (struct aout_final_link_info): Add includes field.
1911 (aout_link_includes_newfunc): New static function.
1912 (NAME(aout,final_link)): Initialize includes hash table.
1913 (aout_link_write_symbols): Eliminate duplicate N_BINCL entries.
1914
480ccad5
SS
1915Wed Dec 13 10:52:14 1995 Stan Shebs <[email protected]>
1916
1917 * mpw-config.in: Match on mips-*-* instead of mips-idt-ecoff.
1918
3920d9c9
KK
1919Wed Dec 13 11:07:45 1995 Kim Knuttila <[email protected]>
1920
1921 * coff-ppc.c (coff_ppc_relocate_section): removed debugging code.
1922
207345f2
KK
1923Tue Dec 12 17:42:06 1995 Kim Knuttila <[email protected]>
1924
1925 * peicode.h (pe_print_reloc): New function to dump the .reloc section.
1926 (pe_print_private_bfd_data): call pe_print_reloc.
1927 * coffcode.h (coff_set_alignment_hook): .reloc section alignment.
1928 * coff-ppc.c (in_reloc_p): Added missing non-eligible relocs. Spiffed
1929 up some debugging as well.
1930
273c019e
ILT
1931Tue Dec 12 11:34:23 1995 Ian Lance Taylor <[email protected]>
1932
1933 * config.bfd: Handle sparc-*-elf*. From Ronald F. Guilmette
1934 <[email protected]>.
1935
010d9f2d
ILT
1936Fri Dec 8 17:47:07 1995 Ian Lance Taylor <[email protected]>
1937
1938 * elflink.h (elf_link_add_object_symbols): Set section_count to 0
1939 when setting sections to NULL.
1940
4a4a66bd
ILT
1941Wed Dec 6 17:05:37 1995 Ian Lance Taylor <[email protected]>
1942
1943 * xcofflink.c (struct xcoff_loader_info): Add export_defineds
1944 field.
1945 (bfd_xcoff_size_dynamic_sections): Add export_defineds parameter.
1946 (xcoff_build_ldsyms): If export_defineds is set, set XCOFF_EXPORT
1947 for all symbols.
1948 * bfd-in.h (bfd_xcoff_size_dynamic_sections): Update declaration.
1949 * bfd-in2.h: Rebuild.
1950
545bf026
KK
1951Mon Dec 4 16:40:47 1995 Kim Knuttila <[email protected]>
1952
1953 * coffcode.h (coff_set_alignment_hook): Removed some debugging printf's
1954
1f4ae0d6
ILT
1955Mon Dec 4 11:25:39 1995 Ian Lance Taylor <[email protected]>
1956
55cac920
ILT
1957 * ihex.c (ihex_scan): Handle record types 4 and 5.
1958 (ihex_object_p): Permit types 4 and 5.
1959 (ihex_set_section_contents): Remove check for out of range
1960 addresses.
1961 (ihex_write_object_contents): Generate types 4 and 5.
1962
1f4ae0d6
ILT
1963 * elflink.h (elf_link_output_extsym): Just ignore warning and
1964 indirect references to symbols which don't really exist.
1965
53d45489
KK
1966Sun Dec 3 19:00:27 1995 Kim Knuttila <[email protected]>
1967
1968 * peicode.h (pe_print_idata): Minor format fixes
1969 (pe_print_edata): New function. Under private printing, this formats
1970 the edata section of a PE file.
1971 (pe_print_private_bfd_data): Added call to pe_print_edata.
1972
361e8876
DE
1973Sun Dec 3 16:46:54 1995 Richard Earnshaw ([email protected])
1974
1975 * aout-arm.c (MY_swap_std_reloc_out): Use KEEPIT to get the symbol
1976 index, don't call stoi.
1977
58142f10
ILT
1978Fri Dec 1 14:46:51 1995 Ian Lance Taylor <[email protected]>
1979
ffd15489
ILT
1980 * srec.c (srec_scan): Set lma as well as vma.
1981
1982 * ihex.c: New file; support for Intel Hex format.
1983 * targets.c (enum bfd_flavour): Add bfd_target_ihex_flavour.
1984 (ihex_vec): Declare.
1985 (bfd_target_vector): Always include ihex_vec.
1986 * bfd.c (struct _bfd): Add ihex_data field to tdata union.
1987 * Makefile.in: Rebuild dependencies.
1988 (BFD_LIBS): Add ihex.o
1989 (BFD_LIBS_CFILES): Add ihex.c.
1990 * bfd-in2.h: Rebuild.
1991
ae0a6bea
ILT
1992 * elf.c (assign_file_positions_for_segments): Sort the sections in
1993 each segment.
1994 (get_program_header_size): Return the right size if segment_map is
1995 not NULL.
1996 (copy_private_bfd_data): Don't bother to sort the sections.
1997
1998 * bfd.c (bfd_record_phdr): New function.
1999 * bfd-in.h (bfd_record_phdr): Declare.
2000 * bfd_in2.h: Rebuild.
2001
ce0ee4bf
ILT
2002 * elf32-sparc.c (elf32_sparc_relocate_section): Remove bogus
2003 BFD_ASSERT.
2004
58142f10
ILT
2005 * libbfd.c (bfd_malloc, bfd_realloc): New functions.
2006 (bfd_zmalloc): Return PTR, not char *. Take size_t, not
2007 bfd_size_type.
2008 * libbfd-in.h (bfd_malloc, bfd_realloc): Declare.
2009 (bfd_zmalloc): Change declaration.
2010 * libbfd.h: Rebuild.
2011 * Many files: Use bfd_malloc and bfd_realloc rather than malloc
2012 and realloc. Don't set bfd_error_no_memory if they fail.
2013
59066248
KK
2014Thu Nov 30 19:32:26 1995 Kim Knuttila <[email protected]>
2015
2016 * coff-ppc.c: Added macros to tidy up toc cell treatment. Numerous
2017 uses as well. Added a new howto to deal with TOCREL16 relocs that
2018 are TOCDEFN as well.
2019 (coff_ppc_relocate_section): Expanded treatment of ADDR32NB relocs
2020 to handle RVA relocs from dlltool.
2021 (ppc_coff_rtype2howto): TOCDEFN reloc addition.
2022 (coff_ppc_rtype_to_howto): TOCDEFN reloc addition.
2023 (ppc_coff_reloc_type_lookup): TOCDEFN reloc addition.
2024
2025 * coffcode.h (coff_set_alignment_hook): check idata$X sections
2026 to get the right section alignment.
2027
6933148a
ILT
2028Thu Nov 30 16:48:18 1995 Ian Lance Taylor <[email protected]>
2029
2030 * elf.c (_bfd_elf_make_section_from_shdr): Don't set lma based on
2031 p_paddr if p_paddr is zero.
2032 (make_mapping): Set includes_filehdr and includes_phdrs for first
2033 PT_LOAD segment.
2034 (map_sections_to_segments): Set includes_phdrs for PT_PHDR
2035 segment.
2036 (assign_file_positions_for_segments): Handle includes_filehdr and
2037 includes_phdrs. Remove special handling of PT_PHDR and first
2038 PT_LOAD segments.
2039 (copy_private_bfd_data): Set includes_filehdr and includes_phdr
2040 when appropriate. Remove special handling of PT_PHDR segment.
2041 Use a more complex condition for when a section is included in a
2042 segment to handle Solaris linker oddities.
2043
f62fed1c
ILT
2044Thu Nov 30 11:17:33 1995 Manfred Hollstein KS/EF4A 60/1F/110 #40283 <[email protected]>
2045
2046 * coff-m88k.c (howto_table): Reformatted for easier reading;
2047 special_function now points to new function m88k_special_reloc.
2048 (howto_hvrt16): Function previously used for handling HVRT16 relocs
2049 removed.
2050 (rtype2howto): Do not add reloc's r_offset to the addend, this will
2051 be done correctly by m88k_special_reloc.
2052 (reloc_processing): New function to be used by RELOC_PROCESSING.
2053 (RELOC_PROCESSING): Define to call reloc_processing.
2054
64ecde46
ILT
2055Wed Nov 29 12:42:36 1995 Ian Lance Taylor <[email protected]>
2056
b00c57ec
ILT
2057 * peicode.h (pe_print_idata): Call malloc rather than xmalloc.
2058 (pe_print_pdata): Likewise.
2059
a9713b91
ILT
2060 * opncls.c (bfd_alloc_by_size_t): Set bfd_error_no_memory if
2061 obstack_alloc fails.
2062 (bfd_alloc_finish): Set bfd_error_no_memory if obstack_finish
2063 fails.
2064 * libbfd.c (bfd_zmalloc): Set bfd_error_no_memory if malloc fails.
2065 * Many files: don't set bfd_error_no_memory if one of the above
2066 routines fails.
2067
3dbf33ee
ILT
2068 * elf.c (assign_file_positions_for_segments): Don't adjust p_paddr
2069 if p_paddr_valid is set.
2070 (copy_private_bfd_data): New static function.
2071 (_bfd_elf_copy_private_section_data): Call copy_private_bfd_data.
2072
44ef8897
ILT
2073 * elf.c (assign_file_positions_for_segments): Fix case where extra
2074 program headers were allocated.
2075
27fb8f29
ILT
2076 * elf.c (_bfd_elf_print_private_bfd_data): New function.
2077 * elf-bfd.h (_bfd_elf_print_private_bfd_data): Declare.
2078 * elfxx-target.h (bfd_elfNN_bfd_print_private_bfd_data): Define to
2079 _bfd_elf_print_private_bfd_data.
2080
64ecde46
ILT
2081 * coff-alpha.c (alpha_ecoff_swap_reloc_in): Don't abort if
2082 r_symndx is RELOC_SECTION_NONE for an ALPHA_R_IGNORE reloc.
2083 Change a RELOC_SECTION_LITA symndx to RELOC_SECTION_ABS.
2084 (alpha_ecoff_swap_reloc_out): Change RELOC_SECTION_ABS to
2085 RELOC_SECTION_LITA for ALPHA_R_IGNORE.
2086 (alpha_adjust_reloc_out): For ALPHA_R_IGNORE, don't change
2087 RELOC_SECTION_ABS to RELOC_SECTION_NONE.
2088
fd0198f0
ILT
2089Tue Nov 28 16:59:50 1995 Ian Lance Taylor <[email protected]>
2090
2091 * elf-bfd.h (struct elf_obj_tdata): Add segment_map field.
2092 * elf.c (make_mapping): New static function.
2093 (map_sections_to_segments): New static function.
2094 (elf_sort_sections): New static function.
2095 (assign_file_positions_for_segments): New static function.
2096 (map_program_segments): Remove.
2097 (get_program_header_size): Remove sorted_hdrs, count, and
2098 maxpagesize parameters. Simplify.
2099 (assign_file_positions_except_relocs): When generating an
2100 executable, use assign_file_positions_for_segments.
2101 (elf_sort_hdrs): Remove.
2102 (_bfd_elf_sizeof_headers): Remove eliminated parameters from call
2103 to get_program_header_size.
2104
3b3f7625
ILT
2105Mon Nov 27 12:27:46 1995 Ian Lance Taylor <[email protected]>
2106
1ff0461b
ILT
2107 * hp300hpux.c (MY(callback)): Set lma as well as vma.
2108
80c8485c
ILT
2109 * configure, config.in: Regenerate with autoconf 2.7.
2110
3b3f7625
ILT
2111 * elf32-i386.c (elf_backend_plt_readonly): Set correctly, to 1.
2112 * elf32-sparc.c (elf_backend_plt_readonly): Set correctly, to 0.
2113
fa63d1ef
ILT
2114Wed Nov 22 12:02:09 1995 Ian Lance Taylor <[email protected]>
2115
a877f591
ILT
2116 * ecoff.c (_bfd_ecoff_new_section_hook): Handle .rconst section.
2117 (ecoff_sec_to_styp_flags): Likewise.
2118 (_bfd_ecoff_styp_to_sec_flags): Handle STYP_RCONST.
2119 (ecoff_set_symbol_info): Handle scRConst.
2120 (ecoff_slurp_reloc_table): Handle RELOC_SECTION_RCONST.
2121 (ecoff_compute_section_file_positions): Handle .rconst section.
2122 (_bfd_ecoff_write_object_contents): Likewise.
2123 (ecoff_link_check_archive_element): Handle scRConst.
2124 (ecoff_link_add_externals): Likewise.
2125 (ecoff_link_write_external): Handle .rconst section.
2126 (ecoff_reloc_link_order): Likewise.
2127 * ecofflink.c (bfd_ecoff_debug_accumulate): Handle scRConst.
2128 * coff-alpha.c (alpha_convert_external_reloc): Handle .rconst
2129 section.
2130 (alpha_relocate_section): Handle RELOC_SECTION_RCONST.
2131
fa63d1ef
ILT
2132 * sunos.c (sunos_scan_dynamic_symbol): Only set written if the
2133 DEF_DYNAMIC flag is set.
2134
25bada65
KR
2135Tue Nov 21 13:25:29 1995 Ken Raeburn <[email protected]>
2136
2137 * host-aout.c: If TRAD_HEADER is defined, include it.
2138
7938b4cb
ILT
2139Tue Nov 21 13:03:57 1995 Ian Lance Taylor <[email protected]>
2140
85e493f0
ILT
2141 * aclocal.m4 (AC_PROG_CC): Remove local definition.
2142 (BFD_BINARY_FOPEN): Require AC_CANONICAL_SYSTEM.
2143 (BFD_NEED_DECLARATION): New function.
2144 * configure.in: Use BFD_NEED_DECLARATION.
bd77213b
ILT
2145 * acconfig.h: Put NEED_DECLARATION_* in @TOP@ section.
2146 * configure, config.in: Rebuild with autoconf 2.6.
85e493f0 2147
83dcdc61
ILT
2148 * xcofflink.c (bfd_xcoff_size_dynamic_sections): Clear
2149 special_sections before returning when called with a non XCOFF
2150 BFD.
2151
7938b4cb
ILT
2152 * coffgen.c (coff_renumber_symbols): Sort common symbols with
2153 global symbols.
2154
2155 * coffcode.h (coff_compute_section_file_positions): Only pad the
2156 previous section to force file alignment when creating an
2157 executable.
2158
b5403ad7
ILT
2159Mon Nov 20 14:54:09 1995 Ian Lance Taylor <[email protected]>
2160
a418e05d
ILT
2161 * coffcode.h (coff_compute_section_file_positions): If
2162 RS6000COFF_C, set up the .debug section.
2163
b5403ad7
ILT
2164 * xcofflink.c (xcoff_link_input_bfd): Adjust the TOC anchor value
2165 if it is not large enough to accomodate the entire TOC area with
2166 signed 16 bit offsets.
2167 (xcoff_write_global_symbol): Handle negative TOC offsets in global
2168 linkage code.
2169 (_bfd_ppc_xcoff_relocate_section): Adjust relocations against a
2170 TOC anchor to use the TOC value used in the output file.
2171
90a7abbc
ILT
2172Sat Nov 18 18:01:41 1995 Ian Lance Taylor <[email protected]>
2173
2174 * coffgen.c (_bfd_coff_get_external_symbols): Cast malloc return.
2175 (_bfd_coff_read_string_table): Likewise.
2176
177b1932
DE
2177Sat Nov 18 19:43:04 1995 Richard Earnshaw ([email protected])
2178
2179 * pe-arm.c: Fix typos.
2180 * coff-arm.c: Likewise.
2181
2182Fri Nov 17 16:22:04 1995 Kim Knuttila <[email protected]>
2183
2184 * coff-ppc.c (list_ele): Added "cat"egory member.
2185 (record_toc): New category parameter (priv or pub).
2186 (ppc_record_toc_entry): Check to see if toc bounds exceeded.
2187 (ppc_process_before_allocation): Removed embrionic data-in-toc from
2188 the mainline. It addes extra toc cells in error.
2189 (ppc_coff_swap_sym_in_hook): Added some documentation.
2190 (dump_toc): Can now diagnose "virtual toc" chicanery.
2191
e34314c4
ILT
2192Fri Nov 17 10:41:25 1995 Philippe De Muyter <[email protected]>
2193
2194 * elf-bfd.h (struct elf_link_hash_table): Change type of
2195 dynsymcount and bucketcount fields from size_t to bfd_size_type.
2196
73a68447
ILT
2197Fri Nov 17 10:02:58 1995 Ian Lance Taylor <[email protected]>
2198
535e9e29
ILT
2199 * coffcode.h (coff_pointerize_aux_hook): I960 version: don't
2200 pointerize C_LEAFSTAT or C_LEAFEXT entries.
2201
73a68447
ILT
2202 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Only create
2203 DT_INIT and DT_FINI entries if the _init or _fini symbol is
2204 defined or mentioned in a regular file.
2205
cd2b2402
KK
2206Thu Nov 16 15:16:42 1995 Kim Knuttila <[email protected]>
2207
2208 * coff-ppc.c (ppc_record_data_in_toc_entry): new function
2209 (coff_ppc_relocate_section): Handle TOCDEFN attribute
2210 (coff_ppc_relocate_section): Correct REL24 handling
2211 (ppc_process_before_allocation): Correct TOCDEFN handling
2212
2213 * peicode.h (dir_names): Added name descriptions
2214
b218076e
KR
2215Thu Nov 16 03:38:03 1995 Ken Raeburn <[email protected]>
2216
2217 * VERSION: Updated to cygnus-2.6.
2218
2219Wed Nov 15 19:30:07 1995 Ken Raeburn <[email protected]>
2220
2221 * targets.c (m68k4knetbsd_vec): Declare.
2222
e9f30616
ILT
2223Wed Nov 15 18:05:52 1995 Ian Lance Taylor <[email protected]>
2224
2225 * targets.c (bfd_target): Change type of second argument to
2226 _bfd_print_private_bfd_data from void * to PTR.
2227 * libbfd-in.h (_bfd_generic_bfd_print_private_bfd_data): Cast
2228 using PTR rather than void *.
2229 * bfd-in2, libbfd.h: Rebuild.
2230 * peicode.h (pe_print_private_bfd_data): Change vfile from void *
2231 to PTR.
2232 * elfxx-target.h (bfd_elfNN_bfd_print_private_bfd_data): Define as
2233 _bfd_generic_bfd_print_private_bfd_data rather than casting
2234 bfd_true.
2235
ae75c4a4
KR
2236Wed Nov 15 04:09:14 1995 Ken Raeburn <[email protected]>
2237
2238 * Makefile.in (.dep1): Fix stupid typo in last change. Remove any
2239 "DO NOT DELETE" lines or blank lines that mkdep writes on some
2240 systems.
2241 (BFD_LIBS_CFILES, ALL_MACHINES_CFILES, BFD32_BACKENDS_CFILES,
2242 BFD64_BACKENDS_CFILES): New variables.
2243 (CFILES): Use them.
2244
bebcd3db
ILT
2245Tue Nov 14 11:52:23 1995 Ian Lance Taylor <[email protected]>
2246
4b71e164
ILT
2247 * peicode.h (coff_swap_aouthdr_out): For PPC PE, start isize at 0,
2248 not at the file position of the first section.
2249 * coffcode.h (coff_compute_section_file_positions): Avoid using
2250 unportable #elif.
2251 (coff_write_object_contents): When generating a PPC PE executable
2252 with no symbols, round up the file size to a COFF_PAGE_SIZE
2253 boundary.
2254 * cofflink.c (_bfd_coff_final_link): If there are no symbols,
2255 don't write out a string table.
2256
631b10f4
ILT
2257 * elf.c (bfd_section_from_shdr): When using a different section
2258 header, pass the new one to _bfd_elf_make_section_from_shdr.
2259 (elf_fake_sections): Don't set sh_info and sh_entsize fields.
2260 (elf_map_symbols): Add section VMA to symbol value when comparing
2261 against 0.
2262 (_bfd_elf_compute_section_file_positions): Only build symbol table
2263 if there are some symbols. Set file offset of symtab and strtab
2264 sections.
2265 (assign_file_positions_except_relocs): Remove dosyms parameter.
2266 Change all callers. Never set file offset of symtab and strtab
2267 sections.
2268 (_bfd_elf_copy_private_section_data): New function.
2269 (MAP_ONESYMTAB, MAP_DYNSYMTAB, MAP_STRTAB, MAP_SHSTRTAB): Define.
2270 (_bfd_elf_copy_private_symbol_data): New function.
2271 (swap_out_syms): Check for special mapping of st_shndx created by
2272 copy_private_symbol_data.
2273 * elfxx-target.h: Use new copy routines.
2274 * elf-bfd.h (_bfd_elf_copy_private_symbol_data): Declare.
2275 (_bfd_elf_copy_private_section_data): Declare.
2276
2277 * config.bfd (sh-*-*): Set targ_defvec to shcoff_vec.
2278
2279 * coffcode.h (coff_slurp_symbol_table): If COFF_WITH_PE, handle
2280 C_NT_WEAK.
2281
bebcd3db
ILT
2282 * coff-sh.c (shlcoff_vec): Use _bfd_generic_archive_p, not
2283 _bfd_dummy_target, matching the recent change to archive
2284 recognition.
2285
7ad4ba81
ILT
2286Mon Nov 13 13:24:38 1995 Ian Lance Taylor <[email protected]>
2287
afa67334
ILT
2288 * libbfd.c (bfd_get_file_window): Use casts to avoid doing
2289 arithmetic on PTR types.
2290
f2bd8915
ILT
2291 * aout-target.h (MY(callback)): Set the lma of the sections.
2292
7ad4ba81
ILT
2293 * ecoff.c (ecoff_reloc_link_order): Turn a reloc against a defined
2294 symbol into a reloc against the section.
2295
93b6a3f8
KK
2296Mon Nov 13 07:31:35 1995 Kim Knuttila <[email protected]>
2297
2298 * coff-ppc.c (ppc_coff_link_hash_entry): added support for inline
2299 glue for the relocs: IMGLUE and IFGLUE.
2300 (record_toc): new function - tracks toc contents
2301 (ppc_mark_symbol_as_glue): new function - supports the IMGLUE reloc
2302 (coff_ppc_relocate_section): Added support and fixes for IMGLUE/IFGLUE
2303 (ppc_coff_rtype2howto): removed invalid IMGLUE hack
2304 (coff_ppc_rtype_to_howto): removed invalid IMGLUE hack
125d37c4 2305 (ppc_record_toc_entry): Removed a debug define (duh)
93b6a3f8
KK
2306
2307 * peicode.h (coff_swap_scnhdr_out): Fixed invalid strcmp for ".reldata"
2308 (pe_print_idata): New function - formats the idata section data
2309 (pe_print_pdata): New function - formats the pdata section data
2310 (pe_print_private_bfd_data): calls to above
2311
c769947b
SS
2312Sun Nov 12 12:23:24 1995 Stan Shebs <[email protected]>
2313
2314 * Makefile.in (bfd_libs_here, etc): Provide empty definitions.
2315 * coff-rs6000.c (rs6000coff_vec): Add conditional defines
2316 TARGET_SYM and TARGET_NAME for vector and BFD name.
2317 * coff-pmac.c (pmac_xcoff_vec): Remove.
2318 (TARGET_SYM, TARGET_NAME): Define.
2319 * coffcode.h (coff_set_arch_mach_hook) [POWERMAC]: Set the
2320 machine to 0, not all PowerMacs are 601s.
2321
2322Fri Nov 10 12:10:14 1995 Ian Lance Taylor <[email protected]>
2323
2324 * elfcode.h (elf_object_p): Read in any program headers.
2325 * elf.c (_bfd_elf_make_section_from_shdr): Adjust section lma
2326 based on the program headers, if any.
2327 (elf_fake_sections): Set sh_addr from the vma, not the lma.
2328 (map_program_segments): Set p_paddr of program headers based on
2329 the lma.
2330
ee174815
ILT
2331Thu Nov 9 13:01:31 1995 Ian Lance Taylor <[email protected]>
2332
839087b7
ILT
2333 * archive.c (bfd_generic_archive_p): Preserve tdata in case of
2334 failure.
2335
922530a6
ILT
2336 * aoutx.h (NAME(aout,final_link)): Report a reasonable error when
2337 trying to do a relocateable link with a non-a.out object file.
2338
2339 * archive.c (bfd_generic_archive_p): Check the first object file
2340 in an archive even if target_defaulted is set. If the object file
2341 has the wrong xvec, reject it.
2342
a1774c51
ILT
2343 * aoutx.h (NAME(aout,set_section_contents)): If a section can not
2344 be represented, report the name via _bfd_error_handler.
2345 (translate_to_native_sym_flags): Likewise.
2346 * elf32-mips.c (mips_elf_final_link): Likewise.
2347 * oasys.c (oasys_write_sections): Likewise.
2348
4a378b13
ILT
2349 * coffcode.h (coff_set_alignment_hook): Write RS6000COFF_C version
2350 which checks for STYP_OVRFLO sections.
2351 (coff_compute_section_file_positions): If RS6000COFF_C, handle
2352 reloc and lineno count overflows.
2353 (coff_write_object_contents): Call coff_count_linenumbers before
2354 coff_compute_section_file_positions. If RS6000COFF_C, handle
2355 reloc and lineno count overflows.
2356 * xcofflink.c (_bfd_xcoff_bfd_final_link): Count line numbers and
2357 relocs before dealing with .pad sections. Count overflow section
2358 headers when handling .pad sections.
2359
7906bf87
ILT
2360 * coffcode.h (coff_write_object_contents): Set a.out vstamp to 1
2361 if RS6000COFF_C.
2362
ee174815
ILT
2363 * xcofflink.c (XCOFF_DESCRIPTOR): Define.
2364 (struct xcoff_link_hash_table): Add descriptor_section and
2365 special_sections fields.
2366 (_bfd_xcoff_bfd_link_hash_table_create): Initialize new fields.
2367 (xcoff_link_add_symbols): Set linkage section alignment. Create
2368 descriptor section. Check for magic symbol names (_text, etc.),
2369 and record them in special_sections if found. Set
2370 XCOFF_DESCRIPTOR flag for a function descriptor, and set its
2371 descriptor field to point back to the function code symbol.
2372 (xcoff_sweep): Always mark the special descriptor_section.
2373 (bfd_xcoff_export_symbol): Check whether the symbol might be a
2374 function descriptor, and mark it if it is.
2375 (bfd_xcoff_size_dynamic_sections): Add new special_sections
2376 parameter, and fill it in. Allocate space for the descriptor
2377 section.
2378 (xcoff_build_ldsyms): Set XCOFF_DEF_REGULAR flag when defining
2379 global linkage code. If an undefined function descriptor is
2380 exported, arrange to define it. Warn about any other undefined
2381 exported symbol.
2382 (_bfd_xcoff_bfd_final_link): Write out the descriptor section.
2383 (xcoff_write_global_symbol): Create a function descriptor when
2384 necessary.
2385 * bfd-in.h (bfd_xcoff_size_dynamic_sections): Update declaration.
2386 * bfd-in2.h: Rebuild.
2387
0e829f18
KK
2388Thu Nov 9 08:40:23 1995 Kim Knuttila <[email protected]>
2389
2390 * coff-ppc.c (ppc_coff_link_hash_entry): new types for hashing
2391 (ppc_coff_link_hash_table): new types for hashing
2392 (ppc_coff_link_hash_newfunc): hash entry constructor
2393 (ppc_coff_link_hash_table_init): hash table initializer
2394 (ppc_coff_link_hash_table_create): hash table constructor
2395 (ppc_record_toc_entry): changed references to hash table
2396 (coff_ppc_relocate_section): changed references to hash table
2397
2398 * libcoff-in.h (coff_link_hash_entry): removed toc_offset
2399 * libcoff.h: Rebuild
2400
2401 * cofflink.c (_bfd_coff_link_hash_newfunc): removed toc_offset init
2402 (coff_link_add_symbols): removed toc_offset init
2403
7ac84736
KR
2404Thu Nov 9 04:00:38 1995 Ken Raeburn <[email protected]>
2405
b27cc4bc
KR
2406 * Makefile.in (.dep1): Make sure the file mkdep is to write exists
2407 first.
2408
7ac84736
KR
2409 * configure.in: Added new option --with[out]-mmap. Set USE_MMAP
2410 if it is given and mmep is available.
2411 * acconfig.h: Undef USE_MMAP.
2412 * configure, config.in: Regenerated.
2413 * aoutx.h: If USE_MMAP is not defined, do all symbol and string
2414 table handling the old way.
2415 (aout_get_external_symbols): Don't complain if last byte of string
2416 table is nonzero.
2417 * libbfd.c [HAVE_MADVISE]: Include sys/types.h and sys/mman.h.
2418 (bfd_free_window) [! USE_MMAP]: Don't define.
2419 (bfd_get_file_window,
2420 _bfd_generic_get_section_contents_in_window) [! USE_MMAP]: Abort.
2421
1b3b0c03
ILT
2422Wed Nov 8 20:03:44 1995 Eric Freudenthal <[email protected]>
2423
2424 * coff-a29k.c (SIGN_EXTEND_HWORD): Use ~0xffff rather than
2425 0xffff0000.
2426
092abcdf
ILT
2427Wed Nov 8 11:31:11 1995 Ian Lance Taylor <[email protected]>
2428
33698029
ILT
2429 * coff-a29k.c (a29k_reloc): Change handling of R_IREL reloc to be
2430 compatible with AMD generated COFF files. Try to support both AMD
2431 and GNU formats simultaneously.
2432 (coff_a29k_relocate_section): Likewise.
2433
0bb8ff19
ILT
2434 * libbfd.c (bfd_get_file_window): Change writable parameter from
2435 int to boolean; update all callers. Pass MAP_SHARED if not
2436 writable--it's required on Solaris. Cast fprintf argument to
2437 avoid warning.
2438 * bfd-in.h (bfd_get_file_window): Update declaration.
2439 * bfd-in2.h: Rebuild.
2440 * aoutx.h: Update calls to bfd_get_file_window.
2441
0634a431
ILT
2442 * xcofflink.c (XCOFF_DEF_DYNAMIC): Rename from XCOFF_REF_DYNAMIC.
2443 Change all uses.
2444 (xcoff_swap_ldhdr_in): New static function.
2445 (xcoff_swap_ldsym_in): New static function.
7812bf9c 2446 (xcoff_find_reloc): Handle the case of a single reloc correctly.
0634a431
ILT
2447 (xcoff_link_add_symbols): If we just created a descriptor, pass it
2448 to _bfd_generic_link_add_one_symbol, to save a hash lookup.
417acf22 2449 Handle XTY_ER/XMC_XO symbols correctly.
0634a431
ILT
2450 (xcoff_link_add_dynamic_symbols): Rewrite to read .loader symbols
2451 rather than normal symbol table.
417acf22
ILT
2452 (bfd_xcoff_import_symbol): It's not an error if the symbol is
2453 already defined with the same absolute value.
0634a431
ILT
2454 (xcoff_mark): When considering called symbols, check whether the
2455 descriptor is from a dynamic object, rather than the symbol
2456 itself.
2457 (xcoff_build_ldsyms): Likewise.
2458
092abcdf
ILT
2459 * libbfd.c (bfd_get_file_window): Change return type to boolean.
2460 Cast realloc and malloc return values. If malloc or realloc fail,
2461 set bfd_error_no_memory.
2462 * bfd-in.h (bfd_get_file_window): Change type to boolean.
2463 * bfd-in2.h: Rebuild.
2464
d6f41a7d
KK
2465Tue Nov 7 11:53:48 1995 Kim Knuttila <[email protected]>
2466
2467 * coff-ppc.c (ppc_record_toc_entry): new function.
2468 (in_reloc_p): changed return value.
2469 (coff_ppc_relocate_section): much rework.
2470 (ppc_allocate_toc_section): new function.
2471 (ppc_process_before_allocation): new function.
2472 (ppc_coff_swap_sym_in_hook): new function.
2473
2474 * cofflink.c (_bfd_coff_link_hash_newfunc): initialize toc_offset.
2475 (coff_link_add_symbols): initialize toc_offset.
2476
2477 * peicode.h (coff_swap_sym_in): Added coff_swap_sym_in_hook
2478 (coff_swap_aouthdr_out): Added more sections to the data
2479 dictionary for the pe file header. Also changed linker version
2480 number on the ppc side.
2481 (dir_names): small improvements to the dictionary printing.
2482 (pe_mkobject_hook): save the file level flags.
2483
2484 * libcoff-in.h (coff_link_hash_entry): added toc_offset field
2485 (pe_tdata): added real_flags field
2486 (coff_tdata): added local_toc_sym_map and access macro
2487
2488 * libcoff.h (coff_link_hash_entry): added toc_offset field
2489 (pe_tdata): added real_flags field
2490 (coff_tdata): added local_toc_sym_map and access macro
2491
2492 * coffcode.h (coff_set_alignment_hook): added hook for PE.
2493 (coff_mkobject): init for local_toc_sym_map
2494 (coff_write_object_contents): set the internal_a.magic to
2495 IMAGE_NT_OPTIONAL_HDR_MAGIC which appears to be what other
2496 ppc compilers use.
2497
6bc200f2
ILT
2498Tue Nov 7 13:48:58 1995 Ian Lance Taylor <[email protected]>
2499
c0971298
ILT
2500 * ecofflink.c (_bfd_ecoff_locate_line): Keep looking through stabs
2501 entries until both the line number address and the function name
2502 address are too large.
2503
6a468850
ILT
2504 * configure.in: Call AC_CHECK_PROG to find and cache AR.
2505 * configure: Rebuilt.
2506
6bc200f2
ILT
2507 * aclocal.m4 (BFD_CC_FOR_BUILD): Don't define CC_FOR_BUILD if it
2508 is defined in the environment.
2509
c44bf94c
JL
2510Tue Nov 7 10:57:24 1995 Jeffrey A Law ([email protected])
2511
2512 * som.c (som_get_section_contents_in_window): Define to use
2513 generic version.
2514
cf587de8
ILT
2515Mon Nov 6 17:13:15 1995 Harry Dolan <[email protected]>
2516
2517 * coff-i860.c: New file, based on coff-i386.c.
2518 * cpu-i860.c: New file, based on cpu-i386.c.
2519 * hosts/i860mach3.h: New file, based on hosts/i386mach3.h.
2520 * config.bfd (i860-*-mach3*, i860-*-osf1*, i860-*-coff*): New
2521 targets, using i860coff_vec.
2522 * configure.in (i860-*-mach3*, i860-*-osf1*): New hosts, using
2523 trad-core.o and hosts/i860mach3.h.
2524 (i860coff_vec): Use coff-i860.o and cofflink.o.
2525 * configure: Rebuild.
2526 * Makefile.in: Rebuild dependencies.
2527 (ALL_MACHINES): Add cpu-i860.o.
2528 (BFD32_BACKENDS): Add coff-i860.o.
2529 (CFILES): Add cpu-i860.c and coff-i860.c.
2530 * targets.c (i860coff_vec): Declare.
2531 (bfd_target_vector): Add &i860coff_vec.
2532 * archures.c (bfd_i860_arch): Declare.
2533 (bfd_archures_list): Add &bfd_i860_arch.
2534 * coffcode.h (coff_set_arch_mach_hook): Handle I860 magic number.
2535 (coff_set_flags): Handle bfd_arch_i860.
2536 (coff_write_object_contents): Handle I860 a.out magic number.
2537
83c23fca
ILT
2538Mon Nov 6 14:34:07 1995 Ian Lance Taylor <[email protected]>
2539
2540 * xcofflink.c (xcoff_link_add_symbols): Set the alignment power of
2541 the created .tc section to 2.
2542 (xcoff_mark): Don't keep a .loader reloc for a call to an
2543 undefined symbol when creating a shared library.
2544 (xcoff_build_ldsyms): When creating a shared library, generate
2545 global linkage code for a call to an undefined symbol.
2546
5d9eb9c3
KR
2547Sun Nov 5 21:44:13 1995 Ken Raeburn <[email protected]>
2548
2549 * Makefile.in (CFILES): Rebuild list from BFD_LIBS, ALL_MACHINES,
2550 BFD32_BACKENDS, BFD64_BACKENDS.
2551 (.dep1): Put mkdep output in a separate file.
2552 Rebuilt dependencies.
2553
ffacb892
KR
2554 * ecoff.c (_bfd_ecoff_slurp_armap): Cast _bfd_read_ar_hdr return
2555 value.
2556
4fe6d901
KR
2557 Permit use of mmap when available:
2558
2559 * configure.in: Check for mmap, madvise, mprotect.
2560 * config.in, configure: Regenerated.
2561
2562 * libbfd.c (struct _bfd_window_internal): Define type.
2563 (bfd_init_window, bfd_free_window, bfd_get_file_window): New
2564 functions.
2565 (ok_to_map): New static variable for debugging.
2566 (_bfd_generic_get_section_contents_in_window): New function.
2567 * bfd-in.h (bfd_window_internal): Declare type.
2568 (bfd_window): Define type.
2569 (bfd_init_window, bfd_free_window, bfd_get_file_window): Declare.
2570 * libbfd-in.h (_bfd_generic_get_section_contents_in_window):
2571 Declare.
2572
2573 * libaout.h (struct aoutdata): Add two window fields.
2574 (obj_aout_sym_window, obj_aout_string_window): New macros.
2575 * aoutx.h (some_aout_object_p): Initialize windows.
2576 (aout_get_external_symbols): Get symbol data and strings in
2577 windows instead of explicitly allocated buffers.
2578 (slurp_symbol_table): Free window instead of memory.
2579 (bfd_free_cached_info): Release windows instead of freeing storage
2580 directly.
2581 (aout_link_free_symbols): Ditto.
2582
2583 * targets.c (bfd_target): Add new field for
2584 get_section_contents_in_window.
2585 (BFD_JUMP_TABLE_GENERIC): Updated.
2586 * aout-adobe.c, aout-target.h, binary.c, bout.c, coff-alpha.c,
2587 coff-mips.c, elfxx-target.h, i386msdos.c, i386os9k.c, ieee.c,
2588 libcoff-in.h, oasys.c, srec.c, tekhex.c, versados.c: Added new
2589 macros for get_section_contents_in_window field.
2590
d9e771e3
FF
2591Sat Nov 4 12:23:26 1995 Fred Fish <[email protected]>
2592
2593 * core.c: Renamed to corefile.c
2594 * makefile.dos (OBJS): Change core.o to corefile.o
2595 * Makefile.in (CFILES, BFD_LIBS): Use corefile.c instead of core.c
2596
bf917766
SG
2597start-sanitize-gm
2598Sat Nov 4 10:16:54 1995 Stu Grossman ([email protected])
2599
2600 * config.bfd (mips*-*-magic*): Add bfd_elf32_bigmips_vec to
2601 targ_selvecs to allow debugging under Irix-5 native.
2602
2603end-sanitize-gm
583db7a8
ILT
2604Fri Nov 3 15:54:59 1995 Ian Lance Taylor <[email protected]>
2605
2606 * xcofflink.c (xcoff_link_add_symbols): Rename local variable sub
2607 to o. Clobber and restore the list of new csects around the call
2608 to _bfd_generic_link_add_one_symbol, in case it wants to report a
2609 linker error and the linker wants to read the symbol table. Reset
2610 the line number count of a real section even if it has no relocs.
2611 (_bfd_xcoff_bfd_final_link): If shared, set the DYNAMIC flag.
2612
2613 * coffgen.c (_bfd_coff_read_string_table): Warn if the string size
2614 is too small.
2615
68aed7db
ILT
2616Thu Nov 2 23:16:39 1995 Ian Lance Taylor <[email protected]>
2617
18a9609c
ILT
2618 * xcofflink.c (_bfd_ppc_xcoff_relocate_section): Don't warn about
2619 an undefined symbol in a shared link.
2620
68aed7db
ILT
2621 * linker.c (_bfd_generic_link_add_one_symbol): Correct type of
2622 oldtype from bfd_link_order_type to bfd_link_hash_type. From
2623 [email protected] (Philippe De Muyter).
2624
7f82c7e1
ILT
2625Wed Nov 1 14:26:02 1995 Manfred Hollstein KS/EF4A 60/1F/110 #40283 <[email protected]>
2626
2627 * coff-m88k.c (rtype2howto): New static function.
2628 (RTYPE2HOWTO): Use it rather than a macro definition.
2629
2630 * coffcode.h (coff_write_object_contents): set internal_a.magic
2631 to PAGEMAGICPEXECPAGED #if defined (M68) && !defined (LYNXOS).
2632
4c8b9746 2633 * configure.in: m68*-motorola-sysv* does not use ptrace-core.o;
7f82c7e1
ILT
2634 define TRAD_HEADER to new file hosts/delta68.h.
2635 m88*-motorola-sysv*, however, does use ptrace-core.o.
2636 * hosts/delta68.h: New file.
2637
2638 * ptrace-core.c (ptrace_unix_core_file_p): change bfd_zmalloc to
2639 bfd_zalloc; provide proper parm abfd to calls to bfd_zalloc.
2640
619c7730
KR
2641Wed Nov 1 13:51:54 1995 Ken Raeburn <[email protected]>
2642
2643 * i386linux.c (MY(vec)): Declare before use.
2644
73246ff8
ILT
2645Wed Nov 1 11:45:07 1995 Ian Lance Taylor <[email protected]>
2646
e8d6d5d0
ILT
2647 * reloc16.c (bfd_coff_reloc16_get_relocated_section_contents):
2648 Pass input_bfd, not in_bfd, to bfd_coff_reloc16_extra_cases.
2649
b2193cc5
ILT
2650 * elf.c (bfd_elf_set_dt_needed_name): Don't do anything if the
2651 BFD is not of the right type.
2652 (bfd_elf_get_needed_list): Likewise.
2653 * i386linux.c (bfd_linux_size_dynamic_sections): Likewise.
2654 * sunos.c (bfd_sunos_get_needed_list): Likewise.
2655 * xcofflink.c (XCOFF_XVECP): Define.
2656 (bfd_xcoff_link_record_set): Don't do anything if the BFD is not
2657 of the right type.
2658 (bfd_xcoff_import_symbol): Likewise.
2659 (bfd_xcoff_export_symbol): Likewise.
2660 (bfd_xcoff_link_count_reloc): Likewise.
2661 (bfd_xcoff_record_link_assignment): Likewise.
2662 (bfd_xcoff_size_dynamic_sections): Likewise.
2663
baabeb74
ILT
2664 * sunos.c (sunos_scan_ext_relocs): Only check the reloc symbol
2665 table index against the number of symbols for a base relative
2666 reloc.
2667
73246ff8
ILT
2668 * coff-rs6000.c (_bfd_xcoff_sizeof_headers): Change from macro to
2669 static function.
2670 * xcofflink.c (_bfd_xcoff_bfd_link_hash_table_create): Set
2671 full_aouthdr flag here...
2672 (_bfd_xcoff_bfd_final_link): ...not here.
2673
6ab826bd
FF
2674Tue Oct 31 12:52:02 1995 Fred Fish <[email protected]>
2675
2676 * libelf.h: Rename to elf-bfd.h to avoid conflict with
2677 systems that have a system <libelf.h>.
2678 * Makefile.in: Globally replace libelf.h with elf-bfd.h.
2679 * bfd.c, elf.c, elf32-arc.c, elf32-gen.c, elf32-hppa.c,
2680 elf32-hppa.h, elf32-i386.c, elf32-i860.c, elf32-m68k.c,
2681 elf32-m88k.c, elf32-mips.c, elf32-ppc.c, elf32-sparc.c,
2682 elf64-gen.c, elf64-sparc.c, elfcode.h, elflink.c,
2683 elfxx-target.h: Include elf-bfd.h rather than libelf.h.
2684 * elfxx-target.h: Change libelf.h reference to elf-bfd.h.
2685
999cc186
ILT
2686Tue Oct 31 15:30:07 1995 David Mosberger-Tang <[email protected]>
2687
0652d579
ILT
2688 * ecoff.c (ecoff_set_symbol_info): Add new parameter weak. If
2689 set, set BSF_WEAK in symbol. Change all callers.
2690 (ecoff_get_extr): Set weakext based on BSF_WEAK.
2691 (ecoff_link_add_externals): If weakext is set, pass BSF_WEAK to
2692 _bfd_generic_link_add_one_symbol.
2693 (ecoff_indirect_link_order): Check that the section tdata relocs
2694 are not NULL before using them.
2695
999cc186
ILT
2696 * configure.in (alpha*-*-linux*): Set COREFILE to trad-core.o and
2697 define TRAD_HEADER as hosts/alphalinux.h.
2698 * configure: Rebuild.
2699 * hosts/alphalinux.h: New file.
2700 * trad-core.c (trad_unix_core_file_p): Cast u.u_ar0 to bfd_vma,
2701 not int.
2702
e6080520
ILT
2703Tue Oct 31 12:34:11 1995 Ian Lance Taylor <[email protected]>
2704
2bd0aeb9
ILT
2705 * coffcode.h (coff_slurp_symbol_table): Accept C_BCOMM and
2706 C_ECOMM storage classes.
2707
e6080520
ILT
2708 * xcofflink.c (xcoff_mark_symbol): New static function, broken out
2709 of xcoff_mark.
2710 (xcoff_mark): Call xcoff_mark_symbol.
2711 (bfd_xcoff_export_symbol): Call xcoff_mark_symbol.
2712 (bfd_xcoff_link_count_reloc): Call xcoff_mark_symbol rather than
2713 doing it by hand.
2714 (xcoff_build_ldsyms): Build a .loader symbol for an export symbol.
2715
5fe14a9f
ILT
2716Mon Oct 30 14:53:48 1995 Ian Lance Taylor <[email protected]>
2717
f630a0a4
ILT
2718 * xcofflink.c (struct xcoff_final_link_info): Add new line_filepos
2719 field.
2720 (xcoff_find_reloc): New static function.
2721 (xcoff_link_add_symbols): Use it.
2722 (_bfd_xcoff_bfd_final_link): Set finfo.line_filepos.
2723 (xcoff_link_input_bfd): Handle C_BINCL and C_EINCL. Don't
2724 relocate the value of C_DECL.
2725
5fe14a9f
ILT
2726 * elf.c (elf_fake_sections): Remove bogus BFD_ASSERT.
2727
dff77ed7
SC
2728Sat Oct 28 01:25:34 1995 steve chamberlain <[email protected]>
2729
2730 * cofflink.c (_bfd_coff_generic_relocate_section): Make
2731 callback decide what goes in .relocs.
2732 * pe[i]-i386.c (TARGET_UNDERSCORE): Define.
2733 * peicode.h (pe_mkobject_hook): Only copy aouthdr if
2734 there is one.
2735
697a8fe8
ILT
2736Sat Oct 28 01:51:02 1995 Ian Lance Taylor <[email protected]>
2737
2738 * xcofflink.c (xcoff_link_add_symbols): Handle csects in the
2739 absolute section.
2740
2d7de17d
ILT
2741Fri Oct 27 18:14:39 1995 Ian Lance Taylor <[email protected]>
2742
2743 * xcofflink.c: More improvements, mostly to fix handling of
2744 constructors and a few other special cases.
2745 * coff-rs6000.c (rs6000coff_vec): Set symbol_leading_char back to
2746 zero, reverting yesterday's change.
2747 * bfd-in.h (bfd_xcoff_link_record_set): Declare.
2748 (bfd_xcoff_link_count_reloc): Declare.
2749 (bfd_xcoff_record_link_assignment): Declare.
2750 * bfd-in2.h: Rebuild.
2751
f552f751
NH
2752Fri Oct 27 14:42:15 1995 Niklas Hallqvist <[email protected]>
2753
2754 * PORTING, aout-arm.c, aout-encap.c, aout-rce.c, aout-target.h,
2755 aoutx.h, gen-aout.c, host-aout.c, hp300bsd.c, i386aout.c
2756 i386bsd.c, i386dynix.c, i386linux.c, i386lynx.c, i386mach3.c,
2757 i386netbsd.c, m68klynx.c, m88kmach3.c, mipsbsd.c, newsos3.c,
2758 ns32knetbsd.c, pc532-mach.c, riscix.c, sparclynx.c, sparcnetbsd.c:
2759 Change PAGE_SIZE to TARGET_PAGE_SIZE.
2760
2761 * m68knetbsd.c: Ditto as well as add support for the m68k4k object
2762 format.
2763
2764 * netbsd.h: Double ditto (incl. m68k4k support). NetBSD's text
2765 segments includes the a.out header. See to that the magic number
2766 *always* is big-endian.
2767
2768 * config.bfd: Add m68*-hp*-netbsd* case. Cross-pollinate m68k and
2769 m68k4k NetBSD configurations.
2770
2771 * configure.in, configure: Separate i386 & mips NetBSD
2772 configurations from other BSD ones. Don't assume DEC is the only
2773 thing NetBSD/mips run on. Add {m68k,ns32k,sparc}-*-netbsd*
2774 configurations. Add support for m68k4k NetBSD object format.
2775
2776 * libaout.h: Added M_68K4K_NETBSD magic.
6fd1f40d
NH
2777
2778 * m68k4knetbsd.c: New file.
f552f751
NH
2779
2780 * hosts/{m68k,sparc}nbsd.h: Don't define HOST_BIG_ENDIAN_P.
2781
2782 * hosts/nbsd.h: Define HOST_BIG_ENDIAN_P according to
2783 <machine/endian.h>.
2784
6fd1f40d
NH
2785 * hosts/mipsnbsd.h: New file.
2786
d6d44ef9
SG
2787start-sanitize-gm
2788Fri Oct 27 09:41:51 1995 Stu Grossman ([email protected])
2789
2790 * config.bfd: Add config stuff for mips*-*-magic* to set
2791 targ_defvec to ecoff_big_vec.
2792
2793end-sanitize-gm
867d923d
ILT
2794Thu Oct 26 14:16:47 1995 Ian Lance Taylor <[email protected]>
2795
2796 * xcofflink.c: Numerous changes to get closer to a working XCOFF
2797 linker.
2798 * libcoff-in.h (struct xcoff_tdata): Add full_aouthdr,
2799 toc_section, and entry_section fields.
2800 (struct xcoff_section_tdata): Remove ldrel_count field.
2801 * libcoff.h: Rebuild.
2802 * coffcode.h (coff_mkobject_hook): Initialize new xcoff_data
2803 fields.
2804 (coff_compute_section_file_positions): If RS6000COFF_C, generate
2805 full a.out header if full_aouthdr is set in xcoff_data.
2806 (coff_write_object_contents): Likewise. Set o_snentry and o_sntoc
2807 based on sections stored in xcoff_data.
2808 * coff-rs6000.c (xcoff_copy_private_bfd_data): Copy new xcoff_data
2809 fields.
aad2c618
ILT
2810 (xcoff_reloc_type_lookup): Handle BFD_RELOC_CTOR.
2811 (rs6000coff_vec): Set symbol_leading_char to '.'.
867d923d
ILT
2812 * coffgen.c (coff_get_symbol_info): If fix_value is set, fix the
2813 value stored in ret rather than returning a pointer value.
2814
6bd9ffdb
MM
2815Wed Oct 25 23:10:39 1995 Michael Meissner <[email protected]>
2816
2817 * config.bfd (powerpc{,le}-{elf,sysv4,eabi,solaris2}): Remove MAC
2818 format for now.
2819
9d14250f
JL
2820Wed Oct 25 16:19:27 1995 Jeffrey A Law ([email protected])
2821
2822 * som.c (som_slurp_string_table): Allocate the strings with malloc
2823 since they're free'd by free_cached_info.
2824 (som_slurp_symbol_table): Similarly for the symbol table.
2825
a2bd0529
PB
2826Wed Oct 25 14:59:22 1995 Per Bothner <[email protected]>
2827
2828 * Makefile.in (diststuff): Don't make headers.
2829
28a0c103
ILT
2830Wed Oct 25 11:32:54 1995 Ian Lance Taylor <[email protected]>
2831
356cd465
ILT
2832 * Makefile.in: Rebuild dependencies.
2833
1edd3a7b
ILT
2834 * sunos.c (bfd_sunos_record_link_assignment): Don't do anything if
2835 output_bfd is not SunOS.
2836 (bfd_sunos_size_dynamic_sections): Likewise. Don't scan relocs of
2837 non-SunOS input files.
2838
28a0c103
ILT
2839 * xcofflink.c: Extensive changes to support linking shared objects
2840 and generating a .loader section.
2841 * libcoff-in.h (struct xcoff_tdata): Add import_file_id field.
b73322d9
ILT
2842 (struct xcoff_section_tdata): Add lineno_count, first_symndx,
2843 last_symndx, and ldrel_count fields.
28a0c103
ILT
2844 * libcoff.h: Rebuild.
2845 * coff-rs6000.c (xcoff_howto_table): Correct reloc names.
2846 * coffcode.h (styp_to_sec_flags): Don't set any flags if STYP_PAD
2847 is set.
2848 * bfd-in.h (bfd_xcoff_import_symbol): Declare.
2849 (bfd_xcoff_export_symbol): Declare.
2850 (bfd_xcoff_size_dynamic_sections): Declare.
2851 * bfd-in2.h: Rebuild.
2852
aadf04f7
SS
2853Tue Oct 24 17:44:20 1995 Stan Shebs <[email protected]>
2854
2855 * configure.in: Add xcofflink.o to pmac_xcoff_vec.
2856 * configure: Rebuild.
2857 * mpw-config.in: Add xcofflink.c.o to powerpc-apple-macos.
2858 * coff-pmac.c: Include coff-rs6000.c instead of duplicating its
2859 contents.
2860 (pmac_xcoff_vec): Update to use new xcoff support.
2861 * coff-rs6000.c (xcoff_generic_stat_arch_elt): Make static.
2862 (xcoff_write_armap): Declare buf as unsigned char.
2863 * xcofflink.c (xcoff_link_add_symbols): Declare a local as PTR.
2864
2865 * mpw-make.sed: Generalize subdir_do edit.
2866
ddf4639b
JL
2867Tue Oct 24 10:25:01 1995 Jeffrey A Law ([email protected])
2868
2869 * hppabsd-core.c (make_bfd_asection): Initialize asect->filepos
2870 correctly. Don't initialize asect->vma.
2871
e7bedf65
KR
2872Fri Oct 20 13:23:48 1995 Ken Raeburn <[email protected]>
2873
2874 * opncls.c (_bfd_new_bfd): If _bfd_chunksize wasn't preset, use
2875 something a little less than the page size.
2876
2877Thu Oct 19 13:06:09 1995 Ian Lance Taylor <[email protected]>
2878
2879 * coff-i960.c (coff_i960_adjust_symndx): Clear *adjustedp.
2880
3a70e298
SC
2881Wed Oct 18 16:20:08 1995 steve chamberlain <[email protected]>
2882
2883 * coff-i386.c (coff_i386_reloc_type_lookup): New.
2884 * coffcode.h (coff_write_object_contents): If .bss is before
2885 .data us that as data_start.
2886 * cofflink.c (_bfd_coff_generic_relocate_section): Get reloc
2887 calc correct.
2888 * peicode.h (add_data_entry): Use _cooked_size of data directory.
2889 (coff_swap_outhdr_out): Hardwire in version number.
2890
5a2846e3
KR
2891Wed Oct 18 16:50:54 1995 Ken Raeburn <[email protected]>
2892
3c3a5268
KR
2893 * sunos.c (sunos_add_dynamic_symbols): Rename local variables
2894 major and minor to *_vno, since the former are also macros in
2895 SunOS header files. Cast result of bfd_alloc to appropriate
2896 type.
2897
5a2846e3
KR
2898 * coffgen.c (coff_find_nearest_line): Cast used_by_bfd value
2899 before assigning to sec_data.
2900
0f6c885e
ILT
2901Wed Oct 18 13:25:17 1995 Ian Lance Taylor <[email protected]>
2902
2903 * ecoff.c (_bfd_ecoff_find_nearest_line): The offset argument is
2904 now relative to the section, not absolute.
2905 * ecofflink.c (_bfd_ecoff_locate_line): Use the right symbol to
2906 get the file name when there is a N_SO directory name. When
2907 handling stabs, remember that section->vma was added to the
2908 offset.
2909
11fa6636
ILT
2910Tue Oct 17 18:24:54 1995 Ian Lance Taylor <[email protected]>
2911
2912 * sunos.c (struct sunos_link_hash_table): Add needed field.
2913 (sunos_link_hash_table_create): Call bfd_release, not free.
2914 (sunos_link_hash_table_create): Initialize needed field.
2915 (sunos_add_dynamic_symbols): Record needed objects.
2916 (bfd_sunos_get_needed_list): New function.
2917 * bfd-in.h (bfd_sunos_get_needed_list): Declare.
2918 * bfd-in2.h: Rebuild.
2919
c974e19e
SC
2920Mon Oct 16 14:43:59 1995 steve chamberlain <[email protected]>
2921
2922 * libcoff-in.h (pe_data_type.in_reloc_p): New.
2923
22a35f0b
ILT
2924Mon Oct 16 10:52:50 1995 Ian Lance Taylor <[email protected]>
2925
54406786
ILT
2926 * bfd-in.h (struct bfd_link_needed_list): Rename from
2927 bfd_elf_link_needed_list.
2928 * bfd-in2.h: Rebuild.
2929 * elf.c, elflink.h, libelf.h: Corresponding changes.
2930
dd984644
ILT
2931 Add start at AIX linker support; no shared libraries yet.
2932 * xcofflink.c: New file.
2933 * configure.in (rs600coff_vec): Use xcofflink.o.
2934 * configure: Rebuild.
2935 * libcoff-in.h (struct xcoff_tdata): Add csects and debug_indices
2936 fields.
2937 (struct xcoff_section_tdata): Define.
2938 (xcoff_section_data): Define macro.
2939 (_bfd_xcoff_bfd_link_hash_table_create): Declare.
2940 (_bfd_xcoff_bfd_link_add_symbols): Declare.
2941 (_bfd_xcoff_bfd_final_link): Declare.
2942 (_bfd_ppc_xcoff_relocate_section): Declare.
2943 * libcoff.h: Rebuild.
2944 * coff-rs6000.c: Clean up a bit.
2945 (xcoff_mkobject): Default modtype to 1L, not RE. Initialize
2946 cputype, csects, and debug_indices.
2947 (xcoff_copy_private_bfd_data): Copy cputype.
2948 (xcoff_howto_table): Rename from rs6000coff_howto_table.
2949 (xcoff_rtype2howto): Rename from rs6000coff_rtype2howto.
2950 (xcoff_reloc_type_lookup): Rename from
2951 rs6000coff_reloc_type_lookup.
2952 (coff_relocate_section): Define.
2953 (_bfd_xcoff_sizeof_headers): Define.
2954 (_bfd_xcoff_bfd_get_relocated_section_contents): Define.
2955 (_bfd_xcoff_bfd_relax_section): Define.
2956 (_bfd_xcoff_bfd_link_split_section): Define.
2957 (rs6000coff_vec): For BFD_JUMP_TABLE_LINK, use _bfd_xcoff, not
2958 coff.
2959 * coffcode.h (coff_compute_section_file_positions): If AIX,
2960 increment sofar by SMALL_AOUTSZ if not executable.
2961 (coff_write_object_contents): If AIX, always output an a.out
2962 header; if not executable, header size of SMALL_AOUTSZ.
2963 * hash.c (struct bfd_strtab_hash): Add xcoff field.
2964 (_bfd_stringtab_init): Initialize xcoff field.
2965 (_bfd_xcoff_stringtab_init): New function.
2966 (_bfd_stringtab_add): In XCOFF mode, leave two bytes for length.
2967 (_bfd_stringtab_emit): In XCOFF mode, write out length.
2968 * libbfd-in.h (_bfd_xcoff_stringtab_init): Declare.
2969 * libbfd.h: Rebuild.
2970 * Makefile.in: Rebuild dependencies.
2971 (BFD32_BACKENDS): Add xcofflink.o.
2972 (CFILES): Add xcofflink.c.
2973
22a35f0b
ILT
2974 * elf32-mips.c (mips_elf_symbol_processing): Set SEC_ALLOC, not
2975 SEC_NO_FLAGS, for .acommon section. From Peter Schauer
2976 <[email protected]>.
2977
fb417a21
MM
2978Sat Oct 14 21:36:02 1995 Michael Meissner <[email protected]>
2979
2980 * coff-ppc.c (in_reloc_p): Add, clone from coff-i386.c.
2981
2982Fri Oct 13 17:48:43 1995 Ken Raeburn <[email protected]>
2983
2984 * acconfig.h (HAVE_SYS_PROCFS_H): Undef, with comment.
2985 * config.in: Regenerated.
2986
2987 * opncls.c (getpagesize) [!HAVE_GETPAGESIZE]: Define as 2048.
2988 (_bfd_chunksize): New variable.
2989 (_bfd_new_bfd): Set it to getpagesize() if negative, and use it
2990 for obstack chunk size.
2991 * configure.in: Check for getpagesize.
2992 * configure: Regenerated.
2993
2994 Mon Sep 25 22:49:32 1995 Andreas Schwab <[email protected]>
2995
2996 * trad-core.c (rawptr): Make it a local variable of
2997 ptrace_unix_core_file_p.
2998
b1e46369
SC
2999Fri Oct 13 11:22:01 1995 steve chamberlain <[email protected]>
3000
3001 * coff-arm.c (in_reloc_p): New.
3002 * coff-i386.c (in_reloc_p): New.
3003 * coffcode.h: Allways include peicode.h if COFF_WITH_PE.
3004 (coff_write_object_contents): Only set has_reloc_section
3005 if PE_IMAGE.
3006 * cofflink.c (_bfd_coff_generic_relocate_section): Call
3007 in_reloc_p to decide if reloc should be emitted.
3008 * libcoff.h (pe_data_type.in_reloc_p): New.
3009 * peicode.h (pe_mkobject): Initialize in_reloc_p.
3010
ee9f09cd
ILT
3011Wed Oct 11 00:49:29 1995 Ian Lance Taylor <[email protected]>
3012
b1e46369
SC
3013 * cofflink.c (_bfd_coff_internal_syment_name): Move to coffgen.c.
3014 (_bfd_coff_read_internal_relocs): Likewise.
3015 * coffgen.c (_bfd_coff_internal_syment_name): Copy from coffgen.c.
3016 (_bfd_coff_read_internal_relocs): Likewise.
3017
ee9f09cd
ILT
3018 * elflink.h (elf_link_add_object_symbols): Correct conditions
3019 under which type and size change warnings are issued.
3020
78b31b6b
ILT
3021Tue Oct 10 18:32:46 1995 Ian Lance Taylor <[email protected]>
3022
3023 * coffgen.c (coff_count_linenumbers): Don't count line numbers for
3024 a symbol which is not in a real section.
3025 (coff_write_native_symbol): Corresponding change.
3026
3027 * cofflink.c (_bfd_coff_link_hash_newfunc): Rename from
3028 coff_link_hash_newfunc and make non-static.
3029 (_bfd_coff_link_hash_table_init): New function, broken out of
3030 _bfd_coff_link_hash_table_create.
3031 (_bfd_coff_link_hash_table_create): Use it.
3032 (process_embedded_commands): Make static.
3033 * libcoff-in.h ((_bfd_coff_link_hash_newfunc): Declare.
3034 (_bfd_coff_link_hash_table_init): Declare.
3035 * libcoff.h: Rebuild.
3036
3037 * coffcode.h (coff_mkobject_hook): If RS6000COFF_C, set cputype
3038 field in XCOFF tdata.
3039 (coff_set_arch_mach_hook): Check ifdef RS6000COFF_C, not ifdef
3040 U802ROMAGIC, for clarity. Try to set arch and machine correctly
3041 based on cputype stored in a.out header, or in n_type of initial
3042 .file symbol.
3043 (coff_write_object_contents): Set cputype correctly in a.out
3044 header.
3045 (coff_slurp_symbol_table): Add casts to file_ptr to avoid
3046 warnings.
3047 * coffswap.h (coff_swap_aouthdr_in): Swap in cputype field.
3048 (coff_swap_aouthdr_out): Swap out cputype field. Don't clear
3049 old resv1 field.
3050 * libcoff-in.h (struct xcoff_tdata): Add cputype field.
3051 * libcoff.h: Rebuild.
3052
3053 * cpu-rs6000.c (rs6000_compatible): New static function.
3054 (bfd_rs6000_arch): Use it.
3055 * cpu-powerpc.c (powerpc_compatible): New static function.
3056 (arch_info_struct): Define various flavours of PowerPC.
3057 (bfd_powerpc_arch): Use powerpc_compatible. Point at
3058 arch_info_struct.
3059
9dd7e56f
FF
3060Tue Oct 10 10:50:46 1995 Fred Fish <[email protected]>
3061
78b31b6b 3062 * Makefile.in (FLAGS_TO_PASS): Remove BISON.
9dd7e56f 3063
8235c112
ILT
3064Tue Oct 10 01:28:29 1995 Ian Lance Taylor <[email protected]>
3065
3066 * elflink.h (elf_link_add_object_symbols): Don't warn about
3067 changing the size or type if the old definition was weak.
3068
0322af0d
ILT
3069Mon Oct 9 11:24:08 1995 Ian Lance Taylor <[email protected]>
3070
49488f2b
ILT
3071 * coffcode.h (combined_entry_type): Add fix_line field.
3072 (coff_slurp_line_table): Warn if we try to set the lineno field of
3073 a symbol twice.
3074 (coff_slurp_symbol_table): If RS6000COFF_C, handle C_BINCL and
3075 C_EINCL by setting fix_line. Fix C_BSTAT symbol value.
3076 * coffgen.c (coff_mangle_symbols): Handle fix_line.
3077 (coff_write_symbol): Only use N_DEBUG if the symbol is in the
3078 absolute section.
3079 (coff_print_symbol): Print fix_value symbols in a useful fashion.
3080 * libcoff.h: Rebuild.
3081
5f710a3a
ILT
3082 * libcoff-in.h (struct xcoff_tdata): Define.
3083 (xcoff_data): Define.
3084 * bfd.c (struct _bfd): Add xcoff_obj_data field to tdata union.
3085 * bfd-in2.h, libcoff.h: Rebuild.
3086 * coff-rs6000.c (xcoff_mkobject): New static function.
3087 (coff_mkobject): Define.
3088 (xcoff_copy_private_bfd_data): New static function.
3089 (coff_bfd_copy_private_bfd_data): Define.
3090 (rs6000coff_howto_table): Change R_TOC complain_on_overflow from
3091 signed to bitfield.
3092 (rs6000coff_vec): Add DYNAMIC to object_flags.
3093 * coffcode.h (sec_to_styp_flags): If RS6000COFF_C, handle .pad and
3094 .loader sections specially.
3095 (coff_new_section_hook): If RS6000COFF_C, get the .text and .data
3096 section alignment from the XCOFF tdata information.
3097 (coff_mkobject_hook): If RS6000COFF_C, set DYNAMIC based on
3098 F_SHROBJ, and copy the extra a.out header information into the
3099 XCOFF tdata structure.
3100 (coff_write_object_contents): If RS6000COFF_C, set F_SHROBJ,
3101 F_DYNLOAD and the extra a.out header information.
3102 (coff_slurp_symbol_table): Set BSF_NOT_AT_END for a C_EXT or
3103 C_HIDEXT symbol with attached csect information.
3104 * coffswap.h (coff_swap_aouthdr_in): If RS6000COFF_C, swap
3105 in the o_maxdata field.
3106 (coff_swap_aouthdr_out): If RS6000COFF_C, swap extra XCOFF fields.
3107 * coffgen.c (coff_renumber_symbols): Don't move any symbol to the
3108 end if BSF_NOT_AT_END is set.
3f2c5b2d 3109
0322af0d
ILT
3110 * targets.c (bfd_target): Rename _bfd_read_ar_hdr field to
3111 _bfd_read_ar_hdr_fn.
3112 * libbfd-in.h (_bfd_read_ar_hdr): Update accordingly.
3113 * bfd-in2.h, libbfd.h: Rebuild.
3114 * archive.c (_bfd_get_elt_at_filepos): Cast _bfd_read_ar_hdr
3115 return value.
3116 (do_slurp_bsd_armap, do_slurp_coff_armap): Likewise.
3117 (bfd_slurp_bsd_armap_f2): Likewise.
3118 (_bfd_slurp_extended_name_table): Likewise.
3119
3266eaff
KR
3120Fri Oct 6 16:18:35 1995 Ken Raeburn <[email protected]>
3121
3122 Mon Sep 25 22:49:32 1995 Andreas Schwab <[email protected]>
3123
3124 * archive.c (bfd_get_next_mapent): Return BFD_NO_MORE_SYMBOLS
3125 when the symbol table is empty.
3126
3127 * elf32-m68k.c (elf_m68k_size_dynamic_sections): Don't reserve
3128 space for section symbols, since we don't output them either.
3129 (elf_m68k_adjust_dynindx): Removed.
3130
3131 * ptrace-core.c (rawptr): Make it a local variable of
3132 ptrace_unix_core_file_p.
3266eaff 3133
249479fa
MM
3134Fri Oct 6 12:24:47 1995 Michael Meissner <[email protected]>
3135
45b5d2f0
MM
3136 * coff-rs6000.c (xcoff_write_archive_contents): Return false, not
3137 NULL.
3138
249479fa
MM
3139 * config.bfd (powerpc{,le}-{elf,sysv4,eabi,solaris2}): Add NT, and
3140 Mac object file formats.
3141
c53fac12
ILT
3142Fri Oct 6 12:04:02 1995 Ian Lance Taylor <[email protected]>
3143
4372f33f
ILT
3144 * coffgen.c (coff_fix_symbol_name): Don't try to set up file
3145 auxent if there isn't one.
3146 (coff_write_symbols): If there is no file auxent, use SYMNMLEN
3147 rather than FILNMLEN as the maximum name length.
3148
0fc9ada9
ILT
3149 * coffcode.h (bfd_coff_backend_data): Add new field
3150 _bfd_coff_print_aux.
3151 (bfd_coff_print_aux): New static function.
3152 (coff_pointerize_aux_hook (RS6000COFF_C version)): Pointerize the
3153 scnlen field of an XTY_LD csect aux entry.
3154 (coff_print_aux): New static function.
3155 (coff_slurp_symbol_table): Don't pointerize scnlen field; now done
3156 in coff_pointerize_aux_hook.
3157 (bfd_coff_std_swap_table): Initialize new field.
3158 * coffgen.c (coff_print_symbol): Call bfd_coff_print_aux.
3159 * libcoff.h: Rebuild.
3160 * coff-alpha.c (alpha_ecoff_backend_data): Initialize new field.
3161 * coff-mips.c (mips_ecoff_backend_data): Likewise.
3162
7860fe38
ILT
3163 * coffcode.h (coff_write_object_contents): On AIX, clear F_RELFLG
3164 if there are symbols, for native AIX ld compatibility.
3165
c80cc833
ILT
3166 * coffcode.h (bfd_coff_backend_data): Add new field
3167 _bfd_coff_pointerize_aux_hook.
3168 (coff_pointerize_aux_hook): Define as a function if RS6000COFF_C
3169 or I960, and as 0 otherwise.
3170 (bfd_coff_std_swap_table): Initialize new field.
3171 * libcoff.h: Rebuild.
3172 * coffgen.c (coff_pointerize_aux): Change parameters to take
3173 symbol pointer instead of type and class, and to take aux index.
3174 Call _bfd_coff_pointerize_aux_hook if it is defined.
3175 (coff_get_normalized_symtab): Always call coff_pointerize_aux.
3176 * coff-alpha.c (alpha_ecoff_backend_data): Initialize all fields.
3177 * coff-mips.c (mips_ecoff_backend_data): Likewise.
3178
c53fac12
ILT
3179 * coff-rs6000.c: Add full support for AIX archives. Rewrite old
3180 read-only/host-only support.
3181
3182 * coffcode.h (coff_slurp_symbol_table): Set C_HIDEXT symbols to be
3183 BSF_LOCAL.
d11e6b52
ILT
3184 (OTHER_GLOBAL_CLASS): Do not define to be C_HIDEXT if
3185 RS6000COFF_C.
c53fac12
ILT
3186
3187 * targets.c (bfd_target): Add _bfd_read_ar_hdr field. Modify
3188 BFD_JUMP_TABLE_ARCHIVE accordingly.
3189 * libbfd-in.h (_bfd_snarf_ar_hdr): Don't declare.
3190 (_bfd_compute_and_write_armap): Declare.
3191 (_bfd_generic_read_ar_hdr): Declare.
3192 (_bfd_read_ar_hdr): Define.
3193 (_bfd_noarchive_read_ar_hdr): Define.
3194 (_bfd_archive_bsd_read_ar_hdr): Define.
3195 (_bfd_archive_coff_read_ar_hdr): Define.
3196 * archive.c: Change all callers of _bfd_snarf_ar_hdr to call
3197 _bfd_read_ar_hdr instead.
3198 (_bfd_generic_read_ar_hdr): Rename from _bfd_snarf_ar_hdr.
3199 (_bfd_compute_and_write_armap): Rename from
3200 compute_and_write_armap. Make non-static. Change all callers.
3201 * ecoff.c (_bfd_ecoff_slurp_armap): Call _bfd_read_ar_hdr rather
3202 than _bfd_snarf_ar_hdr.
3203 * aout-target.h (MY_read_ar_hdr): Define if not defined.
3204 * ieee.c (ieee_read_ar_hdr): Define.
3205 * libecoff.h (_bfd_ecoff_read_ar_hdr): Define.
3206 * oasys.c (oasys_read_ar_hdr): Define.
3207 * som.c (som_read_ar_hdr): Define.
3208 * bfd-in2.h, libbfd.h: Rebuild.
3209
f8e47484
SC
3210Thu Oct 5 14:04:07 1995 steve chamberlain <[email protected]>
3211
3212 * peicode.c (coff_swap_filehdr_in): If symptr is
3213 zero, there aren't any symbols, even if nsyms is set.
3214
2b874a2d
ILT
3215Thu Oct 5 11:45:02 1995 Ian Lance Taylor <[email protected]>
3216
aca73687
ILT
3217 * libecoff.h (struct ecoff_backend_data): Add adjust_headers
3218 field.
3219 * ecoff.c (ecoff_sec_to_styp_flags): Check for various Alpha
3220 sections, and set styp correctly for them: .got, .hash, .dynamic,
3221 .liblist, .rel.dyn, .conflic, .dynstr, .dynsym, .comment.
3222 (_bfd_ecoff_styp_to_sec_flags): Check for various Alpha section
3223 types.
3224 (ecoff_sort_hdrs): New static function.
3225 (ecoff_compute_section_file_positions): Return boolean, not void.
3226 Sort the sections by VMA before looking through them. Put the
3227 first non SEC_ALLOC section on a new page. Put every SEC_ALLOC
3228 section on an appropriate boundary within the page.
3229 (ecoff_compute_reloc_file_positions): Check return value of
3230 ecoff_compute_section_file_positions.
3231 (_bfd_ecoff_set_section_contents): Likewise.
3232 (_bfd_ecoff_write_object_contents): Check for various Alpha
3233 section types when incrementing text_size and data_size. Call
3234 adjust_headers backend function if it exists.
3235 * coff-alpha.c (alpha_adjust_headers): New static function.
3236 (alpha_ecoff_backend_data): Initialize adjust_headers field.
3237 * coff-mips.c (mips_ecoff_backend_data): Likewise.
3238
2b874a2d
ILT
3239 * hosts/i386bsd.h: Restore file incorrectly deleted on Sep 6.
3240
c780e5db
JL
3241Wed Oct 4 18:15:02 1995 Jeff Law ([email protected])
3242
3243 * rs6000-core.c (CORE_VERSION_1): Use CORE_VERSION_1 instead
3244 of ALTERNATE_AIX_CORE_FORMAT.
3245 * configure.in (aix4): No longer need CORE_FLAGS.
3246 * configure: Updated.
3247
2a01c351
KR
3248Wed Oct 4 15:36:36 1995 Ken Raeburn <[email protected]>
3249
3250 NS32k changes from Ian Dall:
3251 * aoutx.h (MY_final_link_relocate, MY_relocate_contents): New
3252 macros.
3253 (aout_link_input_section_std, aout_link_input_section_ext,
3254 aout_link_reloc_link_order): Call them instead of _bfd_*
3255 versions.
3256 * aout-target.h (MY_exec_header_not_counted): New macro, defaults
3257 to zero.
3258 (backend_data): Use it instead of hardcoded zero.
3259
3260 * aout-ns32k.c (CTOR_TABLE_RELOC_HOWTO): New macro.
3261 (MY_swap_std_reloc_out): Use udata.i for KEEPIT, don't call stoi.
3262
3263 * ns32knetbsd.c: Include bfd.h.
3264 (MY_text_includes_header, MY_bfd_reloc_type_lookup): New macros.
3265 (MY_bfd_reloc_type_lookup): Declare function too.
3266 * pc532-mach.c (set_sizes): Don't declare.
3267 (MY_text_includes_header, MY_exec_header_not_counted): Define.
3268 (backend_data, MY_backend_data): Don't define.
3269
3270 * config.bfd: Treat ns32k-pc532-ux* like ns32k-pc532-mach*, and
3271 ns32k-*-lites* like ns32k-*-netbsd*.
3272
3273 * hosts/nbsd.h: Swap order of sys/vmparam.h and sys/param.h, to
3274 compile on lites.
3275
5944d75b
ILT
3276Wed Oct 4 14:15:52 1995 Ian Lance Taylor <[email protected]>
3277
3278 * coffcode.h (coff_write_object_contents): Restore setting
3279 f_timdat to 0, deleted on August 22.
3280
db344f82
SC
3281Tue Oct 3 16:28:32 1995 steve chamberlain <[email protected]>
3282
3283 * coffcode.h (coff_bfd_copy_private_symbol_data,
3284 coff_bfd_copy_private_section_data,
3285 coff_bfd_copy_private_bfd_data): ifdef to allow overrides.
3286 * peicode.h (coff_bfd_copy_private_bfd_data): New
3287 (pe_bfd_copy_private_bfd_data): New.
3288 (coff_swap_scnhdr_in): Swap bss size into the right place.
3289 (pe_print_private_bfd_data): Add some newlines.
5944d75b 3290
c780e5db 3291Tue Oct 3 11:53:04 1995 Jeff Law ([email protected])
97f1feda
JL
3292
3293 * som.c (setup_sections): Don't die if a space has no subspaces.
3294
3d7c42c9
ILT
3295Mon Oct 2 14:08:55 1995 Ian Lance Taylor <[email protected]>
3296
3297 * elflink.h (elf_link_add_object_symbols): Don't let a weak
3298 dynamic symbol override a common symbol. Don't change the size or
3299 type if they have been set and the new symbol is not a definition.
3300 Warn if the size or type changes.
3301
c780e5db 3302Sun Oct 1 01:34:41 1995 Jeff Law ([email protected])
709af562
JL
3303
3304 * som.c (som_begin_writing): Don't write the symbol table or
3305 symbol strings.
3306 (som_finish_writing): Write them here. Place them after the
3307 subspace data, but before the relocs.
3308
3309Fri Sep 29 11:01:55 1995 Ian Lance Taylor <[email protected]>
3310
3311 * sunos.c (sunos_add_one_symbol): Just pass false, not
3312 info->shared_library, to sunos_create_dynamic_sections.
3313 (sunos_scan_ext_relocs): Don't warn about a reloc in the .text
3314 section.
3315 (sunos_check_dynamic_reloc): Remove .text section assertion.
3316
7009e451
SS
3317Thu Sep 28 18:48:47 1995 Stan Shebs <[email protected]>
3318
3319 * config.bfd: Add powerpc-*-macos*, powerpc-*-mpw*.
3320 * configure, configure.in: Add pmac_xcoff_vec case.
3321 * Makefile.in (BFD32_BACKENDS): Add coff-pmac.o.
3322 * coff-pmac.c: New file, PowerMac XCOFF support.
3323 * coffcode.h (coff_set_arch_mach_hook): Add PowerMac case.
3324 * targets.c (pmac_xcoff_vec): Declare.
3325
3326 * mpw-config.in: Various changes to be compatible with the
3327 autoconf-based configury.
3328 * mpw-make.sed: New file, sed commands to translate Unix
3329 makefile into MPW syntax.
3330 * mpw-make.in: Remove.
3331 * hosts/mpw.h: Remove.
3332 * bfd-in.h, bfd-in2.h: If MPW, include the file that defines
3333 true and false as enums, then define TRUE_FALSE_ALREADY_DEFINED.
3334
b91537be
SC
3335Thu Sep 28 17:06:23 1995 steve chamberlain <[email protected]>
3336
3337 * binary.c (binary_get_symtab): Return an empty string on error.
3338 * opncls.c (bfd_fdpenr): Change WIN32 restriction to WINGDB.
3339
30360a6f
KK
3340Thu Sep 28 15:30:44 1995 Kim Knuttila <krk@nellie>
3341
3342 * coff-ppc.c: Reformatted according to gnu conventions
3343 Removed irrelevant "if 0" code
3344
20d1e233
ILT
3345Thu Sep 28 11:19:53 1995 Ian Lance Taylor <[email protected]>
3346
69fd4fdd
ILT
3347 * hp300hpux.c (convert_sym_type): Treat secondary symbols as weak
3348 symbols rather than as indirect symbols.
3349 (MY(slurp_symbol_table)): Don't do anything special about
3350 secondary symbols.
3351
46b5a892
ILT
3352 * coffcode.h (coff_new_section_hook): Make sure that the alignment
3353 of .ctors and .dtors sections is no larger than 2.
3354
9db59230
ILT
3355 * sunos.c (sunos_add_one_symbol): Don't change
3356 bfd_link_hash_common to bfd_link_hash_new, since it may be on the
3357 undef list.
3358 (bfd_sunos_record_link_assignment): Don't put __DYNAMIC in the
3359 dynamic symbols when creating a shared library.
3360 (sunos_scan_ext_relocs): Handle relocs correctly when creating a
3361 shared library.
3362 (sunos_scan_dynamic_symbol): Don't mark the __DYNAMIC symbol as
3363 written even if it is not defined in a regular object.
3364 (sunos_write_dynamic_symbol): Use plt_offset for the address of
3365 the jump table reloc. Add an assertion. Use RELOC_JMP_SLOT
3366 rather than the constant 22.
3367 (sunos_check_dynamic_reloc): Handle creating a shared library.
3368 (sunos_finish_dynamic_link): Set the first entry in the GOT to
3369 zero when creating a shared library.
3370 * aoutx.h (NAME(aout,final_link)): If there is a symbol __DYNAMIC,
3371 write it out at the start of the symbol table.
3372
20d1e233
ILT
3373 * Makefile.in (BFD32_BACKENDS): Add coff-arm.o.
3374
a11e10fe
DE
3375Thu Sep 28 00:58:05 1995 Doug Evans <[email protected]>
3376
3377 * config.bfd: Add arm-*-coff.
3378 * configure.in, configure: Add armcoff_{little,big}_vec.
3379 * targets.c (armcoff_{little,big}_vec): Declare.
3380 (bfd_target_vector): Add armcoff_{little,big}_vec.
3381 * coff-arm.c (armcoff_{little,big}_vec): Always define.
3382
99062cfc
ILT
3383Wed Sep 27 10:37:14 1995 Ian Lance Taylor <[email protected]>
3384
3385 * targets.c (bfd_find_target): Remove debugging code.
3386
deacbe0f
KK
3387Wed Sep 27 07:23:39 1995 Kim Knuttila <krk@nellie>
3388
3389 * coff-ppc.c, pe-ppc.c, pei-ppc.c: Initial bfd for coff/PE
3390 support on powerpc.
3391 * Makefile.in: added *-ppc files
3392 * coffcode.h: ppc MAGIC, and use peicode.h rather than coffswap.h to
3393 allow pe based .o's to be shared with other tools on ppc/NT
3394 * config.bfd: added powerpc[le]-[pe|winnt] config support
3395 * configure, configure.in: added bfd_powerpc[le]_pe[i]_vec
3396 * peicode.h: Added more section flags for PE on ppc
3397 Added coff_swap_filehdr_out to allow peicode.h to be
3398 used for non-image PE files on ppc.
3399 Check for image, or not, before copying pe_opthdr
3400 * targets.c: Added new bfd's
30360a6f
KK
3401 * targets.c: Removed two inactive bfds that shouldn't have made it this
3402 far.
deacbe0f 3403
d22b02e0
MM
3404Tue Sep 26 14:06:41 1995 Michael Meissner <[email protected]>
3405
3406 * elf32-ppc.c (ppc_reloc_type): Rename from reloc_type, and use
3407 explicit values to initialize all relocs. Change all users.
3408 (ppc_elf_brtaken_inner): New function to handle branch predicition
3409 relocs.
3410 (ppc_elf_brtaken_reloc): Ditto.
3411 (ppc_elf_howto_raw): Use new functions. Make sure all unsupported
3412 relocs use ppc_elf_unsupported_reloc.
3413 (ppc_elf_merge_private_bfd_data): Keep track of whether an error
3414 needs to be reported.
3415 (ppc_elf_relocate_section): Support branch prediction relocs.
3416
fcf490c0
ILT
3417Tue Sep 26 12:48:05 1995 Ian Lance Taylor <[email protected]>
3418
e6cb7b41
ILT
3419 * bfd.c (bfd_assert): Remove \n from string passed to
3420 _bfd_error_handler.
3421
1af85fbb
ILT
3422 * coff-i386.c: (TWO_DATA_SECS): Don't define.
3423 * coffcode.h (bfd_coff_backend_data): Remove _bfd_make_section_hook.
3424 (bfd_coff_make_section_hook): Don't define.
3425 (coff_make_section_hook): Remove.
3426 (sec_to_styp_flags): Remove TWO_DATA_SECS case.
3427 (styp_to_sec_flags): Likewise.
3428 (coff_write_object_contents): Likewise.
3429 (bfd_coff_std_swap_table): Don't initialize make_section_hook
3430 field.
3431 * libcoff.h: Rebuild.
3432 * coffgen.c (make_a_section_from_file): Just call
3433 bfd_make_section_anyway, not bfd_make_section or
3434 bfd_coff_make_section_hook.
3435 * ecoff.c (_bfd_ecoff_make_section_hook): Remove.
3436 * libecoff.h (_bfd_ecoff_make_section_hook): Don't declare.
3437 * coff-alpha.c (alpha_ecoff_backend_data): Don't initialize
3438 make_section_hook field.
3439 * coff-mips.c (mips_ecoff_backend_data): Likewise.
3440
fcf490c0
ILT
3441 * aoutx.h (translate_from_native_sym_flags): Don't try to stuff
3442 pointers into value field for warning and indirect symbols; just
3443 leave the value field alone.
3444 * linker.c (generic_link_add_symbol_list): Use next symbol for
3445 warning and indirect symbols, rather than looking in symbol value.
3446 * ecoff.c (ecoff_set_symbol_info): Remove indirect_ptr_ptr
3447 parameter. Change all callers. Remove support for indirect
3448 symbols; it didn't work anyhow.
3449 (_bfd_ecoff_slurp_symbol_table): Remove indirect_ptr variable.
3450 * syms.c: Change comments about BSF_WARNING and BSF_INDIRECT.
3451 * bfd-in2.h: Rebuild.
3452
cc47d19a
MM
3453Mon Sep 25 16:04:09 1995 Michael Meissner <[email protected]>
3454
3455 * elf32-ppc.c (ppc_elf_howto_raw): For all 14-bit branch relocs,
3456 go back to telling the tools this reloc operates on 32 bits.
3457
81449d47
ILT
3458Mon Sep 25 11:48:02 1995 Ian Lance Taylor <[email protected]>
3459
7a7fbffb
ILT
3460 * aout-adobe.c (aout_adobe_callback): Use _bfd_error_handler
3461 rather than a direct fprintf.
3462 * archive.c (_bfd_write_archive_contents): Likewise.
3463 * coffcode.h (coff_slurp_symbol_table): Likewise.
3464 * elf32-ppc.c (ppc_elf_merge_private_bfd_data): Likewise.
3465 (ppc_elf_unsupported_reloc): Likewise.
3466 (ppc_elf_relocate_section): Likewise.
3467 * i386linux.c (linux_tally_symbols): Likewise.
3468 (linux_finish_dynamic_link): Likewise.
3469 * osf-core.c (osf_core_core_file_p): Likewise.
3470 * rs6000-core.c (rs6000coff_get_section_contents): Likewise.
3471 * som.c (som_sizeof_headers): Likewise.
3472 * srec.c (srec_bad_byte): Likewise.
3473 * bfd.c (bfd_assert): Likewise. Also change file to be const.
3474 * libbfd-in.h (bfd_assert): Declare first parameter const.
3475 * libbfd.h: Rebuild.
3476 * coff-a29k.c (a29k_reloc): Don't bother to fprintf; returning
3477 bfd_reloc_overflow is enough.
3478 * coff-h8300.c (rtype2howto): Don't bother to fprintf; just abort.
3479 * coff-h8500.c (rtype2howto): Likewise.
3480 * coff-z8k.c (rtype2howto): Likewise.
3481 * coffcode.h (dummy_reloc16_extra_cases): Likewise.
3482 * elf.c (_bfd_elf_get_lineno): Likewise.
3483 (_bfd_elf_no_info_to_howto): Likewise.
3484 (_bfd_elf_no_info_to_howto_rel): Likewise.
3485 * hp300hpux.c (convert_sym_type): Likewise.
3486 (MY(swap_std_reloc_in)): Likewise.
3487 * elf.c (bfd_section_from_shdr): Remove #if 0 sections.
3488
f1c6dd5d
ILT
3489 * libaout.h (struct aoutdata): Add line_buf field.
3490 * aoutx.h (NAME(aout,find_nearest_line)): Remove statics buffer
3491 and filename_buffer. Instead, use a malloc buffer stored in the
3492 new line_buf field. Remove length restrictions.
3493
f0500a41
ILT
3494 * coffgen.c (string_size): Remove static variable.
3495 (debug_string_size, debug_string_section): Likewise.
3496 (coff_fix_symbol_name): Add string_size_p, debug_string_section_p,
3497 and debug_string_size_p parameters. Use them instead of the
3498 global variables. Change all callers.
3499 (coff_write_symbol): Likewise.
3500 (coff_write_alien_symbol, coff_write_native_symbol): Likewise.
3501 (coff_write_symbols): Add local variables to replace removed
3502 global variables.
3503
25b5a53d
ILT
3504 * libcoff-in.h (struct coff_section_tdata): Add offset, i,
3505 function, and line_base fields.
3506 * libcoff.h: Rebuild.
3507 * coffgen.c (coff_find_nearest_line): Use section tdata to cache
3508 information, rather than using static variables.
3509
641ac26a
ILT
3510 * sunos.c (sunos_read_dynamic_info): Adjust offsets in an NMAGIC
3511 file. From Peter DeWolf <[email protected]>.
3512
81449d47
ILT
3513 * init.c (initialized): Remove static variable.
3514 (bfd_init): Don't bother setting initialized.
3515 (bfd_check_init): Remove.
3516 * opncls.c (_bfd_new_bfd): Don't call bfd_check_init.
3517 * libbfd.h: Rebuild.
3518
138b9b81
PS
3519Sat Sep 23 01:22:23 1995 Peter Schauer ([email protected])
3520
3521 * rs6000-core.c (rs6000coff_core_p): Don't check the core file
3522 size for full core dumps. Copy core file header to private data.
3523 (rs6000coff_core_file_failing_command,
3524 rs6000coff_core_file_failing_signal): New functions to extract
3525 the file name and terminating signal from the core file.
3526 * coff-rs6000.c: Use them.
3527
2ffbb79a
ILT
3528Fri Sep 22 17:44:47 1995 Ian Lance Taylor <[email protected]>
3529
3530 Change arch info to be const, initialized at compile time.
3531 * archures.c: Reindent many functions. Change CONST to const.
3532 (bfd_arch_info_type): Make arch_name const. Remove disassemble;
3533 nothing set it anyhow. Make next const.
3534 (bfd_arch_info_list): Remove.
3535 (bfd_archures_list): Rename from archures_init_table. Change from
3536 a table of function pointers to a table of bfd_arch_info_type
3537 structure addresses.
3538 (bfd_scan_arch): Rewrite accordingly. Return a const pointer.
3539 (bfd_lookup_arch): Likewise.
3540 (bfd_set_arch_info): Rewrite accordingly. Change argument to be a
3541 const pointer.
3542 (bfd_default_arch_struct): Make const.
3543 (bfd_arch_init, bfd_arch_linkin): Remove.
3544 (bfd_get_arch_info): Return a const pointer.
3545 * init.c (bfd_init): Don't call bfd_arch_init.
3546 * bfd.c (struct _bfd): Make arch_info const.
3547 * bfd-in2.h: Rebuild.
3548 * libbfd.h: Rebuild.
3549 * configure.in: Put & before everything in $selarchs.
3550 * configure: Rebuild.
3551 * cpu-*.c: Change bfd_*_arch from a function which calls
3552 bfd_arch_linkin to a const structure.
3553 * ieee.c (ieee_object_p): Make arch const.
3554
02f85cda
MM
3555Fri Sep 22 16:23:18 1995 Michael Meissner <[email protected]>
3556
3557 * reloc.c (bfd_reloc_code_type): Add relocations to support all of
3558 PowerPC V.4.
3559 * bfd-in2.h: Regenerate.
3560 * libbfd.h: Regenerate.
3561
3562 * elf32-ppc.c (reloc_type): Update names to match current draft.
3563 (ppc_elf_howto_raw): Mark 14 bit relocs as short sized and PC
3564 relative. Update names to current V.4 draft.
3565 (ppc_elf_reloc_type_lookup): Add support for more relocations.
3566 (ppc_elf_relocate_section): Rename relocations to match draft.
3567
dd82c578
MM
3568Thu Sep 21 21:53:18 1995 Michael Meissner <[email protected]>
3569
3570 * elf32-ppc.c (ppc_elf_merge_private_bfd_data): Allow modules
3571 compiled with -mrelocatable-lib to be linked with either normal
3572 modules or -mrelocatable modules.
3573
f69e888e
ILT
3574Wed Sep 20 12:03:26 1995 Ian Lance Taylor <[email protected]>
3575
e18c4e8f
ILT
3576 * coffcode.h (coff_write_object_contents): Clear the vstamp field
3577 in the a.out header.
3578
f69e888e
ILT
3579 * aoutx.h (NAME(aout,swap_ext_reloc_out)): Don't set r_extern for
3580 a reloc against a local symbol, even if it's not a section.
3581
a5655244
ILT
3582Tue Sep 19 17:02:26 1995 Ian Lance Taylor <[email protected]>
3583
3584 * targets.c (bfd_target): Remove unused align_power_min field.
3585 * bfd-in2.h: Rebuild.
3586 * All backends: Remove initialization of align_power_min.
3587
500d7394
SC
3588Tue Sep 19 14:02:21 1995 steve chamberlain <[email protected]>
3589
3590 * peicode.h (coff_swap_scnhdr_out): Get sizes for BSS right.
500d7394 3591
049df0a8
ILT
3592Mon Sep 18 14:35:01 1995 Arne H. Juul <[email protected]>
3593
3594 * config.bfd (mips-dec-netbsd*): New target.
3595 * configure.host (mips-dec-netbsd*): New host.
3596 * configure.in (mips-dec-netbsd*): New native.
3597 * configure: Rebuild.
3598
1862bbd8
ILT
3599Fri Sep 15 10:24:36 1995 Ian Lance Taylor <[email protected]>
3600
3601 Make the COFF backend linker merge common types:
3602 * cofflink.c (struct coff_debug_merge_element): Define.
3603 (struct coff_debug_merge_type): Define.
3604 (struct coff_debug_merge_hash_entry): Define.
3605 (struct coff_debug_merge_hash_table): Define.
3606 (coff_debug_merge_hash_table_init): Define.
3607 (coff_debug_merge_hash_table_free): Define.
3608 (coff_debug_merge_hash_lookup): Define.
3609 (struct coff_final_link_info): Add debug_merge field.
3610 (coff_debug_merge_hash_newfunc): New static function.
3611 (_bfd_coff_final_link): Allocate and free debug_merge table.
3612 (coff_link_input_bfd): Merge identical enum, struct and union
3613 types.
3614
a208a70f
ILT
3615Thu Sep 14 14:53:58 1995 Ian Lance Taylor <[email protected]>
3616
3617 Convert i960 COFF to use COFF backend linker.
3618 * coff-i960.c (coff_i960_relocate): Use a coff_section_data
3619 structure to store the symbol being used.
3620 (coff_i960_start_final_link): New static function.
3621 (coff_i960_relocate_section): New static function.
3622 (coff_i960_adjust_symndx): New static function.
3623 (coff_start_final_link): Define.
3624 (coff_relocate_section): Define.
3625 (coff_adjust_symndx): Define.
3626 * coffcode.h (bfd_coff_backend_data): Add new callback function
3627 _bfd_coff_start_final_link.
3628 (bfd_coff_start_final_link): Define.
3629 (coff_start_final_link): Define if not defined.
3630 (bfd_coff_std_swap_table): Add coff_start_final_link.
3631 * cofflink.c (_bfd_coff_internal_syment_name): Make globally
3632 visible.
3633 (_bfd_coff_final_link): Call bfd_coff_start_final_link if the
3634 function callback is not NULL.
3635 * libcoff-in.h (struct coff_section_tdata): Add tdata field.
3636 (_bfd_coff_internal_syment_name): Declare.
3637 * libcoff.h: Rebuild.
3638 * configure.in (icoff_big_vec): Add cofflink.o.
3639 (icoff_little_vec): Likewise.
3640 * configure: Rebuild.
3641
f0abedbe
FF
3642Wed Sep 13 17:38:23 1995 Fred Fish <[email protected]>
3643
3644 * Makefile.in (clean-info): Remove extraneous tab from line
3645 following action.
3646
aa4b3dc5
ILT
3647Wed Sep 13 13:27:53 1995 Ian Lance Taylor <[email protected]>
3648
3649 * cofflink.c (coff_link_input_bfd): Fail if a section with no
3650 contents has relocs.
3651
4ca63811 3652Thu Sep 12 12:45:34 1995 steve chamberlain <[email protected]>
beee31b1
SC
3653
3654 * coffcode.h (coff_compute_section_file_positions): Keep the
3655 raw size safe.
3656 (coff_write_object_contents): Remember if it's a relocatable
3657 file.
3658 * libcoff-in.h (pe_data_type): New member 'has_reloc_section'
3659 * peicode.h (coff_swap_filehdr_out): Clear not-reloc flag
3660 if relocatable file. Swap out saved raw size.
3661
ae115e51
ILT
3662Tue Sep 12 12:14:33 1995 Ian Lance Taylor <[email protected]>
3663
9521bac3
ILT
3664 * Makefile.in (do_maintainer_clean): Rename from do_realclean.
3665 (maintainer-clean): Rename from realclean, passing
3666 maintainer-clean down to subdirectories, but leave realclean as a
3667 synonym.
3668
4ca63811
ILT
3669 * linker.c (_bfd_generic_link_add_one_symbol): Pass symbol name to
3670 warning callback.
3671
5aa4c3ff
ILT
3672 * dep-in.sed: Remove config.h from generated dependencies.
3673
396aaeb2
ILT
3674 * sunos.c (sunos_slurp_dynamic_symtab): New static function,
3675 broken out of sunos_canonicalize_dynamic_symtab.
3676 (sunos_canonicalize_dynamic_symtab): Call new function
3677 sunos_slurp_dynamic_symtab.
3678 (sunos_add_dynamic_symbols): Add three new parameters. Return the
3679 dynamic symbol table to the caller.
3680 * aoutx.h (aout_link_add_symbols): Permit add_dynamic_symbols
3681 callback to override the symbols being read.
3682 * libaout.h (struct aout_backend_data): Add three new parameters
3683 to add_dynamic_symbols callback.
3684
ae115e51
ILT
3685 Extensive minor changes to avoid various gcc warnings. Also:
3686 * Makefile.in (BFD32_BACKENDS): Remove coff-arm.o.
3687 * archures.c (bfd_arch_info_type): Change mach field from long to
3688 unsigned long.
3689 (bfd_lookup_arch): Change machine parameter from long to unsigned
3690 long.
3691
b088e4b2
ILT
3692Mon Sep 11 10:55:47 1995 Ian Lance Taylor <[email protected]>
3693
3694 * sunos.c (sunos_scan_std_relocs): Fix BFD_ASSERT: it's OK to find
3695 a symbol with a non-zero plt_offset.
3696
1dff7902
ILT
3697Fri Sep 8 11:47:24 1995 Ian Lance Taylor <[email protected]>
3698
2b71e1e4
ILT
3699 * elfcode.h (align_file_position): Remove; not used.
3700
1dff7902
ILT
3701 * configure.in: Only check for <sys/procfs.h> on a native system,
3702 and make sure it defines prstatus_t.
3703 * configure: Rebuild.
3704
870015b1
ILT
3705Thu Sep 7 12:48:01 1995 Ian Lance Taylor <[email protected]>
3706
535c89f0
ILT
3707 * sunos.c (sunos_write_dynamic_symbol): Correct m68k abort test.
3708
936b870c
ILT
3709 * config.in: Rename from config.h.in.
3710 * configure.in: Call AC_CONFIG_HEADER with config.h:config.in.
a7873a6c 3711 Check for config.h:config.in when creating stamp-h.
936b870c 3712 * configure: Rebuild.
a7873a6c
ILT
3713 * Makefile.in (stamp-h): Depend upon config.in rather than
3714 config.h.in. Set CONFIG_HEADERS to config.h:config.in when
3715 calling config.status.
936b870c 3716
870015b1
ILT
3717 * Makefile.in (do_distclean): Remove config.h and stamp-h.
3718 (Makefile): Just rebuild Makefile.
3719 (config.h, stamp-h): New targets.
3720 * configure.in: Create stamp-h when rebuilding config.h.
3721 * configure: Rebuild.
3722
b7577823
ILT
3723Wed Sep 6 15:00:33 1995 Ian Lance Taylor <[email protected]>
3724
3725 * configure.in: Call AC_CONFIG_HEADER. Substitute
3726 HOST_64BIT_LONG. Check that various header files exist. Check
3727 that fcntl exists. Call BFD_BINARY_FOPEN. Check whether malloc
3728 and/or free need to be declared. Don't make a link to sysdep.h.
3729 Define TRAD_HEADER for various hosts.
3730 * configure: Rebuild.
3731 * configure.host: Don't set my_host. Add definitions taken from
3732 host header files for various entries. Remove entries which now
3733 do nothing.
3734 * acconfig.h: New file.
3735 * config.h.in: New file, built by autoheader.
3736 * sysdep.h: New file.
3737 * Makefile.in (do_distclean): Don't remove sysdep.h.
3738 (RECONFIG): Remove.
3739 (LOCAL_H_DEPS): New variable.
3740 ($(BFD_LIBS)): Use $(LOCAL_H_DEPS) rather than libbfd.h and
3741 $(RECONFIG).
3742 ($(BFD_MACHINES), $(BFD_BACKENDS)): Likewise.
3743 ($(OPTIONAL_BACKENDS)): Likewise.
3744 (stmp-bfd.h): Just substitute for BFD_HOST_64BIT_LONG, rather than
3745 looking through sysdep.h.
3746 * bfd-in.h (BFD_HOST_64BIT_LONG): Define; set by Makefile.
3747 (BFD_HOST_64_BIT): Define based on BFD_HOST_64BIT_LONG.
3748 (fprintf_vma, sprintf_vma): Likewise.
3749 (int64_type, uint64_type): Don't define.
3750 * bfd-in2.h: Rebuild.
3751 * archures.c, bfd.c, srec.c: Include <ctype.h>.
3752 * elfcore.h: Check HAVE_SYS_PROCFS_H rather than HAVE_PROCFS.
3753 * lynx-core.c: Include stuff from old hosts/lynx.h.
3754 * opncls.c (bfd_fdopenr): Check HAVE_FNCTL and defined (F_GETFL),
3755 rather than NO_FCNTL.
3756 * targets.c (bfd_target_list): Check HOST_HPPAHPUX and ! __STDC__
3757 rather than NATIVE_HPPAHPUX_COMPILER.
3758 * trad-core.c: Don't include <errno.h>. Include TRAD_HEADER if it
3759 is defined.
3760 * hosts/*.h: Remove all header files which merely include,
3761 declare, and define things. Leave header files which define
3762 information needed by trad-core.c.
3763
3764 * aclocal.m4 (BFD_BINARY_FOPEN): Define.
3765 (BFD_CC_FOR_BUILD): Define.
3766 * configure.in: Use BFD_CC_FOR_BUILD.
3767 * configure: Rebuild.
3768
7a93ebdd
ILT
3769Tue Sep 5 19:35:28 1995 Ian Lance Taylor <[email protected]>
3770
4c2e4d0e
ILT
3771 * aclocal.m4: Don't try to grep ../Makefile if it doesn't exist.
3772 * configure: Rebuild.
3773
7a93ebdd
ILT
3774 * coff-sparc.c (CALC_ADDEND): Don't set the addend to the value of
3775 a global symbol.
3776
866bb9e5
JM
3777Tue Sep 5 12:48:26 1995 Jason Molenda ([email protected])
3778
3779 * config.bfd: i386pe_ve -> i386pe_vec.
3780
2b79a104
ILT
3781Mon Sep 4 14:02:43 1995 Ian Lance Taylor <[email protected]>
3782
f515fb2f
ILT
3783 * configure.host: Incorporate host Makefile fragments by setting
3784 shell variables.
3785 * configure.in: Call AC_PROG_CC. Substitute CFLAGS, HDEFINES and
3786 AR. Call AC_PROG_INSTALL. Substitute CC_FOR_BUILD, choosing a
3787 value based on whether the code is being compiled by a cross
3788 compiler. Don't substitute host_makefile_frag or frags.
3789 * aclocal.m4: New file to define local AC_PROG_CC.
3790 * configure: Rebuild.
3791 * Makefile.in (INSTALL): Set to @INSTALL@.
3792 (INSTALL_PROGRAM): Set to @INSTALL_PROGRAM@.
3793 (INSTALL_DATA): Set to @INSTALL_DATA@.
3794 (AR): Set to @AR@.
3795 (CC): Define as @CC@.
3796 (CFLAGS): Set to @CFLAGS@.
3797 (CC_FOR_BUILD): Set to @CC_FOR_BUILD@.
3798 (@host_makefile_frag@): Remove.
3799 (ALL_CFLAGS): Change $(HDEFINES) to @HDEFINES@. Move $(CFLAGS)
3800 after other options.
3801 (config.status): Remove dependency upon @frags@.
3802 * config/*.mh, config/README: Remove.
3803
2b79a104
ILT
3804 * config.bfd: Rewrite to incorporate the contents of the Makefile
3805 fragments by setting shell variables, rather than merely returning
3806 the name of a Makefile fragment.
3807 * configure.in: Use shell variables set by config.bfd rather than
3808 looking at the target Makefile fragment files. Don't substitute
3809 target_makefile_frag. Do substitute TDEFINES.
3810 * configure: Rebuild.
3811 * Makefile.in (@target_makefile_frag@): Remove.
3812 (ALL_CFLAGS): Change $(TDEFINES) to @TDEFINES@.
3813 * config/*.mt: Remove.
3814
2cb159a5
KR
3815Mon Sep 4 03:13:28 1995 Ken Raeburn <[email protected]>
3816
3817 * configure.in: Put changequote lines around "i[345]86" patterns
3818 section of core file support.
3819
ef07871c
JL
3820Sun Sep 3 11:31:58 1995 Jeff Law ([email protected])
3821
3822 * som.c (som_bfd_print_private_bfd_data): Define to use the
3823 generic version.
3824
1613e075
SC
3825Fri Sep 1 17:08:40 1995 steve chamberlain <[email protected]>
3826
3827 * peicode.h (coff_swap_aouthdr_in): Add ImageBase to
3828 entry, text_start and data_start.
3829
a52a3ce8
ILT
3830Fri Sep 1 18:06:28 1995 Ian Lance Taylor <[email protected]>
3831
a21227ef
ILT
3832 * Makefile.in (OFILES): Remove $(TDEPFILES).
3833 * config/apollo.mt (TDEPFILES): Remove.
3834 * config/README: Update.
3835
a52a3ce8
ILT
3836 * configure.in: For a native configuration, set COREFILE and
3837 COREFLAG based on the canonical host name.
3838 * configure: Rebuild.
3839 * Makefile.in: Rebuild dependencies.
3840 (ALL_CFLAGS): Add @COREFLAG@.
3841 (OFILES): Replace $(HDEPFILES) with @COREFILE@.
3842 * coff-rs6000.c: Check AIX_CORE rather than HOST_AIX for core file
3843 support routines. Check LYNX_CORE rather than HOST_LYNX.
3844 * lynx-core.c: Check LYNX_CORE rather than HOST_LYNX.
3845 * i386lynx.c: Likewise.
3846 * m68klynx.c: Likewise.
3847 * sparclynx.c: Likewise.
3848 * rs6000-core.c: Check AIX_CORE rather than HOST_AIX.
3849 * *-core.c: Comment changes.
3850 * config/decstation.mh (HDEPFILES): Remove.
3851 (HDEFINES): Remove -DTRAD_CORE.
3852 * config/irix3.mh (RANLIB): Remove.
3853 * config/irix4.mh (HDEPFILES, RANLIB): Remove.
3854 (HDEFINES): Remove -DIRIX_CORE.
3855 * config/riscos.mh (RANLIB, HDEPFILES): Remove.
3856 (HDEFINES): Remove -DTRAD_CORE.
3857 * config/ncr3000.mh (AR_FLAGS, RANLIB): Remove.
3858 * config/ultra3.mh (RANLIB): Remove.
3859 * config/aix4.mh, config/alphaosf.mh, config/amix.mh: Remove.
3860 * config/apollo.mh, config/delta68.mh, config/delta88.mh: Remove.
3861 * config/dpx2.mh, config/esix.mh, config/harris.mh: Remove.
3862 * config/hp300.mh, config/hp300bsd.mh, config/hppabsd.mh: Remove.
3863 * config/hppahpux.mh, config/hppaosf.mh: Remove.
3864 * config/i386aix.mh, config/i386bsd.mh: Remove.
3865 * config/i386linux.mh, config/i386mach3.mh: Remove.
3866 * config/i386sco.mh, config/i386v.mh, config/i386v4.mh: Remove.
3867 * config/irix5.mh, config/m88kmach3.mh, config/mipsbsd.mh: Remove.
3868 * config/mipsmach3.mh, config/news-mips.mh: Remove.
3869 * config/news.mh, config/pc532mach.mh, config/riscix.mh: Remove.
3870 * config/rs600.mh, config/rs6000lynx.mh: Remove.
3871 * config/solaris2.mh, config/stratus.mh: Remove.
3872 * config/symmetry.mh, config/sysv4.mh, config/tahoe.mh: Remove.
3873 * config/vaxbsd.mh, config/vaxult.mh, config/vaxult2.mh: Remove.
3874
d6f672b8
ILT
3875Fri Sep 1 15:18:50 1995 Kazumoto Kojima <[email protected]>
3876
3877 * elflink.h (elf_bfd_final_link): Don't change a DT_INIT or
3878 DT_FINI entry if the appropriate symbol is not in the hash table.
3879
3880 * libelf.h (struct elf_backend_data): Add create_program_headers
3881 and want_hdr_in_seg fields.
3882 * elfxx-target.h (elf_backend_want_hdr_in_seg): Define if not
3883 defined.
3884 (elf_backend_create_program_headers): Likewise.
3885 (elfNN_bed): Initialize create_program_headers and
3886 want_hdr_in_seg.
3887 * elf.c (get_program_header_size): Call create_program_headers
3888 backend routine.
3889 (map_program_segments): Check want_hdr_in_seg backend field. Call
3890 create_program_headers backend routine.
3891
3892 * elf.c (assign_file_positions_except_relocs): Align non allocated
3893 sections when creating an executable.
3894
3895 * elfcode.h (elf_swap_phdr_in): Make non static.
3896 (elf_swap_phdr_out): Make non static.
3897 * libelf.h (bfd_elf32_swap_phdr_in): Declare.
3898 (bfd_elf32_swap_phdr_out): Declare.
3899 (bfd_elf64_swap_phdr_in): Declare.
3900 (bfd_elf64_swap_phdr_out): Declare.
3901
3902 * ecofflink.c (ecoff_collect_shuffle): New static function.
3903 (_bfd_ecoff_get_accumulated_pdr): New function.
3904 (_bfd_ecoff_get_accumulated_sym): New function.
3905 (_bfd_ecoff_get_accumulated_ss): New function.
3906 * libbfd-in.h (_bfd_ecoff_get_accumulated_pdr): Declare.
3907 (_bfd_ecoff_get_accumulated_sym): Declare.
3908 (_bfd_ecoff_get_accumulated_ss): Declare.
3909 * libbfd.h: Rebuild.
3910
0cb70568
ILT
3911Fri Sep 1 13:20:25 1995 Ian Lance Taylor <[email protected]>
3912
d6f672b8
ILT
3913 * libecoff.h (_bfd_ecoff_bfd_print_private_bfd_data): Fix typo.
3914
0cb70568
ILT
3915 * elflink.h (elf_link_add_object_symbols): Handle indirect and
3916 warning symbols. If any section is named .gnu.warning.XXX, treat
3917 the contents as a warning to be issued if the symbol XXX is
3918 referenced.
3919 (elf_link_output_extsym): For an indirect or warning symbol, just
3920 output the symbol it points to.
3921
3922 * linker.c (_bfd_link_hash_newfunc): Don't bother to set bfd_error
3923 if bfd_hash_allocate fails, since it will already be set.
3924 (generic_link_hash_newfunc): Likewise.
3925 (archive_hash_newfunc): Likewise.
3926 (hash_entry_bfd): New static function.
3927 (_bfd_generic_link_add_one_symbol): Pass new arguments to warning
3928 callback. Allocate a new warning using the hash table newfunc.
3929 Use bfd_hash_replace to update the entry in the hash table, rather
3930 than assuming we can copy the fields with structure assignment.
3931
3932 * hash.c (bfd_hash_replace): New function.
3933 * bfd-in.h (bfd_hash_replace): Declare.
3934 * bfd-in2.h: Rebuild.
3935
f14db880
JSC
3936Fri Sep 1 08:12:50 1995 James G. Smith <[email protected]>
3937
3938 * config.bfd: Add mips*vr4300-*-elf* target.
3939 * config/mipsbvr4300.mt: Added.
3940
1613e075 3941See file ChangeLog.2
e6d739eb 3942
41126f15
JK
3943\f
3944Local Variables:
3945mode: indented-text
3946left-margin: 8
6ec3bb6a
ILT
3947fill-column: 74
3948version-control: never
3949End:
This page took 0.905074 seconds and 4 git commands to generate.