Mon Mar 31 23:28:39 1997 H.J. Lu <hjl@gnu.ai.mit.edu>
[deliverable/binutils-gdb.git] / bfd / ChangeLog
CommitLineData
8faaff9e
ILT
1Mon Mar 31 23:28:39 1997 H.J. Lu <hjl@gnu.ai.mit.edu>
2
3 * coffcode.h (coff_mkobject_hook): Declare if not a macro.
4
5cfc9987
ILT
5Mon Mar 31 16:29:50 1997 Joel Sherrill <joel@oarcorp.com>
6
3418d8c4 7 * config.bfd (hppa*-*-rtems*): New target, like hppa-*-*elf*.
5cfc9987 8
34c68301
ILT
9Mon Mar 31 16:11:35 1997 Ian Lance Taylor <ian@cygnus.com>
10
11 * coff-a29k.c (coff_a29k_relocate_section): Don't use symndx as a
12 symbol index for a R_IHCONST reloc.
13
774dc17c
ILT
14Mon Mar 31 15:40:59 1997 Philippe De Muyter <phdm@info.ucl.ac.be>
15
16 * targmatch.sed: Do not use \(\) recursively.
17
9e55b695
ILT
18Fri Mar 28 14:44:08 1997 H.J. Lu <hjl@gnu.ai.mit.edu>
19
20 * m68klinux.c (MACHTYPE_OK): Define.
21 * i386linux.c (MACHTYPE_OK): Define.
22
f3f3b475
ILT
23Fri Mar 28 11:56:15 1997 Ian Lance Taylor <ian@cygnus.com>
24
5f792743
ILT
25 From David S. Miller <davem@caip.rutgers.edu> and H.J. Lu
26 <hjl@gnu.ai.mit.edu>:
27 * sparclinux.c: New file.
774dc17c
ILT
28 * bfd-in.h (bfd_sparclinux_size_dynamic_sections): Declare.
29 * bfd-in2.h: Rebuild.
5f792743
ILT
30 * config.bfd (sparc-*-linuxaout*, sparc-*-linux*): New targets.
31 * configure.in (sparclinux_vec): Add to list of vectors.
32 * configure: Rebuild.
33 * targets.c (sparclinux_vec): Declare.
34 (bfd_target_vector): Add sparclinux_vec.
35 * Makefile.in: Rebuild dependencies.
36 (BFD32_BACKENDS): Add sparclinux.o.
37 (BFD32_BACKENDS_CFILES): Add sparclinux.c.
38
bebe5fbf
ILT
39 * coff-mips.c (mips_ecoff_backend_data): Initialize new
40 bfd_coff_backend_data field.
41 * coff-alpha.c (alpha_ecoff_backend_data): Likewise.
42
f0315e65
ILT
43 * config.bfd: Add bfd_elf64_{big,little}mips_vec to targ_selvecs
44 for mips*el*-*-linux* and mips*-*-linux*. From H.J. Lu
45 <hjl@lucon.org> and Ralf Baechle <ralf@gnu.ai.mit.edu>.
46
f3f3b475
ILT
47 * bfd.c: Include "libiberty.h".
48 (strerror): Don't declare.
49 (bfd_errmsg): Call xstrerror rather than strerror.
50
013b249f
ILT
51Thu Mar 27 12:55:42 1997 Ian Lance Taylor <ian@cygnus.com>
52
eb80d52a
ILT
53 * elf32-i386.c (elf_i386_adjust_dynamic_symbol): Generate a COPY
54 reloc even if the symbol is in the .bss section.
55 * elf32-m68k.c (elf_m68k_adjust_dynamic_symbol): Likewise.
56 * elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): Likewise.
57 * elf32-sparc.c (elf32_sparc_adjust_dynamic_symbol): Likewise.
58
f89adeb7
ILT
59 * coffcode.h (bfd_coff_backend_data): Add new field
60 _bfd_coff_default_section_alignment_power.
61 (bfd_coff_default_section_alignment_power): Define.
62 (bfd_coff_std_swap_table): Initialize new field.
63 * libcoff.h: Rebuild.
64 * cofflink.c (coff_link_add_symbols): Limit alignment of a common
65 symbol to the default section alignment.
66
013b249f
ILT
67 * COPYING: Update FSF address.
68
0e9c4377
MH
69start-sanitize-d30v
70Thu Mar 27 00:45:57 1997 Martin M. Hunt <hunt@pizza.cygnus.com>
71
72 * elf32-d30v.c (elf_d30v_howto_table): Fix a typo in the
73 21-bit absolute that made it act as a relative.
74
75end-sanitize-d30v
537327bc
ILT
76Wed Mar 26 14:50:20 1997 Ian Lance Taylor <ian@cygnus.com>
77
0e9c4377
MH
78 * elflink.c (_bfd_elf_create_linker_section): Don't set
79 bss_section and rel_section from existing sections.
80
537327bc
ILT
81 * elf32-ppc.c (ppc_elf_check_relocs): Only create the got section
82 if it is needed.
83
60d1227a
SG
84Tue Mar 25 22:26:56 1997 Stu Grossman (grossman@critters.cygnus.com)
85
86 * aoutx.h (some_aout_object_p): Change executable test to fix
87 problems with embedded a.out systems.
88
3cd5cf3d
ILT
89Tue Mar 25 14:35:37 1997 Ian Lance Taylor <ian@cygnus.com>
90
6717fb0d
ILT
91 * stabs.c (_bfd_stab_section_offset): New function.
92 * libbfd-in.h (_bfd_stab_section_offset): Declare.
93 * libbfd.h: Rebuild.
94 * elf32-i386.c (elf_i386_relocate_section): Adjust the offset of a
95 stab reloc.
96 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
97 * elf32-mips.c (mips_elf_relocate_section): Likewise.
98 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
99 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
100 * elf64-alpha.c (elf64_alpha_relocate_section): Likewise.
101
3cd5cf3d
ILT
102 * stabs.c (_bfd_link_section_stabs): Copy over the first header
103 symbol. Check for memory allocation failure of *psinfo.
104 (_bfd_write_section_stabs): Add psinfo parameter. Change all
105 callers. Set the value of the header symbol.
106 * libbfd-in.h (_bfd_write_section_stabs): Update declaration.
107 * libbfd.h: Rebuild.
108
67e87a1d
FF
109start-sanitize-tic80
110Mon Mar 24 20:07:29 1997 Fred Fish <fnf@cygnus.com>
111
112 * coff-tic80.c (tic80_howto_table): Add R_ABS entry.
113 (rtype2howto): Handle R_ABS reloc type. Also abort on unhandled
114 reloc types, rather than silently failing to generate an output file.
115
116end-sanitize-tic80
e9148724
ILT
117Mon Mar 24 13:41:00 1997 Ian Lance Taylor <ian@cygnus.com>
118
e1ea3dd5
ILT
119 * targmatch.sed: Use the hold space to put the #ifdef around the
120 the string constant.
121 * targets.c (UNSUPPORTED_TARGET): Don't define.
122 (find_target): Don't check for UNSUPPORTED_TARGET.
123 (bfd_set_default_target): Don't try to optimize by checking for
124 default.
125
032dc9ed
ILT
126 * Makefile.in: Rebuild dependencies.
127 (ALL_MACHINES_CFILES): Add cpu-m32r.c.
128 (BFD32_BACKENDS_CFILES): Add elf32-m32r.c.
129 (elf32-m32r.o): Remove explicit target.
130
19d02576
ILT
131 * config.bfd: Don't set targ_underscore for i[3456]86-*-gnu* or
132 i[3456]86-*-linux*.
133
e9148724
ILT
134 * elf32-sparc.c (elf32_sparc_size_dynamic_sections): Don't
135 count section symbols for sections that were created by the
136 linker, or are not allocatable or not loadable.
137 (elf32_sparc_finish_dynamic_sections): Output output section
138 symbols for section for which we made space for them.
139
0727fe10
ILT
140Fri Mar 21 13:08:26 1997 Ian Lance Taylor <ian@cygnus.com>
141
142 * elf32-sparc.c (elf32_sparc_size_dynamic_sections): If there is
143 no .rela.plt section, don't output a DT_PLTGOT dynamic entry.
144
ff22a9db
DE
145Fri Mar 21 12:36:46 1997 Doug Evans <dje@canuck.cygnus.com>
146
147 * elf32-m32r.c (m32r_elf_howto_table): Use special function for LO16.
148 (m32r_hi16_list): New static local.
149 (m32r_elf_hi16_reloc): Don't perform reloc, just queue it up.
150 (m32r_elf_do_hi16_reloc): Delete.
151 (m32r_elf_relocate_hi16): New function.
152 (m32r_elf_lo16_reloc): New function.
153 (m32r_elf_relocate_section): For HI16 relocs, scan for corresponding
154 LO16 reloc.
155
156 Mon Mar 10 16:03:31 1997 Doug Evans <dje@seba.cygnus.com>
157
158 * elf32-m32r.c (m32r_elf_create_linker_section): Delete.
159 (m32r_elf_add_symbol_hook): Rewrite _SDA_BASE_ support.
160 (m32r_elf_final_sda_base): New function.
161 (m32r_elf_relocate_section): Rewrite sdata support.
162 (m32r_elf_finish_dynamic_sections): Delete.
163
34bc6ffc
ILT
164Thu Mar 20 12:39:02 1997 Ian Lance Taylor <ian@cygnus.com>
165
ac388f2a
ILT
166 Based on patches from Philippe De Muyter <phdm@info.ucl.ac.be>.
167 * coff-svm68k.c: New file. Just defines some macros and includes
168 coff-m68k.c.
169 * coff-m68k.c: Add functions to handle common addends, moved in
170 from cf-m68klynx.c. Control them using COFF_COMMON_ADDEND macro.
171 Control whether relocs are visible using STATIC_RELOCS.
172 * cf-m68klynx.c: Simplify greatly: just define macros to control
173 coff-m68k.c.
174 * coff-aux.c: Likewise. Just leave add_one_symbol routine.
175 * targets. (m68ksysvcoff_vec): Declare.
176 (bfd_target_vector): Add m68ksysvcoff_vec.
177 * config.bfd (m68*-motorola-sysv*): New target.
178 * configure.in (m68ksysvcoff_vec): New vector.
179 * configure: Rebuild.
180 * Makefile.in: Rebuild dependencies.
181 (BFD32_BACKENDS): Add coff-svm68k.o.
182 (BFD32_BACKENDS_CFILES): Add coff-svm68k.c.
183
b9576d75
ILT
184 * binary.c (binary_set_section_contents): Don't get misled if the
185 first section is not loadable. From Matthew L. Martin
186 <mlm@xedia.com>.
187
34bc6ffc
ILT
188 * elflink.h (elf_bfd_final_link): Set the value of a section
189 symbol to the section address unless doing a relocateable link.
190
191Tue Mar 18 23:03:17 1997 Richard Henderson <rth@tamu.edu>
192
193 * elf64-alpha.c (elf64_alpha_adjust_dynamic_symbol): Don't create
194 .plt entry if we've taken the function's address.
195 (elf64_alpha_merge_gots): Merge collected flags info as well.
196
303e7257
ILT
197Tue Mar 18 22:40:09 1997 H.J. Lu <hjl@lucon.org>
198
199 * Many files: Add function prototypes.
200 * cpu-m68k.c (bfd_default_scan_num_mach): Don't declare.
201 * ecofflink.c: Include "libcoff.h" and "libecoff.h".
202 * elf32-ppc.c (ppc_elf_fake_sections): Make static.
203 * opncls.c (bfd_openstreamr): Change stream parameter to PTR.
204 * peicode.h: Change several void * parameters to PTR.
205 * srec.c (srec_get_symbol_info): Make static.
206 * syms.c (bfd_symbol_is_absolute): Remove.
7197adc4 207 * Makefile.in: Rebuild dependencies.
303e7257 208
939b2169
ILT
209Tue Mar 18 12:58:08 1997 Ian Lance Taylor <ian@cygnus.com>
210
e76386d2
ILT
211 * elf32-m32r.c (m32r_elf_is_local_label_name): Remove.
212 (bfd_elf32_bfd_is_local_label): Don't define.
213
939b2169
ILT
214 * xcofflink.c (_bfd_xcoff_bfd_final_link): Call bfd_malloc rather
215 than malloc.
216
50ede03d
ILT
217Mon Mar 17 11:32:53 1997 Ian Lance Taylor <ian@cygnus.com>
218
508539ab
ILT
219 * bfd-in.h: Don't include obstack.h.
220 (struct bfd_hash_table): Change memory field to PTR.
221 * bfd.c (struct _bfd): Change memory field to PTR.
222 * bfd-in2.h: Rebuild.
223 * libbfd-in.h (bfd_release): Declare as function, don't define as
224 macro.
225 * libbfd.h: Rebuild.
226 * opncls.c: Include "objalloc.h" rather than "obstack.h". Use
227 objalloc routines rather than obstack routines.
228 (obstack_chunk_alloc, obstack_chunk_free): Don't define.
229 (getpagesize): Don't define.
230 (_bfd_new_bfd): Don't set _bfd_chunksize.
231 (bfd_openr): Free new bfd and objalloc on failure.
232 (bfd_fdopenr, bfd_openstreamr, bfd_openw): Likewise.
233 (bfd_alloc_size): Remove.
234 (bfd_release): New function.
235 * hash.c: Include "objalloc.h" rather than "obstack.h". Use
236 objalloc routines rather than obstack routines.
237 (obstack_chunk_alloc, obstack_chunk_free): Don't define.
238 * ecofflink.c: Include "objalloc.h" rather than "obstack.h". Use
239 objalloc routines rather than obstack routines.
240 (obstack_chunk_alloc, obstack_chunk_free): Don't define.
241 (struct accumulate): Change memory to struct objalloc *.
242 * liboasys.h (oasys_data_type): Remove oasys_obstack field.
243 * dep-in.sed: Don't remove obstack.h from dependency list.
244 * Makefile.in: Rebuild dependencies.
245 (BFD_H_DEPS): Remove obstack.h.
246 (install): Don't install obstack.h.
247 * Many files: Don't include "obstack.h".
248 * VERSION: Bump.
249
062a1b96
ILT
250 * opncls.c (bfd_alloc_grow, bfd_alloc_finish): Remove.
251 * libbfd-in.h (bfd_alloc_grow, bfd_alloc_finish): Don't declare.
252 * libbfd.h: Rebuild.
253 * ieee.c (ieee_archive_p): Rewrite to not use bfd_alloc_grow.
254 * sunos.c (sunos_add_dynamic_symbols): Likewise.
0103b447 255 * srec.c (srec_scan): Rewrite to not use obstack_1grow.
062a1b96 256
50ede03d
ILT
257 * opncls.c (bfd_alloc): Rename from bfd_alloc_by_size_t. Remove
258 old version of bfd_alloc.
259 * libbfd-in.h (bfd_alloc_by_size_t): Don't declare.
260 * libbfd.h: Rebuild.
261 * Several files: Call bfd_alloc rather than bfd_alloc_by_size_t.
262
5e67a3c6
ILT
263Sat Mar 15 15:24:18 1997 Ian Lance Taylor <ian@cygnus.com>
264
265 * elf32-mips.c (mips_elf_is_local_label_name): Accept the generic
266 ELF local label syntax as well.
267
7305cacd
FF
268Sat Mar 15 10:16:42 1997 Fred Fish <fnf@cygnus.com>
269
270 * config.bfd (powerpc-*-beos*): New target.
271 * configure.in (powerpc-*-beos*): Add case that explicitly
272 does not set COREFILE for now. A future BeOS version is
273 expected to support core files.
274 * configure: Regenerate with autoconf.
275
f56d634e
ILT
276Fri Mar 14 16:43:22 1997 Ian Lance Taylor <ian@cygnus.com>
277
4813bbed
ILT
278 * elf32-mips.c (mips_elf_check_relocs): Give an error if CALL16 is
279 seen with a local symbol, rather than crashing.
280
f56d634e
ILT
281 * elfcode.h (elf_slurp_symbol_table): Don't try to read the
282 version symbols if there aren't any.
283
4507d858
FF
284start-sanitize-tic80
285Thu Mar 13 16:38:30 1997 Fred Fish <fnf@cygnus.com>
286
287 * coff-tic80.c (coff_rtype_to_howto): Define
288 (coff_tic80_rtype_to_howto): Clone generic coff version and
289 add code to handle the funky TI "internal relocations".
290
291end-sanitize-tic80
94ba939a
ILT
292Thu Mar 13 14:08:53 1997 Ian Lance Taylor <ian@cygnus.com>
293
37897db0
ILT
294 * elflink.h (elf_link_add_object_symbols): Don't warn about type
295 or size changes because of a weak symbol.
296
94ba939a
ILT
297 * cisco-core.c (SIGEMT): Define if not defined.
298
e549b1d2
ILT
299Wed Mar 12 21:36:05 1997 Ian Lance Taylor <ian@cygnus.com>
300
301 * elflink.h (elf_link_add_object_symbols): Use extsymoff when
302 setting ever. Sanity check the version number. Sort out copying
303 flags and other information when adding an indirect symbol.
304 (NAME(bfd_elf,size_dynamic_sections)): Preserve any dynamic
305 symbols added by the backend. Clear the entire contents of the
306 versym section.
307 (elf_export_symbol): Ignore indirect symbols.
308 (elf_link_output_extsym): Accept a section without an owner in an
309 assert.
310 * elfcode.h (elf_slurp_symbol_table): Add a sanity check on the
311 version count. Correct the allocation of x_versymp.
312
313 * elf32-mips.c (mips_elf_add_symbol_hook): Don't set the owner of
314 the magic sections used for SHN_MIPS_TEXT and SHN_MIPS_DATA.
315 Don't return bfd_und_section_ptr when info->shared.
316 (mips_elf_final_link): Set the alignment of .rtproc to 4, not 12.
317 (mips_elf_create_dynamic_sections): Correct type: ^= for &=.
318 (mips_elf_check_relocs): Resolve an indirect symbol in
319 sym_hashes.
320 (mips_elf_finish_dynamic_symbol): Don't change SHN_ABS into
321 SHN_MIPS_TEXT or SHN_MIPS_DATA.
322
323 * elf.c (bfd_elf_print_symbol): Tweak version output slightly.
324
325Tue Mar 11 01:38:36 1997 Ian Lance Taylor <ian@cygnus.com>
326
327 From Eric Youngdale <eric@andante.jic.com>:
328 * elf-bfd.h (ELF_LINK_FORCED_LOCAL): Define.
329 * elf.c (bfd_elf_print_symbol): Correct errors in last change.
330 * elflink.h (elf_link_add_object_symbols): Handle cases in which a
331 versioned symbol appears in both a regular and a shared object.
332 (elf_link_assign_sym_version): Set ELF_LINK_FORCED_LOCAL when
333 appropriate. Improve error message.
334 (struct elf_outext_info): Rename from elf_finfo_failed. Change
335 all uses. Add localsyms field.
336 (elf_bfd_final_link): When generating a shared library, call
337 elf_link_output_extsym to output all local symbols.
338 (elf_link_output_extsym): Handle symbols which were forced to
339 become local.
340
d6bfcdb5
ILT
341Sun Mar 9 23:08:49 1997 Ian Lance Taylor <ian@cygnus.com>
342
343 From Eric Youngdale <eric@andante.jic.com>:
344 * elf-bfd.h (elf_symbol_type): Add version field.
345 * elfcode.h (elf_slurp_symbol_table): Set version field.
346 * elflink.h (elf_link_add_object_symbols): When creating an
347 indirect symbol for a default version symbol, set DEF_DYNAMIC if
348 appropriate. Set up an indirection from the nondefault version of
349 the symbol as well.
350 (NAME(bfd_elf,size_dynamic_sections)): Call
351 elf_link_assign_sym_version before checking whether there are any
352 versions. Always record the version name as a dynamic symbol.
353 Initialize counters.
354 (elf_link_assign_sym_version): After finding a version, see if a
355 symbol should be forced to local scope. Create a new version
356 definition if appropriate.
357 (elf_link_output_extsym): Correct indirect symbol handling.
358 * elf.c (bfd_elf_print_symbol): Print version information.
359 (bfd_section_from_shdr): Turn version sections into BFD sections.
360 (elf_fake_sections): Only copy cverdefs and cverrefs into sh_info
361 if sh_info is not already set.
362 (_bfd_elf_copy_private_section_data): Copy sh_info for version
363 sections.
364 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Tell
365 _bfd_stringtab_add to copy the name into permanent memory if
366 appropriate.
367
7debe20c
ILT
368Fri Mar 7 11:55:31 1997 H.J. Lu <hjl@gnu.ai.mit.edu>
369
370 * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Fully parenthesize.
371
358bb592
ILT
372Fri Mar 7 10:37:30 1997 Ian Lance Taylor <ian@cygnus.com>
373
ccd0e5e2
ILT
374 * coffcode.h (bfd_coff_backend_data): Change
375 _bfd_coff_compute_section_file_positions to return a boolean
376 value. Change all callers.
377 (coff_compute_section_file_positions): Change return type to
378 boolean. If the size of the last section changed, then output a
379 zero byte at the end of the file.
380 * libcoff.h: Rebuild.
381
e8c4696e
ILT
382 * xcofflink.c (_bfd_xcoff_bfd_final_link): Always allocate space
383 for at least 6 output symbols.
384 (xcoff_write_global_symbol): When emitting TOC entry relocs, also
385 emit a TC csect to represent the space they take up. For an XO
386 symbol, just emit a reference, not a csect.
387
4104dff6
ILT
388 * Makefile.in ($(SHLINK)): Just use ln -s, not ln -sf, since
389 Solaris doesn't like the combined options, and the -f is
390 unnecessary.
5bd7c941 391 (stamp-tshlink, install): Likewise.
4104dff6 392
358bb592
ILT
393 * elf32-mips.c (mips_elf_relocate_section): Correct R_MIPS16_26
394 handling when little endian.
395
77bf22e6
JL
396Thu Mar 6 13:51:51 1997 Jeffrey A Law (law@cygnus.com)
397
5847e6dd
JL
398 * elf32-mn10300.c (mn10300_elf_final_link_relocate): New function.
399 (mn10300_elf_relocate_section): Likewise.
400 (elf_backend_relocate_section): Define.
401
77bf22e6
JL
402 * elf32-mn10300.c (reloc_type): Remove PCREL{8,16,32}_{1,2}BYTE
403 relocs. Replace them with generic PCREL_{8,16,32} relocs.
404 (elf32_mn10300_howto_table): Likewise.
405 (elf32_mn10300_reloc_map): Likewise.
406 (bfd_elf32_mn10300_reloc): Delete unused function.
407
13b58694
FF
408Thu Mar 6 12:19:59 1997 Fred Fish <fnf@cygnus.com>
409
410start-sanitize-tic80
411 * coff-tic80.c (rtype2howto): If passed a relocation type we don't
412 understand, just set the howto field to NULL, and the caller will
413 print an appropriate error message.
414end-sanitize-tic80
415 * coffcode.h (coff_slurp_reloc_table): Pull duplicate declarations and
416 code fragment out of both legs of #ifdef RELOC_PROCESSING ... #endif
417 block. Use NULL for initializations of "ptr" rather than bare 0.
418 * coff-h8300.c: Fix typo in comment.
419 * coff-h8500.c: Ditto.
420 * coff-w65.c: Ditto
421 * coff-z8k.c: Ditto.
422
da171461
DE
423Wed Mar 5 13:59:09 1997 Doug Evans <dje@seba.cygnus.com>
424
425 * elf32-m32r.c (m32r_elf_do_10_pcrel_reloc): Fix overflow calc.
426 (m32r_elf_relax_section, m32r_elf_relax_delete_bytes,
427 m32r_elf_get_relocated_section_contents): First pass at relax support.
428
da171461
DE
429Mon Mar 3 13:27:09 1997 Ulrich Drepper <drepper@rtl.cygnus.com>
430
431 * elflink.h (elf_link_add_object_symbols): Use correct sh_size
432 entry for reading verdef records.
433 Use correct braces for computing increments of extverdaux and
434 exteverdef record pointers.
435
4b4ac3ae
FF
436start-sanitize-tic80
437Sun Mar 2 22:47:54 1997 Fred Fish <fnf@cygnus.com>
438
439 * coff-tic80.c (COFF_DEFAULT_SECTION_ALIGNMENT_POWER): Set this to 2
440 instead of 4.
441
442end-sanitize-tic80
a48ef404
ILT
443Sun Mar 2 16:25:35 1997 Ian Lance Taylor <ian@cygnus.com>
444
445 * elflink.h (elf_link_find_version_dependencies): Check that
446 DEF_REGULAR is not set as well as checking that DEF_DYNAMIC is
447 set.
448
84fd6e7e
FF
449start-sanitize-tic80
450Fri Feb 28 16:52:40 1997 Fred Fish <fnf@cygnus.com>
451
452 * coffcode.h (coff_set_flags): Add case for TIC80_ARCH_MAGIC.
453
454end-sanitize-tic80
af4dffff
ILT
455Fri Feb 28 15:06:45 1997 Ian Lance Taylor <ian@cygnus.com>
456
73769e1f
ILT
457 * targets.c (bfd_default_vector): Make non-const.
458 (find_target): New static function, broken out of
459 bfd_find_target.
460 (bfd_set_default_target): New function.
461 (bfd_find_target): Call find_target. When defaulting, use
462 bfd_default_vector[0] if it is not NULL.
463 * libbfd-in.h (bfd_default_vector): Adjust declaration.
464 * bfd-in2.h, libbfd.h: Rebuild.
465
af4dffff
ILT
466 * syms.c (bfd_is_local_label): Return false if the symbol has no
467 name.
468 * coff-i960.c (coff_i960_is_local_label_name): New function.
469 (coff_bfd_is_local_label_name): Define.
470 * coff-m68k.c (m68k_coff_is_local_label_name): New function.
471 (coff_bfd_is_local_label_name): Define.
472 * coff-rs6000.c (xcoff_is_local_label_name): New function.
473 (coff_bfd_is_local_label_name): Define.
474 * elf.c (_bfd_elf_is_local_label_name): Treat symbols beginning
475 with .. or _.L_ as local.
476 * elf32-i386.c (elf_i386_is_local_label_name): New function.
477 (bfd_elf32_bfd_is_local_label_name): Define.
478 * evax-alpha.c (evax_bfd_is_local_label_name): Treat symbols
479 beginning with $ as local.
480
85d6f0b4
ILT
481Thu Feb 27 18:36:23 1997 Ian Lance Taylor <ian@cygnus.com>
482
e316f514
ILT
483 * aoutx.h (aout_link_write_symbols): Use bfd_is_local_label_name
484 rather than comparing against info->lprefix.
485 * cofflink.c (_bfd_coff_link_input_bfd): Likewise.
486 * elflink.h (elf_link_input_bfd): Likewise.
487 * linker.c (_bfd_generic_link_output_symbols): Likewise.
488 * xcofflink.c (xcoff_link_input_bfd): Likewise.
489
490 * elfxx-target.h (bfd_elfNN_bfd_is_local_label_name): Define as
491 _bfd_elf_is_local_label_name if not already defined.
492 * elf.c (_bfd_elf_is_local_label_name): New function.
493 * elf-bfd.h (_bfd_elf_is_local_label_name): Declare.
494
495 * coff-m88k.c (coff_bfd_is_local_label_name): Define.
496 (m88k_is_local_label_name): New static function.
497
498 * coffcode.h (coff_bfd_is_local_label_name): Define as
499 _bfd_coff_is_local_label_name if not already defined.
500 * coffgen.c (_bfd_coff_is_local_label_name): New function.
501 * libcoff-in.h (_bfd_coff_is_local_label_name): Declare.
502 * libcoff.h: Rebuild.
503
35a3e78e
ILT
504 * targets.c (BFD_JUMP_TABLE_SYMBOLS): Change _bfd_is_local_label
505 to _bfd_is_local_label_name.
506 (bfd_target): Likewise.
507 * syms.c (bfd_is_local_label): Define as function, not macro.
508 (bfd_is_local_name): Define.
509 * libbfd.c (bfd_generic_is_local_label_name): Rename from
510 bfd_generic_is_local_label, and take a string rather than a
511 symbol.
512 * libbfd-in.h (_bfd_nosymbols_bfd_is_local_label): Don't define.
513 (_bfd_nosymbols_bfd_is_local_label_name): Define.
514 (bfd_generic_is_local_label): Don't declare.
515 (bfd_generic_is_local_label_name): Declare.
516 * bfd-in2.h, libbfd.h: Rebuild.
517 * All backends: Change local_label to local_label_name.
518
85d6f0b4
ILT
519 * elf32-mips.c (struct mips_got_info): Add assigned_gotno field.
520 (mips_elf_relocate_got_local): Change return type to boolean.
521 Don't assume that the first zero entry is unassigned; instead, use
522 assigned_gotno.
523 (mips_elf_relocate_section): Check return value of
524 mips_elf_relocate_got_local.
525 (mips_elf_create_got_section): Initialize assigned_gotno field.
526
56819c99
MH
527start-sanitize-d30v
528Wed Feb 26 15:19:51 1997 Martin M. Hunt <hunt@pizza.cygnus.com>
529
530 * elf32-d30v.c (bfd_elf_d30v_reloc): Add code to do 32-bit
531 relocations.
532
533end-sanitize-d30v
fa802cb0
ILT
534Wed Feb 26 13:33:03 1997 Ian Lance Taylor <ian@cygnus.com>
535
536 * elflink.h (elf_link_input_bfd): Don't skip symbols from sections
537 that have no contents merely because linker_mark is not set.
538
539Tue Feb 25 18:51:35 1997 Stan Shebs <shebs@andros.cygnus.com>
540
541 * config.bfd (mips*-*-lnews*): New target.
542 * coff-mips.c (mips_relocate_section): Make assert compare
543 content byteorder instead of header byteorder.
544 (ecoff_biglittle_vec): New BFD, big-endian headers, little-endian
545 data.
55ef0d90 546 * targets.c (bfd_target_vector): Add ecoff_biglittle_vec.
fa802cb0
ILT
547 * configure.in (ecoff_biglittle_vec): Add case.
548 * configure: Update.
549
7b4be668
ILT
550Tue Feb 25 00:32:49 1997 Ian Lance Taylor <ian@cygnus.com>
551
b08f5ac2
ILT
552 * elf.c (elf_fake_sections): Use SHT_NOTE for any section whose
553 name begins with ".note".
554 (map_sections_to_segments): Add a PT_NOTE segment for any loadable
555 section whose name begins with ".note".
556 (get_program_header_size): Corresponding change.
557
7b4be668
ILT
558 * elf32-mips.c (mips_elf_relocate_section): Check for misaligned
559 jal and for jal overflow.
560
561Mon Feb 24 17:53:14 1997 Ian Lance Taylor <ian@cygnus.com>
562
563 From Eric Youngdale <eric@andante.jic.com>:
564 * elflink.h (elf_link_add_archive_symbols): If a default symbol is
565 not found, try looking it up again without the version name.
566 (elf_link_add_object_symbols): Always link against the dynamic
567 symbol table of a dynamic object. When linking against a dynamic
568 object, include version strings in symbol names, and set up
569 version information. Add indirect symbols for default versions.
570 (elf_link_create_dynamic_sections): Add special version sections.
571 (struct elf_assign_sym_version_info): Define.
572 (struct elf_find_verdep_info): Define.
573 (NAME(bfd_elf,size_dynamic_sections)): Add verdefs parameter. Set
574 up version sections.
575 (elf_adjust_dynamic_symbol): Ignore indirect symbols.
576 (elf_link_find_version_dependencies): New static function.
577 (elf_link_assign_sym_version): New static function.
578 (elf_link_renumber_dynsyms): New static function.
579 (struct elf_final_link_info): Add symver_sec field.
580 (elf_bfd_final_link): Initialize finfo.symver_sec. Don't count
581 local symbols of a dynamic object. Handle DT_VER* constants.
582 (elf_link_output_extsym): Simplify BFD_ASSERT checking for a
583 dynamic object. Skip indirect symbols from ELF objects. Remove
584 the version name before choosing a hash bucket. Write out the
585 version information if appropriate.
586 (elf_link_input_bfd): Check for DYNAMIC, not ET_DYN.
587 * bfd-in.h (bfd_elf32_size_dynamic_sections): Update declaration.
588 (bfd_elf64_size_dynamic_sections): Likewise.
589 * bfd-in2.h: Rebuild.
590 * elf-bfd.h (struct elf_link_hash_entry): Add verinfo field.
591 Change elf_link_hash_flags to unsigned short.
592 (ELF_LINK_HIDDEN): Define.
593 (struct elf_obj_tdata): Add fields dynversym_hdr, dynverref_hdr,
594 dynverdef_hdr, dynversym_section, dynverdef_section,
595 dynverref_section, cverdefs, cverrefs, verdef, verref.
596 (elf_dynversym, elf_dynverdef, elf_dynverref): Define.
597 (_bfd_elf_swap_verdef_in, _bfd_elf_swap_verdef_out): Declare.
598 (_bfd_elf_swap_verdaux_in, _bfd_elf_swap_verdaux_out): Declare.
599 (_bfd_elf_swap_verneed_in, _bfd_elf_swap_verneed_out): Declare.
600 (_bfd_elf_swap_vernaux_in, _bfd_elf_swap_vernaux_out): Declare.
601 (_bfd_elf_swap_versym_in, _bfd_elf_swap_versym_out): Declare.
602 (_bfd_elf_slurp_version_tables): Declare.
603 * elf.c (_bfd_elf_swap_verdef_in): New function.
604 (_bfd_elf_swap_verdef_out): Likewise.
605 (_bfd_elf_swap_verdaux_in, _bfd_elf_swap_verdaux_out): Likewise.
606 (_bfd_elf_swap_verneed_in, _bfd_elf_swap_verneed_out): Likewise.
607 (_bfd_elf_swap_vernaux_in, _bfd_elf_swap_vernaux_out): Likewise.
608 (_bfd_elf_swap_versym_in, _bfd_elf_swap_versym_out): Likewise.
609 (_bfd_elf_print_private_bfd_data): Add DT_VER* constants. Print
610 version information if there is any.
611 (_bfd_elf_link_hash_newfunc): Initialize verinfo field.
612 (bfd_section_from_shdr): Handle SHT_GNU_ver* section types.
613 (elf_fake_sections): Handle .gnu.version* section names.
614 (assign_section_numbers): Handle SHT_GNU_ver* section types.
615 (_bfd_elf_slurp_version_tables): New function.
616 * elflink.c (_bfd_elf_link_record_dynamic_symbol): Don't include
617 version name in string entered in dynamic hash table.
618 * elfcode.h: Include fnmatch.h.
619 * elf32-i386.c (elf_i386_relocate_section): Handle a dynamic
620 symbol which was forced to become local.
621 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
622 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
623 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
624 * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Likewise.
625
7b951eed
JL
626Fri Feb 21 16:15:18 1997 Jeffrey A Law (law@cygnus.com)
627
628 * elf32-mn10200.c (mn10200_elf_final_link_relocate): Simplify
629 somewhat.
630 (mn10200_elf_relax_section): Correctly compute a symbol's value
631 when the symbol is local, but not in the same section as we are
632 relaxing. Implement abs24 -> abs16, imm24 -> imm16 and d24 -> d16
633 relaxing.
634
77dd1a25
DE
635Fri Feb 21 13:55:14 1997 Doug Evans <dje@seba.cygnus.com>
636
637 * elf32-m32r.c: Rewrite to use ELF backend linker.
638 Store lower 16 bits of addend in R_M32R_HI16_[SU]LO insns.
639 Add small data area support (R_M32R_SDA16).
640 * reloc.c: Document BFD_RELOC_M32R_SDA16.
641 * bfd-in2.h,libbfd.h: Regenerated.
642
fd395661
JL
643Thu Feb 20 23:50:31 1997 Jeffrey A Law (law@cygnus.com)
644
645 * elf32-mn10200.c (mn10200_elf_relax_section): New function.
646 (mn10200_elf_relax_delete_bytes): Likewise.
647 (mn10200_elf_symbol_address_p): Likewise.
648 (mn10200_elf_get_relocated_section_contents): Likewise.
649 (bfd_elf32_bfd_relax_section): Define.
650 (bfd_elf32_bfd_get_relocated_section_contents): Likewise.
64af6679
JL
651
652 * elf32-mn10200.c (mn10200_elf_final_link_relocate): New function.
653 (mn10200_elf_relocate_section): Likewise.
654 (elf_backend_relocate_section): Define.
655
fd8d7c31
MH
656start-sanitize-d30v
657Tue Feb 18 17:22:59 1997 Martin M. Hunt <hunt@pizza.cygnus.com>
658
659 * Makefile.in, archures.c, config.bfd, configure.in, elf.c,
660 reloc.c, targets.c: New target, elf-*-D30V.
661
662 * bfd-in2.h, configure, libbfd.h: Rebuilt.
663
664 * cpu-d30v.c, elf32-d30v.c: New files.
665
666end-sanitize-d30v
92a956e8
FF
667Tue Feb 18 15:31:48 1997 Fred Fish <fnf@cygnus.com>
668
669 * reloc.c (struct reloc_howto_struct): Fix typo in comment.
670 * bfd-in2.h: Regenerated.
671start-sanitize-tic80
672 * coff-tic80.c (RTYPE2HOWTO): Replace abort with real function.
673 (rtype2howto): Add function.
674 (tic80_howto_table): Add.
675end-sanitize-tic80
676
677Tue Feb 18 11:41:00 1996 Dawn Perchik <dawn@cygnus.com>
678
679 * sysdep.h: Don't define errno in MSVC if error.h is included.
680
8d1ba96e
JL
681start-sanitize-v850
682Tue Feb 18 10:04:13 1997 Jeffrey A Law (law@cygnus.com)
683
684 * elf32-v850.c (v850_elf_relocate_section): Make sure r_symndx
685 is initialized before it is used.
686
687end-sanitize-v850
8ceca983
ILT
688Mon Feb 17 11:28:40 1997 Ian Lance Taylor <ian@cygnus.com>
689
690 * hp300hpux.c (convert_sym_type): Don't convert a secondary common
691 symbol into a weak undefined symbol; leave it as a common symbol.
692
54626f1a
ILT
693Fri Feb 14 19:08:03 1997 Ian Lance Taylor <ian@cygnus.com>
694
695 * elflink.h (elf_link_add_object_symbols): Don't issue a warning
696 about a symbol defined in a dynamic object if it has already been
697 defined in a regular object.
698
236969ac
ILT
699Thu Feb 13 20:53:22 1997 Klaus Kaempf (kkaempf@progis.de)
700
701 * makefile.vms: Add gcc flags to allow compiling with current gcc
702 snapshot
703 (targmatch.h): New dependency.
704
54626f1a
ILT
705 * reloc.c (BFD_RELOC_ALPHA_CODEADDR): New relocation for
706 openVMS/Alpha.
707 * evax.h (ALPHA_R_CODEADDR): New relocation.
708 * evax-alpha.c (ALPHA_R_CODEADDR): 64 bit procedure relocation for
709 openVMS/Alpha.
710 * evax-etir.c (ALPHA_R_CODEADDR): Output object code for this
711 relocation.
712 * bfd-in2.h, libbfd.h: Rebuild.
713
714 Restrict symbol length to 64 bytes, case preserving:
715 * evax-emh.c (_bfd_evax_write_emh): Remove case hacking.
716 * evax-misc.c (_bfd_evax_case_hack_symbol): Remove.
717 (_bfd_evax_length_hash_symbol): Added.
718 * evax-etir.c (_bfd_evax_write_etir): Call
719 _bfd_evax_length_hash_symbol before output of symbol.
720 * evax-egsd.c (_bfd_evax_write_egsd): Likewise.
721 * evax.h (flag_hash_long_names, flag_show_after_trunc): Remove.
722
723 * evax-emh.c: Output filename to object file without path.
724
725 * evax-egsd.c: New sections for local and global commons.
726
727 * evax-alpha.c, evax-emh.c, evax-egsd.c, evax-etir.c,
728 evax-misc.c, evax.h: Remove 8 bit characters from copyright
729 notices. Replace AXP with Alpha.
730
62332d05
ILT
731Wed Feb 12 18:10:30 1997 Ian Lance Taylor <ian@cygnus.com>
732
733 * sunos.c (sunos_create_dynamic_sections): We need the dynamic
734 sections if we are creating a shared library.
735
3883007e
DE
736Tue Feb 11 15:45:43 1997 Doug Evans <dje@canuck.cygnus.com>
737
738 * configure.host (i386-windows): Don't set host64=true.
739
a4183ba5
ILT
740Tue Feb 11 15:27:32 1997 Ian Lance Taylor <ian@cygnus.com>
741
742 * elf32-mips.c (reloc_type): Add R_MIPS16_GPREL.
743 (elf_mips16_gprel_howto): New static variable.
744 (mips16_gprel_reloc): New static function.
745 (bfd_elf32_bfd_reloc_type_lookup): Handle BFD_RELOC_MIPS16_GPREL.
746 (mips_info_to_howto_rel): Handle R_MIPS16_GPREL.
747 (mips_elf_relocate_section): Handle R_MIPS16_GPREL.
748 * reloc.c (BFD_RELOC_MIPS16_GPREL): Define.
749 * bfd-in2.h, libbfd.h: Rebuild.
750
b9c5ee68
DE
751Mon Feb 10 23:25:00 1997 Doug Evans <dje@seba.ricochet.net>
752
753 * elf32-m32r.c (elf_m32r_howto_table): Change partial_inplace to true
754 for R_M32R_{16,32,24,HI16_ULO,HI16_SLO,LO16}.
755
276c2d7d
GRK
756start-sanitize-r5900
757 Fri Feb 7 16:20:17 1997 Gavin Koch <gavin@cygnus.com>
758
759 * config.bfd: add r5900
760
761end-sanitize-r5900
ba4a4594
ILT
762Fri Feb 7 12:39:11 1997 Ian Lance Taylor <ian@cygnus.com>
763
764 * elflink.h (elf_link_input_bfd): If we've discarded a section,
765 the output section will be the absolute section; don't print an
766 assertion message for that case when doing a relocateable link.
767
e900e695
ILT
768Thu Feb 6 16:55:43 1997 Ian Lance Taylor <ian@cygnus.com>
769
770 * elf32-mips.c (FN_STUB, CALL_STUB, CALL_FP_STUB): Define.
771 (struct mips_elf_link_hash_entry): Add new fields fn_stub,
772 need_fn_sub, call_stub, and call_fp_stub.
773 (struct mips_elf_link_hash_table): Add field mips16_stubs_seen.
774 (mips_elf_link_hash_newfunc): Initialize new fields.
775 (mips_elf_link_hash_table_create): Likewise.
776 (mips_elf_relocate_section): Redirect relocations to use mips16
777 stubs when appropriate.
778 (mips_elf_check_relocs): Attach stub sections to the appropriate
779 symbol. Set need_fn_stub when appropriate.
780 (mips_elf_always_size_sections): New static function.
781 (mips_elf_check_mips16_stubs): New static function.
782 (elf_backend_always_size_sections): Define.
783 * elf-bfd.h (struct elf_obj_tdata): Add local_stubs field.
784
785 * elflink.h (elf_link_input_bfd): Discard local symbols that are
786 attached to sections which are not being included in the link.
787
5b61a02a
ILT
788Wed Feb 5 13:20:17 1997 Ian Lance Taylor <ian@cygnus.com>
789
790 * cofflink.c (_bfd_coff_generic_relocate_section): Ignore the
791 symbol value when computing the addend for a pc_relative
792 pcrel_offset reloc.
793
bcb686ca
ILT
794Mon Feb 3 11:54:06 1997 Ian Lance Taylor <ian@cygnus.com>
795
5a50eec6
ILT
796 * cofflink.c (_bfd_coff_generic_relocate_section): If doing a
797 relocateable link, just skip pc_relative pcrel_offset relocs.
798 * coff-arm.c (coff_arm_rtype_to_howto): Return a different howto
799 structure for an ARM26 reloc which can be resolved.
800 (coff_arm_adjust_symndx): Only convert ARM26 to ARM26D if the
801 reloc can be resolved.
802
bcb686ca
ILT
803 * coff-h8300.c (h8300_reloc16_extra_cases): Correct off by one
804 error in overflow check for R_RELBYTE.
805
167dc907
ILT
806Fri Jan 31 14:07:27 1997 Ian Lance Taylor <ian@cygnus.com>
807
6c58561e
ILT
808 * ieee.c (ieee_slurp_section_data): Pick up the start address.
809 From Mark Rasin <mark.rasin@telrad.co.il>.
810
167dc907
ILT
811 * aoutx.h (aout_link_write_symbols): Don't apply discard_l to
812 debugging symbols.
813
1a2faf1f
JL
814Wed Jan 29 00:00:49 1997 Jeffrey A Law (law@cygnus.com)
815
816 * elf32-mn10200.c (reloc_type): Add 16bit pc-relative reloc.
817 (elf_mn10200_howto_table): Likewise.
818 (mn10200_reloc_map): Likewise.
819
1d5c6cfd
DE
820Mon Jan 27 12:07:35 1997 Doug Evans <dje@seba.cygnus.com>
821
822 * reloc.c: Add relocs BFD_RELOC_M32R_{HI16_[US]LO,LO16}.
823 * bfd-in2.h, libbfd.h: Regenerated.
824 * elf32-m32r.c: Add support for them.
825
9950f925
ILT
826Mon Jan 27 12:25:02 1997 Ian Lance Taylor <ian@cygnus.com>
827
54aa1dea
ILT
828 * aout-arm.c (MY_swap_std_reloc_in): Remove unused r_length.
829 * elf32-ppc.c (ppc_elf_check_relocs): Remove unused plt.
830start-sanitize-v850
831 * elf32-v850.c (v850_elf_final_link_relocate): Remove used
832 r_format and r_pcrel. Always return a value.
833end-sanitize-v850
834 * riscix.c (MY_final_link_callback): Define to dummy value.
835
9950f925
ILT
836 * elf32-i386.c (elf_i386_size_dynamic_sections): When checking for
837 relocations against the text segment, look up the output name of
838 the reloc section.
839 * elf32-m68k.c (elf_m68k_size_dynamic_sections): Likewise.
840 * elf32-mips.c (mips_elf_size_dynamic_sections): Likewise.
841 * elf32-ppc.c (ppc_elf_size_dynamic_sections): Likewise.
842 * elf32-sparc.c (elf32_sparc_size_dynamic_sections): Likewise.
843 * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Likewise.
844
0716c2e9 845start-sanitize-tic80
8c00b01d
FF
846Wed Jan 22 15:40:28 1997 Fred Fish <fnf@cygnus.com>
847
848 * coff-tic80.c (tic80coff_vec): Use correct data put/get
849 routines for little endian data.
850 * coffcode.h (coff_write_object_contents): Set magic to
851 TIC80_ARCH_MAGIC for TIc80.
852
0716c2e9
FF
853Tue Jan 21 12:32:43 1997 Fred Fish <fnf@cygnus.com>
854
855 * coff-tic80.c (tic80coff_vec): Change to little endian data
856 as the default.
857
858end-sanitize-tic80
db109ca2
ILT
859Thu Jan 16 17:45:57 1997 Ian Lance Taylor <ian@cygnus.com>
860
861 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Change type of
862 auxiliary_filters parameter to be const char * const *. Accept a
863 NULL terminated array.
864 * bfd-in.h (bfd_elf32_size_dynamic_sections): Update declaration.
865 (bfd_elf32_size_dynamic_sections): Update declaration.
866 * bfd-in2.h: Rebuild.
867
868Wed Jan 15 11:21:32 1997 Ian Lance Taylor <ian@cygnus.com>
869
870 * elf32-sparc.c (elf32_sparc_adjust_dynamic_symbol): Treat a
871 NOTYPE symbol in a text section as a FUNC symbol.
872
873 * coffcode.h (coff_compute_section_file_positions): Force
874 relocbase to be aligned to COFF_DEFAULT_SECTION_ALIGNMENT_POWER.
875
e1616e16
DE
876Tue Jan 14 08:46:33 1997 Doug Evans <dje@canuck.cygnus.com>
877
878 * libaout.h (machine_type): Reserve several values for sparclet.
879
4af93ad0
MM
880start-sanitize-tic80
881Mon Jan 13 22:39:08 1997 Michael Meissner <meissner@tiktok.cygnus.com>
882
883 * config.bfd (tic80-*-*): Don't require 'coff'.
884
91eb4378 885end-sanitize-tic80
0ce71ebd
MM
886start-sanitize-v850
887Mon Jan 13 19:36:25 1997 Michael Meissner <meissner@tiktok.cygnus.com>
888
889 * elf32-v850.c (v850_elf_howto_table): Set the special_function
890 table to v850_elf_reloc for all non-standard relocations.
891 (v850_elf_check_relocs): Add check for h being non-null.
892 (v850_elf_reloc): Add R_V850_ZDA_OFFSET support. Use switch
893 statement instead of multiple ifs.
894 (v850_elf_relocate_section): Fix up error message, don't just call
895 abort.
896
897end-sanitize-v850
483e1b91
JL
898Mon Jan 6 13:28:35 1997 Jeffrey A Law (law@cygnus.com)
899
09a7bde3 900 * elf32-mn10200.c (elf_mn10200_howto): Don't ever set partial-inplace.
40131692
JL
901 Use bfd_elf_generic_reloc as special function for all relocs.
902 (bfd_elf32_mn10200_reloc): Remove unnecessary function.
903
904 * elf32-mn10200.c (elf_mn10200_howto): Set pcrel_offset for
483e1b91
JL
905 24bit pc-relative reloc.
906
28eb95aa
FF
907start-sanitize-tic80
908Fri Jan 3 16:33:00 1997 Fred Fish <fnf@cygnus.com>
909
910 * Makefile.in (coff-tic80.o): Add coffcode.h to dependency list.
911 * coff-tic80.c (tic80coff_vec): Data byte order is big endian and
912 header byte order is little endian. Use correct bfd_get and
913 bfd_put routines for little endian headers.
914 * coffcode.h (coff_set_arch_mach_hook): Set arch to
915 bfd_arch_tic80 for TIC80_ARCH_MAGIC number.
916
917end-sanitize-tic80
b3ef3894
JL
918Fri Jan 3 16:54:08 1997 Jeffrey A Law (law@cygnus.com)
919
920 * reloc.c: Add BFD_RELOC_24.
921 * elf32-mn10200.c (enum reloc_type): Add 24bit and pcrel relocs.
922 (elf_mn10200_howto, mn10200_reloc_map): Corresponding changes.
923 * bfd-in2.h, libbfd.h: Rebuilt.
924
ff12f303
ILT
925Fri Jan 3 16:58:31 1997 Richard Henderson <rth@tamu.edu>
926
927 elf64-alpha multiple .got rewrite:
928
929 * elf-bfd.h (struct elf_backend_data): Add always_size_sections entry.
930 (bfd_elf*_mkobject): Don't define here ...
931 * elfxx-target.h: ... but rather here. Default always_size_sections
932 hook to NULL.
933 * elf.c (elf_mkobject): Rename to bfd_elf_mkobject, since that was
934 what the #defines in elf-bfd.h transmuted it to anyway.
935
936 * section.c: Add SEC_LINKER_CREATED flag.
937 * bfd-in2.h: Rebuild.
938 * elf32-i386.c (elf_i386_check_relocs): Add SEC_LINKER_CREATED to
939 relocation section flags.
940 (elf_i386_size_dynamic_sections): Use SEC_LINKER_CREATED instead of
941 SEC_IN_MEMORY to recognize generated bits.
942 * elf32-m68k.c (elf_m68k_check_relocs, elf_m68k_size_dynamic_sections):
943 Likewise.
944 * elf32-mips.c (mips_elf_final_link, mips_elf_create_dynamic_sections,
945 mips_elf_create_compact_rel_section, mips_elf_create_got_section,
946 mips_elf_check_relocs, mips_elf_size_dynamic_sections): Likewise.
947 * elf32-ppc.c (ppc_elf_create_linker_section,
948 ppc_elf_size_dynamic_sections): Likewise.
949 * elf32-sparc.c (elf32_sparc_check_relocs,
950 elf32_sparc_size_dynamic_sections): Likewise.
951 * elflink.c (_bfd_elf_create_got_section): Add SEC_LINKER_CREATED to
952 section flags.
953 (_bfd_elf_create_dynamic_sections): Likewise.
954 (_bfd_elf_make_linker_section_rela): Likewise.
955 * elflink.h (elf_link_create_dynamic_sections): Likewise.
956 (bfd_elf,size_dynamic_sections): Call the always_size_sections hook.
957 (elf_bfd_final_link): Use SEC_LINKER_CREATED instead of SEC_IN_MEMORY
958 to identify generated bits.
959 (elf_link_input_bfd): Likewise.
960
961 * elf64-alpha.c: Rewrite everything touching relocations.
962
afaed5e9 963start-sanitize-v850
de224d6a
MM
964Fri Jan 3 11:42:53 1997 Michael Meissner <meissner@tiktok.cygnus.com>
965
966 * elf32-v850.c (all functions and static variables): Go through
967 and regularize names to be of the form v850_elf_<xxx>.
968 (toplevel): Include <elf/v850.h>.
969 (enum reloc_type): Move to include/elf/v850.h.
970 (v850_elf_check_relocs): For common variables, if the variable is
971 referenced by a R_V850_{SDA,ZDA,TDA} relocation, put the variable
972 into the appropriate section.
973 (elf_backend_check_relocs): Define.
974
afaed5e9
MM
975Tue Dec 31 15:15:28 1996 Michael Meissner <meissner@tiktok.cygnus.com>
976
977 * elf32-v850.c (elf_v850_howto_table): Fix some spacing.
978
979end-sanitize-v850
148437ec
ILT
980Tue Dec 31 14:44:50 1996 Ian Lance Taylor <ian@cygnus.com>
981
7c342fc5
ILT
982 * config.bfd (mips*el-*-linux*): New target.
983 (mips*-*-linux*): New target.
984
985 * elf32-mips.c (_bfd_mips_elf_merge_private_bfd_data): Clean up.
986 Return a useful value.
987
6ded6615
ILT
988 * Makefile.in (ALL_CFLAGS): Add -D_GNU_SOURCE.
989
dda7af9f
ILT
990 * configure.in: Check ac_cv_func_mmap_fixed_mapped, not
991 ac_cv_func_mmap.
992 * configure: Rebuild.
ab98712a
ILT
993 * configure.host: Use ac_cv_func_mmap_fixed_mapped instead of
994 ac_cv_func_mmap in bfd/configure.host.
dda7af9f 995
148437ec
ILT
996 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Add
997 filter_shlib and auxiliary_filter_shlib parameters.
998 * elf.c (_bfd_elf_print_private_bfd_data): Handle DT_AUXILIARY and
999 DT_FILTER.
1000 * bfd-in.h (bfd_elf32_size_dynamic_sections): Update declaration.
1001 (bfd_elf64_size_dynamic_sections): Likewise.
1002 * bfd-in2.h: Rebuild.
1003
1eeccb22
ILT
1004Mon Dec 30 18:48:52 1996 Ian Lance Taylor <ian@cygnus.com>
1005
1006 * xcofflink.c (xcoff_build_ldsyms): When exporting all defined
1007 symbols, don't export a symbol which is defined by an object in an
1008 archive which contains shared objects.
1009
60b26712 1010start-sanitize-tic80
fc46a9ec
FF
1011Mon Dec 30 16:12:58 1996 Fred Fish <fnf@cygnus.com>
1012
1013 * archures.c (enum bfd_architecture): Add bfd_arch_tic80
1014 for TI TMS320c80 (MVP).
1015 (bfd_archures_list): Add bfd_tic80_arch.
1016 * bfd-in2.h: Regenerate by running "make headers".
1017
60b26712
FF
1018Sun Dec 29 16:18:52 1996 Fred Fish <fnf@cygnus.com>
1019
1020 * cpu-tic80.c (bfd_tic80_arch): Add struct.
1021 * configure.in (case $vec): Correct typo, "tb" not "tp".
1022 Also add cofflink.o for tic80coff_vec.
1023 * configure: Regenerate with autoconf.
1024
1025end-sanitize-tic80
412f8c93
ILT
1026Mon Dec 30 11:54:56 1996 Ian Lance Taylor <ian@cygnus.com>
1027
1028 * libbfd.c: Patch up the mmap code so that it is only built if BFD
1029 is configured with --with-mmap.
1030
5a608f5b 1031start-sanitize-tic80
fc46a9ec 1032Sun Dec 29 10:48:57 1996 Fred Fish <fnf@cygnus.com>
5a608f5b
FF
1033
1034 * Makefile.in (BFD32_BACKENDS): Add coff-tic80.o
1035 (ALL_MACHINES): Add cpu-tic80.o
1036 (cpu-tic80.o, coff-tic80.o): Add dependencies.
1037 * coff-tic80.c: Add skeleton, cloned from another coff config.
1038 * coffcode.h (coff_write_object_contents): Set magic to TIC80MAGIC
1039 for TIc80.
1040
1041end-sanitize-tic80
60b26712 1042Fri Dec 27 20:56:41 1996 Fred Fish <fnf@cygnus.com>
cd6213ff
FF
1043
1044 * TODO: Correct a misspelling.
1045start-sanitize-tic80
1046 * coff-tic80.c: New file for TI TMS320C80 (MVP).
1047 * cpu-tic80.c: New file for TI TMS320C80 (MVP).
1048 * configure.in (case $vec): Add tic80coff_vec entry.
1049 * configure: Regenerate with autoconf.
1050 * archures.c (bfd_tic80_arch): Declare.
1051 * bfd-in2.h (enum bfd_architecture): Add bfd_arch_tic80.
1052 * config.bfd (case ${targ}): Add tic80*-*-coff* target.
1053 * targets.c (tic80coff_vec): Add decl as extern bfd_target.
1054 (bfd_target_vector): Add tic80coff_vec entry.
1055end-sanitize-tic80
1056
6b8ec6f3
ILT
1057Fri Dec 27 11:48:12 1996 H.J. Lu <hjl@lucon.org>
1058
1059 * elflink.h (elf_buckets): Add some more values for larger
1060 binaries.
1061
78650abd
ILT
1062Thu Dec 26 18:36:54 1996 Ian Lance Taylor <ian@cygnus.com>
1063
1064 * Makefile.in (install): Move subdir_do out of conditional. From
1065 Fred Fish <fnf@cygnus.com>.
1066
8d16fe5c
JL
1067Wed Dec 18 10:04:30 1996 Jeffrey A Law (law@cygnus.com)
1068
1069 * elf32-mn10200.c (enum reloc_type): Enable basic 8, 16, and
1070 32 bit relocs.
1071 (elf_mn10200_howto_table): Likewise.
1072 (mn10200_reloc_map): Likewise.
1073
69e2ff18
ILT
1074Tue Dec 17 11:09:36 1996 Ian Lance Taylor <ian@cygnus.com>
1075
e4f4813f
ILT
1076 * elf32-mips.c (mips_elf_add_symbol_hook): Add 1 to the value of a
1077 mips16 symbol during the link.
1078 (mips_elf_finish_dynamic_symbol): Subtract 1 from the value of a
1079 mips16 symbol.
1080 (mips_elf_link_output_symbol_hook): New static function.
1081 (elf_backend_link_output_symbol_hook): Define.
1082
69e2ff18
ILT
1083 * elf.c (bfd_elf_print_symbol): Print the st_other field if it is
1084 not zero.
1085
e85f2fbd
ILT
1086Mon Dec 16 14:38:39 1996 Ian Lance Taylor <ian@cygnus.com>
1087
1088 * elf.c (bfd_section_from_shdr): Don't check for reloc sections
1089 against SEC_DEBUGGING sections here (revert patch of December 5).
1090 * elfcode.h (elf_object_p): Check for them here, instead.
1091
e35765a9
ILT
1092Sun Dec 15 14:46:06 1996 Ian Lance Taylor <ian@cygnus.com>
1093
1094 * elfcode.h (elf_slurp_reloc_table): Add dynamic parameter.
1095 * elf.c (_bfd_elf_canonicalize_reloc): Pass new argument to
1096 slurp_reloc_table.
1097 (_bfd_elf_get_dynamic_reloc_upper_bound): New function.
1098 (_bfd_elf_canonicalize_dynamic_reloc): New function.
1099 * elf-bfd.h (struct elf_size_info): Update declaration of
1100 slurp_reloc_table.
1101 (_bfd_elf_get_dynamic_reloc_upper_bound): Declare.
1102 (_bfd_elf_canonicalize_dynamic_reloc): Declare.
1103 * elfxx-target.h: Use new dynamic reloc routines by default.
1104 * elf64-mips.c (mips_elf64_slurp_reloc_table): Add dynamic
1105 parameter.
1106
6270adfb
ILT
1107Fri Dec 13 13:18:49 1996 Dan Wilder <dan@gasboy.com>
1108
1109 * coffcode.h (coff_set_flags): Use MC68KBCSMAGIC for bfd_arch_m68k
1110 if NAMES_HAVE_UNDERSCORE is defined.
1111
21e45f82
DE
1112Fri Dec 13 11:13:23 1996 Doug Evans <dje@canuck.cygnus.com>
1113
1114 * libaout.h (enum machine_type): Change M_SPARCLET from 142 to 131.
1115
e7bab9df
MM
1116Thu Dec 12 15:07:20 1996 Michael Meissner <meissner@tiktok.cygnus.com>
1117
1118 * elf32-ppc.c (ppc_elf_check_relocs): Move R_PPC_PLTREL24 into the
1119 supported relocs.
1120
a5147005
ILT
1121Thu Dec 12 14:55:41 1996 Ian Lance Taylor <ian@cygnus.com>
1122
440f3914
ILT
1123 * elflink.h (elf_link_add_object_symbols): Only add a weak
1124 symbol if the real definition is in the dynamic symbol table.
1125 After finding the real definition, then, if it is dynamic, add the
1126 weak symbol to the dynamic symbol table.
1127
e5c3708d
ILT
1128 * coff-aux.c (coff_m68k_aux_link_add_one_symbol): Make static.
1129
a5147005
ILT
1130 * ppcboot.c (ppcboot_set_arch_mach): Don't define; it's a
1131 function.
1132 (ppcboot_bfd_print_private_bfd_data): Don't take the address of an
1133 array.
1134
1135Tue Dec 10 23:23:52 1996 Jeffrey A Law (law@cygnus.com)
1136
1137 * elf32-mn10300.c (reloc_type): Remove big endian mn10300 reloc
1138 variants.
1139 (elf32_mn10300_howto_table, mn10300_reloc_map): Likewise.
1140 (bfd_elf32_mn10300_reloc): Write data in little endian format.
1141 * reloc.c: Remove mn10300 big endian relocs.
1142 * bfd-in2.h, libbfd.h: Rebuilt.
1143
1144 * elf32-mn10200.c: Update from elf32-mn10300.c.
1145
207e944c
JL
1146Fri Dec 6 15:18:05 1996 Jeffrey A Law (law@cygnus.com)
1147
31cffd2e
JL
1148 * elf32-mn10300.c (elf_symbol_leading_char): Define.
1149
207e944c
JL
1150 * elf32-mn10300.c: Add some comments.
1151
6dcf1ef5
ILT
1152Fri Dec 6 17:16:43 1996 Ian Lance Taylor <ian@cygnus.com>
1153
1154 * ihex.c (ihex_scan): Always initialize buf before jumping to
1155 error_return.
1156 (ihex_read_section): Likewise.
1157
d28f058e
JL
1158Thu Dec 5 22:29:18 1996 Jeffrey A Law (law@cygnus.com)
1159
1160 * elf32-mn10300.c (elf_mn10300_howto_table): Don't set partial-
1161 inplace for most relocs.
1162
80be821d
ILT
1163Thu Dec 5 13:24:46 1996 Ian Lance Taylor <ian@cygnus.com>
1164
1165 * elflink.h (elf_link_add_object_symbols): Calling check_relocs
1166 even if SEC_ALLOC is not set.
1167 * elf32-i386.c (elf_i386_check_relocs): Don't check SEC_ALLOC
1168 when deciding whether to copy a reloc into a shared object.
1169 (elf_i386_relocate_section): Likewise.
1170 * elf32-sparc.c (elf32_sparc_check_relocs): Likewise.
1171 (elf32_sparc_relocate_section): Likewise.
1172 * elf32-i386.c (elf_i386_check_relocs): Don't set SEC_ALLOC in a
1173 reloc section if it is not set in the source section.
1174 * elf32-sparc.c (elf32_sparc_check_relocs): Likewise.
1175 * elf.c (bfd_section_from_shdr): Mark a reloc section associated
1176 with a SEC_DEBUGGING section as SEC_DEBUGGING.
1177
e5c4495c
MM
1178Wed Dec 4 14:18:13 1996 Michael Meissner <meissner@tiktok.cygnus.com>
1179
1180 * elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): #if 0 code that
1181 expects a .got.plt until we actually create it.
1182
179b58d9
ILT
1183Mon Dec 2 12:13:51 1996 Ian Lance Taylor <ian@cygnus.com>
1184
e5c4495c
MM
1185 * cofflink.c (_bfd_coff_generic_relocate_section): Print an error
1186 message for bfd_reloc_outofrange, rather than aborting. From
1187 Philippe De Muyter <phdm@info.ucl.ac.be>.
1188
179b58d9
ILT
1189 * cofflink.c (_bfd_coff_final_link): If there aren't any relocs in
1190 a relocateable link, don't try to process them. From Heinz Wrobel
1191 <wrobel@lpr.e-technik.tu-muenchen.de>.
1192
943686fa
JL
1193Mon Dec 2 00:39:24 1996 Jeffrey A Law (law@cygnus.com)
1194
1195 * elf32-mn10300.c (mn10300_info_howto): Renamed from
a5147005 1196 mn10300_info_howto_rel. Tweak reloc argument to be an
943686fa
JL
1197 Elf32_Internal_Rela.
1198 (USE_RELA): Define instead of USE_REL.
1199 (elf_info_to_howto, elf_info_howto_rel): Corresponding changes.
1200
0e0f4106
PS
1201Sun Dec 1 00:18:59 1996 Peter Schauer (pes@regent.e-technik.tu-muenchen.de)
1202
1203 * configure.in, configure: Handle mips*-sgi-irix6*.
1204 * irix-core.c (irix_core_core_file_p): Accept CORE_MAGICN32
1205 core files.
1206
15aafe49
ILT
1207Wed Nov 27 12:10:25 1996 Ian Lance Taylor <ian@cygnus.com>
1208
1209 * elf32-i386.c (elf_i386_relocate_section): Warn about a
1210 relocation against a symbol defined in a section with no output
1211 section.
1212
6c02f1a0
ILT
1213Tue Nov 26 11:07:31 1996 Ian Lance Taylor <ian@cygnus.com>
1214
dfc7020d
ILT
1215 * aclocal.m4 (BFD_CC_FOR_BUILD): Don't require AC_C_CROSS.
1216 * configure, config.in: Rebuild with autoconf 2.12.
1217
6c02f1a0
ILT
1218 * elf-bfd.h (struct elf_link_hash_entry): Add other field.
1219 * elf.c (_bfd_elf_link_hash_newfunc): Initialize other field.
1220 (swap_out_syms): Set st_other from existing st_other field.
1221 * elflink.h (elf_link_add_object_symbols): Store st_other in hash
1222 table other field.
1223 (elf_link_output_extsym): Set the other field from the global hash
1224 table entry.
1225 * elf32-mips.c (enum reloc_type): Add R_MIPS16_26.
1226 (elf_mips16_jump_howto): New static variable.
1227 (mips16_jump_reloc): New static function.
1228 (bfd_elf32_bfd_reloc_type_lookup): Handle BFD_RELOC_MIPS16_JMP.
1229 (mips_info_to_howto_rel): Handle R_MIPS16_26.
1230 (mips_elf_relocate_section): Handle R_MIPS16_26. Handle R_MIPS_26
1231 to a mips16 symbol.
1232 * reloc.c (BFD_RELOC_MIPS16_JMP): Add to list of relocs.
1233 * bfd-in2.h, libbfd.h: Rebuild.
1234 * cpu-mips.c (arch_info_struct): Add mips:16 entry.
1235
f082b5ea
ILT
1236Mon Nov 25 11:23:32 1996 Ian Lance Taylor <ian@cygnus.com>
1237
1238 * configure.host: Use long long for mips-sgi-irix6*.
1239
1240 * coffswap.h (coff_swap_scnhdr_out): Make line number overflow
1241 only a warning. From Philippe De Muyter <phdemuyt@ulb.ac.be>.
1242
12fdaaf8
JL
1243Mon Nov 25 08:52:29 1996 Jeffrey A Law (law@cygnus.com)
1244
1245 * elf32-mn10300.c (bfd_elf32_mn10300_reloc): New function.
1246 (enum reloc_type): Add more reloc types.
1247 (elf32_mn10300_howto_table): Update for new reloc types.
1248 (elf32_mn10300_reloc_map): Update for new reloc types.
1249 * reloc.c: Add some new relocs for the mn10300 series.
1250 * bfd-in2.h, libbfd.h: Rebuilt.
1251
23def276
JL
1252Sat Nov 23 13:26:18 1996 Jeffrey A Law (law@cygnus.com)
1253
1254 * som.c (setup_sections): Don't lose for a space which has
1255 no data, but some symbols.
1256
a600a89e
ILT
1257Fri Nov 22 11:32:13 1996 Ian Lance Taylor <ian@cygnus.com>
1258
1259 * sunos.c (struct sunos_link_hash_table): Add got_needed field.
1260 (sunos_link_hash_table_create): Initialize got_needed.
1261 (sunos_create_dynamic_sections): Only set .got section size if it
1262 is not already set. Set got_needed.
1263 (bfd_sunos_size_dynamic_sections): Check got_needed. Only set
1264 sdynptr, and only handle dynamic sections, if dynamic sections are
1265 needed.
1266 (sunos_scan_std_relocs): Pass false to create_dynamic_sections.
1267 Initialize .got section.
1268 (sunos_scan_ext_relocs): Likewise.
1269 (sunos_write_dynamic_symbol): Set up PLT entry even if this is not
1270 a dynamic symbol.
1271 (sunos_finish_dynamic_link): Check got_needed. Only set up
1272 dynamic linking information if needed.
1273
aa09d6b2
RS
1274Thu Nov 21 10:31:31 1996 Rob Savoye (rob@cygnus.com)
1275
1276 * config.bfd: Added VersaDOS format to the Ericsson configuration.
1277
c3239e66
JL
1278Wed Nov 20 16:31:31 1996 Jeffrey A Law (law@cygnus.com)
1279
1280 * elf32-mn10300.c: Rough cut at relocs for the mn10300.
1281
c3239e66
JL
1282Wed Nov 13 08:12:38 1996 Jeffrey A Law (law@cygnus.com)
1283
1284 * Makefile.in (elf32-d10v.o): Don't depend on elf/d10v.h
1285 anymore.
1286
c3239e66
JL
1287Tue Nov 12 13:30:00 1996 Dawn Perchik <dawn@cygnus.com>
1288
1289 * filemode.c: Include sysdep.h.
1290 * ihex.c: Add casts to eliminate compiler warnings.
1291 * sunos.c: Add casts to eliminate compiler warnings.
1292
9e23db76
MM
1293Mon Nov 11 10:37:02 1996 Michael Meissner <meissner@tiktok.cygnus.com>
1294
1295 * elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): Create .got.plt
1296 section.
1297 (ppc_elf_check_relocs): Add support for R_PPC_LOCAL24PC. Make
1298 appropriate relocations in the .so file if shared.
1299 (ppc_elf_relocate_section): Ditto.
1300
affcfcf9
DE
1301Tue Oct 29 15:03:02 1996 Doug Evans <dje@canuck.cygnus.com>
1302
1303 * elf32-m32r.c (elf_m32r_howto_table, R_M32R_24): Use
1304 complain_overflow_unsigned.
1305
421a2956
MH
1306Tue Oct 29 12:53:46 1996 Martin M. Hunt <hunt@pizza.cygnus.com>
1307
1308 * elf32-d10v.c (elf_d10v_howto_table): Don't complain on
1309 overflows for R_D10V_16 and R_D10V_18.
1310
061cc10b
ILT
1311Tue Oct 29 13:23:53 1996 Ian Lance Taylor <ian@cygnus.com>
1312
1313 * ieee.c (ieee_write_section_part): Use LMA rather than VMA.
1314 (do_with_relocs): Likewise.
1315 (do_as_repeat): Likewise.
1316 (copy_expression): Likewise.
1317
1318Fri Oct 25 16:56:40 1996 Ian Lance Taylor <ian@cygnus.com>
1319
1320 * ieee.c (ieee_write_external_part): Correctly record whether
1321 there is an external part.
1322
1323start-sanitize-v850
1324Thu Oct 24 14:32:52 1996 Jeffrey A Law (law@cygnus.com)
1325
1326 * elf32-v850.c (elf32_v850_bfd_final_link_relocate): Correctly
1327 handle tda offsets for sld.w and sst.w instructions.
1328 Fix alignment check in sld.w and sst.w tda reloc handling.
1329
1330end-sanitize-v850
27c7e907
SG
1331Thu Oct 24 09:08:47 1996 Stu Grossman (grossman@critters.cygnus.com)
1332
1333 * aclocal.m4, configure: Set USE_BINARY_FOPEN for *-*-windows.
1334
90ffe48b
JL
1335start-sanitize-v850
1336Wed Oct 23 00:53:16 1996 Jeffrey A Law (law@cygnus.com)
1337
1338 * elf32-v850.c: Add comments about assumptions about
1339 char, short & long sizes.
1340 (elf32_v850_bfd_final_link_relocate): Fix sign extension
1341 problems for several relocs.
1342
1343 * elf32-v850.c (elf32_v850_howto_table): Fix typo in
1344 R_V850_SDA_OFFSET entry.
1345
c0e8bfc0 1346end-sanitize-v850
84be2a8f
ILT
1347Wed Oct 23 00:20:34 1996 Ian Lance Taylor <ian@cygnus.com>
1348
1349 * xcofflink.c (bfd_xcoff_import_symbol): Don't allocate ldsym.
1350 Store import file index in ldindx.
1351 (xcoff_build_ldsyms): Assume that ldsym was not previously
1352 allocated. For an imported symbol, copy ldindx into l_ifile.
1353
725b96f5
JL
1354start-sanitize-v850
1355Tue Oct 22 19:20:38 1996 Jeffrey A Law (law@cygnus.com)
1356
c322f1b5 1357 * elf32-v850.c (elf_v850_howto_table): Fix ordering of
90ffe48b
JL
1358 R_V850_ZDA_OFFSET and R_V850_TDA_OFFSET. Fix various
1359 fields in R_V850_TDA_OFFSET.
c322f1b5 1360 (elf32_v850_bfd_final_link_relocate): Tweak pc-relative
90ffe48b 1361 relocs to work more like other relocs. Handle R_V850_TDA_OFFSET
c322f1b5
JL
1362 relocations.
1363
725b96f5
JL
1364 * elf32-v850.c: Include bfdlink.h.
1365 (bfd_elf32_v850_reloc): Return an error if we get a reloc
1366 we can't handle.
1367 (elf32_v850_bfd_final_link_relocate): New function.
1368 (v850_elf_relocation_section): Likewise.
1369 (elf_backend_relocate_section): Define.
1370
1371end-sanitize-v850
40c0ea5a
ILT
1372Tue Oct 22 17:22:43 1996 Ian Lance Taylor <ian@cygnus.com>
1373
1374 * binary.c (binary_set_section_contents): Ignore sections which
1375 don't have SEC_LOAD and SEC_ALLOC set.
1376
9c52f4b2
JL
1377Mon Oct 21 12:13:05 1996 Jeffrey A Law (law@cygnus.com)
1378
1379 * linker.c (_bfd_generic_final_link): Avoid losing static
1380 symbols in the .bss section.
1381
bd4dd3d0
ILT
1382Mon Oct 21 10:54:58 1996 Ian Lance Taylor <ian@cygnus.com>
1383
68553b63
ILT
1384 * elf32-mips.c (elf_mips_howto_table): Describe R_MIPS_64.
1385 (mips32_64bit_reloc): New static function.
1386 (mips_reloc_map): Add entry for BFD_RELOC_64.
1387 (mips_elf_relocate_section): Handle R_MIPS_64.
1388
bd4dd3d0
ILT
1389 * linker.c (default_indirect_link_order): Print an error message
1390 when attempting to do a relocateable link with different object
1391 file formats, rather than calling abort.
1392
56910544
DE
1393Thu Oct 17 10:43:29 1996 Doug Evans <dje@canuck.cygnus.com>
1394
1395 * reloc.c (m32r relocs): Rename them.
1396 * bfd-in2.h, libbfd.h: Regenerated.
1397 * elf32-m32r.c: Update.
1398 (m32r_elf_10_pcrel_reloc): New function.
1399 (elf_m32r_howto_table, R_M32R_10_PCREL entry): Use it.
1400 (elf_m32r_howto_table, R_M32R_24 entry): Fix {src,dst}_masks.
1401
e1d98a0a
JL
1402Wed Oct 16 11:24:35 1996 Jeffrey A Law (law@cygnus.com)
1403
4948949e
JL
1404 * linker.c (_bfd_generic_final_link): Set "linker_mark" for
1405 all sections that will be included in the output file.
1406 (_bfd_generic_link_output_symbols): Discard symbols in sections
1407 which are being discarded.
1408
1409start-sanitize-v850
b6d08fce
JL
1410
1411 * elf32-v850.c (enum reloc_type): Add R_V850_SDA_OFFSET,
1412 R_V850_TDA_OFFSET and R_V850_ZDA_OFFSET.
1413 (elf_v850_howto_table): Corresponding changes.
1414 (elf_v850_reloc_map): Corresponding changes.
1415 * reloc.c: Add additional V850 relocations.
1416 * bfd-in2.h, libbfd.h: Rebuilt.
1417
e1d98a0a
JL
1418 * elf32-v850.c (bfd_elf32_v850_reloc): Mask out bits we
1419 no longer want in pc-relative relocs.
1420
05f1baaa
JL
1421Tue Oct 15 22:17:37 1996 Jeffrey A Law (law@cygnus.com)
1422
1423 * elf32-v850.c (bfd_elf32_v850_reloc): Don't silently
1424 accept a reloc against an undefined sybmol!
1425
1336da39
SG
1426Tue Oct 15 16:17:28 1996 Stu Grossman (grossman@critters.cygnus.com)
1427
1428 * elf32-v850.c: Define elf_symbol_leading_char to be '_'.
1429
1430end-sanitize-v850
c24453fe
ILT
1431Tue Oct 15 12:40:41 1996 Ian Lance Taylor <ian@cygnus.com>
1432
ede836b9
ILT
1433 * VERSION: Bump for new relocation.
1434
c24453fe
ILT
1435 * hosts/i386bsd.h: If NBPG is not defined, define it as
1436 PAGE_SIZE, for recent versions of FreeBSD.
1437
e7a50458
ILT
1438Mon Oct 14 12:37:26 1996 Ian Lance Taylor <ian@cygnus.com>
1439
1440 * configure.host: Use `long long' as the 64 bit type on a Solaris
1441 host, since both gcc and the SunPRO compilers support it.
1442
6b31fd3a
ILT
1443Mon Oct 14 11:17:24 1996 Richard Henderson <rth@tamu.edu>
1444
1445 * reloc.c: Create a new BFD_RELOC_ALPHA_ELF_LITERAL. It was a
1446 mistake to have reused the ECOFF LITERAL for ELF since they have
1447 different semantics.
1448 * elf64-alpha.c (elf_reloc_map): Map from ELF_LITERAL.
1449 * bfd-in2.h, libbfd.h: Rebuild.
1450
1451 * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Trap .got
1452 section overflow.
1453
1454 * elf64-alpha.c (elf64_alpha_relocate_section): Do not emit a
1455 dynamic relocation for an undefweak symbol when we are building
1456 a static executable.
1457
f20f2474
SS
1458Thu Oct 10 11:15:06 1996 Stan Shebs <shebs@andros.cygnus.com>
1459
1460 * mpw-make.sed (config.bfd, targmatch.sed): Edit references to
1461 point explicitly to srcdir.
1462 (targmatch.h): Edit references to point explicitly to objdir.
1463
3e222a5a
ILT
1464Thu Oct 10 14:14:23 1996 Ian Lance Taylor <ian@cygnus.com>
1465
1466 * config.bfd: When setting targ_cpu, don't get confused by
1467 linux-gnu.
1468
81501797
SG
1469Tue Oct 8 08:51:19 1996 Stu Grossman (grossman@critters.cygnus.com)
1470
1471 * configure.host: Add support for windows host (a build done
1472 under the Microsoft build environment).
1473
fe4ff515
ILT
1474Tue Oct 8 11:40:16 1996 Ian Lance Taylor <ian@cygnus.com>
1475
1c4794f5
ILT
1476 * elflink.h (elf_link_add_object_symbols): If a symbol is a weak
1477 definition in a dynamic object, add it to the dynamic symbol table
1478 if any dynamic object mentions it. Reverts part of last patch.
1479
9d81de19
ILT
1480 * sunos.c (struct sunos_link_hash_table): Add got_base field.
1481 (sunos_link_hash_table_create): Initialize got_base.
1482 (bfd_sunos_size_dynamic_sections): If the .got section is more
1483 than 0x1000 bytes, set __GLOBAL_OFFSET_TABLE_ and got_base to
1484 0x1000.
1485 (sunos_check_dynamic_reloc): Subtract got_base from a base
1486 relative relocation.
1487
fe4ff515
ILT
1488 * elf32-mips.c (elf_mips_isa): New static function.
1489 (_bfd_mips_elf_merge_private_bfd_data): Don't warn about linking
1490 -mips1 and -mips2 code together, or -mips3 and -mips4 code.
1491
1233f74b
ILT
1492Mon Oct 7 11:44:17 1996 Ian Lance Taylor <ian@cygnus.com>
1493
1494 * archive.c (do_slurp_coff_armap): Only treat archive as little
1495 endian for i960 COFF.
1496
a3d5a706
ILT
1497Fri Oct 4 13:49:01 1996 Ian Lance Taylor <ian@cygnus.com>
1498
65f56a58
ILT
1499 * coffcode.h (coff_compute_section_file_positions): Adjust sofar
1500 by the change in size of the section when EXEC_P is not set.
1501
a9dd34a9
ILT
1502 * coff-m68k.c (coff_rtype_to_howto): Define if not defined.
1503 (m68kcoff_rtype_to_howto): New static function.
1504 * cf-m68klynx.c (coff_m68k_lynx_rtype_to_howto): Add the section
1505 VMA to the addend for a PC relative reloc.
1506
05a68c24
ILT
1507 * dep-in.sed: Rework backslash loop a bit to avoid bug in sed on
1508 HP/UX 10.20.
1509 * Makefile.in: Rebuild dependencies.
1510
a3d5a706
ILT
1511 * dep-in.sed: Remove ../bfd/sysdep.h, since it will appear when
1512 som.h is included.
1513
c00ae065
JL
1514Fri Oct 4 11:41:39 1996 Jeffrey A Law (law@cygnus.com)
1515
1516 * Makefile.in: Remove explicit dependencies for mn10200 and
1517 mn10300 files.
1518 (ALL_MACHINE_CFILES): Add cpu-mn10200.c and cpu-mn10300.c.
1519 (BFD32_BACKENDS_CFILES): Add elf32-mn10200.c and elf32-mn10300.c
1520 (dependencies): Rebuilt.
1521
dee99794
ILT
1522Thu Oct 3 16:57:51 1996 Ian Lance Taylor <ian@cygnus.com>
1523
1d871eb7
ILT
1524 * cofflink.c (coff_link_add_symbols): Set obj_coff_keep_syms
1525 during this function.
1526
6b5af55c
ILT
1527 * elflink.c (_bfd_elf_create_linker_section): Only use an existing
1528 section if the flags are compatible.
1529
dee99794
ILT
1530 * configure.in: Add havevecs, and put it in tdefaults.
1531 * mpw-config.in: Likewise.
1532 * configure: Rebuild.
1533 * targmatch.sed: New file; a sed script to build targmatch.h from
1534 config.bfd.
1535 * config.bfd: Add #if, #endif, and comments for targmatch.h.
1536 * targets.c: Include "fnmatch.h".
1537 (struct targmatch): Define.
1538 (bfd_target_match): Define by including targmatch.h.
1539 (bfd_find_target): If the target is not found by name, search for
1540 it as a configuration triplet.
1541 * Makefile.in: Rebuild dependencies.
1542 (BFD32_BACKENDS): Add aout-arm.o, aout-sparcle.o, hp300bsd.o,
1543 i386dynix.o, m68k4knetbsd.o, and riscix.o.
1544 (BFD32_BACKENDS_CFILES): Add aout-arm.c, aout-sparcle.c,
1545 hp300bsd.c, i386dynix.c, m68k4knetbsd.c, and riscix.c.
1546 (HFILES): Add targmatch.h. Also, alphabetize and reindent.
1547 (CFILES): Remove i386dynix.c and hp300bsd.c.
1548 (targmatch.h): New target.
1549 (do_clean): Remove targmatch.h.
1550
1551 * configure.in: Add BFD_NEED_DECLARATION(getenv).
1552 * acconfig.h: Add NEED_DECLARATION_GETENV.
1553 * configure, config.in: Rebuild.
1554 * sysdep.h: If NEED_DECLARATION_GETENV, declare getenv.
1555 * aout-adobe.c (aout_adobe_object_p): Don't declare getenv.
1556
ae1b99e4
JL
1557Thu Oct 3 09:29:09 1996 Jeffrey A Law (law@cygnus.com)
1558
1559 * cpu-mn10x00.c, elf32-mn10x00: Removed.
1560 * cpu-mn10200.c, cpu-mn10300.c: New files.
1561 * elf32-mn10200.c, elf32-mn10300.c: New files.
1562 * Makefile.in: Break mn10x00 support into two separate
1563 configurations, mn10200 and mn10300.
1564 * archures.c, config.bfd, configure.in, elf.c, targets.c: Likewise.
1565 * bfd-in2.h, configure: Rebuilt.
1566
4c7f3fde
JM
1567Thu Oct 3 15:38:19 1996 Jason Molenda (crash@godzilla.cygnus.co.jp)
1568
1569 * Makefile.in (do_clean): Move config.log to do_distclean.
1570
efc2b064
JL
1571Wed Oct 2 21:40:55 1996 Jeffrey A Law (law@cygnus.com)
1572
1573 * cpu-mn10x00.c, elf32-mn10x00.c: New files.
1574 * Makefile.in (ALL_MACHINES): Add cpu-mn10x00.o.
1575 (BFD32_BACKENDS): Similarly for elf32-mn10x00.o.
1576 (elf32-mn10x00.o): Add dependencies.
1577 * archures.c (enum bfd_architecture): Add bfd_arch_mn10x00.
1578 (bfd_mn10x00_arch): Declare.
1579 (bfd_archures_list): Add bfd_mn10x00_arch.
1580 * config.bfd: Add mn10x00-*-*.
1581 * configure.in: Add bfd_elf32_mn10x00_vec.
1582 * elf.c (prep_headers): Handle bfd_arch_mn10x00.
1583 * targets.c (bfd_elf32_mn10x00_vec): Declare.
1584 (bfd_target_vector): Add bfd_elf32_mn10x00_vec.
1585 * bfd-in2.h, configure: Rebuilt.
1586
bf53bd9f
ILT
1587Wed Oct 2 15:46:45 1996 Klaus Kaempf <kkaempf@progis.de>
1588
1589 openVMS/Alpha: Provide filename and case_hack flags via
1590 symbol table from gas.
1591 Add case_hack code for symbol output from vax/vms.
1592 * evax-alpha.c (evax_initialize): Remove filename handling,
1593 filename is provided via symbol table.
1594 (evax_get_symtab): Use local symbol count when setting up table.
1595 * evax-egsd.c (_bfd_evax_slurp_egsd): Print correct name when
1596 debugging.
1597 (_bfd_evax_write_egsd): Skip file name symbol.
1598 * evax-emh.c (get_vms_time_string): Local function now.
1599 (_bfd_evax_write_emh): Extract source filename and case_hack flags
1600 from symbol table.
1601 * evax_write_etir (_bfd_evax_write_etir): Pass all symbol names
1602 through _bfd_evax_case_hack_symbol.
1603 * evax-misc.c (hash_string, _bfd_evax_case_hack_symbol): New
1604 functions.
1605 (_bfd_evax_basename): Removed.
1606 (_bfd_get_vms_time_string): Moved to evax-emh.c.
1607 * evax.h (evax_private_data_struct): Remove filename.
1608 (flag_hash_long_names, flag_show_after_trunc,
1609 flag_no_hash_mixed_case, vms_name_mapping): New flags for
1610 vms_case_hack.
1611
263d4a62
ILT
1612Wed Oct 2 12:02:02 1996 Ian Lance Taylor <ian@cygnus.com>
1613
a0fe6c2d
ILT
1614 * freebsd.h (N_GET_MAGIC_NET): Don't use ntohl.
1615 (N_GETMID_NET, N_GETFLAG_NET): Likewise.
1616 (NO_SWAP_MAGIC): Don't define.
1617 (SWAP_MAGIC): Define.
1618
263d4a62
ILT
1619 * cofflink.c (_bfd_coff_link_input_bfd): Don't crash if there is
1620 no hash table entry for a global symbol.
1621
161ac690
ILT
1622Tue Oct 1 16:14:22 1996 Joel Sherrill <joel@oarcorp.com>
1623
1624 * config.bfd (mips*-*-rtems*): New target, like mips*-*-elf*.
1625
0db6249c
ILT
1626Tue Oct 1 12:31:39 1996 Ian Lance Taylor <ian@cygnus.com>
1627
8dd53b5c
ILT
1628 * cofflink.c (coff_link_add_symbols): Don't override a meaningful
1629 symbol type with T_NULL. Warn if symbol type changes. Based on
e5c4495c 1630 patch from Philippe De Muyter <phdm@info.ucl.ac.be>.
8dd53b5c 1631
0db6249c
ILT
1632 * elflink.h (elf_link_add_object_symbols): Only put a symbol from
1633 a dynamic object in the dynamic symbol table if it is referenced
1634 or defined by a regular object.
1635
1636start-sanitize-v850
1637Fri Sep 27 18:41:07 1996 Stu Grossman (grossman@critters.cygnus.com)
1638
1639 * elf32-v850.c (bfd_elf32_v850_is_local_label): New function to
1640 remove dwarf local labels. Shrinks binaries by a factor of 3!
1641
1642end-sanitize-v850
1643Mon Sep 23 13:33:00 1996 Ian Lance Taylor <ian@cygnus.com>
1644
1645 * elf32-ppc.c (ppc_elf_add_symbol_hook): Create the .sbss section
1646 by hand, rather than by calling bfd_make_section.
1647
80675684
DE
1648Mon Sep 23 09:23:41 1996 Doug Evans <dje@seba.cygnus.com>
1649
1650 * reloc.c: Rename m32r relocs.
1651 * bfd-in2.h, libbfd.h: Rebuilt.
1652 * elf32-m32r.c: Update.
80675684 1653
a5a43df1
ILT
1654Fri Sep 20 11:43:43 1996 Ian Lance Taylor <ian@cygnus.com>
1655
e12ab364
ILT
1656 * aoutx.h (aout_link_input_section_ext): When doing a relocateable
1657 link, adjust the symbol index of a base relative reloc. Don't
1658 change the addend of a PC relative reloc if pcrel_offset is set.
1659 * sunos.c (bfd_sunos_size_dynamic_sections): Don't do anything for
1660 a relocateable link.
1661
a5a43df1
ILT
1662 * reloc.c (bfd_perform_relocation): Apply the relocation even if
1663 it is zero, in case src_mask matters.
1664 (bfd_install_relocation): Likewise.
1665
e425358f
ILT
1666Thu Sep 19 11:03:06 1996 Ian Lance Taylor <ian@cygnus.com>
1667
1668 * xcofflink.c (xcoff_link_add_symbols): Always initialize
1669 keep_syms.
1670 (_bfd_xcoff_bfd_final_link): Don't set target_index
1671 to an uninitialized value.
1672
7f21c97c
ILT
1673Tue Sep 17 14:18:31 1996 Ian Lance Taylor <ian@cygnus.com>
1674
1675 * coffcode.h (coff_slurp_line_table): Warn about illegal symbol
1676 indices, rather than crashing.
1677 (coff_slurp_reloc_table): Likewise. Check whether the howto field
1678 is NULL.
8d784abe
ILT
1679 * coff-sh.c (sh_relocate_section): Check for an illegal symbol
1680 index.
7f21c97c 1681
9859bc31
ILT
1682Mon Sep 16 12:39:36 1996 Ian Lance Taylor <ian@cygnus.com>
1683
1153e84b
ILT
1684 * coff-arm.c (aoutarm_std_reloc_howto): Change dst_mask for ARM26D
1685 reloc to 0.
1686 (coff_arm_adjust_symndx): New static function.
1687 (coff_adjust_symndx): Define.
1688
9859bc31
ILT
1689 * srec.c (srec_scan): Accept multiple symbols on a single line.
1690 From Pascal Martin <pmartin@alsys.com>.
1691
1692 * README: New file.
1693
f8b82e49
DE
1694Fri Sep 13 14:32:42 1996 Doug Evans <dje@canuck.cygnus.com>
1695
1696 * aoutf1.h (MY_bfd_merge_private_bfd_data): Define.
1697 (sunos_merge_private_bfd_data): New function.
1698
0a7b8735
ILT
1699Fri Sep 13 15:50:57 1996 Ian Lance Taylor <ian@cygnus.com>
1700
76d30c3f
ILT
1701 * bfd.c (bfd_copy_private_bfd_data): Switch on output BFD rather
1702 than input BFD.
1703 (bfd_merge_private_bfd_data): Likewise.
1704 * section.c (bfd_copy_private_section_data): Likewise.
1705 * syms.c (bfd_copy_private_symbol_data): Likewise.
1706 * bfd-in2.h: Rebuild.
1707 * aout-target.h (MY_bfd_copy_private_section_data): Check that
1708 both BFD's are the right flavour.
1709 * ecoff.c (_bfd_ecoff_bfd_copy_private_bfd_data): Likewise.
1710 * elf.c (_bfd_elf_copy_private_symbol_data): Likewise.
1711 * elf32-mips.c (_bfd_mips_elf_copy_private_bfd_data): Likewise.
1712 (_bfd_mips_elf_merge_private_bfd_data): Likewise.
1713 * elf32-ppc.c (ppc_elf_copy_private_bfd_data): Likewise.
1714 (ppc_elf_merge_private_bfd_data): Likewise.
1715 * elf32-sparc.c (elf32_sparc_merge_private_bfd_data): Likewise.
1716 * peicode.h (pe_bfd_copy_private_section_data): Likewise.
1717
0a7b8735
ILT
1718 * elf32-hppa.c (elf_hppa_howto_table): Fill in some fields for
1719 R_PARISC_DIR32, so that _bfd_stab_section_find_nearest_line passes
1720 its sanity check.
1721
3ebefb07
DE
1722Thu Sep 12 11:45:57 1996 Doug Evans <dje@seba.cygnus.com>
1723
1724 * reloc.c: Add m32r relocs.
1725 * bfd-in2.h, libbfd.h: Rebuilt.
6cb9c903 1726 * cpu-m32r.c,elf32-m32r.c: New files.
3ebefb07 1727
cacfb845
ILT
1728Thu Sep 12 11:10:05 1996 Ian Lance Taylor <ian@cygnus.com>
1729
1730 * ieee.c (ieee_vec): Set symbol_leading_char field to '_'.
1731
d7775b43
ILT
1732Wed Sep 11 11:57:56 1996 Ian Lance Taylor <ian@cygnus.com>
1733
e461da9b
ILT
1734 * tekhex.c (first_phase): Change type parameter from char to int.
1735 (out): Likewise.
1736 (pass_over): Change func to expect int, not char.
1737
d7775b43
ILT
1738 * elf.c (assign_file_positions_for_segments): Test SEC_ALLOC
1739 rather than SEC_LOAD when aligning the file offset for the first
1740 section in a segment.
1741
ea3f0585
FF
1742Tue Sep 10 16:18:30 1996 Fred Fish <fnf@cygnus.com>
1743
1744 * syms.c (coff_section_type): Make arg const.
1745 * irix-core.c (irix_core_core_file_p): Remove extraneous extra arg
1746 to make_bfd_asection().
1747 * elf-bfd.h (bfd_section_from_phdr): Add prototype.
1748 * elfcode.h (bfd_section_from_phdr): Remove prototype.
1749 (_bfd_elf_stringtab_init): Remove prototype.
1750
1751 * netbsd-core.c (swap_abort): Add prototype.
1752 * aix386-core.c (swap_abort): Ditto & make static
1753 * hpux-core.c (swap_abort): Ditto & make static.
1754 * irix-core.c (swap_abort): Ditto & make static.
1755 * ptrace-core.c (swap_abort): Ditto & make static.
1756 * trad-core.c (swap_abort): Ditto & make static.
1757 * coffswap.h (coff_swap_reloc_in): Ditto.
1758 (coff_swap_reloc_out): Ditto.
1759 (coff_swap_filehdr_in): Ditto.
1760 (coff_swap_filehdr_out): Ditto.
1761 (coff_swap_sym_in): Ditto.
1762 (coff_swap_sym_out): Ditto.
1763 (coff_swap_aux_in): Ditto.
1764 (coff_swap_aux_out): Ditto.
1765 (coff_swap_lineno_in): Ditto.
1766 (coff_swap_lineno_out): Ditto.
1767 (coff_swap_aouthdr_in): Ditto.
1768 (coff_swap_aouthdr_out): Ditto.
1769 (coff_swap_scnhdr_in): Ditto.
1770 (coff_swap_scnhdr_out): Ditto.
1771 * ihex.c (ihex_sizeof_headers): Ditto.
1772 * tekhex.c (getsym): Ditto.
1773 (find_chunk): Ditto & make static.
1774 (insert_byte): Ditto.
1775 (first_phase): Ditto.
1776 (pass_over): Ditto.
1777 (tekhex_get_symtab): Ditto & make static.
1778 (tekhex_get_symtab_upper_bound): Ditto & make static.
1779 (tekhex_mkobject): Ditto.
1780 (tekhex_object_p): Ditto.
1781 (move_section_contents): Ditto.
1782 (tekhex_get_section_contents): Ditto.
1783 (tekhex_set_arch_mach): Ditto & make static.
1784 (tekhex_set_section_contents): Ditto.
1785 (writevalue): Ditto.
1786 (writesym): Ditto.
1787 (out): Ditto.
1788 (tekhex_write_object_contents): Ditto.
1789 (tekhex_sizeof_headers): Ditto.
1790 (tekhex_make_empty_symbol): Ditto.
1791 (tekhex_get_symbol_info): Ditto.
1792 (tekhex_print_symbol): Ditto.
1793 * irix-core.c (make_bfd_asection): Ditto.
1794 (irix_core_core_file_p): Ditto.
1795 (irix_core_core_file_failing_command): Ditto.
1796 (irix_core_core_file_failing_signal): Ditto.
1797 (irix_core_core_file_matches_executable_p): Ditto.
1798 (irix_core_make_empty_symbol): Ditto.
1799 * coff-mips.c (mips_bfd_reloc_type_lookup): Ditto.
1800 * srec.c (srec_new_symbol): Ditto.
1801 (srec_get_section_contents): Ditto.
1802 (srec_set_arch_mach): Ditto.
1803 (srec_set_section_contents): Ditto.
1804 (internal_srec_write_object_contents): Ditto.
1805 (srec_write_object_contents): Ditto.
1806 (symbolsrec_write_object_contents): Ditto.
1807 (srec_sizeof_headers): Ditto.
1808 (srec_make_empty_symbol): Ditto.
1809 (srec_get_symtab_upper_bound): Ditto.
1810 (srec_get_symtab): Ditto.
1811 (srec_print_symbol): Ditto and make static.
1812 * elf.c (elf_read): Ditto
1813 (assign_section_numbers): Ditto.
1814 (elf_fake_sections): Ditto.
1815 (sym_is_global): Ditto.
1816 (elf_map_symbols): Ditto.
1817 (get_program_header_size): Ditto.
1818 * coffgen.c (make_a_section_from_file): Ditto.
1819 (coff_real_object_p): Ditto.
1820 (fixup_symbol_value): Ditto.
1821 (build_debug_section): Ditto.
1822 (copy_name): Ditto.
1823 * syms.c (coff_section_type): Ditto.
1824
00d7a64b
JL
1825Mon Sep 9 22:36:01 1996 Jeffrey A Law (law@cygnus.com)
1826
1827 * bfd-in2.h: Rebuilt after m32r changes.
1828
71d7d44f
DE
1829Mon Sep 9 12:31:22 1996 Doug Evans <dje@canuck.cygnus.com>
1830
66e4c229 1831 * config.bfd,configure.in,configure: Add m32r support.
f0c12b73 1832 * Makefile.in,archures.c,elf.c,targets.c: Likewise.
71d7d44f
DE
1833 * config.bfd: Keep target list alphabetically sorted.
1834
629f776a
JL
1835start-sanitize-v850
1836Mon Sep 9 11:48:41 1996 Jeffrey A Law (law@cygnus.com)
1837
1838 * elf32-v850.c (bfd_elf32_v850_reloc, case R_V850_HI16): Don't forget
1839 to add in the constant part found in the instruction itself.
1840 (case R_V850_HI16_S): Likewise.
1841
1842end-sanitize-v850
9c85b19d
MH
1843Fri Sep 6 17:04:39 1996 Martin M. Hunt <hunt@pizza.cygnus.com>
1844
1845 * elf32-d10v.c (elf_d10v_howto_table): Modify the size of R_D10V_16
1846 and R_D10V_18 to be 1 (word).
1847
4be2140e
ILT
1848Thu Sep 5 15:23:08 1996 Ian Lance Taylor <ian@cygnus.com>
1849
1850 * stabs.c (_bfd_link_section_stabs): If the output_section field
1851 of either section is bfd_abs_section, then the linker is
1852 discarding the section and we should not optimize it.
1853
0cd98b92
DE
1854Tue Sep 3 12:16:20 1996 Doug Evans <dje@canuck.cygnus.com>
1855
1856 * Makefile.in (aout-sparcle.o): New target.
1857 * aoutf1.h (TARGET_IS_BIG_ENDIAN_P): Don't define if little endian.
1858 * config.bfd (sparclet-*-aout*): Add case.
1859 * configure.in (sparcle_aout_vec): Add case.
1860 * configure: Regenerated.
0cd98b92
DE
1861 * targets.c (sparcle_aout_vec): Declare.
1862 (bfd_target_vector): Add sparcle_aout_vec.
1863 * aout-sparcle.c: New file.
1864
b5ef63c4 1865start-sanitize-v850
7b0af209 1866Tue Sep 3 00:57:02 1996 Jeffrey A Law (law@cygnus.com)
b5ef63c4 1867
e73b6ae6
JL
1868 * elf32-v850.c (bfd_elf32_v850_reloc): Fix handling of
1869 low order sign bit propogation for R_V850_HI16_S.
1870
1871 * elf32-v850.c (bfd_elf32_v850_reloc): New function for
7b0af209
JL
1872 handling V850 specific relocs.
1873 (elf_v850_howto_table): Use the new function for some
1874 relocations. Twiddle masks & shifts for some relocs.
1875 Set partial_inplace where needed.
1876
1877end-sanitize-v850
1878Mon Sep 2 12:12:34 1996 Ian Lance Taylor <ian@cygnus.com>
1879
1880 * cpu-mips.c: Add an explicit mips:3000 entry, and change the
1881 default architecture to a machine number of 0.
1882 * elf32-mips.c (_bfd_mips_elf_object_p): Set the machine number
1883 for E_MIPS_ARCH_1.
1884 (_bfd_mips_elf_merge_private_bfd_data): If the machine number of
1885 the output BFD is the default, set it from the first input BFD.
1886
1887start-sanitize-v850
1888Sun Sep 1 18:38:01 1996 Jeffrey A Law (law@cygnus.com)
1889
1890 * elf32-v850.c (elf_v850_howto_table): All the 16bit relocs
1891 insert at bitpos zero. The HI16 relocs are shifted right
1892 by 16 bits. Fix src_mask for all relocs.
1893 (TARGET_LITTLE_SYM, TARGET_LITTLE_NAME): Define. The V850 is
1894 little endian!
1895 (TARGET_BIG_SYM, TARGET_BIG_NAME): Remove. The V850 is little
1896 endian!
b5ef63c4
MA
1897
1898end-sanitize-v850
bde9d875
ILT
1899Sun Sep 1 15:41:08 1996 Ian Lance Taylor <ian@cygnus.com>
1900
1901 * rs6000-core.c (rs6000coff_core_file_matches_executable_p):
1902 Rewrite to use BFD file read routines and to avoid using a fixed
1903 length for the file name.
1904
01b49cb3 1905start-sanitize-v850
237b5c4c
JL
1906Sat Aug 31 10:22:25 1996 Jeffrey A Law (law@cygnus.com)
1907
1908 * elf32-v850.c (enum reloc_type): Add R_V850_{32,16,8}.
1909 (elf_v850_howto_table): Add support for R_V850_{32,16,8}.
1910 (v850_reloc_map): Add translation from BFD_RELOC_{32,16,8}
1911 to R_V850_{32,16,8}.
1912
01b49cb3
C
1913Fri Aug 30 18:06:04 1996 J.T. Conklin <jtc@hippo.cygnus.com>
1914
1915 * elf32-v850.c (reloc_type): Add R_V850_HI16_S.
1916 (elf_v850_howto_table): Add info for HI16_S reloc.
1917 (v850_reloc_map): Add HI_16_S reloc.
1918 * reloc.c: Define BFD_RELOC_V850_* relocs.
1919
1920end-sanitize-v850
492cfc71
ILT
1921Fri Aug 30 11:49:19 1996 Ian Lance Taylor <ian@cygnus.com>
1922
c86158e5
ILT
1923 Add SH ELF support.
1924 * elf32-sh.c: New file.
1925 * elf.c (prep_headers): Handle bfd_arch_sh.
1926 * elfcode.h (write_relocs): Handle absolute symbol.
1927 * elf-bfd.h (_bfd_elf32_link_read_relocs): Declare.
1928 (_bfd_elf64_link_read_relocs): Declare.
1929 * elflink.h (NAME(_bfd_elf,link_read_relocs)): Rename from
1930 elf_link_read_relocs. Make globally visible. Change all
1931 callers.
1932 (elf_link_input_bfd): Get external symbols from cache in
1933 symtab_hdr->contents. Get contents from cache in
1934 elf_section_data.
1935 * elfxx-target.h (bfD_elfNN_bfd_relax_section): Only define if not
1936 already defined.
1937 * reloc.c: Define BFD_RELOC_SH_* relocs.
1938 * libbfd-in.h (_bfd_sh_align_load_span): Declare.
1939 * coff-sh.c (sh_insns_conflict): Fix a return value.
1940 (_bfd_sh_align_load_span): New globally visible function, broken
1941 out of sh_align_load.
1942 (sh_align_load): Call _bfd_sh_align_load_span.
1943 (sh_swap_insns): Change relocs parameter to PTR.
1944 * bfd-in2.h, libbfd.h: Rebuild.
1945 * targets.c (bfd_elf32_sh_vec): Declare.
1946 (bfd_elf32_shl_vec): Declare.
1947 * config.bfd (sh-*-elf*): New target.
1948 * configure.in (bfd_elf32_sh_vec): New target vector.
1949 (bfd_elf32_shl_vec): New target vector.
1950 * configure: Rebuild.
1951 * Makefile.in: Rebuild dependencies.
1952 (BFD32_BACKENDS): Add elf32-sh.o.
1953 (BFD32_BACKENDS_CFILES): Add elf32-sh.c.
1954
1955 * elf.c (map_sections_to_segments): Check that LMA does not skip a
1956 page before checking D_PAGED.
1957
492cfc71
ILT
1958 * ihex.c (ihex_scan): Removed unnecessary extbase variable.
1959 (ihex_write_object_contents): Remove extbase; always use segbase
1960 instead.
1961
f7954d86
MM
1962Thu Aug 29 16:52:17 1996 Michael Meissner <meissner@tiktok.cygnus.com>
1963
1964 * configure.in (i[345]86-*-*): Recognize i686 for pentium pro.
1965 * configure.host (i[345]86-*-*): Ditto.
1966 * config.bfd (i[345]86-*-*): Ditto.
1967 * configure: Regenerate.
1968
1969 * config.bfd (i[3456]86-*-dgux*): Recognize as a synonym for x86
1970 elf.
1971
1972Tue Aug 27 09:18:18 1996 Jeffrey A Law (law@cygnus.com)
1973
1974 * elf32-hppa.c (hppa_elf_gen_reloc_type): Add new argument.
1975 * elf32-hppa.h (hppa_elf_gen_reloc_type): Update prototype.
1976 * som.c (hppa_som_gen_reloc_type): Add new argument. If
1977 we encounter an R_DATA_ONE_SYMBOL reloc against a symbol that
1978 will have an ST_CODE type, change the symbol's type to ST_DATA.
1979 * som.c (hppa_som_gen_reloc_type): Update prototype.
1980
4da624dd
ILT
1981Tue Aug 27 00:12:22 1996 Ian Lance Taylor <ian@cygnus.com>
1982
1983 * elf32-mips.c (mips_elf_check_relocs): Set dynobj if needed for
1984 R_MIPS_32 and R_MIPS_REL32. Set sgot and g as soon as possible.
1985 (mips_elf_size_dynamic_sections): Don't require .got to exist.
1986 (mips_elf_finish_dynamic_sections): Likewise.
1987
9461513b
ILT
1988Thu Aug 22 10:54:38 1996 Ian Lance Taylor <ian@cygnus.com>
1989
1c952df6
ILT
1990 * configure.host (HLDENV): New variable to set. Set it for
1991 *-*-sysv4*, since those linkers may not support -R but they always
1992 support LD_RUN_PATH.
1993
9461513b
ILT
1994 * libieee.h (NSECTIONS): Don't define.
1995 (ieee_data_struct): Change section_table to asection **. Add
1996 section_table_size.
1997 * ieee.c (get_section_entry): If the table isn't big enough, make
1998 it bigger.
1999 (ieee_slurp_sections): Remove assertion about number of sections.
2000 (ieee_object_p): Adjust initialization of ieee to match changes to
2001 the structure.
2002
2003 * xcofflink.c (xcoff_mark): Don't copy relocs for undefined
2004 symbols merely because we are generating a shared library.
2005 (xcoff_build_ldsyms): Don't set up global linkage code for an
2006 undefined symbol merely because we are generating a shared
2007 library.
2008
0c1d95c7
C
2009start-sanitize-v850
2010Tue Aug 20 15:06:05 1996 J.T. Conklin <jtc@hippo.cygnus.com>
2011
2012 * Makefile.in (ALL_MACHINES): Add cpu-v850.o.
2013 (BFD32_BACKENDS) Add elf32-v850.o.
2014 * archures.c: Add bfd_v850_arch.
2015 * bfd-in2.h: Add bfd_v850_arch.
2016 * config.bfd (v850-*-*): New target.
2017 * configure: (bfd_elf32_v850_vec) New vector.
2018 * configure.in: (bfd_elf32_v850_vec) New vector.
2019 * cpu-v850.c: New file.
2020 * elf.c (prep_headers): Added case bfd_arch_v850.
2021 * elf32-v850.c: New file.
2022 * targets.c (bfd_elf32_v850_vec): New vector.
2023
2024end-sanitize-v850
2025Fri Aug 16 16:25:35 1996 Ian Lance Taylor <ian@cygnus.com>
2026
2027 * xcofflink.c (xcoff_link_add_dynamic_symbols): Create and define
2028 a function code symbol for an XMC_XO symbol.
2029
22edd547
SS
2030Thu Aug 15 12:33:29 1996 Stan Shebs <shebs@andros.cygnus.com>
2031
2032 * mpw-config.in: Update editing of autoconf vars to reflect
2033 Jul 18 configure.in change.
2034 * mpw-make.sed: Update editing of include pathnames to be
2035 more general, add @DASH_C_FLAG@ to explicit compile rule edit.
2036
2037Thu Aug 15 10:35:13 1996 Richard Henderson <rth@tamu.edu>
2038
2039 * elf64-alpha.c (elf64_alpha_output_extsym): The section from
2040 which to offset to get the .plt entry address is ".plt".
2041
53ef6e60
JSC
2042Thu Aug 15 16:40:30 1996 James G. Smith <jsmith@cygnus.co.uk>
2043
2044 * reloc.c: (BFD_RELOC_ARM_THUMB_ADD, BFD_RELOC_ARM_THUMB_IMM,
2045 BFD_RELOC_ARM_THUMB_SHIFT, BFD_RELOC_ARM_THUMB_OFFSET):
2046 Added, for internal use by the ARM gas.
2047 * libbfd.h: Rebuilt
2048 * bfd-in2.h: Rebuilt
2049
37d7888d
ILT
2050Wed Aug 14 17:02:09 1996 Richard Henderson <rth@tamu.edu>
2051
2052 * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Correct typo
2053 in section dynidx start.
2054
e38d6d36
ILT
2055Tue Aug 13 14:35:38 1996 Ian Lance Taylor <ian@cygnus.com>
2056
2057 * elf.c (_bfd_elf_make_section_from_shdr): Treat sections whose
2058 name begins with .gnu.linkonce as SEC_LINK_ONCE. This is an
2059 optimization for g++.
2060
ae20860e
MM
2061Tue Aug 13 17:04:40 1996 Michael Meissner <meissner@tiktok.cygnus.com>
2062
2063 * elf32-ppc.c (ppc_elf_merge_private_bfd_data): If one module has
2064 the -mrelocatable-lib bit set and the other doesn't, clear the
2065 -mrelocatable-lib bit in the header.
2066
4596421b
ILT
2067Sat Aug 10 22:59:17 1996 Ian Lance Taylor <ian@cygnus.com>
2068
2069 * elflink.h (elf_link_add_object_symbols): Do not resolve a common
2070 symbol against a STT_FUNC symbol in a shared library.
2071
f11e3f62
ILT
2072Fri Aug 9 12:44:57 1996 Ian Lance Taylor <ian@cygnus.com>
2073
410bc61d
ILT
2074 * xcofflink.c (xcoff_link_add_dynamic_symbols): If a descriptor
2075 symbol is found, automatically define the corresponding function
2076 code.
2077
d92099f1
ILT
2078 * cofflink.c (coff_link_add_symbols): Only set (*sym_hash)->numaux
2079 if sym.n_numaux is not zero.
2080 (_bfd_coff_link_input_bfd): Permit the symbol and the hash table
2081 entry to disagree about the number of aux entries if the symbol
2082 has zero.
2083
f11e3f62
ILT
2084 * elf32-mips.c (mips_elf_check_relocs): Create the .rel.dyn
2085 section if it might be needed, not just if info->shared.
2086 (mips_elf_adjust_dynamic_symbol): Make room for a null element at
2087 the start of .rel.dyn if we are going to use it.
2088 (mips_elf_finish_dynamic_sections): Only clear the first element
2089 of .rel.dyn if the size is greater than zero.
2090
fbc4ed7d
ILT
2091Thu Aug 8 16:24:55 1996 Ian Lance Taylor <ian@cygnus.com>
2092
b2a05baf
ILT
2093 * xcofflink.c (xcoff_link_input_bfd): If we already called the
2094 undefined_symbol callback for a symbol, then don't issue any more
2095 warnings about loader relocs.
2096 (_bfd_ppc_xcoff_relocate_section): Don't do any further processing
2097 after calling the undefined_symbol callback.
2098
fbc4ed7d
ILT
2099 * xcofflink.c (XCOFF_MULTIPLY_DEFINED): Define.
2100 (xcoff_link_add_symbols): Permit multiple definitions of a symbol
2101 as the AIX linker seems to do.
2102
8612a388
ILT
2103Thu Aug 8 12:21:56 1996 Klaus Kaempf <kkaempf@progis.de>
2104
2105 * evax-alpha.c (evax_alpha_vec): Corrected flags, cleanup.
2106 (evax_initialize): Remove evax_reloc_table.
2107 (evax_close_and_cleanup): Ditto.
2108 (reloc_nil): Ditto.
2109 (alpha_howto_table): Remove ALPHA_R_SWREL32 and ALPHA_R_SWREL64
2110 entries.
2111 (evax_bfd_reloc_type_lookup): Ditto.
2112 * evax-egsd.c (_bfd_evax_slurp_egsd): Add a few casts; set
2113 cooked_size == raw_size.
2114 * evax-emh.c (_bfd_evax_register_filename): Remove.
2115 * evax-etir.c (etir_stc): Allow ETIR_S_C_STC_xx commands.
2116 * evax-misc.c (add_new_contents): Malloc section at full size.
2117 (_bfd_save_evax_section): Memcpy section contents directly.
2118 * evax.h (ALPHA_R_SWREL32, ALPHA_R_SWREL64): Remove.
2119 (evax_reloc_table): Remove.
2120
2121 * hosts/alphavms.h (O_ACCMODE): Define if needed.
2122
2123 * makefile.vms: Add better support for DEC C compilation
2124 Add evax.h dependencies
2125
2126 * reloc.c (bfd_get_reloc_size): Add case for 16 byte reloc.
2127 (BFD_RELOC_SWREL32,BFD_RELOC_SWREL64): Remove.
2128 (BFD_RELOC_ALPHA_BASEREG): Remove.
2129 * bfd-in2.h, libbfd.h: Rebuild.
2130
320a5c6b
SG
2131Thu Aug 8 08:17:32 1996 Stu Grossman (grossman@critters.cygnus.com)
2132
2133 * archive.c (bsd_write_armap): Ifdef around calls to getuid and
2134 getgid if _WIN32 is defined.
2135 * opncls.c (bfd_fdopenr): Remove unnecessary WINGDB ifdef.
2136
2055bf85
SG
2137Wed Aug 7 23:19:00 1996 Stu Grossman (grossman@critters.cygnus.com)
2138
2139 * aoutx.h bfd-in.h bfd-in2.h opncls.c riscix.c som.c targets.c:
2140 Change NO_FLAGS to BFD_NO_FLAGS to avoid conflict with an HPUX
2141 include file.
2142 * libbfd.c: Create dummy getpagesize() macro if HAVE_GETPAGESIZE
2143 isn't defined.
2144
85fe9d3e
ILT
2145Wed Aug 7 14:11:44 1996 Philippe De Muyter <phdm@info.ucl.ac.be>
2146
2147 * configure.in: Call BFD_NEEDED_DECLARATION on strstr and
2148 realloc.
2149 * acconfig.h (NEED_DECLARATION_STRSTR): New macro.
2150 (NEED_DECLARATION_REALLOC): New macro.
2151 * configure, config.in: Rebuild.
2152 * sysdep.h (strstr): Declare if NEED_DECLARATION_STRSTR.
2153 (realloc): Declare if NEED_DECLARATION_REALLOC.
2154
2155 * aclocal.m4 (BFD_NEED_DECLARATION): Include <string.h> or
2156 <strings.h> if they exist.
2157
2158 * ieee.c (ieee_set_section_contents): Cast bfd_alloc return.
2159
9b3307b0
ILT
2160Wed Aug 7 12:12:03 1996 Ian Lance Taylor <ian@cygnus.com>
2161
cc425b55
ILT
2162 * cpu-i386.c (i8086_arch): Architecture info for the i8086.
2163
9b3307b0
ILT
2164 Based on patches from Eric Valette <valette@crf.canon.fr>:
2165 * elf32-i386.c (enum reloc_type): Add FIRST_INVALID_RELOC,
2166 LAST_INVALID_RELOC, R_386_16, R_386_PC16, R_386_8, R_386_PC8.
2167 (elf_howto_table): Add entries for new relocs.
2168 (elf_i386_reloc_type_lookup): Handle new relocs.
2169 (elf_i386_info_to_howto): Just call abort.
2170 (elf_i386_info_to_howto_rel): Check that the reloc type is valid.
2171 (elf_i386_relocate_section): Likewise.
2172
75e3a45a
MH
2173Tue Aug 6 12:54:56 1996 Martin M. Hunt <hunt@pizza.cygnus.com>
2174
2175 * elf32-d10v.c (elf_d10v_howto_table): Added R_D10V_32.
2176
191d910c
ILT
2177Mon Aug 5 13:42:41 1996 Ian Lance Taylor <ian@cygnus.com>
2178
b944e7e8
ILT
2179 * elf.c (_bfd_elf_make_section_from_shdr): For a loadable section,
2180 only get the LMA from the phdr if they are in the same part of the
2181 file.
2182
191d910c
ILT
2183 * elf.c (map_sections_to_segments): Rewrite tests for starting a
2184 new segment to make them more comprehensible. If the relationship
2185 between the LMA and the VMA changed, start a new segment. Don't
2186 check dynsec when deciding whether to start a new segment for a
2187 writeable section; -N will now handle this.
2188
e751d506
JL
2189Thu Aug 1 22:43:08 1996 Jeffrey A Law (law@cygnus.com)
2190
2191 * libhppa.h: Remove "esel" changes. Not the right approach.
2192 * som.c: Corresponding changes.
2193 (som_bfd_derive_misc_symbol_info): Use ST_DATA for symbols
2194 which don't have a SOM symbol type associated with them.
2195 Reverses a 1994 change.
2196
cdb88e87
ILT
2197Wed Jul 31 15:50:55 1996 Ian Lance Taylor <ian@cygnus.com>
2198
2199 Make ld -N more reasonable for ELF:
2200 * elf.c (map_sections_to_segments): If D_PAGED is not set, set
2201 phdr_in_section to false, and always use a single load segment.
2202 (elf_sort_sections): Sort sections by LMA after VMA.
2203 (assign_file_positions_for_segments): If D_PAGED is not set, don't
2204 align to maxpagesize.
2205 (assign_file_positions_except_relocs): Likewise.
2206 * elfcode.h (elf_object_p): If a section is loaded but not page
2207 aligned, clear D_PAGED.
2208
d1b40d8e
JSC
2209Wed Jul 31 15:00:12 1996 James G. Smith <jsmith@cygnus.co.uk>
2210
2211 * reloc.c: (BFD_RELOC_ARM_OFFSETIMM8, BFD_RELOC_ARM_HWLITERAL):
2212 Added, for internal use by the ARM gas.
2213 * libbfd.h: Rebuilt
2214 * bfd-in2.h: Rebuilt
2215
ad240a82
JL
2216Tue Jul 30 14:14:57 1996 Jeffrey A Law (law@cygnus.com)
2217
2218 * libhppa.h (R_HPPA_ESEL): New field selector.
2219 (e_esel): Similarly.
2220 * som.c (hppa_som_gen_reloc_type): If we encounter an e_esel,
2221 then generate R_COMP2 (PUSH_SYM), R_DATA_EXPR fixup stream.
2222 (som_write_fixups): Handle R_DATA_EXPR just like R_CODE_EXPR.
2223
fb4dc1eb
ILT
2224Tue Jul 30 13:31:27 1996 Ian Lance Taylor <ian@cygnus.com>
2225
2226 * xcofflink.c (_bfd_xcoff_bfd_link_add_symbols): Do the regular
2227 archive search before looking for stripped dynamic objects.
2228
b223f950
ILT
2229Fri Jul 26 17:51:39 1996 Ian Lance Taylor <ian@cygnus.com>
2230
2231 * xcofflink.c (xcoff_build_ldsyms): Make exporting an undefined
2232 symbol a warning rather than an error.
2233
64f808f9
ILT
2234Wed Jul 24 12:02:53 1996 Ian Lance Taylor <ian@cygnus.com>
2235
2236 * elf.c (assign_file_positions_for_segments): Track the virtual
2237 memory position separately from the file position, and use it to
2238 compute the alignment adjustment.
2239
11609502
MH
2240Tue Jul 23 10:43:31 1996 Martin M. Hunt <hunt@pizza.cygnus.com>
2241
2242 * elf32-d10v.c (elf_d10v_howto_table): Changed all relocs to "long"
2243 and fixed mask on R_D10V_10_PCREL_L.
2244
9bd65136
ILT
2245Mon Jul 22 15:30:30 1996 Ian Lance Taylor <ian@cygnus.com>
2246
bf9884d4
ILT
2247 * elf64-mips.c: Include "aout/ar.h".
2248 (mips_elf64_slurp_armap): New static function.
2249 (mips_elf64_write_armap): New static function.
2250 (bfd_elf64_archive_*): Define.
2251 * elfxx-target.h (bfd_elfNN_archive_p): Define if not defined.
2252 Use instead of bfd_generic_archive_p.
2253 (bfd_elfNN_write_archive_contents): Define if not defined. Use
2254 instead of _bfd_write_archive_contents.
2255 (bfd_elfNN_mkdarchive): Define if not defined. Use instead of
2256 _bfd_generic_mkarchive.
2257 (TARGET_BIG_SYM): If bfd_elfNN_archive_functions is defined, use
2258 bfd_elfNN_archive in BFD_JUMP_TABLE_ARCHIVE rather than
2259 _bfd_archive_coff.
2260 (TARGET_LITTLE_SYM): Likewise.
2261 * archive.c (bfd_slurp_armap): Check for and reject an archive map
2262 name of /SYM64/.
2263 * Makefile.in: Rebuild dependencies.
2264
2265 * elf32-mips.c (_bfd_mips_elf_final_write_processing): Handle
2266 SHT_MIPS_LIBLIST, SHT_MIPS_CONTENT, SHT_MIPS_SYMBOL_LIB, and
2267 SHT_MIPS_EVENTS sections.
2268 (_bfd_mips_elf_section_from_shdr): Handle SHT_MIPS_IFACE,
2269 SHT_MIPS_CONTENT, SHT_MIPS_SYMBOL_LIB, and SHT_MIPS_EVENTS
2270 sections.
2271 (_bfd_mips_elf_fake_sections): Likewise.
2272
9bd65136
ILT
2273 * libecoff.h (ecoff_data_type): Add rdata_in_text field.
2274 * ecoff.c (ecoff_compute_section_file_positions): Copy
2275 rdata_in_text from backend info to tdata. Clear it if any data
2276 section comes before .rdata.
2277 (_bfd_ecoff_write_object_contents): Use rdata_in_text field in
2278 tdata rather than backend info.
2279
194141a9
ILT
2280Fri Jul 19 18:15:51 1996 Ian Lance Taylor <ian@cygnus.com>
2281
2282 * configure.in: Fix test for whether a compiler has a 64 bit
2283 type. From Jim Wilson <wilson@cygnus.com>.
2284
a8a3d83a
ILT
2285Thu Jul 18 15:39:10 1996 Ian Lance Taylor <ian@cygnus.com>
2286
f4e14cb9
ILT
2287 * configure.host (mips-sgi-irix6*): New host.
2288
2289 * configure.in: Set and substitute VERSION, BFD_HOST_64BIT_LONG
2290 (replacing HOST_64BITLONG), BFD_HOST_64_BIT_DEFINED,
2291 BFD_HOST_64_BIT, and BFD_HOST_U_64_BIT. Add bfd-in2.h:bfd-in2.h
2292 to AC_OUTPUT call.
2293 * configure: Rebuild.
2294 * bfd-in.h (BFD_ARCH_SIZE): Define as @wordsize@, not @WORDSIZE@.
2295 (BFD_HOST_64_BIT): Define conditionally.
2296 (BFD_HOST_U_64_BIT): Define when BFD_HOST_64_BIT is defined.
2297 (bfd_vma): Typedef as BFD_HOST_U_64_BIT.
2298 (symvalue, bfd_size_type): Likewise.
2299 * bfd-in2.h: Rebuild.
2300 * Makefile.in (do_clean): Remove bfd-tmp.h.
2301 (do_distclean): Remove bfd-in3.h.
2302 (stmp-bfd.h): Just do copy-if-change bfd-in3.h bfd.h.
2303 (bfd-in3.h): New target.
2304
74556b94
ILT
2305 * config.bfd (sparc-*-sysv4*): Don't build sunos_big_vec. From
2306 Andrew Gierth <ANDREWG@microlise.co.uk>.
2307
ab659fd6
ILT
2308 * configure.host: Set INSTALL_SHLIB.
2309 * configure.in: Call AC_SUBST (INSTALL_SHLIB).
2310 * configure: Rebuild.
2311 * Makefile.in (install): Use @INSTALL_SHLIB@.
2312
e8c249cb
ILT
2313 * config.bfd (mips*-*-irix6*): New target.
2314 * configure.host: Handle Irix 6 shared library like Irix 5.
2315
a8a3d83a
ILT
2316 * xcofflink.c (xcoff_link_add_symbols): Don't check an XMC_TD
2317 symbol for a magic name.
2318 (xcoff_link_input_bfd): Don't change the reloc symbol for an
2319 XMC_TD symbol.
2320 (_bfd_ppc_xcoff_relocate_section): Don't get the TOC offset for an
2321 XMC_TD symbol.
2322
b576c7b3
SS
2323Thu Jul 18 11:36:31 1996 Stan Shebs <shebs@andros.cygnus.com>
2324
2325 * mpw-config.in: Add ELF support to mips config, create the
2326 elf32-target.h file in the object dir.
2327 * mpw-make.sed: Edit elfXX-target.h refs at beginnings of lines.
2328
2ba0d82d
KK
2329Wed Jul 17 18:02:32 1996 Kim Knuttila <krk@cygnus.com>
2330
2331 * coff-ppc.c: Redid debug scheme - numerous fprintf's gone.
2332 Also removed most abort calls, in favor of using bfd reporting.
2333
b576c7b3 2334Wed Jul 17 14:51:52 1996 Martin M. Hunt <hunt@pizza.cygnus.com>
50bd50d4 2335
b576c7b3
SS
2336 * Makefile.in (ALL_MACHINES): Add cpu-d10v.o.
2337 (BFD32_BACKENDS) Add elf32-d10v.o.
50bd50d4
MH
2338 * archures.c: Add bfd_d10v_arch.
2339 * bfd-in2.h: Add bfd_d10v_arch.
2340 * config.bfd (d10v-*-*): New target.
2341 * configure: (bfd_elf32_d10v_vec) New vector.
2342 * configure.in: (bfd_elf32_d10v_vec) New vector.
2343 * cpu-d10v.c: New file.
2344 * elf.c (prep_headers): Added case bfd_arch_d10v.
2345 * elf32-d10v.c: New file.
2346 * libbfd.h: Rebuild.
b576c7b3
SS
2347 * reloc.c (BFD_RELOC_D10V_10_PCREL_R, BFD_RELOC_D10V_10_PCREL_L,
2348 BFD_RELOC_D10V_18, BFD_RELOC_D10V_18_PCREL): Define.
50bd50d4 2349 * targets.c (bfd_elf32_d10v_vec): New vector.
50bd50d4 2350
2ce9802e
KK
2351Wed Jul 17 10:58:55 1996 Kim Knuttila <krk@cygnus.com>
2352
2353 * coff-ppc.c (coff_ppc_relocate_section): Removed bogus fprintf
2354
9676e446 2355Tue Jul 16 23:49:02 1996 Stu Grossman (grossman@critters.cygnus.com)
3cc21bf6 2356
9676e446
SG
2357 * archures.c bfd-in2.h: Add bfd_mach_i386_i386 and
2358 bfd_mach_i386_i8086 machine types.
3cc21bf6 2359
f7171978
ILT
2360Wed Jul 10 12:42:56 1996 Ian Lance Taylor <ian@cygnus.com>
2361
2362 * ecoff.c (_bfd_ecoff_new_section_hook): Set SEC_CODE for _INIT
2363 and _FINI sections.
2364
74e2ab38
ILT
2365Wed Jul 10 11:18:21 1996 Richard Henderson <rth@tamu.edu>
2366
2367 * coffcode.h (coff_set_section_contents): A/UX does not require
2368 special handling of the _LIB section.
2369
01cfaa6b
JL
2370Tue Jul 9 15:52:20 1996 Jeffrey A Law (law@cygnus.com)
2371
2372 * coff-h8300.c (h8300_reloc16_extra_cases): Use the correct
2373 value for R_RELBYTE.
2374
2375 * reloc16.c (bfd_coff_reloc16_relax_section): Only "shrinks"
2376 array if one was allocated.
2377
eb52b9dc
ILT
2378Tue Jul 9 12:21:54 1996 Ian Lance Taylor <ian@cygnus.com>
2379
2380 From Kazumoto Kojima <kkojima@kk.info.kanagawa-u.ac.jp>:
2381 * elf32-mips.c (struct mips_elf_link_hash_table): Add new fields
2382 use_rld_obj_head and rld_value.
2383 (mips_elf_link_hash_table_create): Initialize new fields.
2384 (mips_elf_add_symbol_hook): Mark __rld_obj_head symbol as
2385 dynamic.
2386 (mips_elf_create_dynamic_sections): Create .rld_map section. If
2387 __rld_obj_head symbol not seen, create an __rld_map symbol.
2388 (mips_elf_size_dynamic_sections): Make space in .rld_map section.
2389 Create a DT_MIPS_RLD_MAP entry rather than a DT_DEBUG entry.
2390 (mips_elf_finish_dynamic_symbol): Save value of __rld_map or
2391 __rld_obj_head symbol.
2392 (mips_elf_finish_dynamic_sections): Handle DT_MIPS_RLD_MAP.
2393
56b4cbaa
ILT
2394Mon Jul 8 16:18:03 1996 Ian Lance Taylor <ian@cygnus.com>
2395
9b292d4c
ILT
2396 * elf32-mips.c (mips_reloc_map): Remove BFD_RELOC_32_PCREL entry.
2397
dab45734
ILT
2398 * elf32-ppc.c (ppc_elf_howto_raw): For R_PPC_ADDR16_HA, use
2399 ppc_elf_addr16_ha_reloc.
2400 (ppc_elf_addr16_ha_reloc): New static function.
2401
56b4cbaa
ILT
2402 * coff-mips.c (struct mips_hi): Define.
2403 (mips_refhi_list): New static variable.
2404 (mips_refhi_addr, mips_refhi_addend): Remove.
2405 (mips_refhi_reloc): Maintain a list of unmatched REFHI relocs.
2406 (mips_reflo_reloc): Process mips_refhi_list.
2407 (mips_relhi_list): New static variable.
2408 (mips_relhi_addr, mips_relhi_addend): Remove.
2409 (mips_relhi_reloc): Maintain a list of unmatched RELHI relocs.
2410 (mips_rello_reloc): Process mips_relhi_list.
2411 (mips_relocate_section): Permit an arbitrary number of REFHI or
2412 RELHI relocs before the associated REFLO or RELLO reloc.
2413
b777c6a7
ILT
2414Fri Jul 5 19:27:49 1996 Ian Lance Taylor <ian@cygnus.com>
2415
2416 * aout-target.h (MY(callback)): Set reloc_count fields.
2417
100b65dd
ILT
2418Thu Jul 4 12:00:37 1996 Ian Lance Taylor <ian@cygnus.com>
2419
48f3aaf3
ILT
2420 * sunos.c (sunos_add_dynamic_symbols): Don't create dynamic
2421 sections unless this is a SunOS link.
2422
100b65dd
ILT
2423 * VERSION: Set to 2.7.1.
2424
2425 * Released binutils 2.7.
2426
a31e14f4
ILT
2427Wed Jul 3 14:59:47 1996 Ian Lance Taylor <ian@cygnus.com>
2428
4d3daf4f
ILT
2429 * i386aout.c: Include "aout/aout64.h".
2430 (i386aout_write_object_contents): New static function.
2431 (MY_write_object_contents): Define.
2432
a31e14f4
ILT
2433 * netbsd.h (MY(write_object_contents)): Make sure that
2434 adjust_sizes_and_vmas is called before fiddling with the magic
2435 number.
2436
d2d04f7a
ILT
2437Tue Jul 2 23:30:39 1996 Ian Lance Taylor <ian@cygnus.com>
2438
2439 * stabs.c (_bfd_link_section_stabs): Fix casts of psinfo.
2440
4f6ee760
ILT
2441Sun Jun 30 13:34:33 1996 Ian Lance Taylor <ian@cygnus.com>
2442
2443 * libbfd-in.h (itos, stoi): Don't define.
2444 * libbfd.h: Rebuild.
2445 * i386lynx.c (KEEPIT): Define as udata.i.
2446 (NAME(lynx,swap_std_reloc_out)): Don't use stoi.
2447 (NAME(lynx,swap_ext_reloc_out)): Likewise.
2448 * riscix.c (riscix_swap_std_reloc_out): Use udata.i rather than
2449 flags. Don't use stoi.
2450
2451 * elf32-mips.c (ELF_MAGPAGESIZE): Change definition to 0x1000.
2452
2453 * elf.c (map_sections_to_segments): Don't start a new segment for
2454 a writable section if it's on the same page as the previous
2455 segment. Reset the writable variable for a readonly section.
2456
dfb89b82
KK
2457Sat Jun 29 16:18:51 1996 Kim Knuttila <krk@cygnus.com>
2458
2459 * peicode.h (coff_swap_aouthdr_in): Missing initializations of
2460 first_thunk_address, thunk_size, and import_table_size.
2461 * peicode.h: Improved some diagnostics regarding edata sections.
2462
2463 * coff-ppc.c (coff_ppc_relocate_section): Earlier error check
2464 on IMGLUE relocs.
2465 (coff_ppc_relocate_section): Improved diagnostic for large TOCDEFN's.
2466 (TARGET_LITTLE_SYM): Added missing D_PAGED.
2467
8e80606f
ILT
2468Fri Jun 28 13:48:45 1996 Ian Lance Taylor <ian@cygnus.com>
2469
f93fb275
ILT
2470 * xcofflink.c (xcoff_link_check_ar_symbols): An undefined symbol
2471 with XCOFF_DEF_DYNAMIC set is really defined.
2472 (xcoff_link_check_dynamic_ar_symbols): Likewise.
2473 (xcoff_link_add_symbols): Only create special sections if using an
2474 XCOFF hash table.
2475
8e80606f
ILT
2476 * reloc.c (bfd_perform_relocation): Handle xcoff-powermac like
2477 aixcoff-rs6000.
2478 (bfd_install_relocation): Likewise.
2479
eec2f824
ILT
2480Fri Jun 28 11:17:00 1996 Richard Henderson <rth@tamu.edu>
2481
2482 * elf64-alpha.c (struct alpha_elf_link_hash_entry): Add flags
2483 field.
2484 (ALPHA_ELF_LINK_HASH_LU_ADDR): Define.
2485 (ALPHA_ELF_LINK_HASH_LU_MEM): Define.
2486 (ALPHA_ELF_LINK_HASH_LU_FUNC): Define.
2487 (elf64_alpha_link_hash_newfunc): Initialize flags field.
2488 (elf64_alpha_check_relocs): Record types of LITUSE entries that
2489 are found for LITERAL relocs.
2490 (elf64_alpha_adjust_dynamic_symbol): If a symbol has its address
2491 taken, we cannot generate a .plt entry for the symbol.
2492
5304aea9
ILT
2493Thu Jun 27 11:24:29 1996 Ian Lance Taylor <ian@cygnus.com>
2494
2495 * configure.in: Add AC_ISC_POSIX, and check for setitimer and
2496 sysconf functions (for gprof).
2497 * configure, config.in: Rebuild.
2498
017047d4
ILT
2499Wed Jun 26 16:29:02 1996 Ian Lance Taylor <ian@cygnus.com>
2500
f292bbe9
ILT
2501 * ecoff.c (_bfd_ecoff_archive_p): Check the first object file in
2502 an archive if it has a map. If the object file has the wrong
2503 xvec, reject it.
2504
566e2325
ILT
2505 * coff-alpha.c (alpha_adjust_reloc_in): Set the addend for a
2506 BRADDR, SREL16, SREL32, or SREL64 reloc against an external
2507 symbol.
2508 (alpha_relocate_section): Likewise.
2509
017047d4
ILT
2510 * coffswap.h (coff_swap_reloc_out): Use RELSZ, not sizeof.
2511 (coff_swap_filehdr_out): Use FILHSZ, not sizeof.
2512 (coff_swap_sym_out): Use SYMESZ, not sizeof.
2513 (coff_swap_aux_out): Use AUXESZ, not sizeof.
2514 (coff_swap_lineno_out): Use LINESZ, not sizeof.
2515 (coff_swap_aouthdr_out): Use AOUTSZ, not sizeof.
2516 (coff_swap_scnhdr_out): Use SCNHSZ, not sizeof.
2517 * peicode.h: Corresponding changes.
2518
cb73f5d7
MM
2519Tue Jun 25 15:28:34 1996 Michael Meissner <meissner@tiktok.cygnus.com>
2520
2521 * elflink.h (elf_create_pointer_linker_section): Comment out code
2522 dealing with making GOT pointers negative of the GOT symbol for
2523 now.
2524
297a4f1a
ILT
2525Tue Jun 25 11:41:24 1996 Richard Henderson <rth@tamu.edu>
2526
2527 * elf64-alpha.c (elf64_alpha_adjust_dynamic_symbol): Don't
2528 increment the .rela.plt size until after we're done creating the
2529 .plt entry.
2530 (elf64_alpha_finish_dynamic_symbol): Change .plt entry to load the
2531 .rela.plt offset directly rather than calculating it.
2532
dbbfec07
JM
2533Mon Jun 24 17:15:10 1996 Jason Molenda (crash@godzilla.cygnus.co.jp)
2534
01e58ff6
JM
2535 * Makefile.in, (bindir, libdir, datadir, mandir, infodir, includedir):
2536 Use autoconf-set values.
2537 * doc/Makefile.in (bindir, libdir, datadir, mandir, infodir,
2538 includedir, INSTALL, INSTALL_PROGRAM, INSTALL_DATA): Use autoconf-set
2539 values.
dbbfec07
JM
2540 (docdir): Deleted.
2541 * configure.in (AC_PREREQ): autoconf v2.5 or higher.
2542 * configure: Rebuilt.
2543
50004d8d
JL
2544Mon Jun 24 22:50:35 1996 Jeffrey A Law (law@cygnus.com)
2545
2546 * som.c (som_write_fixups): Fix typo in R_END_TRY for exception
2547 handling code > 1k away.
2548
2549Mon Jun 24 18:41:06 1996 Michael Meissner <meissner@tiktok.cygnus.com>
2550
2551 * elflink.h (elf_create_pointer_linker_section): If DEBUG is
2552 defined, output whenever the symbol is updated.
2553
2e0567eb
ILT
2554Mon Jun 24 17:58:12 1996 Jouke Numan <jnuman@bazis.nl>
2555
2556 * elf.c (elf_fake_sections): Don't set sh_addr of a non SEC_ALLOC
2557 section to 0 if user_set_vma is set.
2558 * elflink.h (elf_bfd_final_link): Likewise.
2559
2560Sun Jun 23 20:42:51 1996 Doug Evans <dje@canuck.cygnus.com>
2561
2562 Partially undo patch of Jun 20.
2563 * coffcode.h (coff_set_alignment_hook): Use COFF_IMAGE_WITH_PE.
2564 (coff_compute_section_file_positions): Likewise.
2565 (coff_write_object_contents): Likewise. Re-add deleted code, but
2566 use #ifdef COFF_WITH_PE, not COFF_OBJ_WITH_PE.
2567 * peicode.h (pe_bfd_copy_private_bfd_data): Re-add #ifdef.
2568
bff4a496
ILT
2569Fri Jun 21 17:38:15 1996 Joel Sherrill <joel@merlin.gcs.redstone.army.mil>
2570
2571 * config.bfd: Add support for *-*-rtems* configurations.
2572
7ae6550f
ILT
2573Fri Jun 21 15:19:59 1996 Ian Lance Taylor <ian@cygnus.com>
2574
2575 * elf.c (prep_headers): Add bfd_arch_alpha case.
2576
e8f46717
ILT
2577Fri Jun 21 12:35:27 1996 Richard Henderson <rth@tamu.edu>
2578
2579 * elf64-alpha.c: New file.
2580 * config.bfd (alpha-*-linuxecoff*): New target.
2581 (alpha-*-linux*, alpha-*-elf*): New targets.
2582 * configure.in (bfd_elf64_alpha_vec): New vector.
2583 * configure: Rebuild.
2584 * targets.c (bfd_elf64_alpha_vec): Declare.
2585 (bfd_target_vector): Add bfd_elf64_alpha_vec if BFD64.
2586 * reloc.c (BFD_RELOC_ALPHA_GPDISP): Define.
2587 * bfd-in2.h, libbfd.h: Rebuild.
2588 * Makefile.in: Rebuild dependencies.
2589 (BFD64_BACKENDS): Add elf64-alpha.o.
2590 (BFD64_BACKENDS_CFILES): Add elf64-alpha.c.
2591
bacecac8
ILT
2592Thu Jun 20 18:14:25 1996 Ian Lance Taylor <ian@cygnus.com>
2593
2594 * ecoff.c (ecoff_armap_hash): If hlog is 0, just return 0, rather
2595 than relying on a right shift of 32.
2596
9ca108cd
DE
2597Thu Jun 20 11:00:57 1996 Doug Evans <dje@canuck.cygnus.com>
2598
b9110a3c
DE
2599 * coffcode.h (coff_set_alignment_hook): Change COFF_IMAGE_WITH_PE
2600 ifdef to COFF_WITH_PE.
2601 (coff_compute_section_file_positions): Likewise.
2602 (coff_write_object_contents): Likewise. Delete COFF_OBJ_WITH_PE.
2603 * pe-{arm,i386,ppc}.c (COFF_OBJ_WITH_PE): Delete.
2604 * peicode.h (pe_bfd_copy_private_bfd_data): Delete ifdef
2605 COFF_IMAGE_WITH_PE, always include.
2606
9ca108cd
DE
2607 * peicode.h (coff_swap_scnhdr_out): ".drectve" doesn't have trailing 0.
2608
c2073f05
ILT
2609Wed Jun 19 11:37:52 1996 Ian Lance Taylor <ian@cygnus.com>
2610
7fc6a16a
ILT
2611 * elf.c (map_sections_to_segments): Fix up the test for -Ttext to
2612 approximate the correct answer if SIZEOF_HEADERS was not used.
2613
c2073f05
ILT
2614 * binary.c (binary_set_section_contents): Set section file
2615 position based on LMA rather than VMA.
2616
4838929e
ILT
2617Wed Jun 19 11:19:25 1996 Manfred Hollstein KS/EIC5 60/3/142 #40283 <manfred@lts.sel.alcatel.de>
2618
2619 * linker.c (_bfd_generic_link_output_symbols): Don't output any
2620 symbols if info->strip == strip_all.
2621
2622Tue Jun 18 15:17:36 1996 Jeffrey A. Law <law@rtl.cygnus.com>
2623
2624 * coff-h8300.c: Remove #if 0 code.
2625 (compatable): Don't allow mixing/matching of different architectures.
2626
4838929e
ILT
2627 * archures.c (bfd_mach_h8300s): Add.
2628 * bfd-in2.h: Rebuilt.
2629 * coff-h8300.c (funcvec_hash_newfunc): Handle H8/S too.
2630 (BADMAG): Likewise.
2631 (h8300_reloc16_estimate): Likewise.
2632 (h8300_reloc16_extra_cases): Likewise.
2633 (h8300_bfd_link_add_symbols): Likewise.
2634 * coffcode.h (coff_set_arch_mach_hook): Likewise.
2635 (coff_set_flags): Likewise.
2636 * cpu-h8300.c (h8300_scan): Likewise.
2637 Add H8/S to bfd_h8300_arch list.
2638
c3d8e071
ILT
2639Tue Jun 18 14:42:58 1996 Klaus Kaempf <kkaempf@progis.de>
2640
2641 Added support for Alpha OpenVMS:
2642 * evax.h, evax-alpha.c, evax-egsd.c, evax-emh.c: New files.
2643 * evax-etir.c, evax-misc.c, hosts/alphavms.h: New files.
2644 * config.h-vms, makefile.vms: New files.
2645 * config.bfd (alpha-*-*vms*): New target.
2646 * configure.in (evax_alpha_vec): New target vector.
2647 * configure: Rebuild.
2648 * reloc.c (BFD_RELOC_SWREL32, BFD_RELOC_SWREL64): Define.
2649 (BFD_RELOC_ALPHA_LINKAGE, BFD_RELOC_ALPHA_BASEREG): Define.
2650 * targets.c (bfd_target_evax_flavour): Define.
2651 (evax_alpha_vec): Declare.
2652 (bfd_target_vector): Add ecoffalpha_little_vec and evax_alpha_vec
2653 if BFD64 is defined.
2654 * bfd-in2.h, libbfd.h: Rebuild.
2655 * Makefile.in: Rebuild dependencies.
2656 (BFD64_BACKENDS): Add evax-alpha.o, evax-egsd.o, evax-etir.o,
2657 evax-emh.o, and evax-misc.o.
2658 (BFD64_BACKENDS_CFILES): Add evax-alpha.c, evax-egsd.c,
2659 evax-etir.c, evax-emh.c, and evax-misc.c.
2660 (HFILES): Add evax.h.
2661
142aa7d9
ILT
2662Tue Jun 18 13:54:18 1996 Ian Lance Taylor <ian@cygnus.com>
2663
2664 * coff-h8300.c (h8300_reloc16_extra_cases): Make name a const
2665 pointer.
2666 (h8300_bfd_link_add_symbols): Likewise.
2667
b658d64d
JL
2668Mon Jun 17 10:06:50 1996 Jeffrey A. Law <law@rtl.cygnus.com>
2669
2670 * som.h (R_HPPA_BEGIN_TRY, R_HPPA_END_TRY): Define.
2671 * som.c (som_write_fixups): Handle R_BEGIN_TRY and R_END_TRY.
2672
2df1e84b
ILT
2673Mon Jun 17 12:49:11 1996 Ian Lance Taylor <ian@cygnus.com>
2674
2675 * elf32-mips.c (mips_elf_relocate_section): Don't create a reloc
2676 for R_MIPS_REL32 and R_MIPS_32 relocs if no dynamic sections were
2677 created.
2678 (mips_elf_check_relocs): Only create .rel.dyn for R_MIPS_REL32 and
2679 R_MIPS_32 relocs if creating a shared library.
2680
2681Thu Jun 13 20:14:51 1996 Doug Evans <dje@canuck.cygnus.com>
2682
2683 * peicode.h (add_data_entry): Use pei_section_data rather than
2684 _cooked_size. Corresponds to May 13 change in coffcode.h.
2685
8100e72c
ILT
2686Thu Jun 13 10:23:40 1996 Ian Lance Taylor <ian@cygnus.com>
2687
51bc9642
ILT
2688 * cofflink.c (_bfd_coff_final_link): Handle long section names.
2689 * coffcode.h (coff_write_object_contents): If there are long
2690 section names, always set the f_symptr field, even if there are no
2691 symbols.
2692 * peicode.h (coff_swap_filehdr_in): Don't clear the f_symptr field
2693 if there are no symbols.
2694
8100e72c
ILT
2695 * coffgen.c (make_a_section_from_file): Check return value of
2696 _bfd_coff_read_string_table.
2697 (coff_real_object_p): Check return value of
2698 make_a_section_from_file.
2699 (_bfd_coff_read_string_table): Check that there are some symbols
2700 before trying to read the string table size.
2701
0e3bd85e
ILT
2702Wed Jun 12 11:16:37 1996 Ian Lance Taylor <ian@cygnus.com>
2703
ed675a04
ILT
2704 * xcofflink.c (xcoff_link_add_symbols): When considering whether
2705 to replace a symbol in a dynamic object with a symbol from another
2706 dynamic object, do the replacement if the existing symbol is
2707 global linkage code.
2708
49144784
ILT
2709 * xcofflink.c (_bfd_ppc_xcoff_relocate_section): Check explicitly
2710 for _ptrgl, and treat it as global linkage code.
2711
0e3bd85e
ILT
2712 * aoutx.h (NAME(aout,find_nearest_line)): Notice if we find a
2713 filename or N_SO symbol past the offset, and use it to indicate
2714 that there is no line number or function when appropriate.
2715
a5c7acea
ILT
2716Tue Jun 11 15:24:48 1996 Ian Lance Taylor <ian@cygnus.com>
2717
2718 * xcofflink.c (xcoff_build_ldsyms): Set XCOFF_DEF_REGULAR for a
2719 common symbol defined by the linker. Don't export function code
2720 even if export_defineds is set.
2721
2722Mon Jun 10 11:57:27 1996 Jeffrey A Law (law@cygnus.com)
2723
2724 * coff-h8300.c (howto_table): Add new entries for R_BCC_INV
2725 and R_JMP_DEL.
2726 (rtype2howto): Handle R_BCC_INV and R_JMP_DEL.
2727 (h8300_symbol_address_p): New function.
2728 (h8300_reloc16_estimate): Eliminate jumps made unnecessary by
2729 relaxing.
2730
890f5b7f
JL
2731Sun Jun 9 16:30:20 1996 Jeffrey A Law (law@cygnus.com)
2732
2733 * coff-h8300.c (h8300_reloc16_estimate): Fix many minor spacing
2734 problems.
2735 (h8300_reloc16_estimate, cases R_JMP1, R_JMP2): Adjust "dot"
2736 correctly for the two variants. Allow relaxing if the target
2737 is 128 bytes away since after relaxation it'll be 126 bytes away.
2738 (h8300_reloc16_estimate, case R_PCRWORD): Correctly adjust
2739 "dot" and "value". Allow relaxing if the target is 128 bytes
2740 away since after relaxation it'll be 126 bytes away.
2741 * reloc16.c (bfd_coff_reloc16_relax_section): Keep relaxing
2742 the given section until nothing changes.
2743
0593fc16
ILT
2744Thu Jun 6 15:24:45 1996 Richard Henderson <rth@tamu.edu>
2745
2746 * ecoff.c (_bfd_ecoff_new_section_hook): Remove the _PDATA
2747 alignment hack--we can get the lnnoptr info another way without
2748 suddenly increasing the alignment requirements. Set the flags for
2749 the _PDATA section.
2750 (ecoff_compute_section_file_positions): Do so.
2751
9b263b79
ILT
2752Thu Jun 6 11:24:37 1996 Ian Lance Taylor <ian@cygnus.com>
2753
bbf7c335
ILT
2754 * ieee.c (ieee_write_object_contents): Put a timestamp in the file
2755 to keep the HP emulator database happy.
2756
9b263b79
ILT
2757 * config.bfd: Recognize powerpc-*-linux* and powerpcle-*-linux*.
2758 From Kevin Buettner <kev@primenet.com>.
2759
2760Wed Jun 5 15:16:04 1996 Ian Lance Taylor <ian@cygnus.com>
2761
2762 * aoutx.h (translate_to_native_sym_flags): Don't try to print the
2763 name of a NULL section.
2764
26145b15
ILT
2765Tue Jun 4 18:53:58 1996 Ian Lance Taylor <ian@cygnus.com>
2766
2767 * linker.c (_bfd_generic_link_add_one_symbol): If notice_all is
2768 set, always call the notice callback.
2769
2770 * VERSION: Increment for bfdlink.h change.
2771
3a2080d8
ILT
2772Mon Jun 3 11:01:53 1996 Ian Lance Taylor <ian@cygnus.com>
2773
9d175198
ILT
2774 * coff-sh.c (COFF_DEFAULT_SECTION_ALIGNMENT_POWER): Set to 4.
2775 (sh_relax_delete_bytes): Correct handling of differently sized
2776 trailing alignment reloc.
2777
5a04f1bd
ILT
2778 * bfd-in.h: Use #error if BFD_HOST_64_BIT can not be defined.
2779 * bfd-in2.h: Rebuild.
2780 * configure.in: Warn if there is no known 64 bit type.
2781 * configure: Rebuild.
2782
60c8b04f
ILT
2783 * Makefile.in: Rebuild dependencies.
2784 (BFD32_BACKENDS): Add ppcboot.o.
2785 (BFD32_BACKENDS_CFILES): Add ppcboot.c.
2786
3a2080d8
ILT
2787 * elf32-mips.c (mips_elf_size_dynamic_sections): Initialize c.
2788 From Per Fogelstrom <per.fogelstrom@mailbox200.swipnet.se>.
2789
903612a2
ILT
2790Sat Jun 1 21:49:58 1996 Ian Lance Taylor <ian@cygnus.com>
2791
2792 * elf64-mips.c (bfd_mips_elf64_swap_reginfo_in)
2793 (bfd_mips_elf64_swap_reginfo_out): Move from here...
2794 * elf32-mips.c (bfd_mips_elf64_swap_reginfo_in)
2795 (bfd_mips_elf64_swap_reginfo_out): ...to here.
2796
38893c8c
ILT
2797Fri May 31 13:51:28 1996 Ian Lance Taylor <ian@cygnus.com>
2798
bc05732b
ILT
2799 * elf64-mips.c: Improve reloc special_functions and handling of
2800 SHT_MIPS_OPTIONS section.
2801 * elf32-mips.c (_bfd_mips_elf_hi16_reloc): Rename from
2802 mips_elf_hi16_reloc and make globally visible.
2803 (_bfd_mips_elf_lo16_reloc): Rename from mips_elf_lo16_reloc and
2804 make globally visible.
2805 (_bfd_mips_elf_got16_reloc): Rename from mips_elf_got16_reloc and
2806 make globally visible.
2807 (_bfd_mips_elf_gprel16_reloc): Rename from mips_elf_gprel16_reloc
2808 and make globally visible.
2809 (gprel16_with_gp): Check howto->src_mask before using value in
2810 insn.
2811 (_bfd_mips_elf_gprel32_reloc): Rename from mips_elf_gprel32_reloc
2812 and make globally visible.
2813 (gprel32_with_gp): Check howto->src_mask before fetching value.
2814 (bfd_mips_elf_swap_options_in): New function.
2815 (bfd_mips_elf_swap_options_out): New function.
2816 (_bfd_mips_elf_set_private_flags): Rename from
2817 mips_elf_set_private_flags and make globally visible.
2818 (_bfd_mips_elf_copy_private_bfd_data): Rename from
2819 mips_elf_copy_private_bfd_data and make globally visible.
2820 (_bfd_mips_elf_merge_private_bfd_data): Rename from
2821 mips_elf_merge_private_bfd_data and make globally visible.
2822 (_bfd_mips_elf_section_from_shdr): Accept .MIPS.options as a name
2823 for a SHT_MIPS_OPTIONS section.
2824 (mips_elf32_section_from_shdr): Handle SHT_MIPS_OPTIONS section.
2825 (_bfd_mips_elf_fake_sections): Consider .MIPS.options to be the
2826 name of a SHT_MIPS_OPTIONS section.
2827 (_bfd_mips_elf_set_section_contents): New function.
2828 (mips_elf32_section_processing): Set the GP value in a
2829 SHT_MIPS_OPTIONS section.
2830 (_bfd_mips_elf_find_nearest_line): Rename from
2831 mips_elf_find_nearest_line and make globally visible.
2832 (bfd_elf32_set_section_contents): Define.
2833 * elf-bfd.h (_bfd_mips_elf_hi16_reloc): Declare.
2834 (_bfd_mips_elf_lo16_reloc): Declare.
2835 (_bfd_mips_elf_gprel16_reloc): Declare.
2836 (_bfd_mips_elf_got16_reloc): Declare.
2837 (_bfd_mips_elf_gprel32_reloc): Declare.
2838 (_bfd_mips_elf_set_private_flags): Declare.
2839 (_bfd_mips_elf_copy_private_bfd_data): Declare.
2840 (_bfd_mips_elf_merge_private_bfd_data): Declare.
2841 (_bfd_mips_elf_find_nearest_line): Declare.
2842 (_bfd_mips_elf_set_section_contents): Declare.
2843
38893c8c
ILT
2844 * elf32-hppa.c (elf32_hppa_info_to_howto): Rename from
2845 elf_info_to_howto.
2846 (elf_info_to_howto): Define.
2847 * elf32-sparc.c (elf32_sparc_info_to_howto): Rename from
2848 elf_info_to_howto.
2849 (elf_info_to_howto): Define.
2850 * elf64-sparc.c (sparc64_elf_info_to_howto): Rename from
2851 elf_info_to_howto.
2852 (elf_info_to_howto): Define.
2853
2854 * coff-w65.c (h8300_reloc16_estimate): Rename R_MOVB[12] to
2855 R_MOV16B[12], to match change in coff/internal.h.
2856
cabd8fa0
ILT
2857Thu May 30 12:38:49 1996 Ian Lance Taylor <ian@cygnus.com>
2858
00176555
ILT
2859 * elf64-mips.c: Extensive additions to provide better support for
2860 writing files and for gas.
2861 * elf32-mips.c (_bfd_mips_elf_object_p): New function, broken out
2862 of mips_elf_object_p.
2863 (mips_elf32_object_p): Rename from mips_elf_object_p; call
2864 _bfd_mips_elf_object_p.
2865 (_bfd_mips_elf_final_write_processing): Rename from
2866 mips_elf_final_write_processing and make globally visible.
2867 (_bfd_mips_elf_fake_sections): Rename from
2868 mips_elf_fake_sections and make globally visible.
2869 (_bfd_mips_elf_section_from_bfd_section): Rename from
2870 mips_elf_section_from_bfd_section and make globally visible.
2871 (_bfd_mips_elf_section_processing): New function, broken out of
2872 mips_elf_section_processing.
2873 (mips_elf32_section_processing): Rename from
2874 mips_elf_section_processing; call
2875 _bfd_mips_elf_section_processing.
2876 (_bfd_mips_elf_symbol_processing): Rename from
2877 mips_elf_symbol_processing and make globally visible.
2878 (_bfd_mips_elf_read_ecoff_info): Rename from
2879 mips_elf_read_ecoff_info and make globally visible.
2880 (mips_elf32_ecoff_debug_swap): Rename from
2881 mips_elf_ecoff_debug_swap.
2882 * elf.c (_bfd_elf_symbol_from_bfd_symbol): Use asymbol rather than
2883 struct symbol_cache_entry.
2884 (_bfd_elf_validate_reloc): New function, moved in from
2885 elfcode.h:validate_reloc.
2886 * elfcode.h (validate_reloc): Remove; moved into elf.c and renamed
2887 to _bfd_elf_validate_reloc. Change all callers.
2888 * elf-bfd.h (bfd_section_from_shdr): Declare.
2889 (_bfd_elf_symbol_from_bfd_symbol): Declare.
2890 (_bfd_elf_validate_reloc): Declare.
2891 (_bfd_mips_elf_object_p): Declare.
2892 (_bfd_mips_elf_fake_sections): Declare.
2893 (_bfd_mips_elf_section_from_bfd_section): Declare.
2894 (_bfd_mips_elf_section_processing): Declare.
2895 (_bfd_mips_elf_symbol_processing): Declare.
2896 (_bfd_mips_elf_read_ecoff_info): Declare.
2897 (_bfd_mips_elf_final_write_processing): Declare.
2898 * elfxx-target.h (bfd_elfNN_get_reloc_upper_bound): Don't define
2899 if already defined.
2900
cabd8fa0
ILT
2901 * elf32-mips.c (mips_elf_object_p): Handle E_MIPS_ARCH_4.
2902 (mips_elf_final_write_processing): Likewise.
2903
d1bf45aa
ILT
2904Wed May 29 16:15:29 1996 Ian Lance Taylor <ian@cygnus.com>
2905
2906 64-bit MIPS ELF ABI objdump support:
2907 * elf64-mips.c: New file.
2908 * Makefile.in: Rebuild dependencies.
2909 (BFD64_BACKENDS): Add elf64-mips.o.
2910 (BFD64_BACKENDS_CFILES): Add elf64-mips.c.
2911 * config.bfd (mips*el-*-elf*) Add bfd_elf64_bigmips_vec and
2912 bfd_elf64_littlemips_vec to targ_selvecs.
2913 (mips*-*-elf*): Likewise.
2914 * confingure.in: Add bfd_elf64_bigmips_vec and
2915 bfd_elf64_littlemips_vec to vector switch.
2916 * configure: Rebuild.
2917 * elf32-mips.c (_bfd_mips_elf_section_from_shdr): New function,
2918 broken out of mips_elf_section_from_shdr.
2919 (mips_elf32_section_from_shdr): Rename from
2920 mips_elf_section_from_shdr. Call new function.
2921 (elf_backend_section_from_shdr): Update name of renamed function.
2922 * elf-bfd.h (struct elf_size_info): Change second parameter of
2923 write_out_phdrs to be const. Likewise for second parameter of
2924 swap_symbol_out.
2925 (struct bfd_elf_section_data): Add rel_hdr2 field.
2926 (bfd_elf32_swap_symbol_in): Change second parameter to be const.
2927 (bfd_elf32_swap_symbol_out): Likewise.
2928 (bfd_elf32_swap_reloc_in): Likewise.
2929 (bfd_elf32_swap_reloc_out): Likewise.
2930 (bfd_elf32_swap_reloca_in): Likewise.
2931 (bfd_elf32_swap_reloca_out): Likewise.
2932 (bfd_elf32_swap_phdr_in): Likewise.
2933 (bfd_elf32_swap_phdr_out): Likewise.
2934 (bfd_elf32_swap_dyn_in): Likewise.
2935 (bfd_elf32_swap_dyn_out): Likewise.
2936 (bfd_elf32_slurp_symbol_table): Declare.
2937 (bfd_elf32_write_shdrs_and_ehdr): Declare.
2938 (bfd_elf32_write_out_phdrs): Declare.
2939 (bfd_elf64_swap_symbol_in): Change second parameter to be const.
2940 (bfd_elf64_swap_symbol_out): Likewise.
2941 (bfd_elf64_swap_reloc_in): Likewise.
2942 (bfd_elf64_swap_reloc_out): Likewise.
2943 (bfd_elf64_swap_reloca_in): Likewise.
2944 (bfd_elf64_swap_reloca_out): Likewise.
2945 (bfd_elf64_swap_phdr_in): Likewise.
2946 (bfd_elf64_swap_phdr_out): Likewise.
2947 (bfd_elf64_swap_dyn_in): Likewise.
2948 (bfd_elf64_swap_dyn_out): Likewise.
2949 (bfd_elf64_slurp_symbol_table): Declare.
2950 (bfd_elf64_write_shdrs_and_ehdr): Declare.
2951 (bfd_elf64_write_out_phdrs): Declare.
2952 (_bfd_mips_elf_section_from_shdr): Declare.
2953 * elf.c (bfd_section_from_shdr): Remove assertion requiring
2954 SHT_REL/SHT_RELA to match use_rela_p. If there is already a reloc
2955 section for the section, add the new one to rel_hdr2. Increment
2956 reloc_count rather than setting it.
2957 * elfcode.h (elf_slurp_symbol_table): Define name as macro.
2958 Remove static declaration.
2959 (elf_write_shdrs_and_ehdr): Define name as macro.
2960 (elf_write_out_phdrs): Likewise.
2961 (elf_swap_ehdr_in, elf_swap_ehdr_out): Declare.
2962 (elf_swap_shdr_in, elf_swap_shdr_out): Declare.
2963 (elf_swap_symbol_in): Change second parameter to be const.
2964 (elf_swap_symbol_out): Likewise.
2965 (elf_swap_ehdr_in, elf_swap_ehdr_out): Likewise.
2966 (elf_swap_shdr_in, elf_swap_shdr_out): Likewise.
2967 (elf_swap_phdr_in, elf_swap_phdr_out): Likewise.
2968 (elf_swap_reloc_in, elf_swap_reloc_out): Likewise.
2969 (elf_swap_reloca_in, elf_swap_reloca_out): Likewise.
2970 (elf_write_out_phdrs): Rename from write_out_phdrs. Change second
2971 parameter to be const. Make non-static.
2972 (elf_write_shdrs_and_ehdr): Rename from write_shdrs_and_ehdr.
2973 Make non-static.
2974 (elf_slurp_symbol_table): Make non-static.
2975 (NAME(_bfd_elf,size_info)): Update names of renamed functions.
2976 * elfxx-target.h (elf_info_to_howto): Define if not defined.
2977 (elf_backend_size_info): Likewise.
2978 (elfNN_bed): Use elf_backend_size_info.
2979 * targets.c (bfd_elf64_bigmips_vec): Declare.
2980 (bfd_elf64_littlemips_vec): Declare.
2981 (bfd_target_vector): Add bfd_elf64_bigmips_vec and
2982 bfd_elf64_littlemips_vec if BFD64 is defined.
2983
2984 * libbfd.c (bfd_get_file_window): Add cast to fprintf argument.
2985
7dd3d45a
ILT
2986Tue May 28 11:42:08 1996 Ian Lance Taylor <ian@cygnus.com>
2987
07692951
ILT
2988 * coff-sh.c (sh_relax_delete_bytes): Insert nop instructions, not
2989 zeroes, in alignment holes.
2990
a4322a77
ILT
2991 * configure: Rebuild with autoconf 2.10.
2992
7dd3d45a
ILT
2993 * aoutx.h (NAME(aout,find_nearest_line)): Make room for the
2994 potential leading underscore in the allocated buffer.
2995
0293d5b0
MM
2996Fri May 24 14:28:38 1996 Michael Meissner <meissner@tiktok.cygnus.com>
2997
2998 * elf32-ppc.c (ppc_elf_add_symbol_hook): Do not put small common
2999 symbols into .sbss if this is a relocatable link.
3000
a5d0cd50
ILT
3001Thu May 23 12:26:24 1996 Ian Lance Taylor <ian@cygnus.com>
3002
3003 * xcofflink.c (_bfd_ppc_xcoff_relocate_section): Warn about
3004 undefined symbols when creating a shared library.
3005
3006Fri May 17 13:54:15 1996 Ian Lance Taylor <ian@cygnus.com>
3007
3008 * coff-sh.c: Add a bunch of new code and static const arrays to
3009 support aligning loads and stores on four byte memory boundaries.
3010 Also:
3011 (sh_coff_howtos): Add entries for R_SH_CODE, R_SH_DATA and
3012 R_SH_LABEL.
3013 (sh_relax_section): Look for R_SH_CODE relocs. If we find one,
3014 call sh_align_loads.
3015 (sh_relax_delete_bytes): Don't mark R_SH_CODE or R_SH_DATA relocs
3016 as unused.
3017
c403d358
ILT
3018Thu May 16 16:34:13 1996 Ian Lance Taylor <ian@cygnus.com>
3019
3020 * cache.c (bfd_open_file): Unlink the file before opening it for
3021 write. From Marty Leisner <leisner@sdsp.mc.xerox.com>.
3022
3023 * opncls.c (bfd_fdopenr): Set opened_once.
3024
2f710e17
ILT
3025Tue May 14 12:35:32 1996 Ian Lance Taylor <ian@cygnus.com>
3026
ff60fc3a
ILT
3027 * som.c (som_slurp_reloc_table): Clear external_relocs cache after
3028 freeing it.
3029
2f710e17
ILT
3030 * libbfd.c: Remove #ifdef FILE_OFFSET_IS_CHAR_INDEX, and compile
3031 the code unconditionally.
3032
efb33f6b
ILT
3033Mon May 13 19:51:37 1996 Ian Lance Taylor <ian@cygnus.com>
3034
3035 * libcoff-in.h (struct pei_section_tdata): Define structure.
3036 (pei_section_data): Define macro.
3037 * libcoff.h: Rebuild.
3038 * coffcode.h (coff_set_alignment_hook): If COFF_IMAGE_WITH_PE,
3039 store s_paddr field in pei_section_data.
3040 (coff_compute_section_file_positions): Use pei_section_data rather
3041 than _cooked_size, and don't overwrite an existing value.
3042 (coff_write_object_contents): If COFF_OBJ_WITH_PE, set s_paddr to
3043 0. If COFF_IMAGE_WITH_PE, set s_paddr to pei_section_data.
3044 * peicode.h (coff_bfd_copy_private_section_data): Define if
3045 COFF_IMAGE_WITH_PE.
3046 (pe_bfd_copy_private_section_data): New static function if
3047 COFF_IMAGE_WITH_PE.
3048
5ecd6d7f
ILT
3049Wed May 8 16:10:38 1996 Ian Lance Taylor <ian@cygnus.com>
3050
db1e2aa7
ILT
3051 * srec.c (srec_set_arch_mach): Write as a function rather than a
3052 macro definition.
3053
5ecd6d7f
ILT
3054 * xcofflink.c (_bfd_xcoff_bfd_link_add_symbols): If an archive has
3055 no map, just check each member in turn to see whether it is
3056 required.
3057
aefee5c8
MM
3058Wed May 8 09:17:34 1996 Michael Meissner <meissner@tiktok.cygnus.com>
3059
3060 * ppcboot.c (ppcboot_object_p): Check for type 0x41 in partition
3061 table. Call BFD_ASSERT to validate header size, instead of
3062 calling fatal.
3063 (ppcboot_bfd_print_private_bfd_data): Put quotes around partition
3064 name.
3065
0d1fcbbb
MM
3066Tue May 7 16:10:19 1996 Michael Meissner <meissner@tiktok.cygnus.com>
3067
3068 * ppcboot.c: New target for looking at PPCbug boot records.
3069
3070 * config{ure.in,.bfd}: Add support for ppcboot target.
3071 * targets.c: Ditto.
3072 * configure: Regenerate.
3073
f4597f8c
JL
3074Tue May 7 11:15:19 1996 Jeffrey A Law (law@cygnus.com)
3075
3076 * coff-h8300.c (howto_table): Update names to match recent
3077 changes to include/coff/internal.h. Fix minor errors in the
3078 existing relocs. Add R_MOVL1 and R_MOVL2.
3079 (rtype2howto): Similarly.
3080 (h8300_reloc16_estimate): Rewrite to simplify, fix bugs in the
3081 existing relaxing code and peform more relaxing.
3082 (h8300_reloc16_extra_cases): Likewise.
3083
0dc70e1a
JL
3084Mon May 6 18:24:09 1996 Jeffrey A Law (law@cygnus.com)
3085
3086 * reloc16.c (bfd_coff_reloc16_get_value): Handle common
3087 symbols correctly.
3088
d1b8ccb0
PS
3089Sat May 4 05:08:45 1996 Peter Schauer (pes@regent.e-technik.tu-muenchen.de)
3090
3091 * elfcode.h (elf_object_p): Reject generic ELF target if
3092 e_machine matches an alternate machine code in a specific backend.
3093
3094 * netbsd-core.c (netbsd_core_vec): Remove initializer for
3095 obsolete align_power_min field.
3096
c9f5444e
JL
3097Fri May 3 13:07:35 1996 Jeffrey A Law (law@cygnus.com)
3098
3099 * coff-h8300.c (reloc_howto_type): Add howto entry for
3100 R_PCRWORD_B.
3101 (rtype2howto): Handle R_PCRWORD_B.
3102 (h8300_reloc16_extra_cases): Handle R_PCRWORD_B.
3103 (h8300_reloc_16_estimate): Likewise. Try to turn a 16bit
3104 pc-relative branch (R_PCRWORD) into an 8bit pc-relative
3105 branch (R_PCWORD_B).
3106
4ad842aa
ILT
3107Fri May 3 10:47:41 1996 Ian Lance Taylor <ian@cygnus.com>
3108
340d654f
ILT
3109 * aoutx.h (translate_from_native_sym_flags): Set the section for
3110 BSF_CONSTRUCTOR symbols.
3111
4ad842aa
ILT
3112 * cofflink.c (_bfd_coff_link_input_bfd): Correct setting of
3113 last_bf_index.
3114
9c7a5748
DE
3115Wed May 1 18:39:32 1996 Doug Evans <dje@canuck.cygnus.com>
3116
3117 * coffcode.h (coff_write_object_contents): In comdat section lookup,
3118 stop looking when section is found.
3119
622c93a3
ILT
3120Wed May 1 14:17:57 1996 Ian Lance Taylor <ian@cygnus.com>
3121
e8f3bb64 3122 * coffcode.h (STRING_SIZE_SIZE): Define.
9aac8e83
ILT
3123 (styp_to_sec_flags): Handle long symbol names when looking for the
3124 section symbol.
e8f3bb64
ILT
3125 (bfd_coff_backend_data): Add _bfd_coff_long_section_names field.
3126 (bfd_coff_long_section_names): Define.
3127 (coff_write_object_contents): Handle long section names.
3128 (bfd_coff_std_swap_table): Initialize new field.
3129 * libcoff.h: Rebuild.
3130 * coffgen.c (make_a_section_from_file): Handle long section
3131 names.
3132 (coff_write_symbols): Handle long section names.
3133 * coff-alpha.c (alpha_ecoff_backend_data): Initialize new field.
3134 * coff-mips.c (mips_ecoff_backend_data): Likewise.
3135 * pe-arm.c (COFF_LONG_SECTION_NAMES): Define.
3136 * pei-arm.c (COFF_LONG_SECTION_NAMES): Define.
3137 * pe-i386.c (COFF_LONG_SECTION_NAMES): Define.
3138 * pei-i386.c (COFF_LONG_SECTION_NAMES): Define.
3139 * pe-ppc.c (COFF_LONG_SECTION_NAMES): Define.
3140 * pei-ppc.c (COFF_LONG_SECTION_NAMES): Define.
3141
622c93a3
ILT
3142 * bout.c (b_out_callback): Set lma of sections.
3143 (b_out_bfd_get_relocated_section_contents): Rename in_abfd
3144 parameter to output_bfd. Used input_bfd instead of output_bfd in
3145 several places.
3146
6b725f83
ILT
3147Tue Apr 30 17:56:39 1996 Ian Lance Taylor <ian@cygnus.com>
3148
b7d1158a
ILT
3149 * aoutx.h (translate_from_native_sym_flags): Don't create
3150 SEC_CONSTRUCTOR sections.
3151 * ecoff.c (ecoff_set_symbol_info): Likewise.
3152
6b725f83
ILT
3153 * elf32-mips.c (mips_elf_copy_private_bfd_data): Copy elf_gp.
3154 From Don Bowman <bowman@waterloo.hp.com>.
3155
e28a1e77
DE
3156Tue Apr 30 17:06:32 1996 Doug Evans <dje@canuck.cygnus.com>
3157
3158 * coff-arm.c (armcoff_little_vec): If COFF_WITH_PE is defined, add
3159 SEC_LINK_ONCE and SEC_LINK_DUPLICATES to section_flags.
3160
abec70b9
ILT
3161Mon Apr 29 13:15:17 1996 Ian Lance Taylor <ian@cygnus.com>
3162
3163 * elf32-mips.c (struct mips_elf_link_hash_entry): Add
3164 mips_32_relocs field.
3165 (mips_elf_link_hash_newfunc): Initialize mips_32_relocs field.
3166 (mips_elf_relocate_section): Copy R_MIPS_REL32 and R_MIPS_32
3167 relocs against a global symbol which is not defined in a regular
3168 file.
3169 (mips_elf_check_relocs): For a R_MIPS_REL32 or R_MIPS_32 reloc
3170 against a global symbol, increment mips_32_relocs.
3171 (mips_elf_adjust_dynamic_symbol): If mips_32_relocs is set, and
3172 the symbol is not defined in a regular file, make room in the
3173 .rel.dyn section.
3174
ecba7a3a
ILT
3175Fri Apr 26 18:00:37 1996 Ian Lance Taylor <ian@cygnus.com>
3176
656c5b6d
ILT
3177 * ecoff.c (ecoff_compute_section_file_positions): Track the real
3178 file position and the virtual file position separately. Set
3179 filepos information bsaed on the real file position.
3180 (_bfd_ecoff_set_section_contents): Handle .lib sections like the
3181 Jan 23 change to coffcode.h.
3182
ecba7a3a
ILT
3183 * som.c (som_slurp_symbol_table): Set the symbol count to the
3184 number of BFD symbols created.
3185
e25a7988
MM
3186Fri Apr 26 12:34:29 1996 Michael Meissner <meissner@tiktok.cygnus.com>
3187
3188 * elf32-ppc.c (ppc_elf_check_relocs): Forward relocations to the
3189 output file if linking shared objects. Loop to check all relocs,
3190 rather than returning false on first error.
3191
5c28a96e
MM
3192Thu Apr 25 13:25:12 1996 Michael Meissner <meissner@tiktok.cygnus.com>
3193
3f7ca26b
MM
3194 * elf32-ppc.c (ppc_elf_create_linker_section): Add PLT case.
3195 (ppc_elf_additional_program_headers): If .interp section, bump #
3196 of program headers by 1.
3197 (ppc_elf_adjust_dynamic_symbol): Flesh out support.
3198 (ppc_elf_size_dynamic_sections): Add support for .plt section.
3199 (ppc_elf_check_relocs): Print out filename in debug code. Enable
3200 PLT support.
3201 (ppc_elf_finish_dynamic_symbol): Add support for PLT's, beef up
3202 debug output.
3203 (ppc_elf_relocate_section): If the output section isn't defined,
3204 don't abort, just give an error message.
3205
5c28a96e
MM
3206 * elflink.c (_bfd_elf_create_dynamic_sections): If the section
3207 being created is .sdata or .sdata2, don't make the symbol dynamic.
3208
f5d65485
ILT
3209Wed Apr 24 14:04:07 1996 Ian Lance Taylor <ian@cygnus.com>
3210
3211 * xcofflink.c (_bfd_xcoff_bfd_link_add_symbols): Look through the
3212 members of an archive for dynamic objects with no symbols, and
3213 pass them directly to check_archive_element.
3214 (xcoff_link_check_ar_symbols): Pass dynamic objects to
3215 xcoff_link_check_dynamic_ar_symbols.
3216 (xcoff_link_check_dynamic_ar_symbols): New static function.
3217
3218 * coff-rs6000.c (rs6000coff_vec): Change BFD_JUMP_TABLE_DYNAMIC
3219 from _bfd_nodynamic to _bfd_xcoff.
3220 * libcoff-in.h (_bfd_xcoff_get_dynamic_symtab_upper_bound):
3221 Declare.
3222 (_bfd_xcoff_canonicalize_dynamic_symtab): Declare.
3223 (_bfd_xcoff_get_dynamic_reloc_upper_bound): Declare.
3224 (_bfd_xcoff_canonicalize_dynamic_reloc): Declare.
3225 * libcoff.h: Rebuild.
3226 * xcofflink.c (xcoff_swap_ldrel_in): New static function.
3227 (xcoff_get_section_contents): New static function.
3228 (_bfd_xcoff_get_dynamic_symtab_upper_bound): New function.
3229 (_bfd_xcoff_canonicalize_dynamic_symtab): New function.
3230 (_bfd_xcoff_get_dynamic_reloc_upper_bound): New function.
3231 (xcoff_dynamic_reloc): New static variable.
3232 (_bfd_xcoff_canonicalize_dynamic_reloc): New function.
3233 (xcoff_link_add_dynamic_symbols): Use xcoff_get_section_contents.
3234
3235Tue Apr 23 12:48:42 1996 Ian Lance Taylor <ian@cygnus.com>
3236
3237 * coff-sparc.c (bfd_coff_generic_reloc): Return bfd_reloc_ok even
3238 if reloc_entry->addend is not 0.
3239 (CALC_ADDEND): Just set the addend to reloc.r_offset.
3240
34249b2f
DE
3241Mon Apr 22 18:29:01 1996 Doug Evans <dje@canuck.cygnus.com>
3242
3243 * elf32-sparc.c (_bfd_sparc_elf_howto_table): Fix spelling of
3244 R_SPARC_GLOB_JMP.
3245 * elf64-sparc.c (sparc64_elf_howto_table): Likewise.
3246 Add entries for R_SPARC_[56].
3247 (sparc_reloc_map): Add entries for R_SPARC_[56].
3248
af50cd91
ILT
3249Mon Apr 22 15:07:24 1996 Ian Lance Taylor <ian@cygnus.com>
3250
1726b8f0
ILT
3251 Optimize linking of stabs in sections as used in ELF and COFF.
3252 * stabs.c: New file.
3253 * libbfd-in.h (_bfd_link_section_stabs): Declare.
3254 (_bfd_write_section_stabs): Declare.
3255 (_bfd_write_stab_strings): Declare.
3256 * libbfd.h: Rebuild.
3257 * libcoff-in.h (struct coff_section_tdata): Add stab_info field.
3258 (struct coff_link_hash_table): Add stab_info field.
3259 * libcoff.h: Rebuild.
3260 * cofflink.c (_bfd_coff_link_hash_table_init): Initialize
3261 stab_info field.
3262 (coff_link_add_symbols): Call _bfd_link_section_stabs if
3263 appropriate.
3264 (_bfd_coff_final_link): Write out stab strings hash table.
3265 (_bfd_coff_link_input_bfd): Handle optimized stabs sections.
3266 * coff-ppc.c (ppc_bfd_coff_final_link): Write out stab strings
3267 hash table.
3268 * elf-bfd.h (struct elf_link_hash_table): Add stab_info field.
3269 (struct bfd_elf_section_data): Add stab_info field.
3270 * elf.c (_bfd_elf_link_hash_table_init): Initialize stab_info
3271 field.
3272 * elflink.h (elf_link_add_object_symbols): If appropriate, call
3273 _bfd_link_section_stabs.
3274 (elf_bfd_final_link): Write out stab strings hash table.
3275 (elf_link_input_bfd): Handle optimized stabs sections.
3276 * reloc.c (_bfd_final_link_relocate): Check address against
3277 _raw_size rather than _cooked_size.
3278 * Makefile.in: Rebuild dependencies.
3279 (BFD_LIBS): Add stabs.o
3280 (BFD_LIBS_CFILES): Add stabs.c.
3281
3282 * VERSION: Increment for bfdlink.h change.
3283
af50cd91
ILT
3284 * coffgen.c (coff_renumber_symbols): Correct handling of
3285 BSF_NOT_AT_END common symbols.
3286
f9fa5df3
ILT
3287Fri Apr 19 19:21:56 1996 Ian Lance Taylor <ian@cygnus.com>
3288
3289 * coff-ppc.c (record_toc): Add cast to avoid warning.
3290 (ppc_allocate_toc_section): Likewise.
3291 (coff_ppc_relocate_section): Remove ANSI C string concatenation.
3292 (ppc_coff_reloc_type_lookup): Remove unreached code.
3293 * coffcode.h (coff_write_object_contents): Don't take the address
3294 of an array.
3295 * peicode.h (pe_print_idata): Add casts to avoid warning.
3296 (pe_print_edata): Likewise.
3297 (pe_print_reloc): Remove ANSI C string concatenation.
3298
d6e0e2f7
ILT
3299Thu Apr 18 18:51:18 1996 Ian Lance Taylor <ian@cygnus.com>
3300
3301 * libcoff-in.h (struct coff_final_link_info): Add last_bf_index
3302 and last_bf fields.
3303 * libcoff.h: Rebuild.
3304 * coffswap.h (coff_swap_aux_in): Swap endndx field for C_FCN
3305 symbols.
3306 (coff_swap_aux_out): Likewise.
3307 * peicode.h (coff_swap_aux_in): Likewise.
3308 (coff_swap_aux_out): Likewise.
3309 * coffgen.c (coff_pointerize_aux): Check endndx field for C_FCN
3310 symbols.
3311 * cofflink.c (_bfd_coff_final_link): Initialize last_bf_index
3312 field.
3313 (_bfd_coff_link_input_bfd): Check endndx field for C_FCN symbols.
3314 Fix up .bf endndx link fields.
3315 * coff-ppc.c (ppc_bfd_coff_final_link): Initialize last_bf_index
3316 field.
3317 * xcofflink.c (xcoff_link_input_bfd): Check endndx field for C_FCN
3318 symbols.
3319
221d1e19
MM
3320Wed Apr 17 12:08:24 1996 Michael Meissner <meissner@tiktok.cygnus.com>
3321
3322 * pe{,i}-ppc.c (PPC_PE): Define instead of PPC, so that compiling
3323 on Solaris PowerPC systems doesn't get confused.
3324
3325 * ccffcode.h (coff_write_object_contents): Use #ifdef PPC_PE, not
3326 #ifdef PPC.
3327
3328 * elfcore.h (bfd_prstatus, bfd_fpregset): Add thread argument.
3329 (elf_corefile_note): If HAVE_SYS_PROCFS_H is not defined, don't
3330 update did_reg and did_reg2.
3331
8f9a56c6
ILT
3332Wed Apr 17 13:07:37 1996 Ian Lance Taylor <ian@cygnus.com>
3333
f97fca78
ILT
3334 * xcofflink.c (xcoff_link_input_bfd): Check for TOC overflow.
3335
8f9a56c6
ILT
3336 * linker.c (_bfd_generic_link_add_one_symbol): When calling the
3337 callback routines, pass h->root.string rather than name, in case
3338 copy is true and name is transient.
3339
603fdf16
SG
3340Tue Apr 16 16:36:38 1996 Stu Grossman (grossman@lisa.cygnus.com)
3341
3342 * elfcore.h: Add support for core files with multiple threads.
3343 (Primarily for Solaris.)
3344
a2d914e1
ILT
3345Tue Apr 16 13:44:08 1996 Ian Lance Taylor <ian@cygnus.com>
3346
cdf23557
ILT
3347 * aoutx.h (NAME(aout,squirt_out_relocs)): Don't do anything if
3348 section->orelocation is NULL.
3349
a2d914e1
ILT
3350 * coffgen.c (bfd_coff_get_syment): New function.
3351 (bfd_coff_get_auxent): New function.
3352 * bfd-in.h (bfd_coff_get_syment): Declare.
3353 (bfd_coff_get_auxent): Declare.
3354 * bfd-in2.h: Rebuild.
3355
5cf36a32
ILT
3356Mon Apr 15 19:06:59 1996 Ian Lance Taylor <ian@cygnus.com>
3357
3358 * elf32-mips.c (struct mips_hi16): Define.
3359 (mips_hi16_addr, mips_hi16_addend): Remove.
3360 (mips_hi16_list): New static variable.
3361 (mips_elf_hi16_reloc): Maintain a list of unmatched HI16 relocs.
3362 (mips_elf_lo16_reloc): Process mips_hi16_list.
3363 (mips_elf_relocate_section): Permit an arbitrary number of HI16
3364 relocs before the associated LO16 reloc.
3365
b7fce5be
ILT
3366Wed Apr 10 00:23:53 1996 Ian Lance Taylor <ian@cygnus.com>
3367
176512da
ILT
3368 * versados.c (versados_scan): Check bfd_alloc return value.
3369 (versados_object_p): Check all bfd_read return values. Require
3370 that lang field be less than 10, to avoid confusion with Intel Hex
3371 files.
3372
18de3f19
ILT
3373 * libaout.h (WRITE_HEADERS): Write out the relocs even if there
3374 aren't any symbols.
3375 * aoutx.h (NAME(aout,swap_std_reloc_out)): Set r_index to N_ABS,
3376 not 0, for an absolute symbol.
3377 (NAME(aout,swap_ext_reloc_out)): Likewise.
3378
66ab4152
ILT
3379 * ihex.c (ihex_scan): Accept a length of 4 for record type 5.
3380 (ihex_write_object_contents): For a large start address, output
3381 the full 32 bit address in record type 5.
3382
b7fce5be
ILT
3383 * ieee.c (ieee_write_byte): Change second parameter from bfd_byte
3384 to int to avoid promotion problems in prototype.
3385
f1b45745
ILT
3386Tue Apr 9 11:44:21 1996 Ian Lance Taylor <ian@cygnus.com>
3387
f400f358
ILT
3388 * configure.host: Use ${srcdir} when looking for picfrag.
3389
3d9a5986
ILT
3390 * configure.host: Switch on ${libdir}, not $(libdir). From
3391 alan@spri.levels.unisa.edu.au (Alan Modra).
3392
f1b45745
ILT
3393 * aoutx.h (aout_link_add_symbols): Always call add_dynamic_symbols
3394 entry point, not just for DYNAMIC objects.
3395 * sunos.c (sunos_add_dynamic_symbols): Always call
3396 sunos_create_dynamic_sections. If called with a non DYNAMIC
3397 object, don't do anything else.
3398 (sunos_add_one_symbol): Don't call sunos_create_dynamic_sections.
3399
6f21f2e3
ILT
3400Mon Apr 8 12:09:36 1996 Ian Lance Taylor <ian@cygnus.com>
3401
639b5a09
ILT
3402 * configure.in: Permit --enable-shared to specify a list of
3403 directories.
3404 * configure: Rebuild.
3405
6f21f2e3
ILT
3406 * configure.host: Set HLDFLAGS and SHLIB_CFLAGS for *-dec-osf*
3407 host when configuring with --enable-shard.
3408
3f5f565b
ILT
3409Fri Apr 5 12:24:13 1996 Ian Lance Taylor <ian@cygnus.com>
3410
1ac75f5c
ILT
3411 * config.bfd: Add i[345]86-*-freebsdelf* target; from John Polstra
3412 <jdp@polstra.com>.
3413
1a9951a9
ILT
3414 * linker.c (link_action): For WARN_ROW/warn, use MWARN, not CYCLE,
3415 to avoid crashing in bfd_hash_replace.
3416
f1ac3acb 3417 * sysdep.h: Use #ifdef, not #if.
3f5f565b 3418
eb5f58e0
ILT
3419Thu Apr 4 23:32:23 1996 Ian Lance Taylor <ian@cygnus.com>
3420
3421 * config.in: Rebuild.
3422
ab1aa5cd
FF
3423Thu Apr 4 18:49:09 1996 Fred Fish <fnf@cygnus.com>
3424
3425 * configure.in (mips-sony-bsd*): Fix typo in AC_DEFINE.
3426 (AC_CHECK_HEADERS): Check for sys/time.h
3427 (AC_HEADER_TIME): Add macro.
3428 * configure: Rebuild.
3429 * sysdep.h: Use TIME_WITH_SYS_TIME and HAVE_SYS_TIME_H
3430 to control what combination of <time> and <sys/time.h>
3431 get included.
3432
d1f74cd2
DE
3433Tue Apr 2 13:11:53 1996 Doug Evans <dje@canuck.cygnus.com>
3434
3435 * aoutf1.h (sunos_32_set_arch_mach): Handle M_SPARCLET.
3436 (aout_32_sunos4_write_object_contents): Likewise.
3437 * aoutx.h (NAME(aout,machine_type)): Handle
3438 bfd_mach_sparc_{sparclet,sparclite}.
3439 * archures.c (bfd_mach_sparc_{sparclet,sparclite}): Define.
3440 (bfd_mach_sparc_v9_p): Update.
3441 * cpu-sparc.c (arch_info_struct): Add entries for sparclet,sparclite.
3442 * libaout.h (enum machine_type): Add M_SPARCLET.
3443 * sunos.c (MACHTYPE_OK): Define.
3444 * bfd-in2.h: Regenerated.
3445
1dad72bd
ILT
3446Tue Apr 2 00:33:18 1996 Ian Lance Taylor <ian@cygnus.com>
3447
19bfbcbe
ILT
3448 * elf-bfd.h (struct elf_link_hash_table): Add hgot field.
3449 * elf.c (_bfd_elf_link_hash_table_init): Initialize hgot field.
3450 * elflink.c (_bfd_elf_create_got_section): Store the
3451 _GLOBAL_OFFSET_TABLE_ hash table entry in the hgot field.
3452 * elf32-sparc.c (elf32_sparc_check_relocs): If the size of the
3453 global offset table goes over 0x1000, set the value of
3454 _GLOBAL_OFFSET_TABLE_ to 0x1000 into the section.
3455 (elf32_sparc_relocate_section): Subtract the offset of
3456 _GLOBAL_OFFSET_TABLE_ when handling GOT relocations.
3457
1dad72bd
ILT
3458 * elfcode.h: Don't include <string.h>.
3459
ca4e2190
JL
3460Mon Apr 1 10:39:24 1996 Jeffrey A Law (law@cygnus.com)
3461
3462 * linker.c (_bfd_generic_link_hash_newfunc): Renamed from
3463 generic_link_hash_newfunc. All references changed.
3464 * genlink.h (_bfd_generic_link_hash_newfunc): Declaration
3465 moved here from libbfd-in.h.
3466 * libbfd-in.h: Corresponding changes.
3467 * libbfd.h: Regenerated.
3468
ce6a7731
ILT
3469Mon Apr 1 12:35:36 1996 Ian Lance Taylor <ian@cygnus.com>
3470
aad53b0d
ILT
3471 * aoutx.h (aout_link_input_section_std): When reporting an
3472 overflow error, use the name of the symbol in the hash table if
3473 available.
3474 (aout_link_input_section_ext): Likewise.
3475
ce6a7731
ILT
3476 * elflink.h (elf_adjust_dynamic_symbol): If a common symbol got
3477 defined in a regular file, set ELF_LINK_HASH_DEF_REGULAR.
3478
323b430f
SC
3479Sun Mar 31 01:58:41 1996 steve chamberlain <sac@slash.cygnus.com>
3480
3481 * peicode.h (coff_swap_aouthdr_out): Delete test for .junk.
3482 * coffcode.h (coff_compute_section_file_positions): Likewise.
3483 (coff_write_object_contents): Likewise.
3484
7fc1cd16
ILT
3485Fri Mar 29 12:44:36 1996 Ian Lance Taylor <ian@cygnus.com>
3486
5a28331f
ILT
3487 * section.c (SEC_LINK_ONCE): Define.
3488 (SEC_LINK_DUPLICATES): Define.
3489 (SEC_LINK_DUPLICATES_DISCARD): Define.
3490 (SEC_LINK_DUPLICATES_ONE_ONLY): Define.
3491 (SEC_LINK_DUPLICATES_SAME_SIZE): Define.
3492 (SEC_LINK_DUPLICATES_SAME_CONTENTS): Define.
3493 * bfd-in2.h: Rebuild.
3494 * coffcode.h (sec_to_styp_flags): If COFF_WITH_PE, turn
3495 SEC_LINK_ONCE into IMAGE_SCN_LNK_COMDAT.
3496 (styp_to_sec_flags): If COFF_WITH_PE, turn IMAGE_SCN_LNK_REMOVE
3497 into SEC_EXCLUDE. If IMAGE_SCN_LNK_COMDAT is set, set
3498 SEC_LINK_ONCE, and look through the symbol table for the setting
3499 for SEC_LINK_DUPLICATES.
3500 (coff_write_object_contents): If COFF_WITH_PE, if SEC_LINK_ONCE is
3501 set for a section, find the section symbol in the symbol table,
3502 and set the aux entry based on SEC_LINK_DUPLICATES.
3503 * coffgen.c (coff_print_symbol): Add a space before "checksum".
3504 * coff-arm.c (armcoff_big_vec): If COFF_WITH_PE is defined, add
3505 SEC_LINK_ONCE and SEC_LINK_DUPLICATES to section_flags.
3506 * coff-i386.c (i386coff_vec): Likewise.
3507 * coff-ppc.c (TARGET_LITTLE_SYM, TARGET_BIG_SYM): Likewise.
3508
7fc1cd16
ILT
3509 * VERSION: Bump to 2.6.1.
3510 * Makefile.in (stamp-h): Depend upon VERSION.
3511
9399a257
JL
3512Thu Mar 28 23:48:49 1996 Jeffrey A Law (law@cygnus.com)
3513
3514 * libbfd-in.h (generic_link_hash_newfunc): Add declaration.
3515 * libbfd.h: Rebuilt.
3516 * linker.c (generic_link_hash_newfunc): No longer static.
3517 * coffcode.h (coff_bfd_link_hash_create): Allow specific targets
3518 to override.
3519 * coff-h8300.c: Add two derived hash tables and their associated
3520 funtions and #defines for use by the h8300 linker.
3521 (h8300_reloc16_extra_cases, case R_MEM_INDIRECT): Create entries in
3522 the function vector as needed. Place the address of the function
3523 vector entry in the location specified by the R_MEM_INDIRECT reloc.
3524 Rewrite the vectors section contents as necessary.
3525 (h8300_bfd_link_add_symbols): New function for the h8300 linker.
3526 (coff_bfd_link_add_symbols): Define to use h8300 specific version.
3527 (coff_bfd_link_hash_table_create): Likewise.
3528
506f2bb4
ILT
3529Thu Mar 28 17:44:08 1996 Ian Lance Taylor <ian@cygnus.com>
3530
3531 * libhppa.h: If gcc 2.7 or higher, declare all the functions with
3532 __attribute__ ((__unused__)) so that -Wall doesn't warn about
3533 them.
3534 (hppa_rebuild_insn): Pass pointer to correct type to
3535 low_sign_unext and dis_assemble_21.
3536
05a84ae1
DE
3537Thu Mar 28 11:00:36 1996 Doug Evans <dje@canuck.cygnus.com>
3538
3539 * config.bfd (sparc64-{sysv4*,solaris2*}): Delete.
3540 Stick with sparc-*-{sysv4*,solaris2*}.
3541
919cf4b5
ILT
3542Wed Mar 27 10:43:34 1996 Ian Lance Taylor <ian@cygnus.com>
3543
8230f31c
ILT
3544 * peicode.h (coff_swap_aux_in): Swap in extra PE x_scn fields.
3545 (coff_swap_aux_out): Swap out extra PE x_scn fields.
3546 * coffswap.h (coff_swap_aux_in): Zero out extra PE x_scn fields.
3547 * coffgen.c (coff_print_symbol): If any of the extra PE x_scn
3548 fields is non-zero, print them.
3549
9addd1d4
ILT
3550 * coff-ppc.c (ppc_record_toc_entry): Put inside COFF_IMAGE_WITH_PE
3551 ifdef. Remove unused variables.
3552 (ppc_record_data_in_toc_entry): Ifdef out. Removed unused
3553 variables.
3554 (ppc_mark_symbol_as_glue): Put inside COFF_IMAGE_WITH_PE ifdef.
3555 (get_symbol_value): Ifdef out.
3556 (pe_ppc_reloc): Ifdef out. Remove unused variables.
3557 (coff_ppc_relocate_section): Remove unused variables. Make
3558 fprintf strings and argument types correspond. Put before_addr in
3559 DEBUG_RELOC ifdef.
ff0e4a93
ILT
3560 (dump_toc): Make fprintf strings and argument types correspond.
3561 (ppc_process_before_allocation): Remove unused variables. Always
3562 return a value.
9addd1d4
ILT
3563 (ppc_reflo_reloc): Ifdef out.
3564 (ppc_addr32nb_reloc): Ifdef out.
3565 (ppc_coff_rtype2howto): Make fprintf strings and argument types
3566 correspond.
3567 (coff_ppc_rtype_to_howto): Likewise.
3568 (ppc_coff_swap_sym_in_hook): Remove unused variables.
3569
3570 * peicode.h (pe_print_idata): Move otherwise unused variables into
3571 the #ifdef where they are used. Always return a value.
ff0e4a93
ILT
3572 (pe_print_edata): Make fprintf strings and argument types
3573 correspond. Always return a value.
9addd1d4
ILT
3574 (pe_print_pdata): Removed unused variable addr_value. Always
3575 return a value.
3576 (pe_print_reloc): Remove unused variable onaline. Make fprintf
ff0e4a93 3577 strings and argument types correspond. Always return a value.
9addd1d4
ILT
3578
3579 * elf32-ppc.c (ppc_elf_fake_sections): Return true.
3580 (ppc_elf_finish_dynamic_symbol): Move definition of unused
3581 variable rela inside #if 0 section where it is used.
3582
c877bdf1
ILT
3583 * ns32k.h: New file.
3584 * cpu-ns32k.h: Include ns32k.h. Rename externally visible
3585 functions to start with _bfd_.
3586 * aout-ns32k.c: Include ns32k.h. Change references to renamed
3587 functions in cpu-ns32k.h.
3588 * Makefile.in: Rebuild dependencies.
3589 (HFILES): Add ns32k.h.
3590
ff0e4a93
ILT
3591 * section.c (struct sec): Add linker_mark field. Change
3592 user_set_vma and reloc_done to be single bit fields.
3593 (STD_SECTION): Update accordingly.
7ec49f91
ILT
3594 * bfd-in2.h: Rebuild.
3595 * aoutx.h (NAME(aout,final_link)): Mark sections included in the
3596 link.
3597 (aout_link_input_bfd): Don't link unmarked sections.
3598 * cofflink.c (_bfd_coff_final_link): Mark sections included in the
3599 link.
3600 (_bfd_coff_link_input_bfd): Don't link unmarked sections.
3601 * coff-ppc.c (ppc_bfd_coff_final_link): Mark sections included in
3602 the link.
3603 * elflink.h (elf_bfd_final_link): Mark sections included in the
3604 link.
3605 (elf_link_input_bfd): Don't link unmarked sections.
3606 * xcofflink.c (_bfd_xcoff_bfd_final_link): Mark sections included
3607 in the link.
3608 (xcoff_link_input_bfd): Don't link unmarked sections.
3609
919cf4b5
ILT
3610 * coffswap.h (coff_swap_scnhdr_out): Include section name in
3611 overflow error messages.
3612
986cf3b8
ILT
3613Tue Mar 26 15:46:18 1996 Ian Lance Taylor <ian@cygnus.com>
3614
fd681dcd
ILT
3615 * bfd.c (_bfd_default_error_handler): If _bfd_error_program_name
3616 is not set, print "BFD: " before the error message.
3617
986cf3b8
ILT
3618 * configure.in: Use AC_CHECK_TOOL to find ar and ranlib. From
3619 Miles Bader <miles@gnu.ai.mit.edu>.
3620 * configure: Rebuild.
3621
3998d526
ILT
3622Fri Mar 22 12:17:00 1996 Ian Lance Taylor <ian@cygnus.com>
3623
c3dffbd7
ILT
3624 * xcofflink.c (xcoff_link_input_bfd): Fix scan for C_BINCL/C_EINCL
3625 symbols.
3626
3998d526
ILT
3627 * config.bfd: Add ieee_vec to targ_selvecs for i960 targets and
3628 m68k-aout, m68k-coff, and m68k-elf targets.
3629
e4d27380
ILT
3630Fri Mar 22 11:33:44 1996 Martin Anantharaman <martin@goofy.imech.uni-duisburg.de>
3631
3632 * ieee.c: Changed #ifdef KEEPMINUSPCININST to #if KEEPMINUSPCININST.
3633 (ieee_generic_stat_arch_elt): Restructured to prevent
3634 ieee_object_p from being called repeatedly.
3635
51776a11
SC
3636Thu Mar 21 11:00:47 1996 steve chamberlain <sac@slash.cygnus.com>
3637
3638 * coffcode.h (coff_write_object_contents): Allocate
3639 buffers large enough for any FILEHDR or AOUTHDR.
3640
3641Thu Mar 21 16:28:17 1996 David Mosberger-Tang <davidm@azstarnet.com>
3642
3643 * ecofflink.c (lookup_line): New static function, renamed and
3644 slighly changed from old _bfd_ecoff_locate_line.
3645 (_bfd_ecoff_locate_line): Cache line number information. Use
3646 lookup_line for actual lookup.
3647
9e4ebb1b
MM
3648Thu Mar 21 14:59:11 1996 Michael Meissner <meissner@tiktok.cygnus.com>
3649
3650 * peicode.h (pe_print_pdata): Warn if the .pdata section is not a
3651 multiple of 20 bytes.
3652
9e7427a4
ILT
3653Thu Mar 21 13:54:40 1996 Ian Lance Taylor <ian@cygnus.com>
3654
51776a11
SC
3655 * ecoff.c (_bfd_ecoff_find_nearest_line): Use bfd_zalloc to
3656 allocate ecoff_find_line, and don't initialize by hand.
3657 * elf32-mips.c (mips_elf_find_nearest_line): Use bfd_zalloc for
3658 mips_elf_find_line, and don't call memset.
3659
9e7427a4
ILT
3660 * coffcode.h (coff_compute_section_file_positions): If not
3661 producing a final executable, don't consider sofar when aligning
3662 the section to the correct size.
3663
3664Wed Mar 20 16:53:12 1996 Ian Lance Taylor <ian@cygnus.com>
3665
3666 * coffcode.h (coff_add_missing_symbols): Ifdef out.
3667 (coff_write_object_contents): Don't call coff_add_missing_symbols.
3668 * coffgen.c (coff_section_symbol): Ifdef out.
3669
e7f9ba4f
ILT
3670Mon Mar 18 12:54:41 1996 Ian Lance Taylor <ian@cygnus.com>
3671
3672 * elf32-mips.c (mips_elf_gprel32_reloc): Initialize gp if
3673 output_bfd is not NULL.
3674
34c4d647
DE
3675Thu Mar 14 17:12:06 1996 Doug Evans <dje@charmed.cygnus.com>
3676
3677 * coffgen.c (coff_get_normalized_symtab): Call bfd_zalloc instead
3678 of bfd_alloc (fixes fix_line not being initialized).
3679 Delete zeroing of fix_{value,tag,end,scnlen} fields.
3680
4e054247
JL
3681Thu Mar 14 16:06:06 1996 Jeffrey A Law (law@cygnus.com)
3682
57289b5c
JL
3683 * coffcode.h: Allow specific backends to override the
3684 bfd_link_add_symbols routine.
3685
4e054247
JL
3686 * coff-h8300.c: Include genlink.h.
3687 (howto_table): Add R_MEM_INDIRECT.
3688 (rtype2howto): Support R_MEM_INDIRECT.
3689 (h8300_reloc16_extra_cases): Handle R_MEM_INDIRECT like R_RELBYTE
3690 for now.
3691
a10d3dec
ILT
3692Tue Mar 12 12:41:17 1996 David Mosberger-Tang <davidm@koala.azstarnet.com>
3693
3694 * coff-alpha.c (alpha_relocate_section): Use
3695 info->callbacks_warning, rather than _bfd_error_handler, for
3696 "multiple gp" warning.
3697
ea2488ad
ILT
3698Tue Mar 12 12:10:55 1996 Ian Lance Taylor <ian@cygnus.com>
3699
8881b321
ILT
3700 * linker.c (bfd_wrapped_link_hash_lookup): New function.
3701 (_bfd_generic_link_add_one_symbol): Remove BFD_ASSERT on hash
3702 table string. Use bfd_wrapped_link_hash_lookup.
3703 (_bfd_generic_link_write_global_symbol): Remove BFD_ASSERT on hash
3704 table string.
3705 * aoutx.h (aout_link_write_symbols): Use the name from the hash
3706 table, if any, when writing out symbols.
3707 (aout_link_input_section_std): Use the name from the hash table,
3708 if any, when reporting undefined symbols.
3709 (aout_link_input_section_ext): Likewise.
3710 (aout_link_reloc_link_order): Use bfd_wrapped_link_hash_lookup.
3711 * bout.c (get_value): Likewise.
3712 * cofflink.c (_bfd_coff_reloc_link_order): Likewise.
3713 * ecoff.c (ecoff_reloc_link_order): Likewise.
3714 * elflink.h (elf_link_add_object_symbols): Likewise.
3715 (elf_reloc_link_order): Likewise.
3716 * linker.c (_bfd_generic_link_output_symbols): Likewise.
3717 (_bfd_generic_reloc_link_order): Likewise.
3718 (default_indirect_link_order): Likewise.
3719 * reloc16.c (bfd_coff_reloc16_get_value): Likewise.
3720 * sunos.c (sunos_add_one_symbol): Likewise.
3721 * xcofflink.c (xcoff_link_add_symbols): Likewise.
3722 (bfd_xcoff_link_count_reloc): Likewise.
3723 (xcoff_reloc_link_order): Likewise.
3724
3725 * ecoffswap.h (ecoff_swap_fdr_in): If ECOFF_64, turn 0xffffffff
3726 into -1 for intern->rss.
3727
ea2488ad
ILT
3728 * configure: Rebuild with autoconf 2.8.
3729
c189fdfb
ILT
3730Mon Mar 11 12:28:31 1996 Ian Lance Taylor <ian@cygnus.com>
3731
3732 * stab-syms.c (__define_stab_duplicate): Define.
3733 (bfd_get_stab_name): Rename from aout_stab_name. Rewrite to use a
3734 switch.
3735 * bfd-in.h (bfd_get_stab_name): Declare.
3736 * bfd-in2.h: Rebuild.
3737 * Makefile.in: Rebuild dependencies.
3738 (BFD_LIBS): Add stab-syms.o.
3739 (BFD_LIBS_CFILES): Add stab-syms.c.
3740 (BFD32_BACKENDS): Remove stab-syms.o.
3741 (BFD32_BACKENDS_CFILES): Remove stab-syms.c.
3742 * configure.in: Don't list stab-syms.o in bfd_backends.
3743 * configure: Rebuild.
3744 * libaout.h (aout_stab_name): Don't declare.
3745 * aoutx.h (NAME(aout,get_symbol_info)): Call bfd_get_stab_name,
3746 not aout_stab_name.
3747
3748Fri Mar 8 11:26:20 1996 Ian Lance Taylor <ian@cygnus.com>
3749
3750 * elf.c (assign_file_positions_for_segments): Adjust file offset
3751 for section alignment even if SEC_LOAD is not set.
3752
c5bde1ef
ILT
3753Tue Mar 5 12:02:23 1996 Ian Lance Taylor <ian@cygnus.com>
3754
8f218e05
ILT
3755 * configure.in: Don't set SHLIB or SHLINK to an empty string,
3756 since they appear as targets in Makefile.in.
3757 * configure: Rebuild.
3758
c5bde1ef
ILT
3759 * sunos.c (sunos_scan_ext_relocs): If not making a shared library,
3760 don't fiddle with a symbol which is not defined anywhere.
3761
cb84f028
ILT
3762Mon Mar 4 12:49:16 1996 Ian Lance Taylor <ian@cygnus.com>
3763
4e59f523
ILT
3764 * xcofflink.c (xcoff_mark): Treat undefined imported symbols as
3765 though they are defined in a shared library.
3766 (xcoff_build_ldsyms): Likewise.
3767
ea2504d5
ILT
3768 * coffgen.c (coff_find_nearest_line): Don't look at the line
3769 numbers for the section if section->lineno is NULL.
3770
cb84f028
ILT
3771 * elf.c (_bfd_elf_symbol_from_bfd_symbol): Print a useful error
3772 message rather than calling BFD_ASSERT.
3773 * elfcode.h (write_relocs): Check return value of
3774 _bfd_elf_symbol_from_bfd_symbol.
3775
6e036cf7
MM
3776Fri Mar 1 09:42:59 1996 Michael Meissner <meissner@tiktok.cygnus.com>
3777
3778 * elf32-ppc.c (ppc_elf_add_symbol_hook): Don't set SEC_LOAD flag
3779 for .sbss section.
3780
d08435de
JL
3781Wed Feb 28 11:25:47 1996 Jeffrey A Law (law@cygnus.com)
3782
3783 * libhppa.h (hppa_reloc_field_selector_type): Add R_HPPA_NLSEL
3784 and R_HPPA_NLRSEL.
3785 (e_nsel, e_nlsel, e_nlrsel): Undefine. Add to
3786 hppa_reloc_field_selector_type_alt.
3787 (hppa_field_adjust): Handle e_nlsel, e_nlrsel. Fix e_nsel handling.
3788 * som.c (hppa_som_gen_reloc_type): Handle N', NL' NLR' field
3789 selectors.
3790 (som_write_fixups): Finish handling of R_N0SEL and R_N1SEL.
3791
09609415
ILT
3792Wed Feb 28 11:00:24 1996 Ian Lance Taylor <ian@cygnus.com>
3793
3794 * elf.c (assign_file_positions_for_segments): Adjust the segment
3795 memory size for the alignment of a SEC_ALLOC section, not just a
3796 SEC_LOAD section.
3797
55626bf0
ILT
3798Tue Feb 27 14:17:31 1996 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
3799
3800 * m68klinux.c: New file.
3801 * hosts/m68klinux.h: New file.
3802 * config.bfd (m68*-*-linuxaout*, m68*-*-linux*): New targets.
3803 * configure.in (m68*-*-linux*): New native host.
3804 (m68klinux_vec): New vector.
3805 * configure: Rebuild.
3806 * targets.c (m68klinux_vec): Declare.
3807 * i386linux.c (bfd_i386linux_size_dynamic_sections): Renamed from
3808 bfd_linux_size_dynmic_sections to avoid clash with m68klinux.c.
3809 * bfd-in.h (bfd_i386linux_size_dynamic_sections): Rename
3810 declaration from bfd_linux_size_dynamic_sections.
3811 (bfd_m68klinux_size_dynamic_sections): Declare.
3812 * bfd-in2.h: Rebuild.
3813 * Makefile.in: Rebuild dependencies.
3814 (BFD32_BACKENDS): Add m68klinux.o.
3815 (BFD32_BACKENDS_CFILES): Add m68klinux.c.
3816
6c7b3090
JL
3817Tue Feb 27 11:31:34 1996 Jeffrey A Law (law@cygnus.com)
3818
3819 * libhppa.h (pa_arch): Add pa20.
3820 (hppa_reloc_field_selector_type): Add R_HPPA_NSEL.
3821 (e_nsel): Undefine. Add to hppa_reloc_field_selector_type_alt.
3822 (hppa_field_adjust): Handle e_nsel.
3823 * som.c: Provide default definitions for many new relocs found only
3824 in hpux10 include files.
3825 (som_fixup_formats): Add several new relocs from hpux10.
3826 (som_hppa_howto_table): Add hpux10 relocs.
3827 (som_write_fixups): Handle R_N0SEL and R_N1SEL hpux10 relocs.
3828
14fd4616
SS
3829Mon Feb 26 12:52:48 1996 Stan Shebs <shebs@andros.cygnus.com>
3830
3831 * mpw-make.sed: Edit out recent shared library support, and
3832 rules to rebuild .h files using doc/chew.
3833
3d9f042c
ILT
3834Mon Feb 26 14:48:39 1996 David Mosberger-Tang <davidm@AZStarNet.com>
3835
3836 * ecoff.c (ecoff_compute_section_file_positions): Adjust the file
3837 size even of sections with no contents.
3838
bdec6228
ILT
3839Mon Feb 26 14:01:13 1996 Ian Lance Taylor <ian@cygnus.com>
3840
88358469
ILT
3841 * cofflink.c (_bfd_coff_link_input_bfd): When merging, skip names
3842 starting with '$' the way we skip names starting with '.'. When
3843 updating x_endndx, don't be fooled by an index which has been
3844 merged.
3845
bdec6228
ILT
3846 * cofflink.c (_bfd_coff_link_input_bfd): Don't try to optimize a
3847 struct/union/enum type with no elements.
3848
053ae1d7
ILT
3849Sat Feb 24 11:38:58 1996 Ian Lance Taylor <ian@cygnus.com>
3850
15f4406c
ILT
3851 * bfd.c (bfd_errmsg): Handle a NULL return from strerror.
3852
c8435133
ILT
3853 * archive.c (bfd_generic_archive_p): If the first file in the
3854 archive can not be recognized as an object, don't assume that this
3855 is the wrong format.
3856
053ae1d7
ILT
3857 * elf.c (bfd_elf_set_dt_needed_name): Don't do anything if the
3858 format is not bfd_object.
3859 (bfd_elf_get_dt_soname): Likewise.
3860
ea74d979
ILT
3861Wed Feb 21 13:58:04 1996 Ian Lance Taylor <ian@cygnus.com>
3862
3863 * coff-sh.c (sh_relax_delete_bytes): Correct range of R_SH_USES
3864 reloc.
3865
871a3f3b
C
3866Tue Feb 20 16:22:44 1996 J.T. Conklin <jtc@rtl.cygnus.com>
3867
3868 * bfd.c (tdata): Add netbsd_core_data.
3869 * bfd-in2.h: Regenerated.
3870
3871Tue Feb 20 16:50:02 1996 Ian Lance Taylor <ian@cygnus.com>
3872
fe6fc35f
ILT
3873 * sunos.c (SUNOS_CONSTRUCTOR): Define.
3874 (sunos_add_one_symbol): Don't let a symbol from a dynamic object
3875 override a constructor symbol. Set SUNOS_CONSTRUCTOR when
3876 appropriate.
3877
871a3f3b
C
3878 * bout.c (b_out_squirt_out_relocs): Use udata.i rather than flags
3879 to get the symbol index, matching 14 Jul 95 change.
3880
d3785301
FF
3881Tue Feb 20 08:26:27 1996 Fred Fish <fnf@phydeaux.cygnus.com>
3882
3883 * coff-alpha.c (alpha_ecoff_get_relocated_section_contents):
3884 Remove duplicate definition of gp.
3885
60a49e7f
ILT
3886Mon Feb 19 12:37:41 1996 Ian Lance Taylor <ian@cygnus.com>
3887
81bdcecf
ILT
3888 * coff-alpha.c (alpha_ecoff_get_relocated_section_contents): Don't
3889 assume that we can set the GP value and then get the same value,
3890 since it won't be true if the output file is neither ELF nor
3891 ECOFF.
3892 * coff-mips.c (mips_adjust_reloc_in): Don't bother to use
3893 _bfd_get_gp_value here.
3894 (mips_gprel_reloc): Don't assume we can set and get the GP value.
3895 * elf32-mips.c (mips_elf_hi16_reloc): Get gp value from
3896 mips_elf_final_gp.
3897 (mips_elf_lo16_reloc): Likewise.
3898 (mips_elf_final_gp): Add pgp parameter. Set it to the GP value.
3899 Don't require that the BFD be ELF.
3900 (mips_elf_gprel16_reloc): Get gp value from mips_elf_final_gp.
3901 (mips_elf_gprel32_reloc): Likewise.
3902 (mips_elf_relocate_section): Don't assume we can set and get the
3903 GP value.
3904 (mips_elf_finish_dynamic_symbol): Don't bother to use
3905 _bfd_get_gp_value here.
3906
3907 * elf32-mips.c (mips_elf_create_procedure_table): Initialize sv.
3908 Don't change epdr between malloc and free. Be careful not to free
3909 NULL pointers. Zero out the first RPDR.
3910
7b61165a
ILT
3911 * configure.host: On Linux, only pass -rpath option if $(libdir)
3912 is neither /lib nor /usr/lib. From Alan Modra
3913 <alan@mullet.Levels.UniSA.Edu.Au>.
3914
60a49e7f
ILT
3915 * elf-bfd.h (struct elf_obj_tdata): Rename dt_needed_name to
3916 dt_name.
3917 (elf_dt_name): Rename from elf_dt_needed_name.
3918 * elf.c (bfd_elf_set_dt_needed_name): Use elf_dt_name, not
3919 elf_dt_needed_name.
3920 (bfd_elf_get_dt_soname): New function.
3921 * elflink.h (elf_link_add_object_symbols): Use elf_dt_name, not
3922 elf_dt_needed_name. Save the SONAME back in elf_dt_name.
3923 * bfd-in.h (bfd_elf_get_dt_soname): Declare.
3924 * bfd-in2.h: Rebuild.
3925
b268e261
DE
3926Mon Feb 19 02:50:23 1996 Doug Evans <dje@charmed.cygnus.com>
3927
3928 * elf32-sparc.c (elf32_sparc_reloc_type_lookup): Renamed from
3929 _bfd_sparc_elf_reloc_type_lookup.
3930 (bfd_elf32_bfd_reloc_type_lookup): Update.
3931 * elf64-sparc.c (SPARC64_OLD_RELOCS): Define.
3932 (sparc64_elf_howto_table): Define.
3933 (sparc_reloc_map): Define.
3934 (sparc64_elf_reloc_type_lookup): New function.
3935 (sparc_elf_wdisp16_reloc): New function.
3936 (elf_info_to_howto): Use sparc64_elf_howto_table.
3937 (sparc64_elf_relocate_section): Likewise.
3938 (bfd_elf64_bfd_reloc_type_lookup): Update.
3939
9e2ef098
ILT
3940Sun Feb 18 15:02:25 1996 Ian Lance Taylor <ian@cygnus.com>
3941
3942 * configure.host: Check for 'do not mix' from native linker before
3943 trying to use -rpath.
3944
4c70373f
ILT
3945Fri Feb 16 12:46:18 1996 Ian Lance Taylor <ian@cygnus.com>
3946
cba3f8a9
ILT
3947 * bfd.c (_bfd_get_gp_value): New function.
3948 (_bfd_set_gp_value): New function.
3949 * libbfd-in.h (_bfd_get_gp_value): Declare.
3950 (_bfd_set_gp_value): Declare.
3951 * libbfd.h: Rebuild.
3952 * coff-alpha.c (alpha_ecoff_get_relocated_section_contents): Use
3953 _bfd_get_gp_value and _bfd_set_gp_value rather than referring
3954 directly to the fields in the tdata information.
3955 (alpha_relocate_section): Likewise.
3956 * coff-mips.c (mips_adjust_reloc_in): Likewise.
3957 (mips_gprel_reloc): Likewise.
3958 (mips_relocate_section): Likewise.
3959 * elf32-mips.c (mips_elf_hi16_reloc): Likewise.
3960 (mips_elf_lo16_reloc): Likewise.
3961 (mips_elf_final_gp): Likewise.
3962 (mips_elf_gprel16_reloc): Likewise.
3963 (mips_elf_gprel32_reloc): Likewise.
3964 (mips_elf_relocate_section): Likewise.
3965 (mips_elf_finish_dynamic_symbol): Likewise.
3966
4c70373f
ILT
3967 * bout.c (b_out_set_arch_mach): Recognize bfd_mach_i960_jx.
3968
a0a2dd54
ILT
3969Thu Feb 15 11:29:13 1996 Ian Lance Taylor <ian@cygnus.com>
3970
f54c7482 3971 * configure.in: Call AC_PROG_CC before configure.host.
65eed095
ILT
3972 * configure: Rebuild.
3973 * configure.host: Don't set information which autoconf should
3974 figure out, namely CC, CFLAGS, LDFLAGS, AR, and RANLIB.
65eed095 3975
14293419
ILT
3976 * configure.host: Remove go32 and win32 host information, since it
3977 should no longer be needed.
3978
edf3fe48
ILT
3979 * elf.c (map_sections_to_segments): If we have a .dynamic section,
3980 then start a new segment rather than put a writable section in a
3981 readonly segment.
3982
b5e4f369
ILT
3983 * configure.host: Set RPATH_ENVVAR.
3984
f2e33e27
ILT
3985 * Makefile.in: Rebuild dependencies.
3986
a0a2dd54
ILT
3987 * elflink.c (_bfd_elf_create_linker_section): Remove unused
3988 zero_section variable.
3989
52c6bc4d
ILT
3990Thu Feb 15 10:39:17 1996 H.J. Lu <hjl@zoom.com>
3991
3992 * Makefile.in ($(srcdir)/bfd-in2.h): Rename target from bfd-in2.h.
3993 ($(srcdir)/libbfd.h): Rename from libbfd.h.
3994 ($(srcdir)/libcoff.h): Rename from libcoff.h.
3995
c9e5279f
ILT
3996Wed Feb 14 16:29:07 1996 Martin Anantharaman <martin@mail.imech.uni-duisburg.de>
3997
cb50baea
ILT
3998 * ieee.c (ieee_write_expression): Only use an R variable for a
3999 local symbol. Don't output a zero offset. Handle a zero address.
4000 (SRC_MASK, PCREL_OFFSET): Define based on KEEPMINUSPCININST.
4001 (rel32_howto, rel16_howto, rel8_howto): Use SRC_MASK and
4002 PCREL_OFFSET.
4003 (parse_expression): Don't try to handle multiple occurrences of a
4004 P variable. Handle I variables differently from X variables. Fix
4005 the order of minus expressions.
4006 (ieee_slurp_external_symbols): Generate an I variable for an NN
4007 record. Fix handling of ATI and ATX records.
4008 (ieee_slurp_sections): Only set minimal section attributes.
4009 Adjust them later, based on the section contents.
4010 (ieee_object_p): Read in the file until just after the ME record.
4011 Call ieee_slurp_section_data to set the section flags.
4012 (do_one): Add iterations parameter. Only repeat the first load
4013 item. Set the section and file reloc flags.
4014 (ieee_slurp_section_data): Set section flags. Pass iterations to
4015 do_one.
4016 (ieee_canonicalize_reloc): Handle I variables.
4017 (do_with_relocs): Only emit relocation size when necessary.
4018 Increase MAXRUN to 127. Change ov to be assigned, and take
4019 src_mask and pcrel_offset into account.
4020 (ieee_write_data_part): Skip sections that are not loaded.
4021 (ieee_write_external_part): Don't output optional last entry of WX
4022 records.
4023 (ieee_write_me_part): Make setting of me_record neater.
4024 (ieee_generic_stat_arch_elt): Get the size of an archive element.
4025
c9e5279f
ILT
4026 * syms.c (stt): Add entries for zerovars, vars, and code.
4027
4028 * elfcode.h (validate_reloc): New static function.
4029 (write_relocs): Call validate_reloc for non ELF relocs.
4030
4031 * elfxx-target.h (elf_symbol_leading_char): Define if not defined.
4032 (TARGET_BIG_SYM): Use elf_symbol_leading_char.
4033 (TARGET_LITTLE_SYM): Likewise.
4034
4035 * config.bfd (m68*-*-psos*): New target.
4036
d9d65be6
ILT
4037Tue Feb 13 15:56:22 1996 Bryan Ford <baford@snake.cs.utah.edu>
4038
4039 * i386msdos.c: Remove some #if 0 code.
4040 (msdos_write_object_contents): Don't include empty sections in the
4041 size computation, regardless of their address.
4042
4043Tue Feb 13 15:36:37 1996 Michael Meissner <meissner@tiktok.cygnus.com>
4044
4045 * elf32-ppc.c (ppc_elf_relocate_section): Don't segfault if dynboj
4046 is NULL, ie, the -r switch is used.
4047
db5970c7
ILT
4048Tue Feb 13 14:35:15 1996 Ian Lance Taylor <ian@cygnus.com>
4049
e9f03cd4
ILT
4050 * reloc.c (BFD_RELOC_MIPS_GOT_HI16): Define.
4051 (BFD_RELOC_MIPS_GOT_LO16): Define.
b7384d22 4052 (BFD_RELOC_MIPS_CALL_HI16, BFD_RELOC_MIPS_CALL_LO16): Define.
e9f03cd4
ILT
4053 * bfd-in2.h, libbfd.h: Rebuild.
4054 * elf32-mips.c (mips_reloc_map): Map new relocs.
4055
fe7c066a
ILT
4056 * configure.host: Set HDLFLAGS for *-*-hpux with --enable-shared.
4057
1ab628e4
ILT
4058 * Makefile.in ($(SHLINK)): Check ts against $(SHLIB), not
4059 $(SHLINK).
4060
db5970c7
ILT
4061 * ieee.c (get_symbol): Set the section to bfd_abs_section.
4062 (do_with_relocs): If EXEC_P is set and there are no relocs, use a
4063 simple number for the section address, rather than an expression.
4064 Limit the number of bytes between relocs to MAXRUN.
4065 (ieee_write_me_part): Set me_record to the file offset after the
4066 start address.
4067 (ieee_write_processor): New static function.
4068 (ieee_write_object_contents): Use ieee_write_processor.
4069
318b7c18
ILT
4070Fri Feb 9 10:53:00 1996 Ian Lance Taylor <ian@cygnus.com>
4071
db5970c7
ILT
4072 * configure.host: Use ${CC-gcc} when testing for -rpath on SunOS.
4073
4074 * coff-aux.c: Change include of aux.h to aux-coff.h.
318b7c18 4075
56b64690
ILT
4076Thu Feb 8 14:01:03 1996 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
4077
4078 * elf32-m68k.c (elf_m68k_relocate_section): For a R_68K_RELATIVE
4079 relocation put the addend both in the reloc entry and the data.
4080 (elf_m68k_finish_dynamic_symbol): Likewise. Mask out marker in
4081 GOT offset value.
4082
4083 * elf32-m68k.c (elf_m68k_relocate_section): If -Bsymbolic, resolve
4084 a R_68K_PCxx reloc against a defined global symbol directly.
4085 (elf_m68k_check_relocs): Don't count such a reloc.
4086
4087 * elf32-m68k.c (elf_m68k_check_relocs): Don't record a symbol with
4088 a PLTxx reloc as dynamic. Disallow PLTxxO reloc against a local
4089 symbol for now, otherwise always record the symbol as dynamic.
4090 (elf_m68k_adjust_dynamic_symbol): If a symbol with a PLTxx reloc
4091 is not referenced by a dynamic object, and we are not making a
4092 shared object, then don't make a PLT entry. If we do make a PLT
4093 entry, make sure the symbol has been recorded as dynamic.
4094
5d649ca8
ILT
4095Wed Feb 7 13:56:06 1996 Ian Lance Taylor <ian@cygnus.com>
4096
4097 * configure.host: When making a shared library, set HLDFLAGS to
4098 pass an appropriate -rpath option. Use the make variable SONAME
4099 as the shared library soname, rather than computing it here. On
4100 SunOS, build stamp-tshlink in place of $(SHLINK).
4101 * Makefile.in (SONAME): New variable.
4102 ($(SHLINK)): Make a link to the transformed name, as well.
4103 (stamp-tshlink): New target.
4104 (install): Skip stamp-tshlink during install.
4105
8cc98cd5
MM
4106Wed Feb 7 13:37:39 1996 Michael Meissner <meissner@tiktok.cygnus.com>
4107
56b64690
ILT
4108 * elf32-ppc.c (ppc_elf_add_symbol_hook): Do not assume that the
4109 linker sections have been set up yet.
4110
8cc98cd5
MM
4111 * elf.c (make_mapping): Add an additional argument to suppress
4112 making the first section include the program headers.
4113 (map_sections_to_segments): If the user used -Ttext such that the
4114 program headers are on a different page, do not set the flags
4115 saying that this section includes the program headers.
4116
fe16107d
C
4117Tue Feb 6 14:04:49 1996 J.T. Conklin <jtc@rtl.cygnus.com>
4118
4119 * configure.in (*-*-netbsd*): Set COREFILE to netbsd-core.c.
4120 don't define TRAD_HEADER.
4121 * configure: Rebuild.
4122
4123 * netbsd-core.c: New file, support for NetBSD core files.
4124 * hosts/*nbsd.h: Removed.
4125
f1783016
DE
4126Tue Feb 6 11:47:49 1996 Doug Evans <dje@charmed.cygnus.com>
4127
4128 * reloc.c (BFD_RELOC_SPARC_[567]): New reloc types.
4129 (BFD_RELOC_SPARC_LO7 reloc type): Deleted.
4130 * libbfd.h, bfd-in2.h: Regenerated.
4131 * elf32-sparc.c (_bfd_sparc_elf_reloc_type_lookup): Renamed from
4132 bfd_elf32_bfd_reloc_type_lookup.
4133 (reloc_type{,_names}): Deleted.
4134 (_bfd_sparc_elf_howto_table): Renamed from elf_sparc_howto_table.
4135 Add sparc64 relocs.
4136 (sparc_reloc_map): Add sparc64 relocs.
4137 (sparc_elf_notsupported_reloc): New static function.
4138 (sparc_elf_wdisp16_reloc): New static function.
4139 (elf32_sparc_check_relocs): Handle R_SPARC_WDISP{16,19}.
4140 (elf32_sparc_relocate_section): Likewise.
4141 (bfd_elf32_bfd_reloc_type_lookup): Define.
4142 * elf64-sparc.c (sparc64_elf_wdisp16_reloc): Deleted.
4143 (reloc_type{,_names}): Deleted.
4144 (elf_sparc_howto_table): Deleted.
4145 (sparc_reloc_map): Deleted.
4146 (_bfd_sparc_elf_howto_table): Renamed from elf_sparc_howto_table.
4147 (bfd_elf64_bfd_reloc_type_lookup): Change from function to #define.
4148
48fd00b6
ILT
4149Tue Feb 6 12:12:22 1996 Ian Lance Taylor <ian@cygnus.com>
4150
2300e217
ILT
4151 * configure.host: Make SHLIB_CFLAGS include $(PICFLAG) on a
4152 *-*-hpux* host.
4153
48fd00b6
ILT
4154 * Makefile.in (program_transform_name): New variable.
4155 (install): Transform library name before installing it.
4156
8adca582
ILT
4157Mon Feb 5 10:38:27 1996 Ian Lance Taylor <ian@cygnus.com>
4158
cbe75cb6
ILT
4159 * archures.c (bfd_mach_i960_hx): Define.
4160 * bfd-in2.h: Rebuild.
4161 * cpu-i960.c (scan_960_mach): Accept machine "hx".
4162 (MATRIX): Expand entries for HX.
4163 (arch_info_struct): Add i960:hx entry.
4164 * bout.c (b_out_set_arch_mach): Handle bfd_mach_i960_hx.
4165 * coffcode.h (coff_set_arch_mach_hook): Handle F_I960HX.
4166 (coff_set_flags): Handle bfd_mach_i960_hx.
4167
44f795f7
ILT
4168 Support for building as a shared library, based on patches from
4169 Alan Modra <alan@spri.levels.unisa.edu.au>:
4170 * configure.in: Add AC_ARG_ENABLE for shared and commonbfdlib.
4171 New substitutions: ALLLIBS, PICFLAG, SHLIB, SHLIB_CC,
4172 SHLIB_CFLAGS, COMMON_SHLIB, PICLIST, SHLINK.
4173 * configure: Rebuild.
4174 * configure.host: If --enable-shared, adjust shared library stuff
4175 based on the host. If the host is SunOS, and the linker supports
4176 -rpath, set HLDFLAGS to use it.
4177 * Makefile.in (ALLLIBS): New variable.
4178 (PICFLAG, SHLIB, SHLIB_CC, SHLIB_CFLAGS): New variables.
4179 (COMMON_SHLIB, SHLINK): New variables.
4180 (.c.o): If PICFLAG is set, compile twice, once PIC, once normal.
4181 (STAGESTUFF): Remove variable.
4182 (all): Depend upon $(ALLLIBS) and @PICLIST@ rather than
4183 $(TARGETLIB).
4184 (stamp-ofiles): New target, like old ofiles target, but build
4185 using a temporary file and move-if-change, and touch stamp-ofiles
4186 when done.
4187 (ofiles): Just depend upon stamp-ofiles.
4188 (stamp-piclist, piclist): New targets.
4189 ($(SHLIB), $(SHLINK)): New targets.
4190 (targets.o, archures.o): Build twice if PICFLAG is set.
4191 (do_mostlyclean): Remove pic/*.o.
4192 (do_clean): Remove stamp-ofiles, $(SHLIB), $(SHLINK), piclist, and
4193 stamp-piclist.
4194 (do_distclean): Remove pic and stamp-picdir.
4195 (install): Install shared libraries.
4196 ($(OFILES)): Depend upon stamp-picdir.
4197 (stamp-picdir): New target.
4198
cb62d2bc
ILT
4199 * libcoff-in.h: Add comment reminding people that libcoff.h is a
4200 generated file.
4201 * libcoff.h: Rebuild.
4202
8adca582
ILT
4203 * elflink.h (elf_adjust_dynamic_symbol): Don't try to get the
4204 flavour of a section with no owner.
4205
4206 * elf32-mips.c (mips_elf_create_dynamic_sections): Clear
4207 ELF_LINK_NON_ELF flag.
4208 (mips_elf_create_got_section): Likewise.
4209
4210 * elf.c: Revert last change, since it breaks dynamic linking.
4211 * elf-bfd.h (struct elf_backend_data): Remove want_hdr_in_seg
4212 field.
4213 * elf32-mips.c (elf_backend_want_hdr_in_seg): Don't define.
4214 * elfxx-target.h (elf_backend_want_hdr_in_seg): Don't define.
4215 (elfNN_bed): Don't initialize want_hdr_in_seg field.
4216
4217Sun Feb 4 20:45:13 1996 Michael Meissner <meissner@tiktok.cygnus.com>
4218
4219 * elf.c (assign_file_positions_for_segments): If the backend does
4220 not want the elf header or the program headers in the address
4221 space, do not include them in the calculations.
4222
4223 * elf32-ppc.c (ppc_elf_additional_program_headers): New hook
4224 function to determine if we need additional program headers.
4225 (ppc_elf_modify_segment_map): Define as a NOP function for now.
4226 (ppc_elf_create_linker_section): .sdata2 is a read-only section.
4227
0f09ddd4
ILT
4228Sat Feb 3 23:00:03 1996 Ian Lance Taylor <ian@cygnus.com>
4229
4230 * coffcode.h: Move today's libcoff.h change into coffcode.h.
4231
b48f10ba
FF
4232Sat Feb 3 15:43:44 1996 Fred Fish <fnf@cygnus.com>
4233
0f09ddd4
ILT
4234 * libcoff.h (bfd_coff_link_add_one_symbol): Combine macro args
4235 back into one line. Some compilers (sunos 4.1.3 for example)
4236 won't accept args split across more than one line.
b48f10ba 4237
50761d3b
SC
4238Fri Feb 2 11:42:15 1996 Steve Chamberlain <sac@slash.cygnus.com>
4239
4240 * aclocal.m4 (BFD_BINARY_FOPEN): Understand cygwin32.
4241 * configure: Regenerate.
4242
9dce8260
JL
4243Fri Feb 2 12:12:16 1996 Jeffrey A Law (law@cygnus.com)
4244
4245 * elf32-hppa.c (elf32_hppa_backend_symbol_table_processing): Don't
4246 try to do arithmetic on a void *, cast it to a unsigned char * first.
4247
6c55897c
ILT
4248Thu Feb 1 16:04:06 1996 Ian Lance Taylor <ian@cygnus.com>
4249
869b7d80
ILT
4250 * elf-bfd.h (ELF_LINK_NON_ELF): Define.
4251 * elf.c (_bfd_elf_link_hash_newfunc): Set elf_link_hash_flags to
4252 ELF_LINK_NON_ELF.
4253 * elflink.h (elf_link_add_object_symbols): Reset ELF_LINK_NON_ELF
4254 flag for a newly defined symbol.
4255 (NAME(bfd_elf,record_link_assignment)): Likewise.
4256 (elf_adjust_dynamic_symbol): If ELF_LINK_NON_ELF is set, try to
4257 set the DEF or REF_REGULAR flags correctly.
4258
6f6956c6
ILT
4259 * Makefile.in (bfd-in2.h): Make bfd.h, not protos, in docdir.
4260 (libbfd.h, libcoff.h): Corresponding change.
4261
6c55897c
ILT
4262 * elf32-i386.c (elf_i386_check_relocs): Don't record a symbol with
4263 a PLT32 reloc as dynamic.
4264 (elf_i386_adjust_dynamic_symbol): If a symbol with a PLT32 reloc
4265 is not referenced by a dynamic object, and we are not making a
4266 shared object, then don't make a PLT entry. If we do make a PLT
4267 entry, make sure the symbol has been recorded as dynamic.
4268
b06136f2
SC
4269Wed Jan 31 17:23:32 1996 Steve Chamberlain <sac@slash.cygnus.com>
4270
4271 * coff-i386.c (coff_i386_reloc_type_lookup): Add BFD_RELOC_32_PCREL.
4272 * config.bfd (i[345]86-*-win32): Becomes i[345]86-*-cygwin32.
4273 (powerpcle-*-cygwin32): New.
4274 * peicode.h (add_data_entry): Get address from vma.
4275
5c867ecd
MM
4276Wed Jan 31 16:23:57 1996 Michael Meissner <meissner@tiktok.cygnus.com>
4277
4278 * elflink.c (_bfd_elf_create_linker_section): If the symbol
4279 attached to the section has already been created as an undefined
4280 symbol, treat it as if it hasn't been created yet.
4281
28c16b55
ILT
4282Wed Jan 31 16:16:53 1996 Ian Lance Taylor <ian@cygnus.com>
4283
4284 * elflink.h (elf_bfd_final_link): Don't output initial dummy
4285 symbol or section symbols if stripping all symbols and this is not
4286 a relocateable link. Don't output the symbol string table if
4287 there are no symbols.
4288 (elf_link_flush_output_syms): Don't do anything if there are no
4289 symbols to flush.
4290
d19df9b5
ILT
4291Wed Jan 31 12:55:49 1996 Richard Henderson <rth@tamu.edu>
4292
4293 * coff-aux.c: New file.
4294 * hosts/m68kaux.h: New file.
4295 * config.bfd (m68*-apple-aux*): New target.
4296 * configure.in (m68*-apple-aux*): New native host.
4297 (m68kaux_coff_vec): New vector.
4298 * configure: Rebuild.
4299 * targets.c (m68kaux_coff_vec): Declare.
4300 * coffcode.h (bfd_coff_backend_data): Add field
4301 _bfd_coff_link_add_one_symbol.
4302 (bfd_coff_link_add_one_symbol): Define.
4303 (compare_arelent_ptr): New static function if TARG_AUX.
4304 (coff_write_relocs): If TARG_AUX, sort the relocs.
4305 (coff_write_object_contents): Set A/UX aouthdr magic number.
4306 (coff_link_add_one_symbol): Define if not defined.
4307 (bfd_coff_std_swap_table): Initialize new field.
4308 * libcoff.h: Rebuild.
4309 * cofflink.c (coff_link_add_symbols): Call
4310 bfd_coff_link_add_one_symbol rather than
4311 _bfd_generic_link_add_one_symbol.
4312 * coff-m68k.c (COFF_PAGE_SIZE): Don't define if already defined.
4313 * coff-alpha.c (alpha_ecoff_backend_data): Initialize new field.
4314 * coff-mips.c (mips_ecoff_backend_data): Likewise.
4315 * Makefile.in: Rebuild dependencies.
4316 (BFD32_BACKENDS): Add coff-aux.o.
4317 (BFD32_BACKENDS_CFILES): Add coff-aux.c.
4318
a796aafd
ILT
4319Wed Jan 31 11:37:46 1996 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
4320
4321 * elf32-m68k.c (elf_m68k_relocate_section): Fix R_68K_GOT*
4322 relocation; ignore addend with R_68K_{GOT,PLT}*O relocation.
4323
a8763553
ILT
4324Tue Jan 30 12:09:04 1996 Ian Lance Taylor <ian@cygnus.com>
4325
66761e59
ILT
4326 * Makefile.in (do_maintainer_clean): Remove $(srcdir)/bfd-in2.h,
4327 $(srcdir)/libbfd.h and $(srcdir)/libcoff.h.
4328 (maintainer-clean): Warn about deleting special files.
4329 (bfd-in2.h, libbfd.h, libcoff.h): New targets.
4330
cf5138e3
ILT
4331 * elf32-hppa.c (elf32_hppa_relocate_section): Handle indirect and
4332 warning symbols correctly.
4333 * elf32-i386.c (elf_i386_relocate_section): Likewise.
4334 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
4335 * elf32-mips.c (mips_elf_relocate_section): Likewise.
4336 * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
4337 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
4338 * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
4339
a8763553
ILT
4340 * syms.c (_bfd_stab_section_find_nearest_line): Add casts to avoid
4341 warnings.
4342
bdd2e7f1
KK
4343Mon Jan 29 14:27:24 1996 Kim Knuttila <krk@cygnus.com>
4344
4345 * libcoff-in.h: aligned newly exported names with bfd naming
4346 conventions. Removed an erroneous define of POWERPC_LE_PE.
4347 * libcoff.h: Rebuild.
4348 * cofflink.c, coff-ppc.c: the above function name changes
4349
d2bb6c79
ILT
4350Mon Jan 29 13:06:28 1996 Ian Lance Taylor <ian@cygnus.com>
4351
eb5bc1f3
ILT
4352 From Basim Kadhim <kadhim@spock.cs.colorado.edu>:
4353 * ecoff.c (struct extsym_info): Define.
4354 (_bfd_ecoff_bfd_final_link): Pass a pointer to struct extsym_info
4355 to ecoff_link_write_external.
4356 (ecoff_link_write_external): Accept a struct extsym_info pointer.
4357 Strip symbols when appropriate.
4358
052b35d2
ILT
4359 Based on patches from Ronald F. Guilmette <rfg@monkeys.com>:
4360 * syms.c (BSF_OBJECT): Define.
4361 (bfd_print_symbol_vandf): Print 'O' for BSF_OBJECT.
4362 * bfd-in2.h: Rebuild.
4363 * elfcode.h (elf_slurp_symbol_table): Set BSF_OBJECT for an
4364 STT_OBJECT symbol.
4365 * elf.c (swap_out_syms): Only set type to STT_OBJECT if BSF_OBJECT
4366 is set.
4367
53787b23
ILT
4368 * elf32-i386.c (elf_i386_relocate_section): If -Bsymbolic, when
4369 copying relocs into a shared object, treat a defined global symbol
4370 as a local symbol.
4371 * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
4372 * elf32-mips.c (mips_elf_relocate_section): Likewise.
4373 * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
4374
d2bb6c79
ILT
4375 * elflink.h (elf_link_add_object_symbols): Only set weakdef to a
4376 real defined symbol, not to a weak defined symbol.
4377
13d1a4dd
KK
4378Mon Jan 29 11:34:36 1996 Kim Knuttila <krk@cygnus.com>
4379
4380 * cofflink.c: removed the POWERPC_LE_PE hack, promoted some types
4381 and made a few static functions externs.
4382
4383 * coff-ppc.c (ppc_bfd_coff_final_link): new function, replaces the
4384 POWERPC_LE_PE hack in cofflink.
4385
4386 * libcoff-in.h: promoted the following from cofflink.c to allow
4387 _bfd_coff_final_link to be overridden - STRING_SIZE_SIZE,
4388 coff_debug_merge_element, struct coff_debug_merge_type,
4389 coff_debug_merge_hash_entry, coff_debug_merge_hash_table,
4390 coff_debug_merge_hash_table_init, coff_debug_merge_hash_table_free,
4391 coff_debug_merge_hash_lookup, coff_link_section_info,
4392 coff_final_link_info, coff_debug_merge_hash_newfunc,
4393 coff_write_global_sym, coff_link_input_bfd, coff_reloc_link_order.
4394
4395 * libcoff.h: re-gen'd
4396
86aac8ea
ILT
4397Fri Jan 26 18:33:35 1996 Ian Lance Taylor <ian@cygnus.com>
4398
4399 * syms.c: Include "bfdlink.h".
4400 (struct stab_find_info): Define.
4401 (_bfd_stab_section_find_nearest_line): New function.
4402 * libbfd-in.h (_bfd_stab_section_find_nearest_line): Declare.
4403 * libbfd.h: Rebuild.
4404 * elf-bfd.h (struct elf_obj_tdata): Add line_info field.
4405 * elf.c (_bfd_elf_find_nearest_line): Try calling
4406 _bfd_stab_section_find_nearest_line before searching the ELF
4407 symbol table. Find the closest STT_FUNC symbol, not the last one.
4408 * libcoff-in.h (coff_data_type): Add line_info field.
bdd2e7f1 4409 * libcoff.h: Rebuild.
86aac8ea
ILT
4410 * coffgen.c (coff_find_nearest_line): Try calling
4411 _bfd_stab_section_find_nearest_line before searching the COFF
4412 symbol table.
4413 * Makefile.in: Rebuild dependencies.
4414
4415Fri Jan 26 16:11:19 1996 Michael Meissner <meissner@tiktok.cygnus.com>
4416
4417 * elf32-ppc.c (R_PPC_EMB_SDA21 relocations): Make relocation size
4418 4 bytes, so we get the correct value when updating the register
4419 field in little endian mode.
4420
43d36aad
ILT
4421Thu Jan 25 12:14:16 1996 Ian Lance Taylor <ian@cygnus.com>
4422
f0a97077
ILT
4423 * libcoff-in.h (struct xcoff_tdata): Remove toc_section and
4424 entry_section fields. Add sntoc and snentry fields.
4425 * libcoff.h: Rebuild.
4426 * coffcode.h (coff_mkobject_hook): Initialize sntoc and snentry,
4427 not toc_section and entry_section (the COFF file does not have any
4428 sections at this point).
4429 (coff_write_object_contents): Set o_snentry and o_sntoc from
4430 snentry and sntoc rather than entry_section and toc_section.
4431 * coff-rs6000.c (xcoff_copy_private_bfd_data): Copy sntoc and
4432 snentry, not toc_section and entry_section.
4433 * xcofflink.c (bfd_xcoff_size_dynamic_sections): Don't set
4434 entry_section from hentry.
4435 (xcoff_link_input_bfd): If a defined symbol has XCOFF_ENTRY set,
ea2504d5 4436 set snenty.
f0a97077
ILT
4437 (xcoff_link_input_bfd): Set sntoc, not toc_section.
4438 (xcoff_write_global_symbol): Get toc_section from sntoc, rather
4439 than using toc_section directly.
4440
9b4598d0
ILT
4441 * archures.c: Add missing `.' in enum bfd_architecture.
4442 * bfd-in2.h: Rebuild.
4443
43d36aad
ILT
4444 * config.bfd (i[345]86-*-sco*elf*): Use bfd_elf32_i386_vec. From
4445 Robert Lipe <robertl@arnet.com>.
4446
eb82bc60
MM
4447Thu Jan 25 12:08:51 1996 Michael Meissner <meissner@tiktok.cygnus.com>
4448
4449 * elf32-ppc.c (ppc_elf_size_dynamic_sections): Add .rela.sdata{,2}
4450 to sections we allocate. Use bfd_zalloc to allocate initialial
4451 sections, not bfd_alloc.
4452 (ppc_elf_check_relocs): Remove BFD_ASSERTs for !shared from
4453 SDA{,2}I16 relocations.
4454 (ppc_elf_add_symbol_hook): Use the value of -G nn to determine
4455 whether to put something in .sbss or not.
4456 (ppc_elf_relocate_section): Add support for more relocations. Add
c1e65e24
MM
4457 in sec->output_offset where appropriate. Make error messages
4458 include the symbol name.
eb82bc60
MM
4459
4460 * elflink.c (_bfd_elf_create_linker_section): Lookup symbol before
4461 trying to add it to the symbol table, so _GLOBAL_OFFSET_TABLE_
4462 doesn't get redefined messages if -shared.
4463
4464 * elflink.h (elf_create_pointer_linker_section) Only bump RELA
4465 section if the rel_section field has been set up.
4466
9d621c7d
MM
4467Wed Jan 24 20:40:26 1996 Michael Meissner <meissner@tiktok.cygnus.com>
4468
4469 * elf32-ppc.c (ppc_elf_relocate_section): Fix typo in eabi
4470 relocations.
4471
75c9ddc9
DE
4472Wed Jan 24 10:38:34 1996 Doug Evans <dje@charmed.cygnus.com>
4473
4474 * elf32-sparc.c (elf32_sparc_merge_private_bfd_data): Delete checking
4475 of flags, only flags used are controlled by mach number. Bump up
4476 output file mach number to highest of input file mach numbers.
4477 (elf32_sparc_object_p): Watch for EF_SPARC_SUN_US1.
4478 (elf32_sparc_final_write_processing): Set EF_SPARC_SUN_US1 if v8plusa.
4479
72c513bc
DE
4480 * config.bfd (sparc64-*-{sysv4*,solaris2*}): Comment out
4481 bfd_elf64_sparc_vec support.
4482
3cbe19d2
MM
4483Tue Jan 23 14:33:05 1996 Michael Meissner <meissner@tiktok.cygnus.com>
4484
4485 * elf32-ppc.c (ppc_elf_copy_private_bfd_data): Don't complain if
4486 the embedded bit is set on some objects and not on others. Just
4487 or it together.
d8fd85ad
MM
4488 (ppc_elf_relocate_section): Implement R_PPC_EMB_{SDA21,RELSDA}
4489 relocations.
3cbe19d2 4490
5eb83ede
ILT
4491Tue Jan 23 14:22:45 1996 Ian Lance Taylor <ian@cygnus.com>
4492
4a3d3b42
ILT
4493 * coffcode.h (coff_new_section_hook): Don't try to align the
4494 .stabstr section.
4495
5eb83ede
ILT
4496 * coffcode.h (coff_set_section_contents): Fix the handling of the
4497 .lib section to work even if the entire section contents are
4498 written at once. From Gvran Uddeborg <gvran@uddeborg.pp.se> and
4499 Robert Lipe <robertl@arnet.com>.
4500
05f927dd
MM
4501Mon Jan 22 18:45:51 1996 Michael Meissner <meissner@tiktok.cygnus.com>
4502
4503 * elflink.h (elf_finish_pointer_linker_section): Don't allocate
4504 memory here for contents.
4505
4506 * elf32-ppc.c (ppc_elf_relocate_section): Bump up _SDA_BASE_ and
4507 _SDA2_BASE_ by 32768.
4508 (ppc_elf_size_dynamic_sections): #if out PLT code which we haven't
4509 started using. Allocate contents for .sdata and .sdata2 sections
4510 also.
4511 (ppc_elf_check_relocs): Use bfd_get_section_name in debug message,
4512 rather than _name.
4513 (ppc_elf_finish_dynamic_symbol): Remove code that attempted to
4514 size _SDA{,2}_BASE_.
4515 (ppc_elf_relocate_section): Change how sdata{,2} relocations are
4516 done.
4517
5bc513b4
DE
4518Mon Jan 22 08:52:04 1996 Doug Evans <dje@charmed.cygnus.com>
4519
5a5bac64
DE
4520 * elflink.h (elf_finish_pointer_linker_section): Fix typo.
4521
5bc513b4 4522 * archures.c (bfd_mach_sparc_v9): Renamed from bfd_mach_sparc64.
5bc513b4 4523 (bfd_mach_sparc_{v8plus,v8plusa}): Define.
5bc513b4 4524 (bfd_mach_sparc_v9a): Define.
049f3d4c 4525 (bfd_mach_sparc_v9_p): Define.
5bc513b4
DE
4526 * bfd-in2.h: Regenerated.
4527 * aoutx.h (aout,machine_type): bfd_mach_sparc64 renamed to
4528 bfd_mach_sparc_v9.
d3366d23 4529 * elf64-sparc.c (sparc64_elf_object_p): Likewise.
5bc513b4
DE
4530 * config.bfd (sparc64-*-sysv4*,sparc64-*-solaris2*): Set targ_defvec
4531 to bfd_elf32_sparc_vec.
4532 * cpu-sparc.c (arch_info_struct): Renamed from sparc_arch_info.
5bc513b4 4533 Add v8plus{,a} support.
5bc513b4 4534 Add v9a support.
768b8ade 4535 (sparc_compatible): New function.
5bc513b4 4536 * elf32-sparc.h: #include "elf/sparc.h".
75c9ddc9 4537 (elf32_sparc_merge_private_bfd_data, elf32_sparc_object_p,
5bc513b4 4538 elf32_sparc_final_write_processing): New functions.
75c9ddc9 4539 (bfd_elf32_bfd_merge_private_bfd_data, elf_backend_object_p,
5bc513b4 4540 elf_backend_final_write_processing): Define.
5bc513b4 4541
3b3753b8
MM
4542Mon Jan 22 11:21:51 1996 Michael Meissner <meissner@tiktok.cygnus.com>
4543
4544 * elf-bfd.h (struct elf_link_hash_entry): Add
4545 linker_section_pointer field.
4546 (enum elf_linker_section_enum): Enumeration for new way of
4547 creating linker dynamic sections and symbols.
4548 (elf_linker_section{,_pointers}): New structures for creating
4549 dynamic sections and symbols.
4550 (elf_obj_tdata): Add linker_section_pointers and linker_section
4551 fields.
4552 (elf_local_ptr_offsets,elf_linker_section): New accessor macros.
4553 (_bfd_elf_create_linker_section): New declarations.
4554 (_bfd_elf_find_pointer_linker_section): Ditto.
4555 (bfd_elf{32,64}_{create,finish}_pointer_linker_section): Ditto.
4556 (_bfd_elf_make_linker_section_rela): Ditto.
4557
4558 * elf.c (_bfd_elf_link_hash_newfunc): Initialize new fields.
4559
4560 * elf32-ppc.c (ppc_elf_create_dynamic_sections): Delete.
4561 (ppc_elf_create_linker_section): New function to create the
4562 sections .got, .sdata, and .sdata2.
4563 (ppc_elf_size_dynamic_sections): Zap .rela.{sdata,sdata2} if
4564 needed.
4565 (ppc_elf_check_relocs): Support more of the eabi relocations.
4566 (ppc_elf_relocate_section): Ditto.
4567 (ppc_elf_finish_dynamic_symbols): Adjust _SDA{,2}_BASE_ by 32768
4568 if the .sdata{,2} + .sbss{,2} section size is > 32k.
4569
4570 * elflink.h (elf_create_pointer_linker_section): New function to
4571 create initialized pointers in dynamic linker sections.
4572 (elf_finish_pointer_linker_section): Actually intialize the
4573 pointers created above.
4574
4575 * elfcode.h (bfd_elf{32,64}_create_pointer_linker_section): New
4576 macros to provide both 32 and 64 bit versions of
4577 elf_create_pointer_linker_section.
4578 (bfd_elf{32,64}_finish_pointer_linker_section): New macros to
4579 provide both 32 and 64 bit versions of
4580 elf_finish_pointer_linker_section.
4581
4582 * elflink.c (_bfd_elf_create_linker_section): New function to
4583 create a linker section.
4584 (_bfd_elf_find_pointer_linker_section): Find a unique pointer to a
4585 given address in the linker pointer offsets created for a given
4586 symbol.
4587 (_bfd_elf_make_linker_section_rela): Make a RELA section
4588 corresponding to the generated linker section.
4589
6b3eb07e
DE
4590Sat Jan 20 08:36:10 1996 Doug Evans <dje@canuck.cygnus.com>
4591
4592 * elf32-sparc.c (ELF_MACHINE_ALT1): Define.
4593
e7894f6b
KK
4594Thu Jan 18 18:25:34 1996 Kim Knuttila <krk@cygnus.com>
4595
4596 * coff-ppc.c (coff_ppc_relocate_section): changed TOCDEFN relocs.
4597 (coff_ppc_relocate_section): Handle special values for gcc built dlls.
4598 (dump_toc): fix diagnosing code to identify out-of-toc-bounds entries.
4599 Also begin the toc at 4 as an eye catcher ('31313131' marks the first
4600 toc entry in an objdump) for now.
4601 (ppc_do_last, ppc_get_last): New function - needed to save processing
4602 the toc owner to the end.
4603 (ppc_coff_swap_sym_in_hook): Removed an incorrect hack for doing the
4604 toc owner last.
4605
4606 * cofflink.c (_bfd_coff_final_link): Added a new hack to keep the
4607 toc owner from being done till last. Must define POWERPC_LE_PC
4608 to enable it.
4609
4610 * coffcode.h (coff_set_alignment_hook): alignment setting for .stab
4611
4612 * peicode.h (coff_swap_scnhdr_out): set section flags for stab/str
4613 to INFO.
4614 (coff_swap_aouthdr_out): Removed a non-working hack for computing the
4615 SizeOfImage for PowerPC. Ignore the size of the .junk section.
4616
80b99ca0
ILT
4617Thu Jan 18 17:42:12 1996 Ian Lance Taylor <ian@cygnus.com>
4618
4619 * elfcore.h: Include <signal.h> before <sys/procfs.h>.
4620
df96df4c
ILT
4621Wed Jan 17 12:40:14 1996 Ian Lance Taylor <ian@cygnus.com>
4622
4623 * cpu-powerpc.c (arch_info_struct): Change last entry to not point
4624 back to first.
4625 (bfd_powerpc_arch): Point at first entry in arch_info_struct.
4626
d49ddb85
ILT
4627Tue Jan 16 15:10:49 1996 Ian Lance Taylor <ian@cygnus.com>
4628
4629 * elf.c (assign_file_positions_for_segments): Don't increment file
4630 offset for a segment which contains no loadable sections.
4631
4500a112
MM
4632Mon Jan 15 17:46:27 1996 Michael Meissner <meissner@tiktok.cygnus.com>
4633
4634 * reloc.c: Add new PowerPC relocations.
4635 * {bfd-in2,libbfd}.h: Regenerate.
4636
4637 * elf32-ppc.c (ppc_elf_howto_raw): Add more PPC relocations.
4638 (ppc_elf_reloc_type_lookup): Lookup new relocations.
4639
252239f8
ILT
4640Mon Jan 15 14:29:44 1996 Ian Lance Taylor <ian@cygnus.com>
4641
20ab764e
ILT
4642 * aoutx.h (howto_table_ext): Fix RELOC_BASE10 and RELOC_BASE22
4643 entries.
4644
0a4ffa2d
ILT
4645 * sunos.c (sunos_scan_ext_relocs): Don't fail assert if
4646 info->shared.
4647
45ca3195
ILT
4648 * coffgen.c (coff_find_nearest_line): Don't try to cache
4649 information in sections that are not owned by a BFD. From Richard
4650 Henderson <richard@atheist.tamu.edu>.
4651
252239f8
ILT
4652 * elf32-mips.c: Numerous changes to dynamic linking code, mostly
4653 from Kazumoto Kojima <kkojima@info.kanagawa-u.ac.jp>.
4654 * elflink.h (elf_link_output_extsym): Remove special check for
4655 _rld_new_interface.
4656
4657 * ecoffswap.h: Add prototypes for static functions.
4658
bd2d10c0
MM
4659Sun Jan 14 21:36:08 1996 Michael Meissner <meissner@tiktok.cygnus.com>
4660
4661 * elf32-ppc.c (ppc_elf_{unsupported,std}_reloc): Remove functions.
4662 (ppc_elf_howto_raw): Remove ppc_elf_{unsupported,std}_reloc
4663 references.
4664 (ppc_elf_relocate_section): No longer allow .sdata/.sbss sections
4665 to satisfy a TOC16 relocation. Rewrite unsupported relocation
4666 support. Begin support for R_PPC_SDA{2,}REL.
4667
1c3a295b
MM
4668Sat Jan 13 09:36:52 1996 Michael Meissner <meissner@tiktok.cygnus.com>
4669
4670 * elf32-ppc.c (ppc_elf_create_dynamic_sections): New function to
4671 create the .got and .got.neg sections.
4672 (ppc_elf_size_dynamic_sections): Call it.
4673 (ppc_elf_check_relocs): Call it.
4674 (ppc_elf_size_dynamic_sections): Support .got.neg, just like .got.
4675 (ppc_elf_check_relocs): Add error messages for relocations we
4676 don't yet support. Do not include R_PPC_SDAREL16 like a GOT
4677 relocation.
4678
57081126
MM
4679Fri Jan 12 15:27:59 1996 Michael Meissner <meissner@tiktok.cygnus.com>
4680
4681 * elf32-ppc.c (ppc_elf_fake_sections): Define, and handle the new
4682 section flags for V.4 and eabi.
4683
3c38b3df
ILT
4684Fri Jan 12 13:59:16 1996 Ian Lance Taylor <ian@cygnus.com>
4685
14899eb7
ILT
4686 * elf.c (assign_file_positions_for_segments): If a segment
4687 contains no sections, don't mark it as readable.
4688
98bb57ad
ILT
4689 * elf-bfd.h (_bfd_elf_section_from_bfd_section): Declare.
4690 * elfcode.h (_bfd_elf_section_from_bfd_section): Don't declare.
4691
02fcd126
ILT
4692 * elf.c (_bfd_elf_print_private_bfd_data): Dump contents of
4693 dynamic section, if there is one.
4694 * elf-bfd.h (struct elf_size_info): Add swap_dyn_in field.
4695 (bfd_elf32_swap_dyn_in): Change type of second parameter to PTR.
4696 (bfd_elf64_swap_dyn_in): Likewise.
4697 * elfcode.h (elf_swap_dyn_in): Change type of second parameter to
4698 PTR.
4699 (NAME(_bfd_elf,size_info)): Initialize swap_dyn_in field.
4700
3c38b3df
ILT
4701 * elf32-i386.c (elf_i386_size_dynamic_sections): Don't create a
4702 DT_TEXTREL entry because of .rel.plt. From Martin Pirker
4703 <pirker@eiunix.tuwien.ac.at>.
4704
83f4323e
MM
4705Thu Jan 11 17:06:14 1996 Michael Meissner <meissner@tiktok.cygnus.com>
4706
4707 * section.c (SEC_{EXCLUDE,SORT_ENTRIES}): New section flags for
4708 PowerPC V.4 and eabi.
4709 * bfd-in2.h: Regenerate.
4710 * libfd.h: Regenerate.
4711
4712 * elfxx-target.h (TARGET_{BIG,LITTLE}_SYM): Add new flags.
4713
4714 * elf32-ppc.c (ppc_elf_section_from_shdr): Support SHT_ORDERED
4715 section type and SHF_EXCLUDE section flag, turning them into the
4716 appropriate bfd section flag.
4717
a0271667
ILT
4718Thu Jan 11 11:23:30 1996 Ian Lance Taylor <ian@cygnus.com>
4719
c9746fb6
ILT
4720 * xcofflink.c (xcoff_link_add_symbols): Create the special
4721 sections if we see a DYNAMIC object, in case that is the only
4722 XCOFF input object we see.
4723
5b3b9ff6
ILT
4724 * elf32-mips.c: Extensive changes for a start at dynamic linking
4725 support, from Kazumoto Kojima <kkojima@info.kanagawa-u.ac.jp>.
4726
4727 * elf-bfd.h (struct elf_backend_data): Add type_change_ok field.
4728 (struct elf_backend_data): Remove
4729 elf_backend_create_program_headers field. Add
4730 elf_backend_additional_program_headers and
4731 elf_backend_modify_segment_map fields.
4732 * elfxx-target.h (elf_backend_type_change_ok): Define if not
4733 defined.
4734 (elf_backend_additional_program_headers): Likewise.
4735 (elf_backend_modify_segment_map): Likewise.
4736 (elf_backend_create_program_headers): Don't define.
4737 (elfNN_bed): Change to account for field changes.
4738 * elf.c (assign_file_positions_for_segments): Call new
4739 modify_segment_map backend function. Don't call old
4740 create_program_headers backend function.
4741 (get_program_header_size): Call additional_program_headers rather
4742 than create_program_headers.
4743 * elflink.h (elf_link_add_object_symbols): Initialize
4744 type_change_ok from new backend field.
4745 (elf_link_output_extsym): Don't warn if _rld_new_interface is
4746 defined.
4747 (elf_reloc_link_order): Treat a reloc against a defined symbol as
4748 a reloc against the appropriate section.
4749
761f377f
ILT
4750 * elf-bfd.h (struct bfd_elf_section_data): Add tdata field.
4751 (struct elf_obj_tdata): Rename ppc_flags_init field to flags_init.
4752 (elf_flags_init): Rename from elf_ppc_flags_init.
4753 * elf32-ppc.c (ppc_elf_set_private_flags): Use elf_flags_init, not
4754 elf_ppc_flags_init.
4755 (ppc_elf_copy_private_bfd_data): Likewise.
4756 (ppc_elf_merge_private_bfd_data): Likewise.
4757
a0271667
ILT
4758 * elf32-m68k.c (howto_table): Change src_mask to 0 for all
4759 relocation entries.
4760
64d5f5d0
ILT
4761Tue Jan 9 15:22:53 1996 David Mosberger-Tang <davidm@azstarnet.com>
4762
4763 * coff-alpha.c (alpha_relocate_section): During final link, allow
4764 output .lita section to be bigger than 64k by adjusting gp value
4765 on a per-input section basis.
4766 * libecoff.h (struct ecoff_tdata): Add issued_multiple_gp_warning
4767 field.
4768 (struct ecoff_section_tdata): Add gp field.
4769
c40d9c77
ILT
4770Tue Jan 9 12:00:36 1996 Ian Lance Taylor <ian@cygnus.com>
4771
64d5f5d0
ILT
4772 Handle Alpha ECOFF changes in OSF/1 3.2.
4773 * libecoff.h (struct ecoff_backend_data): Add get_elt_at_filepos
4774 field.
4775 * coff-alpha.c: Include "aout/ar.h".
4776 (alpha_ecoff_get_relocated_section_contents): Don't require an
4777 ALPHA_R_IGNORE reloc after an ALPHA_R_GPDISP reloc, since OSF/1
4778 3.2 doesn't generate one.
4779 (alpha_relocate_section): Likewise.
4780 (alpha_ecoff_slurp_armap): Define.
4781 (alpha_ecoff_slurp_extended_name_table): Define.
4782 (alpha_ecoff_construct_extended_name_table): Define.
4783 (alpha_ecoff_truncate_arname): Define.
4784 (alpha_ecoff_write_armap): Define.
4785 (alpha_ecoff_generic_stat_arch_elt): Define.
4786 (alpha_ecoff_update_armap_timestamp): Define.
4787 (ARFZMAG): Define.
4788 (alpha_ecoff_read_ar_hdr): New static function.
4789 (alpha_ecoff_get_elt_at_filepos): New static function.
4790 (alpha_ecoff_openr_next_archived_file): New static function.
4791 (alpha_ecoff_get_elt_at_index): New static function.
4792 (alpha_ecoff_backend_data): Initialize get_elt_at_filepos field.
4793 (ecoffalpha_little_vec): Change BFD_JUMP_TABLE_ARCHIVE from
4794 _bfd_ecoff to alpha_ecoff.
4795 * ecoff.c (ecoff_link_add_archive_symbols): Use get_elt_at_filepos
4796 field from backend structure, rather than always calling
4797 _bfd_get_elt_at_filepos.
4798 * coff-mips.c (mips_ecoff_backend_data): Initialize
4799 get_elt_at_filepos field.
4800 * archive.c (_bfd_generic_read_ar_hdr_mag): New function, copied
4801 from _bfd_generic_read_ar_hdr with minor changes.
4802 (_bfd_generic_read_ar_hdr): Use _bfd_generic_read_ar_hdr_mag.
4803 * libbfd-in.h (_bfd_generic_read_ar_hdr_mag): Declare.
4804 * libbfd.h: Rebuild.
4805
4806 * bfd-in.h (BFD_IN_MEMORY): Define.
4807 * libbfd-in.h (struct bfd_in_memory): Define.
4808 * libbfd.c (bfd_read): Handle BFD_IN_MEMORY flag.
4809 (bfd_get_file_window): Don't try to map a BFD_IN_MEMORY file.
4810 (bfd_write, bfd_stat): Abort if BFD_IN_MEMORY is set.
4811 (bfd_tell, bfd_flush, bfd_seek): Handle BFD_IN_MEMORY flag.
4812 * bfd.c (struct _bfd): Change iostream field from char * to PTR.
4813 (bfd_get_size): Handle BFD_IN_MEMORY flag.
4814 * cache.c (bfd_cache_close): Ignore BFD_IN_MEMORY files.
4815 (bfd_open_file): Cast to PTR, not char *, when setting iostream.
4816 (bfd_cache_lookup_worker): Abort if BFD_IN_MEMORY is set.
4817 * opncls.c (bfd_fdopenr): Cast to PTR, not char *, when setting
4818 iostream.
4819 (bfd_openstreamr): Likewise.
4820 * aoutx.h (NAME(aout,some_aout_object_p)): Only fstat iostream if
4821 BFD_IN_MEMORY is not set.
4822 * riscix.c (riscix_some_aout_object_p): Likewise.
4823 * bfd-in2.h, libbfd.h: Rebuild.
4824
4825 * targets.c (bfd_target): Add _bfd_get_elt_at_index field.
4826 (BFD_JUMP_TABLE_ARCHIVE): Add _get_elt_at_index.
4827 (bfd_get_elt_at_index): Define.
4828 * archive.c (_bfd_generic_get_elt_at_index): Rename from
4829 bfd_get_elt_at_index. Change index parameter from int to
4830 symindex.
4831 * libbfd-in.h (_bfd_generic_get_elt_at_index): Declare.
4832 (_bfd_noarchive_get_elt_at_index): Define.
4833 (_bfd_archive_bsd_get_elt_at_index): Define.
4834 (_bfd_archive_coff_get_elt_at_index): Define.
4835 * bfd-in2.h, libbfd.h: Rebuild.
4836 * aout-target.h (MY_get_elt_at_index): Define if not defined.
4837 * coff-rs6000.c (xcoff_get_elt_at_index): Define.
4838 * ieee.c (ieee_get_elt_at_index): Define.
4839 * libecoff.h (_bfd_ecoff_get_elt_at_index): Define.
4840 * oasys.c (oasys_get_elt_at_index): Define.
4841 * som.c (som_get_elt_at_index): Define.
4842
c40d9c77
ILT
4843 * ecoff.c (_bfd_ecoff_find_nearest_line): Don't restrict line
4844 numbers to the .text section.
4845
efa77952
ILT
4846Mon Jan 8 17:00:57 1996 Ian Lance Taylor <ian@cygnus.com>
4847
4848 * ieee.c (ieee_write_debug_part): Change return type to boolean.
4849 If there is a SEC_DEBUGGING section, get the contents of the debug
4850 information part from it.
4851 (ieee_set_section_contents): Store the contents of a SEC_DEBUGGING
4852 section in memory.
4853 (ieee_write_object_contents): Check ieee_write_debug_part return.
4854
767f22d5
FF
4855Thu Jan 4 17:12:37 1996 Fred Fish <fnf@cygnus.com>
4856
4857 * config.bfd (i[345]86-*-freebsd*): Add target.
4858 * configure.in (i386freebsd_vec): Add vec.
4859 * configure: Regenerate.
4860 * Makefile.in (BFD32_BACKENDS): Add i386freebsd.o.
4861 (BFD32_BACKENDS_CFILES): Add i386freebsd.c.
4862 Rebuild dependencies..
4863 * freebsd.h: New file.
4864 * i386freebsd.c: New file.
4865 * targets.c (i386freebsd_vec): Declare.
4866 (bfd_target_vector): Add i386freebsd_vec.
4867 * i386linux.c (SEGMENT_SIZE): Define as TARGET_PAGE_SIZE
4868 * i386netbsd.c (SEGMENT_SIZE): Define as TARGET_PAGE_SIZE
4869
f8254a3c
ILT
4870Thu Jan 4 16:27:46 1996 Ian Lance Taylor <ian@cygnus.com>
4871
4872 * ieee.c (ieee_slurp_debug): New static function.
4873 (ieee_object_p): Call it.
4874 (ieee_slurp_section_data): Skip debugging sections.
4875 (ieee_get_reloc_upper_bound): Likewise.
4876 (ieee_get_section_contents): Likewise.
4877 (ieee_canonicalize_reloc): Likewise.
4878 (ieee_write_section_part): Likewise.
4879 (ieee_write_debug_part): Likewise.
4880 (ieee_write_data_part): Likewise.
4881 (init_for_output): Likewise.
4882
07a159db
MM
4883Wed Jan 3 19:42:47 1996 Michael Meissner <meissner@wogglebug.tiac.net>
4884
4885 * elf32-ppc.c (ppc_elf_relocate_section): Make @GOT relocations
4886 work.
4887 (ppc_elf_howto_raw): Just use bfd_elf_generic_reloc for all howto
4888 relocs, since ppc_elf_relocate_section handles the linker case.
4889 (ppc_elf_{addr16_ha,got16,toc16,brtaken}_reloc): Delete, no longer
4890 used.
4891 (ppc_elf_{addr16_ha,got16,toc16,brtaken}_inner): Merge these into
4892 ppc_elf_relocate_section since that is now the only caller.
4893 (ppc_elf_relocate_section): Ditto.
4894
d812945a
ILT
4895Wed Jan 3 15:11:30 1996 Ian Lance Taylor <ian@cygnus.com>
4896
4897 * coffcode.h (coff_write_object_contents): If we don't know the
4898 section of the entry point for an XCOFF executable, always set the
4899 entry address to -1.
4900
3a56d0b4
MM
4901Tue Jan 2 14:17:15 1996 Michael Meissner <meissner@tiktok.cygnus.com>
4902
4903 * elf.c (bfd_section_from_shdr): Add support for note sections.
4904
c4406e50
ILT
4905Tue Jan 2 13:10:25 1996 Ian Lance Taylor <ian@cygnus.com>
4906
d812945a
ILT
4907 * bfd-in.h (struct _symbol_info): Add stab_type field.
4908 * bfd-in2.h: Rebuild.
4909 * aoutx.h (NAME(aout,get_symbol_info)): Set stab_type.
4910
c4406e50
ILT
4911 * elf32-ppc.c: Remove trailing newline from calls to
4912 _bfd_error_handler.
4913 (ppc_elf_merge_private_bfd_data): Only warn about endianness
4914 difference if target endianness is known.
4915
08556813
MM
4916Thu Dec 21 12:43:49 1995 Michael Meissner <meissner@tiktok.cygnus.com>
4917
4918 * elf32-ppc.c (ppc_elf_howto_raw): Add a phony reloc to handle the
4919 old style TOC16 references without using R_PPC_GOT.
4920 (ppc_reloc_type): Ditto.
4921 (ppc_elf_reloc_type_lookup): Add support for TOC16.
4922 (ppc_elf_toc16_inner): Renamed from ppc_elf_got16_inner.
4923 (ppc_elf_toc16_reloc): Renamed from ppc_elf_toc16_reloc.
4924 (ppc_elf_got16_{inner,reloc}): Stubs for real GOT support.
4925 (ppc_elf_check_relocs): New function for GOT/PLT support that is
4926 work in progress.
4927 (ppc_elf_adjust_dynamic_symbol): Ditto.
4928 (ppc_elf_adjust_dynindx): Ditto.
4929 (ppc_elf_size_dynamic_sections): Ditto.
4930 (ppc_elf_finish_dynamic_symbol): Ditto.
4931 (ppc_elf_finish_dynamic_sections): Ditto.
4932 (ELF_DYNAMIC_INTERPRETER): Define.
4933
86587dd4
KR
4934Wed Dec 20 19:14:18 1995 Ken Raeburn <raeburn@cygnus.com>
4935
4936 * elf.c (copy_private_bfd_data): When attaching sections to
4937 segments ignore sections that won't be allocated. Patch from
4938 Andreas Schwab.
4939
bf7f243f
KR
4940Tue Dec 19 20:01:43 1995 Ken Raeburn <raeburn@cygnus.com>
4941
4942 * config.bfd: Match on m68k-cbm-* only if OS doesn't match
4943 anything else.
4944
d9518e2e
ILT
4945Tue Dec 19 16:38:59 1995 Ian Lance Taylor <ian@cygnus.com>
4946
4947 * coff-i960.c (CALC_ADDEND): Define.
4948 (coff_i960_relocate_section): Add the input section VMA to the
4949 addend for PC relative relocs.
4950
4951Sun Dec 17 20:11:55 1995 Kim Knuttila <krk@cygnus.com>
4952
4953 * peicode.h (pe_print_pdata): Must test the entire entry for zero
4954 to correctly terminate.
4955
010a405a
ILT
4956Fri Dec 15 12:05:57 1995 Ian Lance Taylor <ian@cygnus.com>
4957
dc092b6b
ILT
4958 * targets.c (enum bfd_endian): Define.
4959 (bfd_target): Rename byteorder_big_p to byteorder, and change it
4960 from boolean to enum bfd_endian. Change header_byteorder_big_p
4961 correspondingly.
4962 * bfd-in.h (bfd_big_endian, bfd_little_endian): New macros.
4963 (bfd_header_big_endian, bfd_header_little_endian): New macros.
4964 * bfd-in2.h: Rebuild.
4965 * All targets: Change initialization of byteorder and
4966 header_byteorder to use enum bfd_endian values rather than
4967 booleans.
4968 * All files: Change all references to byteorder_big_p and
4969 header_byteorder_big_p to use new bfd_*_endian macros.
4970
010a405a
ILT
4971 * coffgen.c (make_a_section_from_file): Set lma to s_paddr, not
4972 s_vaddr.
4973 * coffcode.h (coff_write_object_contents): Set s_paddr to lma, not
4974 vma.
4975 * ecoff.c (_bfd_ecoff_write_object_contents): Likewise.
4976
fcb43906
SC
4977Fri Dec 15 07:32:09 1995 steve chamberlain <sac@slash.cygnus.com>
4978
4979 * pe[i]-i386.c (TARGET_UNDERSCORE): Define to '_'.
4980
0d709d31
ILT
4981Thu Dec 14 13:45:37 1995 Ian Lance Taylor <ian@cygnus.com>
4982
14578105
ILT
4983 * ieee.c: Lots of minor cleanups. Make many functions return
4984 errors rather than calling abort. Also:
4985 (ieee_write_twobyte): Remove; change callers to call existing
4986 ieee_write_2bytes function.
4987 (ieee_write_expression): Don't output the section twice when
4988 outputting a local symbol. Don't emit an extraneous zero if there
4989 is only one term.
4990 (ieee_slurp_sections): Set the lma as well as the vma.
4991 (ieee_archive_p): Use bfd_alloc_grow rather than an obstack.
4992
0d709d31
ILT
4993 * ihex.c (ihex_set_arch_mach): Don't accept any architecture, just
4994 a recognized one or bfd_arch_unknown.
4995 (ihex_get_symtab_upper_bound): Define as bfd_0l, to permit objcopy
4996 to succeed.
4997 (ihex_get_symtab): Likewise.
4998
14dc2f77
ILT
4999Wed Dec 13 15:44:06 1995 Ian Lance Taylor <ian@cygnus.com>
5000
5001 * aoutx.h: Include <ctype.h>.
5002 (struct aout_link_includes_table): Define.
5003 (struct aout_link_includes_totals): Define.
5004 (struct aout_link_includes_entry): Define.
5005 (aout_link_includes_lookup): Define macro.
5006 (struct aout_final_link_info): Add includes field.
5007 (aout_link_includes_newfunc): New static function.
5008 (NAME(aout,final_link)): Initialize includes hash table.
5009 (aout_link_write_symbols): Eliminate duplicate N_BINCL entries.
5010
480ccad5
SS
5011Wed Dec 13 10:52:14 1995 Stan Shebs <shebs@andros.cygnus.com>
5012
5013 * mpw-config.in: Match on mips-*-* instead of mips-idt-ecoff.
5014
3920d9c9
KK
5015Wed Dec 13 11:07:45 1995 Kim Knuttila <krk@cygnus.com>
5016
5017 * coff-ppc.c (coff_ppc_relocate_section): removed debugging code.
5018
207345f2
KK
5019Tue Dec 12 17:42:06 1995 Kim Knuttila <krk@cygnus.com>
5020
5021 * peicode.h (pe_print_reloc): New function to dump the .reloc section.
5022 (pe_print_private_bfd_data): call pe_print_reloc.
5023 * coffcode.h (coff_set_alignment_hook): .reloc section alignment.
5024 * coff-ppc.c (in_reloc_p): Added missing non-eligible relocs. Spiffed
5025 up some debugging as well.
5026
273c019e
ILT
5027Tue Dec 12 11:34:23 1995 Ian Lance Taylor <ian@cygnus.com>
5028
5029 * config.bfd: Handle sparc-*-elf*. From Ronald F. Guilmette
5030 <rfg@monkeys.com>.
5031
010d9f2d
ILT
5032Fri Dec 8 17:47:07 1995 Ian Lance Taylor <ian@cygnus.com>
5033
5034 * elflink.h (elf_link_add_object_symbols): Set section_count to 0
5035 when setting sections to NULL.
5036
4a4a66bd
ILT
5037Wed Dec 6 17:05:37 1995 Ian Lance Taylor <ian@cygnus.com>
5038
5039 * xcofflink.c (struct xcoff_loader_info): Add export_defineds
5040 field.
5041 (bfd_xcoff_size_dynamic_sections): Add export_defineds parameter.
5042 (xcoff_build_ldsyms): If export_defineds is set, set XCOFF_EXPORT
5043 for all symbols.
5044 * bfd-in.h (bfd_xcoff_size_dynamic_sections): Update declaration.
5045 * bfd-in2.h: Rebuild.
5046
545bf026
KK
5047Mon Dec 4 16:40:47 1995 Kim Knuttila <krk@cygnus.com>
5048
5049 * coffcode.h (coff_set_alignment_hook): Removed some debugging printf's
5050
1f4ae0d6
ILT
5051Mon Dec 4 11:25:39 1995 Ian Lance Taylor <ian@cygnus.com>
5052
55cac920
ILT
5053 * ihex.c (ihex_scan): Handle record types 4 and 5.
5054 (ihex_object_p): Permit types 4 and 5.
5055 (ihex_set_section_contents): Remove check for out of range
5056 addresses.
5057 (ihex_write_object_contents): Generate types 4 and 5.
5058
1f4ae0d6
ILT
5059 * elflink.h (elf_link_output_extsym): Just ignore warning and
5060 indirect references to symbols which don't really exist.
5061
53d45489
KK
5062Sun Dec 3 19:00:27 1995 Kim Knuttila <krk@cygnus.com>
5063
5064 * peicode.h (pe_print_idata): Minor format fixes
5065 (pe_print_edata): New function. Under private printing, this formats
5066 the edata section of a PE file.
5067 (pe_print_private_bfd_data): Added call to pe_print_edata.
5068
361e8876
DE
5069Sun Dec 3 16:46:54 1995 Richard Earnshaw (rearnsha@armltd.co.uk)
5070
5071 * aout-arm.c (MY_swap_std_reloc_out): Use KEEPIT to get the symbol
5072 index, don't call stoi.
5073
58142f10
ILT
5074Fri Dec 1 14:46:51 1995 Ian Lance Taylor <ian@cygnus.com>
5075
ffd15489
ILT
5076 * srec.c (srec_scan): Set lma as well as vma.
5077
5078 * ihex.c: New file; support for Intel Hex format.
5079 * targets.c (enum bfd_flavour): Add bfd_target_ihex_flavour.
5080 (ihex_vec): Declare.
5081 (bfd_target_vector): Always include ihex_vec.
5082 * bfd.c (struct _bfd): Add ihex_data field to tdata union.
5083 * Makefile.in: Rebuild dependencies.
5084 (BFD_LIBS): Add ihex.o
5085 (BFD_LIBS_CFILES): Add ihex.c.
5086 * bfd-in2.h: Rebuild.
5087
ae0a6bea
ILT
5088 * elf.c (assign_file_positions_for_segments): Sort the sections in
5089 each segment.
5090 (get_program_header_size): Return the right size if segment_map is
5091 not NULL.
5092 (copy_private_bfd_data): Don't bother to sort the sections.
5093
5094 * bfd.c (bfd_record_phdr): New function.
5095 * bfd-in.h (bfd_record_phdr): Declare.
5096 * bfd_in2.h: Rebuild.
5097
ce0ee4bf
ILT
5098 * elf32-sparc.c (elf32_sparc_relocate_section): Remove bogus
5099 BFD_ASSERT.
5100
58142f10
ILT
5101 * libbfd.c (bfd_malloc, bfd_realloc): New functions.
5102 (bfd_zmalloc): Return PTR, not char *. Take size_t, not
5103 bfd_size_type.
5104 * libbfd-in.h (bfd_malloc, bfd_realloc): Declare.
5105 (bfd_zmalloc): Change declaration.
5106 * libbfd.h: Rebuild.
5107 * Many files: Use bfd_malloc and bfd_realloc rather than malloc
5108 and realloc. Don't set bfd_error_no_memory if they fail.
5109
59066248
KK
5110Thu Nov 30 19:32:26 1995 Kim Knuttila <krk@cygnus.com>
5111
5112 * coff-ppc.c: Added macros to tidy up toc cell treatment. Numerous
5113 uses as well. Added a new howto to deal with TOCREL16 relocs that
5114 are TOCDEFN as well.
5115 (coff_ppc_relocate_section): Expanded treatment of ADDR32NB relocs
5116 to handle RVA relocs from dlltool.
5117 (ppc_coff_rtype2howto): TOCDEFN reloc addition.
5118 (coff_ppc_rtype_to_howto): TOCDEFN reloc addition.
5119 (ppc_coff_reloc_type_lookup): TOCDEFN reloc addition.
5120
5121 * coffcode.h (coff_set_alignment_hook): check idata$X sections
5122 to get the right section alignment.
5123
6933148a
ILT
5124Thu Nov 30 16:48:18 1995 Ian Lance Taylor <ian@cygnus.com>
5125
5126 * elf.c (_bfd_elf_make_section_from_shdr): Don't set lma based on
5127 p_paddr if p_paddr is zero.
5128 (make_mapping): Set includes_filehdr and includes_phdrs for first
5129 PT_LOAD segment.
5130 (map_sections_to_segments): Set includes_phdrs for PT_PHDR
5131 segment.
5132 (assign_file_positions_for_segments): Handle includes_filehdr and
5133 includes_phdrs. Remove special handling of PT_PHDR and first
5134 PT_LOAD segments.
5135 (copy_private_bfd_data): Set includes_filehdr and includes_phdr
5136 when appropriate. Remove special handling of PT_PHDR segment.
5137 Use a more complex condition for when a section is included in a
5138 segment to handle Solaris linker oddities.
5139
f62fed1c
ILT
5140Thu Nov 30 11:17:33 1995 Manfred Hollstein KS/EF4A 60/1F/110 #40283 <manfred@lts.sel.alcatel.de>
5141
5142 * coff-m88k.c (howto_table): Reformatted for easier reading;
5143 special_function now points to new function m88k_special_reloc.
5144 (howto_hvrt16): Function previously used for handling HVRT16 relocs
5145 removed.
5146 (rtype2howto): Do not add reloc's r_offset to the addend, this will
5147 be done correctly by m88k_special_reloc.
5148 (reloc_processing): New function to be used by RELOC_PROCESSING.
5149 (RELOC_PROCESSING): Define to call reloc_processing.
5150
64ecde46
ILT
5151Wed Nov 29 12:42:36 1995 Ian Lance Taylor <ian@cygnus.com>
5152
b00c57ec
ILT
5153 * peicode.h (pe_print_idata): Call malloc rather than xmalloc.
5154 (pe_print_pdata): Likewise.
5155
a9713b91
ILT
5156 * opncls.c (bfd_alloc_by_size_t): Set bfd_error_no_memory if
5157 obstack_alloc fails.
5158 (bfd_alloc_finish): Set bfd_error_no_memory if obstack_finish
5159 fails.
5160 * libbfd.c (bfd_zmalloc): Set bfd_error_no_memory if malloc fails.
5161 * Many files: don't set bfd_error_no_memory if one of the above
5162 routines fails.
5163
3dbf33ee
ILT
5164 * elf.c (assign_file_positions_for_segments): Don't adjust p_paddr
5165 if p_paddr_valid is set.
5166 (copy_private_bfd_data): New static function.
5167 (_bfd_elf_copy_private_section_data): Call copy_private_bfd_data.
5168
44ef8897
ILT
5169 * elf.c (assign_file_positions_for_segments): Fix case where extra
5170 program headers were allocated.
5171
27fb8f29
ILT
5172 * elf.c (_bfd_elf_print_private_bfd_data): New function.
5173 * elf-bfd.h (_bfd_elf_print_private_bfd_data): Declare.
5174 * elfxx-target.h (bfd_elfNN_bfd_print_private_bfd_data): Define to
5175 _bfd_elf_print_private_bfd_data.
5176
64ecde46
ILT
5177 * coff-alpha.c (alpha_ecoff_swap_reloc_in): Don't abort if
5178 r_symndx is RELOC_SECTION_NONE for an ALPHA_R_IGNORE reloc.
5179 Change a RELOC_SECTION_LITA symndx to RELOC_SECTION_ABS.
5180 (alpha_ecoff_swap_reloc_out): Change RELOC_SECTION_ABS to
5181 RELOC_SECTION_LITA for ALPHA_R_IGNORE.
5182 (alpha_adjust_reloc_out): For ALPHA_R_IGNORE, don't change
5183 RELOC_SECTION_ABS to RELOC_SECTION_NONE.
5184
fd0198f0
ILT
5185Tue Nov 28 16:59:50 1995 Ian Lance Taylor <ian@cygnus.com>
5186
5187 * elf-bfd.h (struct elf_obj_tdata): Add segment_map field.
5188 * elf.c (make_mapping): New static function.
5189 (map_sections_to_segments): New static function.
5190 (elf_sort_sections): New static function.
5191 (assign_file_positions_for_segments): New static function.
5192 (map_program_segments): Remove.
5193 (get_program_header_size): Remove sorted_hdrs, count, and
5194 maxpagesize parameters. Simplify.
5195 (assign_file_positions_except_relocs): When generating an
5196 executable, use assign_file_positions_for_segments.
5197 (elf_sort_hdrs): Remove.
5198 (_bfd_elf_sizeof_headers): Remove eliminated parameters from call
5199 to get_program_header_size.
5200
3b3f7625
ILT
5201Mon Nov 27 12:27:46 1995 Ian Lance Taylor <ian@cygnus.com>
5202
1ff0461b
ILT
5203 * hp300hpux.c (MY(callback)): Set lma as well as vma.
5204
80c8485c
ILT
5205 * configure, config.in: Regenerate with autoconf 2.7.
5206
3b3f7625
ILT
5207 * elf32-i386.c (elf_backend_plt_readonly): Set correctly, to 1.
5208 * elf32-sparc.c (elf_backend_plt_readonly): Set correctly, to 0.
5209
fa63d1ef
ILT
5210Wed Nov 22 12:02:09 1995 Ian Lance Taylor <ian@cygnus.com>
5211
a877f591
ILT
5212 * ecoff.c (_bfd_ecoff_new_section_hook): Handle .rconst section.
5213 (ecoff_sec_to_styp_flags): Likewise.
5214 (_bfd_ecoff_styp_to_sec_flags): Handle STYP_RCONST.
5215 (ecoff_set_symbol_info): Handle scRConst.
5216 (ecoff_slurp_reloc_table): Handle RELOC_SECTION_RCONST.
5217 (ecoff_compute_section_file_positions): Handle .rconst section.
5218 (_bfd_ecoff_write_object_contents): Likewise.
5219 (ecoff_link_check_archive_element): Handle scRConst.
5220 (ecoff_link_add_externals): Likewise.
5221 (ecoff_link_write_external): Handle .rconst section.
5222 (ecoff_reloc_link_order): Likewise.
5223 * ecofflink.c (bfd_ecoff_debug_accumulate): Handle scRConst.
5224 * coff-alpha.c (alpha_convert_external_reloc): Handle .rconst
5225 section.
5226 (alpha_relocate_section): Handle RELOC_SECTION_RCONST.
5227
fa63d1ef
ILT
5228 * sunos.c (sunos_scan_dynamic_symbol): Only set written if the
5229 DEF_DYNAMIC flag is set.
5230
25bada65
KR
5231Tue Nov 21 13:25:29 1995 Ken Raeburn <raeburn@cygnus.com>
5232
5233 * host-aout.c: If TRAD_HEADER is defined, include it.
5234
7938b4cb
ILT
5235Tue Nov 21 13:03:57 1995 Ian Lance Taylor <ian@cygnus.com>
5236
85e493f0
ILT
5237 * aclocal.m4 (AC_PROG_CC): Remove local definition.
5238 (BFD_BINARY_FOPEN): Require AC_CANONICAL_SYSTEM.
5239 (BFD_NEED_DECLARATION): New function.
5240 * configure.in: Use BFD_NEED_DECLARATION.
bd77213b
ILT
5241 * acconfig.h: Put NEED_DECLARATION_* in @TOP@ section.
5242 * configure, config.in: Rebuild with autoconf 2.6.
85e493f0 5243
83dcdc61
ILT
5244 * xcofflink.c (bfd_xcoff_size_dynamic_sections): Clear
5245 special_sections before returning when called with a non XCOFF
5246 BFD.
5247
7938b4cb
ILT
5248 * coffgen.c (coff_renumber_symbols): Sort common symbols with
5249 global symbols.
5250
5251 * coffcode.h (coff_compute_section_file_positions): Only pad the
5252 previous section to force file alignment when creating an
5253 executable.
5254
b5403ad7
ILT
5255Mon Nov 20 14:54:09 1995 Ian Lance Taylor <ian@cygnus.com>
5256
a418e05d
ILT
5257 * coffcode.h (coff_compute_section_file_positions): If
5258 RS6000COFF_C, set up the .debug section.
5259
b5403ad7
ILT
5260 * xcofflink.c (xcoff_link_input_bfd): Adjust the TOC anchor value
5261 if it is not large enough to accomodate the entire TOC area with
5262 signed 16 bit offsets.
5263 (xcoff_write_global_symbol): Handle negative TOC offsets in global
5264 linkage code.
5265 (_bfd_ppc_xcoff_relocate_section): Adjust relocations against a
5266 TOC anchor to use the TOC value used in the output file.
5267
90a7abbc
ILT
5268Sat Nov 18 18:01:41 1995 Ian Lance Taylor <ian@cygnus.com>
5269
5270 * coffgen.c (_bfd_coff_get_external_symbols): Cast malloc return.
5271 (_bfd_coff_read_string_table): Likewise.
5272
177b1932
DE
5273Sat Nov 18 19:43:04 1995 Richard Earnshaw (rearnsha@armltd.co.uk)
5274
5275 * pe-arm.c: Fix typos.
5276 * coff-arm.c: Likewise.
5277
5278Fri Nov 17 16:22:04 1995 Kim Knuttila <krk@cygnus.com>
5279
5280 * coff-ppc.c (list_ele): Added "cat"egory member.
5281 (record_toc): New category parameter (priv or pub).
5282 (ppc_record_toc_entry): Check to see if toc bounds exceeded.
5283 (ppc_process_before_allocation): Removed embrionic data-in-toc from
5284 the mainline. It addes extra toc cells in error.
5285 (ppc_coff_swap_sym_in_hook): Added some documentation.
5286 (dump_toc): Can now diagnose "virtual toc" chicanery.
5287
e34314c4
ILT
5288Fri Nov 17 10:41:25 1995 Philippe De Muyter <phdm@info.ucl.ac.be>
5289
5290 * elf-bfd.h (struct elf_link_hash_table): Change type of
5291 dynsymcount and bucketcount fields from size_t to bfd_size_type.
5292
73a68447
ILT
5293Fri Nov 17 10:02:58 1995 Ian Lance Taylor <ian@cygnus.com>
5294
535e9e29
ILT
5295 * coffcode.h (coff_pointerize_aux_hook): I960 version: don't
5296 pointerize C_LEAFSTAT or C_LEAFEXT entries.
5297
73a68447
ILT
5298 * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Only create
5299 DT_INIT and DT_FINI entries if the _init or _fini symbol is
5300 defined or mentioned in a regular file.
5301
cd2b2402
KK
5302Thu Nov 16 15:16:42 1995 Kim Knuttila <krk@cygnus.com>
5303
5304 * coff-ppc.c (ppc_record_data_in_toc_entry): new function
5305 (coff_ppc_relocate_section): Handle TOCDEFN attribute
5306 (coff_ppc_relocate_section): Correct REL24 handling
5307 (ppc_process_before_allocation): Correct TOCDEFN handling
5308
5309 * peicode.h (dir_names): Added name descriptions
5310
b218076e
KR
5311Thu Nov 16 03:38:03 1995 Ken Raeburn <raeburn@cygnus.com>
5312
5313 * VERSION: Updated to cygnus-2.6.
5314
5315Wed Nov 15 19:30:07 1995 Ken Raeburn <raeburn@cygnus.com>
5316
5317 * targets.c (m68k4knetbsd_vec): Declare.
5318
e9f30616
ILT
5319Wed Nov 15 18:05:52 1995 Ian Lance Taylor <ian@cygnus.com>
5320
5321 * targets.c (bfd_target): Change type of second argument to
5322 _bfd_print_private_bfd_data from void * to PTR.
5323 * libbfd-in.h (_bfd_generic_bfd_print_private_bfd_data): Cast
5324 using PTR rather than void *.
5325 * bfd-in2, libbfd.h: Rebuild.
5326 * peicode.h (pe_print_private_bfd_data): Change vfile from void *
5327 to PTR.
5328 * elfxx-target.h (bfd_elfNN_bfd_print_private_bfd_data): Define as
5329 _bfd_generic_bfd_print_private_bfd_data rather than casting
5330 bfd_true.
5331
ae75c4a4
KR
5332Wed Nov 15 04:09:14 1995 Ken Raeburn <raeburn@cygnus.com>
5333
5334 * Makefile.in (.dep1): Fix stupid typo in last change. Remove any
5335 "DO NOT DELETE" lines or blank lines that mkdep writes on some
5336 systems.
5337 (BFD_LIBS_CFILES, ALL_MACHINES_CFILES, BFD32_BACKENDS_CFILES,
5338 BFD64_BACKENDS_CFILES): New variables.
5339 (CFILES): Use them.
5340
bebcd3db
ILT
5341Tue Nov 14 11:52:23 1995 Ian Lance Taylor <ian@cygnus.com>
5342
4b71e164
ILT
5343 * peicode.h (coff_swap_aouthdr_out): For PPC PE, start isize at 0,
5344 not at the file position of the first section.
5345 * coffcode.h (coff_compute_section_file_positions): Avoid using
5346 unportable #elif.
5347 (coff_write_object_contents): When generating a PPC PE executable
5348 with no symbols, round up the file size to a COFF_PAGE_SIZE
5349 boundary.
5350 * cofflink.c (_bfd_coff_final_link): If there are no symbols,
5351 don't write out a string table.
5352
631b10f4
ILT
5353 * elf.c (bfd_section_from_shdr): When using a different section
5354 header, pass the new one to _bfd_elf_make_section_from_shdr.
5355 (elf_fake_sections): Don't set sh_info and sh_entsize fields.
5356 (elf_map_symbols): Add section VMA to symbol value when comparing
5357 against 0.
5358 (_bfd_elf_compute_section_file_positions): Only build symbol table
5359 if there are some symbols. Set file offset of symtab and strtab
5360 sections.
5361 (assign_file_positions_except_relocs): Remove dosyms parameter.
5362 Change all callers. Never set file offset of symtab and strtab
5363 sections.
5364 (_bfd_elf_copy_private_section_data): New function.
5365 (MAP_ONESYMTAB, MAP_DYNSYMTAB, MAP_STRTAB, MAP_SHSTRTAB): Define.
5366 (_bfd_elf_copy_private_symbol_data): New function.
5367 (swap_out_syms): Check for special mapping of st_shndx created by
5368 copy_private_symbol_data.
5369 * elfxx-target.h: Use new copy routines.
5370 * elf-bfd.h (_bfd_elf_copy_private_symbol_data): Declare.
5371 (_bfd_elf_copy_private_section_data): Declare.
5372
5373 * config.bfd (sh-*-*): Set targ_defvec to shcoff_vec.
5374
5375 * coffcode.h (coff_slurp_symbol_table): If COFF_WITH_PE, handle
5376 C_NT_WEAK.
5377
bebcd3db
ILT
5378 * coff-sh.c (shlcoff_vec): Use _bfd_generic_archive_p, not
5379 _bfd_dummy_target, matching the recent change to archive
5380 recognition.
5381
7ad4ba81
ILT
5382Mon Nov 13 13:24:38 1995 Ian Lance Taylor <ian@cygnus.com>
5383
afa67334
ILT
5384 * libbfd.c (bfd_get_file_window): Use casts to avoid doing
5385 arithmetic on PTR types.
5386
f2bd8915
ILT
5387 * aout-target.h (MY(callback)): Set the lma of the sections.
5388
7ad4ba81
ILT
5389 * ecoff.c (ecoff_reloc_link_order): Turn a reloc against a defined
5390 symbol into a reloc against the section.
5391
93b6a3f8
KK
5392Mon Nov 13 07:31:35 1995 Kim Knuttila <krk@cygnus.com>
5393
5394 * coff-ppc.c (ppc_coff_link_hash_entry): added support for inline
5395 glue for the relocs: IMGLUE and IFGLUE.
5396 (record_toc): new function - tracks toc contents
5397 (ppc_mark_symbol_as_glue): new function - supports the IMGLUE reloc
5398 (coff_ppc_relocate_section): Added support and fixes for IMGLUE/IFGLUE
5399 (ppc_coff_rtype2howto): removed invalid IMGLUE hack
5400 (coff_ppc_rtype_to_howto): removed invalid IMGLUE hack
125d37c4 5401 (ppc_record_toc_entry): Removed a debug define (duh)
93b6a3f8
KK
5402
5403 * peicode.h (coff_swap_scnhdr_out): Fixed invalid strcmp for ".reldata"
5404 (pe_print_idata): New function - formats the idata section data
5405 (pe_print_pdata): New function - formats the pdata section data
5406 (pe_print_private_bfd_data): calls to above
5407
c769947b
SS
5408Sun Nov 12 12:23:24 1995 Stan Shebs <shebs@andros.cygnus.com>
5409
5410 * Makefile.in (bfd_libs_here, etc): Provide empty definitions.
5411 * coff-rs6000.c (rs6000coff_vec): Add conditional defines
5412 TARGET_SYM and TARGET_NAME for vector and BFD name.
5413 * coff-pmac.c (pmac_xcoff_vec): Remove.
5414 (TARGET_SYM, TARGET_NAME): Define.
5415 * coffcode.h (coff_set_arch_mach_hook) [POWERMAC]: Set the
5416 machine to 0, not all PowerMacs are 601s.
5417
5418Fri Nov 10 12:10:14 1995 Ian Lance Taylor <ian@cygnus.com>
5419
5420 * elfcode.h (elf_object_p): Read in any program headers.
5421 * elf.c (_bfd_elf_make_section_from_shdr): Adjust section lma
5422 based on the program headers, if any.
5423 (elf_fake_sections): Set sh_addr from the vma, not the lma.
5424 (map_program_segments): Set p_paddr of program headers based on
5425 the lma.
5426
ee174815
ILT
5427Thu Nov 9 13:01:31 1995 Ian Lance Taylor <ian@cygnus.com>
5428
839087b7
ILT
5429 * archive.c (bfd_generic_archive_p): Preserve tdata in case of
5430 failure.
5431
922530a6
ILT
5432 * aoutx.h (NAME(aout,final_link)): Report a reasonable error when
5433 trying to do a relocateable link with a non-a.out object file.
5434
5435 * archive.c (bfd_generic_archive_p): Check the first object file
5436 in an archive even if target_defaulted is set. If the object file
5437 has the wrong xvec, reject it.
5438
a1774c51
ILT
5439 * aoutx.h (NAME(aout,set_section_contents)): If a section can not
5440 be represented, report the name via _bfd_error_handler.
5441 (translate_to_native_sym_flags): Likewise.
5442 * elf32-mips.c (mips_elf_final_link): Likewise.
5443 * oasys.c (oasys_write_sections): Likewise.
5444
4a378b13
ILT
5445 * coffcode.h (coff_set_alignment_hook): Write RS6000COFF_C version
5446 which checks for STYP_OVRFLO sections.
5447 (coff_compute_section_file_positions): If RS6000COFF_C, handle
5448 reloc and lineno count overflows.
5449 (coff_write_object_contents): Call coff_count_linenumbers before
5450 coff_compute_section_file_positions. If RS6000COFF_C, handle
5451 reloc and lineno count overflows.
5452 * xcofflink.c (_bfd_xcoff_bfd_final_link): Count line numbers and
5453 relocs before dealing with .pad sections. Count overflow section
5454 headers when handling .pad sections.
5455
7906bf87
ILT
5456 * coffcode.h (coff_write_object_contents): Set a.out vstamp to 1
5457 if RS6000COFF_C.
5458
ee174815
ILT
5459 * xcofflink.c (XCOFF_DESCRIPTOR): Define.
5460 (struct xcoff_link_hash_table): Add descriptor_section and
5461 special_sections fields.
5462 (_bfd_xcoff_bfd_link_hash_table_create): Initialize new fields.
5463 (xcoff_link_add_symbols): Set linkage section alignment. Create
5464 descriptor section. Check for magic symbol names (_text, etc.),
5465 and record them in special_sections if found. Set
5466 XCOFF_DESCRIPTOR flag for a function descriptor, and set its
5467 descriptor field to point back to the function code symbol.
5468 (xcoff_sweep): Always mark the special descriptor_section.
5469 (bfd_xcoff_export_symbol): Check whether the symbol might be a
5470 function descriptor, and mark it if it is.
5471 (bfd_xcoff_size_dynamic_sections): Add new special_sections
5472 parameter, and fill it in. Allocate space for the descriptor
5473 section.
5474 (xcoff_build_ldsyms): Set XCOFF_DEF_REGULAR flag when defining
5475 global linkage code. If an undefined function descriptor is
5476 exported, arrange to define it. Warn about any other undefined
5477 exported symbol.
5478 (_bfd_xcoff_bfd_final_link): Write out the descriptor section.
5479 (xcoff_write_global_symbol): Create a function descriptor when
5480 necessary.
5481 * bfd-in.h (bfd_xcoff_size_dynamic_sections): Update declaration.
5482 * bfd-in2.h: Rebuild.
5483
0e829f18
KK
5484Thu Nov 9 08:40:23 1995 Kim Knuttila <krk@cygnus.com>
5485
5486 * coff-ppc.c (ppc_coff_link_hash_entry): new types for hashing
5487 (ppc_coff_link_hash_table): new types for hashing
5488 (ppc_coff_link_hash_newfunc): hash entry constructor
5489 (ppc_coff_link_hash_table_init): hash table initializer
5490 (ppc_coff_link_hash_table_create): hash table constructor
5491 (ppc_record_toc_entry): changed references to hash table
5492 (coff_ppc_relocate_section): changed references to hash table
5493
5494 * libcoff-in.h (coff_link_hash_entry): removed toc_offset
5495 * libcoff.h: Rebuild
5496
5497 * cofflink.c (_bfd_coff_link_hash_newfunc): removed toc_offset init
5498 (coff_link_add_symbols): removed toc_offset init
5499
7ac84736
KR
5500Thu Nov 9 04:00:38 1995 Ken Raeburn <raeburn@cygnus.com>
5501
b27cc4bc
KR
5502 * Makefile.in (.dep1): Make sure the file mkdep is to write exists
5503 first.
5504
7ac84736
KR
5505 * configure.in: Added new option --with[out]-mmap. Set USE_MMAP
5506 if it is given and mmep is available.
5507 * acconfig.h: Undef USE_MMAP.
5508 * configure, config.in: Regenerated.
5509 * aoutx.h: If USE_MMAP is not defined, do all symbol and string
5510 table handling the old way.
5511 (aout_get_external_symbols): Don't complain if last byte of string
5512 table is nonzero.
5513 * libbfd.c [HAVE_MADVISE]: Include sys/types.h and sys/mman.h.
5514 (bfd_free_window) [! USE_MMAP]: Don't define.
5515 (bfd_get_file_window,
5516 _bfd_generic_get_section_contents_in_window) [! USE_MMAP]: Abort.
5517
1b3b0c03
ILT
5518Wed Nov 8 20:03:44 1995 Eric Freudenthal <freudenthal@nyu.edu>
5519
5520 * coff-a29k.c (SIGN_EXTEND_HWORD): Use ~0xffff rather than
5521 0xffff0000.
5522
092abcdf
ILT
5523Wed Nov 8 11:31:11 1995 Ian Lance Taylor <ian@cygnus.com>
5524
33698029
ILT
5525 * coff-a29k.c (a29k_reloc): Change handling of R_IREL reloc to be
5526 compatible with AMD generated COFF files. Try to support both AMD
5527 and GNU formats simultaneously.
5528 (coff_a29k_relocate_section): Likewise.
5529
0bb8ff19
ILT
5530 * libbfd.c (bfd_get_file_window): Change writable parameter from
5531 int to boolean; update all callers. Pass MAP_SHARED if not
5532 writable--it's required on Solaris. Cast fprintf argument to
5533 avoid warning.
5534 * bfd-in.h (bfd_get_file_window): Update declaration.
5535 * bfd-in2.h: Rebuild.
5536 * aoutx.h: Update calls to bfd_get_file_window.
5537
0634a431
ILT
5538 * xcofflink.c (XCOFF_DEF_DYNAMIC): Rename from XCOFF_REF_DYNAMIC.
5539 Change all uses.
5540 (xcoff_swap_ldhdr_in): New static function.
5541 (xcoff_swap_ldsym_in): New static function.
7812bf9c 5542 (xcoff_find_reloc): Handle the case of a single reloc correctly.
0634a431
ILT
5543 (xcoff_link_add_symbols): If we just created a descriptor, pass it
5544 to _bfd_generic_link_add_one_symbol, to save a hash lookup.
417acf22 5545 Handle XTY_ER/XMC_XO symbols correctly.
0634a431
ILT
5546 (xcoff_link_add_dynamic_symbols): Rewrite to read .loader symbols
5547 rather than normal symbol table.
417acf22
ILT
5548 (bfd_xcoff_import_symbol): It's not an error if the symbol is
5549 already defined with the same absolute value.
0634a431
ILT
5550 (xcoff_mark): When considering called symbols, check whether the
5551 descriptor is from a dynamic object, rather than the symbol
5552 itself.
5553 (xcoff_build_ldsyms): Likewise.
5554
092abcdf
ILT
5555 * libbfd.c (bfd_get_file_window): Change return type to boolean.
5556 Cast realloc and malloc return values. If malloc or realloc fail,
5557 set bfd_error_no_memory.
5558 * bfd-in.h (bfd_get_file_window): Change type to boolean.
5559 * bfd-in2.h: Rebuild.
5560
d6f41a7d
KK
5561Tue Nov 7 11:53:48 1995 Kim Knuttila <krk@cygnus.com>
5562
5563 * coff-ppc.c (ppc_record_toc_entry): new function.
5564 (in_reloc_p): changed return value.
5565 (coff_ppc_relocate_section): much rework.
5566 (ppc_allocate_toc_section): new function.
5567 (ppc_process_before_allocation): new function.
5568 (ppc_coff_swap_sym_in_hook): new function.
5569
5570 * cofflink.c (_bfd_coff_link_hash_newfunc): initialize toc_offset.
5571 (coff_link_add_symbols): initialize toc_offset.
5572
5573 * peicode.h (coff_swap_sym_in): Added coff_swap_sym_in_hook
5574 (coff_swap_aouthdr_out): Added more sections to the data
5575 dictionary for the pe file header. Also changed linker version
5576 number on the ppc side.
5577 (dir_names): small improvements to the dictionary printing.
5578 (pe_mkobject_hook): save the file level flags.
5579
5580 * libcoff-in.h (coff_link_hash_entry): added toc_offset field
5581 (pe_tdata): added real_flags field
5582 (coff_tdata): added local_toc_sym_map and access macro
5583
5584 * libcoff.h (coff_link_hash_entry): added toc_offset field
5585 (pe_tdata): added real_flags field
5586 (coff_tdata): added local_toc_sym_map and access macro
5587
5588 * coffcode.h (coff_set_alignment_hook): added hook for PE.
5589 (coff_mkobject): init for local_toc_sym_map
5590 (coff_write_object_contents): set the internal_a.magic to
5591 IMAGE_NT_OPTIONAL_HDR_MAGIC which appears to be what other
5592 ppc compilers use.
5593
6bc200f2
ILT
5594Tue Nov 7 13:48:58 1995 Ian Lance Taylor <ian@cygnus.com>
5595
c0971298
ILT
5596 * ecofflink.c (_bfd_ecoff_locate_line): Keep looking through stabs
5597 entries until both the line number address and the function name
5598 address are too large.
5599
6a468850
ILT
5600 * configure.in: Call AC_CHECK_PROG to find and cache AR.
5601 * configure: Rebuilt.
5602
6bc200f2
ILT
5603 * aclocal.m4 (BFD_CC_FOR_BUILD): Don't define CC_FOR_BUILD if it
5604 is defined in the environment.
5605
c44bf94c
JL
5606Tue Nov 7 10:57:24 1995 Jeffrey A Law (law@cygnus.com)
5607
5608 * som.c (som_get_section_contents_in_window): Define to use
5609 generic version.
5610
cf587de8
ILT
5611Mon Nov 6 17:13:15 1995 Harry Dolan <dolan@ssd.intel.com>
5612
5613 * coff-i860.c: New file, based on coff-i386.c.
5614 * cpu-i860.c: New file, based on cpu-i386.c.
5615 * hosts/i860mach3.h: New file, based on hosts/i386mach3.h.
5616 * config.bfd (i860-*-mach3*, i860-*-osf1*, i860-*-coff*): New
5617 targets, using i860coff_vec.
5618 * configure.in (i860-*-mach3*, i860-*-osf1*): New hosts, using
5619 trad-core.o and hosts/i860mach3.h.
5620 (i860coff_vec): Use coff-i860.o and cofflink.o.
5621 * configure: Rebuild.
5622 * Makefile.in: Rebuild dependencies.
5623 (ALL_MACHINES): Add cpu-i860.o.
5624 (BFD32_BACKENDS): Add coff-i860.o.
5625 (CFILES): Add cpu-i860.c and coff-i860.c.
5626 * targets.c (i860coff_vec): Declare.
5627 (bfd_target_vector): Add &i860coff_vec.
5628 * archures.c (bfd_i860_arch): Declare.
5629 (bfd_archures_list): Add &bfd_i860_arch.
5630 * coffcode.h (coff_set_arch_mach_hook): Handle I860 magic number.
5631 (coff_set_flags): Handle bfd_arch_i860.
5632 (coff_write_object_contents): Handle I860 a.out magic number.
5633
83c23fca
ILT
5634Mon Nov 6 14:34:07 1995 Ian Lance Taylor <ian@cygnus.com>
5635
5636 * xcofflink.c (xcoff_link_add_symbols): Set the alignment power of
5637 the created .tc section to 2.
5638 (xcoff_mark): Don't keep a .loader reloc for a call to an
5639 undefined symbol when creating a shared library.
5640 (xcoff_build_ldsyms): When creating a shared library, generate
5641 global linkage code for a call to an undefined symbol.
5642
5d9eb9c3
KR
5643Sun Nov 5 21:44:13 1995 Ken Raeburn <raeburn@cygnus.com>
5644
5645 * Makefile.in (CFILES): Rebuild list from BFD_LIBS, ALL_MACHINES,
5646 BFD32_BACKENDS, BFD64_BACKENDS.
5647 (.dep1): Put mkdep output in a separate file.
5648 Rebuilt dependencies.
5649
ffacb892
KR
5650 * ecoff.c (_bfd_ecoff_slurp_armap): Cast _bfd_read_ar_hdr return
5651 value.
5652
4fe6d901
KR
5653 Permit use of mmap when available:
5654
5655 * configure.in: Check for mmap, madvise, mprotect.
5656 * config.in, configure: Regenerated.
5657
5658 * libbfd.c (struct _bfd_window_internal): Define type.
5659 (bfd_init_window, bfd_free_window, bfd_get_file_window): New
5660 functions.
5661 (ok_to_map): New static variable for debugging.
5662 (_bfd_generic_get_section_contents_in_window): New function.
5663 * bfd-in.h (bfd_window_internal): Declare type.
5664 (bfd_window): Define type.
5665 (bfd_init_window, bfd_free_window, bfd_get_file_window): Declare.
5666 * libbfd-in.h (_bfd_generic_get_section_contents_in_window):
5667 Declare.
5668
5669 * libaout.h (struct aoutdata): Add two window fields.
5670 (obj_aout_sym_window, obj_aout_string_window): New macros.
5671 * aoutx.h (some_aout_object_p): Initialize windows.
5672 (aout_get_external_symbols): Get symbol data and strings in
5673 windows instead of explicitly allocated buffers.
5674 (slurp_symbol_table): Free window instead of memory.
5675 (bfd_free_cached_info): Release windows instead of freeing storage
5676 directly.
5677 (aout_link_free_symbols): Ditto.
5678
5679 * targets.c (bfd_target): Add new field for
5680 get_section_contents_in_window.
5681 (BFD_JUMP_TABLE_GENERIC): Updated.
5682 * aout-adobe.c, aout-target.h, binary.c, bout.c, coff-alpha.c,
5683 coff-mips.c, elfxx-target.h, i386msdos.c, i386os9k.c, ieee.c,
5684 libcoff-in.h, oasys.c, srec.c, tekhex.c, versados.c: Added new
5685 macros for get_section_contents_in_window field.
5686
d9e771e3
FF
5687Sat Nov 4 12:23:26 1995 Fred Fish <fnf@cygnus.com>
5688
5689 * core.c: Renamed to corefile.c
5690 * makefile.dos (OBJS): Change core.o to corefile.o
5691 * Makefile.in (CFILES, BFD_LIBS): Use corefile.c instead of core.c
5692
bf917766
SG
5693start-sanitize-gm
5694Sat Nov 4 10:16:54 1995 Stu Grossman (grossman@cygnus.com)
5695
5696 * config.bfd (mips*-*-magic*): Add bfd_elf32_bigmips_vec to
5697 targ_selvecs to allow debugging under Irix-5 native.
5698
5699end-sanitize-gm
583db7a8
ILT
5700Fri Nov 3 15:54:59 1995 Ian Lance Taylor <ian@cygnus.com>
5701
5702 * xcofflink.c (xcoff_link_add_symbols): Rename local variable sub
5703 to o. Clobber and restore the list of new csects around the call
5704 to _bfd_generic_link_add_one_symbol, in case it wants to report a
5705 linker error and the linker wants to read the symbol table. Reset
5706 the line number count of a real section even if it has no relocs.
5707 (_bfd_xcoff_bfd_final_link): If shared, set the DYNAMIC flag.
5708
5709 * coffgen.c (_bfd_coff_read_string_table): Warn if the string size
5710 is too small.
5711
68aed7db
ILT
5712Thu Nov 2 23:16:39 1995 Ian Lance Taylor <ian@cygnus.com>
5713
18a9609c
ILT
5714 * xcofflink.c (_bfd_ppc_xcoff_relocate_section): Don't warn about
5715 an undefined symbol in a shared link.
5716
68aed7db
ILT
5717 * linker.c (_bfd_generic_link_add_one_symbol): Correct type of
5718 oldtype from bfd_link_order_type to bfd_link_hash_type. From
5719 phdm@info.ucl.ac.be (Philippe De Muyter).
5720
7f82c7e1
ILT
5721Wed Nov 1 14:26:02 1995 Manfred Hollstein KS/EF4A 60/1F/110 #40283 <manfred@lts.sel.alcatel.de>
5722
5723 * coff-m88k.c (rtype2howto): New static function.
5724 (RTYPE2HOWTO): Use it rather than a macro definition.
5725
5726 * coffcode.h (coff_write_object_contents): set internal_a.magic
5727 to PAGEMAGICPEXECPAGED #if defined (M68) && !defined (LYNXOS).
5728
4c8b9746 5729 * configure.in: m68*-motorola-sysv* does not use ptrace-core.o;
7f82c7e1
ILT
5730 define TRAD_HEADER to new file hosts/delta68.h.
5731 m88*-motorola-sysv*, however, does use ptrace-core.o.
5732 * hosts/delta68.h: New file.
5733
5734 * ptrace-core.c (ptrace_unix_core_file_p): change bfd_zmalloc to
5735 bfd_zalloc; provide proper parm abfd to calls to bfd_zalloc.
5736
619c7730
KR
5737Wed Nov 1 13:51:54 1995 Ken Raeburn <raeburn@cygnus.com>
5738
5739 * i386linux.c (MY(vec)): Declare before use.
5740
73246ff8
ILT
5741Wed Nov 1 11:45:07 1995 Ian Lance Taylor <ian@cygnus.com>
5742
e8d6d5d0
ILT
5743 * reloc16.c (bfd_coff_reloc16_get_relocated_section_contents):
5744 Pass input_bfd, not in_bfd, to bfd_coff_reloc16_extra_cases.
5745
b2193cc5
ILT
5746 * elf.c (bfd_elf_set_dt_needed_name): Don't do anything if the
5747 BFD is not of the right type.
5748 (bfd_elf_get_needed_list): Likewise.
5749 * i386linux.c (bfd_linux_size_dynamic_sections): Likewise.
5750 * sunos.c (bfd_sunos_get_needed_list): Likewise.
5751 * xcofflink.c (XCOFF_XVECP): Define.
5752 (bfd_xcoff_link_record_set): Don't do anything if the BFD is not
5753 of the right type.
5754 (bfd_xcoff_import_symbol): Likewise.
5755 (bfd_xcoff_export_symbol): Likewise.
5756 (bfd_xcoff_link_count_reloc): Likewise.
5757 (bfd_xcoff_record_link_assignment): Likewise.
5758 (bfd_xcoff_size_dynamic_sections): Likewise.
5759
baabeb74
ILT
5760 * sunos.c (sunos_scan_ext_relocs): Only check the reloc symbol
5761 table index against the number of symbols for a base relative
5762 reloc.
5763
73246ff8
ILT
5764 * coff-rs6000.c (_bfd_xcoff_sizeof_headers): Change from macro to
5765 static function.
5766 * xcofflink.c (_bfd_xcoff_bfd_link_hash_table_create): Set
5767 full_aouthdr flag here...
5768 (_bfd_xcoff_bfd_final_link): ...not here.
5769
6ab826bd
FF
5770Tue Oct 31 12:52:02 1995 Fred Fish <fnf@cygnus.com>
5771
5772 * libelf.h: Rename to elf-bfd.h to avoid conflict with
5773 systems that have a system <libelf.h>.
5774 * Makefile.in: Globally replace libelf.h with elf-bfd.h.
5775 * bfd.c, elf.c, elf32-arc.c, elf32-gen.c, elf32-hppa.c,
5776 elf32-hppa.h, elf32-i386.c, elf32-i860.c, elf32-m68k.c,
5777 elf32-m88k.c, elf32-mips.c, elf32-ppc.c, elf32-sparc.c,
5778 elf64-gen.c, elf64-sparc.c, elfcode.h, elflink.c,
5779 elfxx-target.h: Include elf-bfd.h rather than libelf.h.
5780 * elfxx-target.h: Change libelf.h reference to elf-bfd.h.
5781
999cc186
ILT
5782Tue Oct 31 15:30:07 1995 David Mosberger-Tang <davidm@azstarnet.com>
5783
0652d579
ILT
5784 * ecoff.c (ecoff_set_symbol_info): Add new parameter weak. If
5785 set, set BSF_WEAK in symbol. Change all callers.
5786 (ecoff_get_extr): Set weakext based on BSF_WEAK.
5787 (ecoff_link_add_externals): If weakext is set, pass BSF_WEAK to
5788 _bfd_generic_link_add_one_symbol.
5789 (ecoff_indirect_link_order): Check that the section tdata relocs
5790 are not NULL before using them.
5791
999cc186
ILT
5792 * configure.in (alpha*-*-linux*): Set COREFILE to trad-core.o and
5793 define TRAD_HEADER as hosts/alphalinux.h.
5794 * configure: Rebuild.
5795 * hosts/alphalinux.h: New file.
5796 * trad-core.c (trad_unix_core_file_p): Cast u.u_ar0 to bfd_vma,
5797 not int.
5798
e6080520
ILT
5799Tue Oct 31 12:34:11 1995 Ian Lance Taylor <ian@cygnus.com>
5800
2bd0aeb9
ILT
5801 * coffcode.h (coff_slurp_symbol_table): Accept C_BCOMM and
5802 C_ECOMM storage classes.
5803
e6080520
ILT
5804 * xcofflink.c (xcoff_mark_symbol): New static function, broken out
5805 of xcoff_mark.
5806 (xcoff_mark): Call xcoff_mark_symbol.
5807 (bfd_xcoff_export_symbol): Call xcoff_mark_symbol.
5808 (bfd_xcoff_link_count_reloc): Call xcoff_mark_symbol rather than
5809 doing it by hand.
5810 (xcoff_build_ldsyms): Build a .loader symbol for an export symbol.
5811
5fe14a9f
ILT
5812Mon Oct 30 14:53:48 1995 Ian Lance Taylor <ian@cygnus.com>
5813
f630a0a4
ILT
5814 * xcofflink.c (struct xcoff_final_link_info): Add new line_filepos
5815 field.
5816 (xcoff_find_reloc): New static function.
5817 (xcoff_link_add_symbols): Use it.
5818 (_bfd_xcoff_bfd_final_link): Set finfo.line_filepos.
5819 (xcoff_link_input_bfd): Handle C_BINCL and C_EINCL. Don't
5820 relocate the value of C_DECL.
5821
5fe14a9f
ILT
5822 * elf.c (elf_fake_sections): Remove bogus BFD_ASSERT.
5823
dff77ed7
SC
5824Sat Oct 28 01:25:34 1995 steve chamberlain <sac@slash.cygnus.com>
5825
5826 * cofflink.c (_bfd_coff_generic_relocate_section): Make
5827 callback decide what goes in .relocs.
5828 * pe[i]-i386.c (TARGET_UNDERSCORE): Define.
5829 * peicode.h (pe_mkobject_hook): Only copy aouthdr if
5830 there is one.
5831
697a8fe8
ILT
5832Sat Oct 28 01:51:02 1995 Ian Lance Taylor <ian@cygnus.com>
5833
5834 * xcofflink.c (xcoff_link_add_symbols): Handle csects in the
5835 absolute section.
5836
2d7de17d
ILT
5837Fri Oct 27 18:14:39 1995 Ian Lance Taylor <ian@cygnus.com>
5838
5839 * xcofflink.c: More improvements, mostly to fix handling of
5840 constructors and a few other special cases.
5841 * coff-rs6000.c (rs6000coff_vec): Set symbol_leading_char back to
5842 zero, reverting yesterday's change.
5843 * bfd-in.h (bfd_xcoff_link_record_set): Declare.
5844 (bfd_xcoff_link_count_reloc): Declare.
5845 (bfd_xcoff_record_link_assignment): Declare.
5846 * bfd-in2.h: Rebuild.
5847
f552f751
NH
5848Fri Oct 27 14:42:15 1995 Niklas Hallqvist <niklas@appli.se>
5849
4906b2a3 5850 * PORTING, aout-arm.c, aout-encap.c, aout-target.h,
f552f751
NH
5851 aoutx.h, gen-aout.c, host-aout.c, hp300bsd.c, i386aout.c
5852 i386bsd.c, i386dynix.c, i386linux.c, i386lynx.c, i386mach3.c,
5853 i386netbsd.c, m68klynx.c, m88kmach3.c, mipsbsd.c, newsos3.c,
5854 ns32knetbsd.c, pc532-mach.c, riscix.c, sparclynx.c, sparcnetbsd.c:
5855 Change PAGE_SIZE to TARGET_PAGE_SIZE.
5856
5857 * m68knetbsd.c: Ditto as well as add support for the m68k4k object
5858 format.
5859
5860 * netbsd.h: Double ditto (incl. m68k4k support). NetBSD's text
5861 segments includes the a.out header. See to that the magic number
5862 *always* is big-endian.
5863
5864 * config.bfd: Add m68*-hp*-netbsd* case. Cross-pollinate m68k and
5865 m68k4k NetBSD configurations.
5866
5867 * configure.in, configure: Separate i386 & mips NetBSD
5868 configurations from other BSD ones. Don't assume DEC is the only
5869 thing NetBSD/mips run on. Add {m68k,ns32k,sparc}-*-netbsd*
5870 configurations. Add support for m68k4k NetBSD object format.
5871
5872 * libaout.h: Added M_68K4K_NETBSD magic.
6fd1f40d
NH
5873
5874 * m68k4knetbsd.c: New file.
f552f751
NH
5875
5876 * hosts/{m68k,sparc}nbsd.h: Don't define HOST_BIG_ENDIAN_P.
5877
5878 * hosts/nbsd.h: Define HOST_BIG_ENDIAN_P according to
5879 <machine/endian.h>.
5880
6fd1f40d
NH
5881 * hosts/mipsnbsd.h: New file.
5882
d6d44ef9
SG
5883start-sanitize-gm
5884Fri Oct 27 09:41:51 1995 Stu Grossman (grossman@cygnus.com)
5885
5886 * config.bfd: Add config stuff for mips*-*-magic* to set
5887 targ_defvec to ecoff_big_vec.
5888
5889end-sanitize-gm
867d923d
ILT
5890Thu Oct 26 14:16:47 1995 Ian Lance Taylor <ian@cygnus.com>
5891
5892 * xcofflink.c: Numerous changes to get closer to a working XCOFF
5893 linker.
5894 * libcoff-in.h (struct xcoff_tdata): Add full_aouthdr,
5895 toc_section, and entry_section fields.
5896 (struct xcoff_section_tdata): Remove ldrel_count field.
5897 * libcoff.h: Rebuild.
5898 * coffcode.h (coff_mkobject_hook): Initialize new xcoff_data
5899 fields.
5900 (coff_compute_section_file_positions): If RS6000COFF_C, generate
5901 full a.out header if full_aouthdr is set in xcoff_data.
5902 (coff_write_object_contents): Likewise. Set o_snentry and o_sntoc
5903 based on sections stored in xcoff_data.
5904 * coff-rs6000.c (xcoff_copy_private_bfd_data): Copy new xcoff_data
5905 fields.
aad2c618
ILT
5906 (xcoff_reloc_type_lookup): Handle BFD_RELOC_CTOR.
5907 (rs6000coff_vec): Set symbol_leading_char to '.'.
867d923d
ILT
5908 * coffgen.c (coff_get_symbol_info): If fix_value is set, fix the
5909 value stored in ret rather than returning a pointer value.
5910
6bd9ffdb
MM
5911Wed Oct 25 23:10:39 1995 Michael Meissner <meissner@tiktok.cygnus.com>
5912
5913 * config.bfd (powerpc{,le}-{elf,sysv4,eabi,solaris2}): Remove MAC
5914 format for now.
5915
9d14250f
JL
5916Wed Oct 25 16:19:27 1995 Jeffrey A Law (law@cygnus.com)
5917
5918 * som.c (som_slurp_string_table): Allocate the strings with malloc
5919 since they're free'd by free_cached_info.
5920 (som_slurp_symbol_table): Similarly for the symbol table.
5921
a2bd0529
PB
5922Wed Oct 25 14:59:22 1995 Per Bothner <bothner@kalessin.cygnus.com>
5923
5924 * Makefile.in (diststuff): Don't make headers.
5925
28a0c103
ILT
5926Wed Oct 25 11:32:54 1995 Ian Lance Taylor <ian@cygnus.com>
5927
356cd465
ILT
5928 * Makefile.in: Rebuild dependencies.
5929
1edd3a7b
ILT
5930 * sunos.c (bfd_sunos_record_link_assignment): Don't do anything if
5931 output_bfd is not SunOS.
5932 (bfd_sunos_size_dynamic_sections): Likewise. Don't scan relocs of
5933 non-SunOS input files.
5934
28a0c103
ILT
5935 * xcofflink.c: Extensive changes to support linking shared objects
5936 and generating a .loader section.
5937 * libcoff-in.h (struct xcoff_tdata): Add import_file_id field.
b73322d9
ILT
5938 (struct xcoff_section_tdata): Add lineno_count, first_symndx,
5939 last_symndx, and ldrel_count fields.
28a0c103
ILT
5940 * libcoff.h: Rebuild.
5941 * coff-rs6000.c (xcoff_howto_table): Correct reloc names.
5942 * coffcode.h (styp_to_sec_flags): Don't set any flags if STYP_PAD
5943 is set.
5944 * bfd-in.h (bfd_xcoff_import_symbol): Declare.
5945 (bfd_xcoff_export_symbol): Declare.
5946 (bfd_xcoff_size_dynamic_sections): Declare.
5947 * bfd-in2.h: Rebuild.
5948
aadf04f7
SS
5949Tue Oct 24 17:44:20 1995 Stan Shebs <shebs@andros.cygnus.com>
5950
5951 * configure.in: Add xcofflink.o to pmac_xcoff_vec.
5952 * configure: Rebuild.
5953 * mpw-config.in: Add xcofflink.c.o to powerpc-apple-macos.
5954 * coff-pmac.c: Include coff-rs6000.c instead of duplicating its
5955 contents.
5956 (pmac_xcoff_vec): Update to use new xcoff support.
5957 * coff-rs6000.c (xcoff_generic_stat_arch_elt): Make static.
5958 (xcoff_write_armap): Declare buf as unsigned char.
5959 * xcofflink.c (xcoff_link_add_symbols): Declare a local as PTR.
5960
5961 * mpw-make.sed: Generalize subdir_do edit.
5962
ddf4639b
JL
5963Tue Oct 24 10:25:01 1995 Jeffrey A Law (law@cygnus.com)
5964
5965 * hppabsd-core.c (make_bfd_asection): Initialize asect->filepos
5966 correctly. Don't initialize asect->vma.
5967
e7bedf65
KR
5968Fri Oct 20 13:23:48 1995 Ken Raeburn <raeburn@cygnus.com>
5969
5970 * opncls.c (_bfd_new_bfd): If _bfd_chunksize wasn't preset, use
5971 something a little less than the page size.
5972
5973Thu Oct 19 13:06:09 1995 Ian Lance Taylor <ian@cygnus.com>
5974
5975 * coff-i960.c (coff_i960_adjust_symndx): Clear *adjustedp.
5976
3a70e298
SC
5977Wed Oct 18 16:20:08 1995 steve chamberlain <sac@slash.cygnus.com>
5978
5979 * coff-i386.c (coff_i386_reloc_type_lookup): New.
5980 * coffcode.h (coff_write_object_contents): If .bss is before
5981 .data us that as data_start.
5982 * cofflink.c (_bfd_coff_generic_relocate_section): Get reloc
5983 calc correct.
5984 * peicode.h (add_data_entry): Use _cooked_size of data directory.
5985 (coff_swap_outhdr_out): Hardwire in version number.
5986
5a2846e3
KR
5987Wed Oct 18 16:50:54 1995 Ken Raeburn <raeburn@cygnus.com>
5988
3c3a5268
KR
5989 * sunos.c (sunos_add_dynamic_symbols): Rename local variables
5990 major and minor to *_vno, since the former are also macros in
5991 SunOS header files. Cast result of bfd_alloc to appropriate
5992 type.
5993
5a2846e3
KR
5994 * coffgen.c (coff_find_nearest_line): Cast used_by_bfd value
5995 before assigning to sec_data.
5996
0f6c885e
ILT
5997Wed Oct 18 13:25:17 1995 Ian Lance Taylor <ian@cygnus.com>
5998
5999 * ecoff.c (_bfd_ecoff_find_nearest_line): The offset argument is
6000 now relative to the section, not absolute.
6001 * ecofflink.c (_bfd_ecoff_locate_line): Use the right symbol to
6002 get the file name when there is a N_SO directory name. When
6003 handling stabs, remember that section->vma was added to the
6004 offset.
6005
11fa6636
ILT
6006Tue Oct 17 18:24:54 1995 Ian Lance Taylor <ian@cygnus.com>
6007
6008 * sunos.c (struct sunos_link_hash_table): Add needed field.
6009 (sunos_link_hash_table_create): Call bfd_release, not free.
6010 (sunos_link_hash_table_create): Initialize needed field.
6011 (sunos_add_dynamic_symbols): Record needed objects.
6012 (bfd_sunos_get_needed_list): New function.
6013 * bfd-in.h (bfd_sunos_get_needed_list): Declare.
6014 * bfd-in2.h: Rebuild.
6015
c974e19e
SC
6016Mon Oct 16 14:43:59 1995 steve chamberlain <sac@slash.cygnus.com>
6017
6018 * libcoff-in.h (pe_data_type.in_reloc_p): New.
6019
22a35f0b
ILT
6020Mon Oct 16 10:52:50 1995 Ian Lance Taylor <ian@cygnus.com>
6021
54406786
ILT
6022 * bfd-in.h (struct bfd_link_needed_list): Rename from
6023 bfd_elf_link_needed_list.
6024 * bfd-in2.h: Rebuild.
6025 * elf.c, elflink.h, libelf.h: Corresponding changes.
6026
dd984644
ILT
6027 Add start at AIX linker support; no shared libraries yet.
6028 * xcofflink.c: New file.
6029 * configure.in (rs600coff_vec): Use xcofflink.o.
6030 * configure: Rebuild.
6031 * libcoff-in.h (struct xcoff_tdata): Add csects and debug_indices
6032 fields.
6033 (struct xcoff_section_tdata): Define.
6034 (xcoff_section_data): Define macro.
6035 (_bfd_xcoff_bfd_link_hash_table_create): Declare.
6036 (_bfd_xcoff_bfd_link_add_symbols): Declare.
6037 (_bfd_xcoff_bfd_final_link): Declare.
6038 (_bfd_ppc_xcoff_relocate_section): Declare.
6039 * libcoff.h: Rebuild.
6040 * coff-rs6000.c: Clean up a bit.
6041 (xcoff_mkobject): Default modtype to 1L, not RE. Initialize
6042 cputype, csects, and debug_indices.
6043 (xcoff_copy_private_bfd_data): Copy cputype.
6044 (xcoff_howto_table): Rename from rs6000coff_howto_table.
6045 (xcoff_rtype2howto): Rename from rs6000coff_rtype2howto.
6046 (xcoff_reloc_type_lookup): Rename from
6047 rs6000coff_reloc_type_lookup.
6048 (coff_relocate_section): Define.
6049 (_bfd_xcoff_sizeof_headers): Define.
6050 (_bfd_xcoff_bfd_get_relocated_section_contents): Define.
6051 (_bfd_xcoff_bfd_relax_section): Define.
6052 (_bfd_xcoff_bfd_link_split_section): Define.
6053 (rs6000coff_vec): For BFD_JUMP_TABLE_LINK, use _bfd_xcoff, not
6054 coff.
6055 * coffcode.h (coff_compute_section_file_positions): If AIX,
6056 increment sofar by SMALL_AOUTSZ if not executable.
6057 (coff_write_object_contents): If AIX, always output an a.out
6058 header; if not executable, header size of SMALL_AOUTSZ.
6059 * hash.c (struct bfd_strtab_hash): Add xcoff field.
6060 (_bfd_stringtab_init): Initialize xcoff field.
6061 (_bfd_xcoff_stringtab_init): New function.
6062 (_bfd_stringtab_add): In XCOFF mode, leave two bytes for length.
6063 (_bfd_stringtab_emit): In XCOFF mode, write out length.
6064 * libbfd-in.h (_bfd_xcoff_stringtab_init): Declare.
6065 * libbfd.h: Rebuild.
6066 * Makefile.in: Rebuild dependencies.
6067 (BFD32_BACKENDS): Add xcofflink.o.
6068 (CFILES): Add xcofflink.c.
6069
22a35f0b
ILT
6070 * elf32-mips.c (mips_elf_symbol_processing): Set SEC_ALLOC, not
6071 SEC_NO_FLAGS, for .acommon section. From Peter Schauer
6072 <Peter.Schauer@Regent.E-Technik.TU-Muenchen.DE>.
6073
fb417a21
MM
6074Sat Oct 14 21:36:02 1995 Michael Meissner <meissner@tiktok.cygnus.com>
6075
6076 * coff-ppc.c (in_reloc_p): Add, clone from coff-i386.c.
6077
6078Fri Oct 13 17:48:43 1995 Ken Raeburn <raeburn@cygnus.com>
6079
6080 * acconfig.h (HAVE_SYS_PROCFS_H): Undef, with comment.
6081 * config.in: Regenerated.
6082
6083 * opncls.c (getpagesize) [!HAVE_GETPAGESIZE]: Define as 2048.
6084 (_bfd_chunksize): New variable.
6085 (_bfd_new_bfd): Set it to getpagesize() if negative, and use it
6086 for obstack chunk size.
6087 * configure.in: Check for getpagesize.
6088 * configure: Regenerated.
6089
6090 Mon Sep 25 22:49:32 1995 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
6091
6092 * trad-core.c (rawptr): Make it a local variable of
6093 ptrace_unix_core_file_p.
6094
b1e46369
SC
6095Fri Oct 13 11:22:01 1995 steve chamberlain <sac@slash.cygnus.com>
6096
6097 * coff-arm.c (in_reloc_p): New.
6098 * coff-i386.c (in_reloc_p): New.
6099 * coffcode.h: Allways include peicode.h if COFF_WITH_PE.
6100 (coff_write_object_contents): Only set has_reloc_section
6101 if PE_IMAGE.
6102 * cofflink.c (_bfd_coff_generic_relocate_section): Call
6103 in_reloc_p to decide if reloc should be emitted.
6104 * libcoff.h (pe_data_type.in_reloc_p): New.
6105 * peicode.h (pe_mkobject): Initialize in_reloc_p.
6106
ee9f09cd
ILT
6107Wed Oct 11 00:49:29 1995 Ian Lance Taylor <ian@cygnus.com>
6108
b1e46369
SC
6109 * cofflink.c (_bfd_coff_internal_syment_name): Move to coffgen.c.
6110 (_bfd_coff_read_internal_relocs): Likewise.
6111 * coffgen.c (_bfd_coff_internal_syment_name): Copy from coffgen.c.
6112 (_bfd_coff_read_internal_relocs): Likewise.
6113
ee9f09cd
ILT
6114 * elflink.h (elf_link_add_object_symbols): Correct conditions
6115 under which type and size change warnings are issued.
6116
78b31b6b
ILT
6117Tue Oct 10 18:32:46 1995 Ian Lance Taylor <ian@cygnus.com>
6118
6119 * coffgen.c (coff_count_linenumbers): Don't count line numbers for
6120 a symbol which is not in a real section.
6121 (coff_write_native_symbol): Corresponding change.
6122
6123 * cofflink.c (_bfd_coff_link_hash_newfunc): Rename from
6124 coff_link_hash_newfunc and make non-static.
6125 (_bfd_coff_link_hash_table_init): New function, broken out of
6126 _bfd_coff_link_hash_table_create.
6127 (_bfd_coff_link_hash_table_create): Use it.
6128 (process_embedded_commands): Make static.
6129 * libcoff-in.h ((_bfd_coff_link_hash_newfunc): Declare.
6130 (_bfd_coff_link_hash_table_init): Declare.
6131 * libcoff.h: Rebuild.
6132
6133 * coffcode.h (coff_mkobject_hook): If RS6000COFF_C, set cputype
6134 field in XCOFF tdata.
6135 (coff_set_arch_mach_hook): Check ifdef RS6000COFF_C, not ifdef
6136 U802ROMAGIC, for clarity. Try to set arch and machine correctly
6137 based on cputype stored in a.out header, or in n_type of initial
6138 .file symbol.
6139 (coff_write_object_contents): Set cputype correctly in a.out
6140 header.
6141 (coff_slurp_symbol_table): Add casts to file_ptr to avoid
6142 warnings.
6143 * coffswap.h (coff_swap_aouthdr_in): Swap in cputype field.
6144 (coff_swap_aouthdr_out): Swap out cputype field. Don't clear
6145 old resv1 field.
6146 * libcoff-in.h (struct xcoff_tdata): Add cputype field.
6147 * libcoff.h: Rebuild.
6148
6149 * cpu-rs6000.c (rs6000_compatible): New static function.
6150 (bfd_rs6000_arch): Use it.
6151 * cpu-powerpc.c (powerpc_compatible): New static function.
6152 (arch_info_struct): Define various flavours of PowerPC.
6153 (bfd_powerpc_arch): Use powerpc_compatible. Point at
6154 arch_info_struct.
6155
9dd7e56f
FF
6156Tue Oct 10 10:50:46 1995 Fred Fish <fnf@cygnus.com>
6157
78b31b6b 6158 * Makefile.in (FLAGS_TO_PASS): Remove BISON.
9dd7e56f 6159
8235c112
ILT
6160Tue Oct 10 01:28:29 1995 Ian Lance Taylor <ian@cygnus.com>
6161
6162 * elflink.h (elf_link_add_object_symbols): Don't warn about
6163 changing the size or type if the old definition was weak.
6164
0322af0d
ILT
6165Mon Oct 9 11:24:08 1995 Ian Lance Taylor <ian@cygnus.com>
6166
49488f2b
ILT
6167 * coffcode.h (combined_entry_type): Add fix_line field.
6168 (coff_slurp_line_table): Warn if we try to set the lineno field of
6169 a symbol twice.
6170 (coff_slurp_symbol_table): If RS6000COFF_C, handle C_BINCL and
6171 C_EINCL by setting fix_line. Fix C_BSTAT symbol value.
6172 * coffgen.c (coff_mangle_symbols): Handle fix_line.
6173 (coff_write_symbol): Only use N_DEBUG if the symbol is in the
6174 absolute section.
6175 (coff_print_symbol): Print fix_value symbols in a useful fashion.
6176 * libcoff.h: Rebuild.
6177
5f710a3a
ILT
6178 * libcoff-in.h (struct xcoff_tdata): Define.
6179 (xcoff_data): Define.
6180 * bfd.c (struct _bfd): Add xcoff_obj_data field to tdata union.
6181 * bfd-in2.h, libcoff.h: Rebuild.
6182 * coff-rs6000.c (xcoff_mkobject): New static function.
6183 (coff_mkobject): Define.
6184 (xcoff_copy_private_bfd_data): New static function.
6185 (coff_bfd_copy_private_bfd_data): Define.
6186 (rs6000coff_howto_table): Change R_TOC complain_on_overflow from
6187 signed to bitfield.
6188 (rs6000coff_vec): Add DYNAMIC to object_flags.
6189 * coffcode.h (sec_to_styp_flags): If RS6000COFF_C, handle .pad and
6190 .loader sections specially.
6191 (coff_new_section_hook): If RS6000COFF_C, get the .text and .data
6192 section alignment from the XCOFF tdata information.
6193 (coff_mkobject_hook): If RS6000COFF_C, set DYNAMIC based on
6194 F_SHROBJ, and copy the extra a.out header information into the
6195 XCOFF tdata structure.
6196 (coff_write_object_contents): If RS6000COFF_C, set F_SHROBJ,
6197 F_DYNLOAD and the extra a.out header information.
6198 (coff_slurp_symbol_table): Set BSF_NOT_AT_END for a C_EXT or
6199 C_HIDEXT symbol with attached csect information.
6200 * coffswap.h (coff_swap_aouthdr_in): If RS6000COFF_C, swap
6201 in the o_maxdata field.
6202 (coff_swap_aouthdr_out): If RS6000COFF_C, swap extra XCOFF fields.
6203 * coffgen.c (coff_renumber_symbols): Don't move any symbol to the
6204 end if BSF_NOT_AT_END is set.
3f2c5b2d 6205
0322af0d
ILT
6206 * targets.c (bfd_target): Rename _bfd_read_ar_hdr field to
6207 _bfd_read_ar_hdr_fn.
6208 * libbfd-in.h (_bfd_read_ar_hdr): Update accordingly.
6209 * bfd-in2.h, libbfd.h: Rebuild.
6210 * archive.c (_bfd_get_elt_at_filepos): Cast _bfd_read_ar_hdr
6211 return value.
6212 (do_slurp_bsd_armap, do_slurp_coff_armap): Likewise.
6213 (bfd_slurp_bsd_armap_f2): Likewise.
6214 (_bfd_slurp_extended_name_table): Likewise.
6215
3266eaff
KR
6216Fri Oct 6 16:18:35 1995 Ken Raeburn <raeburn@cygnus.com>
6217
6218 Mon Sep 25 22:49:32 1995 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
6219
6220 * archive.c (bfd_get_next_mapent): Return BFD_NO_MORE_SYMBOLS
6221 when the symbol table is empty.
6222
6223 * elf32-m68k.c (elf_m68k_size_dynamic_sections): Don't reserve
6224 space for section symbols, since we don't output them either.
6225 (elf_m68k_adjust_dynindx): Removed.
6226
6227 * ptrace-core.c (rawptr): Make it a local variable of
6228 ptrace_unix_core_file_p.
3266eaff 6229
249479fa
MM
6230Fri Oct 6 12:24:47 1995 Michael Meissner <meissner@tiktok.cygnus.com>
6231
45b5d2f0
MM
6232 * coff-rs6000.c (xcoff_write_archive_contents): Return false, not
6233 NULL.
6234
249479fa
MM
6235 * config.bfd (powerpc{,le}-{elf,sysv4,eabi,solaris2}): Add NT, and
6236 Mac object file formats.
6237
c53fac12
ILT
6238Fri Oct 6 12:04:02 1995 Ian Lance Taylor <ian@cygnus.com>
6239
4372f33f
ILT
6240 * coffgen.c (coff_fix_symbol_name): Don't try to set up file
6241 auxent if there isn't one.
6242 (coff_write_symbols): If there is no file auxent, use SYMNMLEN
6243 rather than FILNMLEN as the maximum name length.
6244
0fc9ada9
ILT
6245 * coffcode.h (bfd_coff_backend_data): Add new field
6246 _bfd_coff_print_aux.
6247 (bfd_coff_print_aux): New static function.
6248 (coff_pointerize_aux_hook (RS6000COFF_C version)): Pointerize the
6249 scnlen field of an XTY_LD csect aux entry.
6250 (coff_print_aux): New static function.
6251 (coff_slurp_symbol_table): Don't pointerize scnlen field; now done
6252 in coff_pointerize_aux_hook.
6253 (bfd_coff_std_swap_table): Initialize new field.
6254 * coffgen.c (coff_print_symbol): Call bfd_coff_print_aux.
6255 * libcoff.h: Rebuild.
6256 * coff-alpha.c (alpha_ecoff_backend_data): Initialize new field.
6257 * coff-mips.c (mips_ecoff_backend_data): Likewise.
6258
7860fe38
ILT
6259 * coffcode.h (coff_write_object_contents): On AIX, clear F_RELFLG
6260 if there are symbols, for native AIX ld compatibility.
6261
c80cc833
ILT
6262 * coffcode.h (bfd_coff_backend_data): Add new field
6263 _bfd_coff_pointerize_aux_hook.
6264 (coff_pointerize_aux_hook): Define as a function if RS6000COFF_C
6265 or I960, and as 0 otherwise.
6266 (bfd_coff_std_swap_table): Initialize new field.
6267 * libcoff.h: Rebuild.
6268 * coffgen.c (coff_pointerize_aux): Change parameters to take
6269 symbol pointer instead of type and class, and to take aux index.
6270 Call _bfd_coff_pointerize_aux_hook if it is defined.
6271 (coff_get_normalized_symtab): Always call coff_pointerize_aux.
6272 * coff-alpha.c (alpha_ecoff_backend_data): Initialize all fields.
6273 * coff-mips.c (mips_ecoff_backend_data): Likewise.
6274
c53fac12
ILT
6275 * coff-rs6000.c: Add full support for AIX archives. Rewrite old
6276 read-only/host-only support.
6277
6278 * coffcode.h (coff_slurp_symbol_table): Set C_HIDEXT symbols to be
6279 BSF_LOCAL.
d11e6b52
ILT
6280 (OTHER_GLOBAL_CLASS): Do not define to be C_HIDEXT if
6281 RS6000COFF_C.
c53fac12
ILT
6282
6283 * targets.c (bfd_target): Add _bfd_read_ar_hdr field. Modify
6284 BFD_JUMP_TABLE_ARCHIVE accordingly.
6285 * libbfd-in.h (_bfd_snarf_ar_hdr): Don't declare.
6286 (_bfd_compute_and_write_armap): Declare.
6287 (_bfd_generic_read_ar_hdr): Declare.
6288 (_bfd_read_ar_hdr): Define.
6289 (_bfd_noarchive_read_ar_hdr): Define.
6290 (_bfd_archive_bsd_read_ar_hdr): Define.
6291 (_bfd_archive_coff_read_ar_hdr): Define.
6292 * archive.c: Change all callers of _bfd_snarf_ar_hdr to call
6293 _bfd_read_ar_hdr instead.
6294 (_bfd_generic_read_ar_hdr): Rename from _bfd_snarf_ar_hdr.
6295 (_bfd_compute_and_write_armap): Rename from
6296 compute_and_write_armap. Make non-static. Change all callers.
6297 * ecoff.c (_bfd_ecoff_slurp_armap): Call _bfd_read_ar_hdr rather
6298 than _bfd_snarf_ar_hdr.
6299 * aout-target.h (MY_read_ar_hdr): Define if not defined.
6300 * ieee.c (ieee_read_ar_hdr): Define.
6301 * libecoff.h (_bfd_ecoff_read_ar_hdr): Define.
6302 * oasys.c (oasys_read_ar_hdr): Define.
6303 * som.c (som_read_ar_hdr): Define.
6304 * bfd-in2.h, libbfd.h: Rebuild.
6305
f8e47484
SC
6306Thu Oct 5 14:04:07 1995 steve chamberlain <sac@slash.cygnus.com>
6307
6308 * peicode.c (coff_swap_filehdr_in): If symptr is
6309 zero, there aren't any symbols, even if nsyms is set.
6310
2b874a2d
ILT
6311Thu Oct 5 11:45:02 1995 Ian Lance Taylor <ian@cygnus.com>
6312
aca73687
ILT
6313 * libecoff.h (struct ecoff_backend_data): Add adjust_headers
6314 field.
6315 * ecoff.c (ecoff_sec_to_styp_flags): Check for various Alpha
6316 sections, and set styp correctly for them: .got, .hash, .dynamic,
6317 .liblist, .rel.dyn, .conflic, .dynstr, .dynsym, .comment.
6318 (_bfd_ecoff_styp_to_sec_flags): Check for various Alpha section
6319 types.
6320 (ecoff_sort_hdrs): New static function.
6321 (ecoff_compute_section_file_positions): Return boolean, not void.
6322 Sort the sections by VMA before looking through them. Put the
6323 first non SEC_ALLOC section on a new page. Put every SEC_ALLOC
6324 section on an appropriate boundary within the page.
6325 (ecoff_compute_reloc_file_positions): Check return value of
6326 ecoff_compute_section_file_positions.
6327 (_bfd_ecoff_set_section_contents): Likewise.
6328 (_bfd_ecoff_write_object_contents): Check for various Alpha
6329 section types when incrementing text_size and data_size. Call
6330 adjust_headers backend function if it exists.
6331 * coff-alpha.c (alpha_adjust_headers): New static function.
6332 (alpha_ecoff_backend_data): Initialize adjust_headers field.
6333 * coff-mips.c (mips_ecoff_backend_data): Likewise.
6334
2b874a2d
ILT
6335 * hosts/i386bsd.h: Restore file incorrectly deleted on Sep 6.
6336
c780e5db
JL
6337Wed Oct 4 18:15:02 1995 Jeff Law (law@hurl.cygnus.com)
6338
6339 * rs6000-core.c (CORE_VERSION_1): Use CORE_VERSION_1 instead
6340 of ALTERNATE_AIX_CORE_FORMAT.
6341 * configure.in (aix4): No longer need CORE_FLAGS.
6342 * configure: Updated.
6343
2a01c351
KR
6344Wed Oct 4 15:36:36 1995 Ken Raeburn <raeburn@cygnus.com>
6345
6346 NS32k changes from Ian Dall:
6347 * aoutx.h (MY_final_link_relocate, MY_relocate_contents): New
6348 macros.
6349 (aout_link_input_section_std, aout_link_input_section_ext,
6350 aout_link_reloc_link_order): Call them instead of _bfd_*
6351 versions.
6352 * aout-target.h (MY_exec_header_not_counted): New macro, defaults
6353 to zero.
6354 (backend_data): Use it instead of hardcoded zero.
6355
6356 * aout-ns32k.c (CTOR_TABLE_RELOC_HOWTO): New macro.
6357 (MY_swap_std_reloc_out): Use udata.i for KEEPIT, don't call stoi.
6358
6359 * ns32knetbsd.c: Include bfd.h.
6360 (MY_text_includes_header, MY_bfd_reloc_type_lookup): New macros.
6361 (MY_bfd_reloc_type_lookup): Declare function too.
6362 * pc532-mach.c (set_sizes): Don't declare.
6363 (MY_text_includes_header, MY_exec_header_not_counted): Define.
6364 (backend_data, MY_backend_data): Don't define.
6365
6366 * config.bfd: Treat ns32k-pc532-ux* like ns32k-pc532-mach*, and
6367 ns32k-*-lites* like ns32k-*-netbsd*.
6368
6369 * hosts/nbsd.h: Swap order of sys/vmparam.h and sys/param.h, to
6370 compile on lites.
6371
5944d75b
ILT
6372Wed Oct 4 14:15:52 1995 Ian Lance Taylor <ian@cygnus.com>
6373
6374 * coffcode.h (coff_write_object_contents): Restore setting
6375 f_timdat to 0, deleted on August 22.
6376
db344f82
SC
6377Tue Oct 3 16:28:32 1995 steve chamberlain <sac@slash.cygnus.com>
6378
6379 * coffcode.h (coff_bfd_copy_private_symbol_data,
6380 coff_bfd_copy_private_section_data,
6381 coff_bfd_copy_private_bfd_data): ifdef to allow overrides.
6382 * peicode.h (coff_bfd_copy_private_bfd_data): New
6383 (pe_bfd_copy_private_bfd_data): New.
6384 (coff_swap_scnhdr_in): Swap bss size into the right place.
6385 (pe_print_private_bfd_data): Add some newlines.
5944d75b 6386
c780e5db 6387Tue Oct 3 11:53:04 1995 Jeff Law (law@hurl.cygnus.com)
97f1feda
JL
6388
6389 * som.c (setup_sections): Don't die if a space has no subspaces.
6390
3d7c42c9
ILT
6391Mon Oct 2 14:08:55 1995 Ian Lance Taylor <ian@cygnus.com>
6392
6393 * elflink.h (elf_link_add_object_symbols): Don't let a weak
6394 dynamic symbol override a common symbol. Don't change the size or
6395 type if they have been set and the new symbol is not a definition.
6396 Warn if the size or type changes.
6397
c780e5db 6398Sun Oct 1 01:34:41 1995 Jeff Law (law@hurl.cygnus.com)
709af562
JL
6399
6400 * som.c (som_begin_writing): Don't write the symbol table or
6401 symbol strings.
6402 (som_finish_writing): Write them here. Place them after the
6403 subspace data, but before the relocs.
6404
6405Fri Sep 29 11:01:55 1995 Ian Lance Taylor <ian@cygnus.com>
6406
6407 * sunos.c (sunos_add_one_symbol): Just pass false, not
6408 info->shared_library, to sunos_create_dynamic_sections.
6409 (sunos_scan_ext_relocs): Don't warn about a reloc in the .text
6410 section.
6411 (sunos_check_dynamic_reloc): Remove .text section assertion.
6412
7009e451
SS
6413Thu Sep 28 18:48:47 1995 Stan Shebs <shebs@andros.cygnus.com>
6414
6415 * config.bfd: Add powerpc-*-macos*, powerpc-*-mpw*.
6416 * configure, configure.in: Add pmac_xcoff_vec case.
6417 * Makefile.in (BFD32_BACKENDS): Add coff-pmac.o.
6418 * coff-pmac.c: New file, PowerMac XCOFF support.
6419 * coffcode.h (coff_set_arch_mach_hook): Add PowerMac case.
6420 * targets.c (pmac_xcoff_vec): Declare.
6421
6422 * mpw-config.in: Various changes to be compatible with the
6423 autoconf-based configury.
6424 * mpw-make.sed: New file, sed commands to translate Unix
6425 makefile into MPW syntax.
6426 * mpw-make.in: Remove.
6427 * hosts/mpw.h: Remove.
6428 * bfd-in.h, bfd-in2.h: If MPW, include the file that defines
6429 true and false as enums, then define TRUE_FALSE_ALREADY_DEFINED.
6430
b91537be
SC
6431Thu Sep 28 17:06:23 1995 steve chamberlain <sac@slash.cygnus.com>
6432
6433 * binary.c (binary_get_symtab): Return an empty string on error.
6434 * opncls.c (bfd_fdpenr): Change WIN32 restriction to WINGDB.
6435
30360a6f
KK
6436Thu Sep 28 15:30:44 1995 Kim Knuttila <krk@nellie>
6437
6438 * coff-ppc.c: Reformatted according to gnu conventions
6439 Removed irrelevant "if 0" code
6440
20d1e233
ILT
6441Thu Sep 28 11:19:53 1995 Ian Lance Taylor <ian@cygnus.com>
6442
69fd4fdd
ILT
6443 * hp300hpux.c (convert_sym_type): Treat secondary symbols as weak
6444 symbols rather than as indirect symbols.
6445 (MY(slurp_symbol_table)): Don't do anything special about
6446 secondary symbols.
6447
46b5a892
ILT
6448 * coffcode.h (coff_new_section_hook): Make sure that the alignment
6449 of .ctors and .dtors sections is no larger than 2.
6450
9db59230
ILT
6451 * sunos.c (sunos_add_one_symbol): Don't change
6452 bfd_link_hash_common to bfd_link_hash_new, since it may be on the
6453 undef list.
6454 (bfd_sunos_record_link_assignment): Don't put __DYNAMIC in the
6455 dynamic symbols when creating a shared library.
6456 (sunos_scan_ext_relocs): Handle relocs correctly when creating a
6457 shared library.
6458 (sunos_scan_dynamic_symbol): Don't mark the __DYNAMIC symbol as
6459 written even if it is not defined in a regular object.
6460 (sunos_write_dynamic_symbol): Use plt_offset for the address of
6461 the jump table reloc. Add an assertion. Use RELOC_JMP_SLOT
6462 rather than the constant 22.
6463 (sunos_check_dynamic_reloc): Handle creating a shared library.
6464 (sunos_finish_dynamic_link): Set the first entry in the GOT to
6465 zero when creating a shared library.
6466 * aoutx.h (NAME(aout,final_link)): If there is a symbol __DYNAMIC,
6467 write it out at the start of the symbol table.
6468
20d1e233
ILT
6469 * Makefile.in (BFD32_BACKENDS): Add coff-arm.o.
6470
a11e10fe
DE
6471Thu Sep 28 00:58:05 1995 Doug Evans <dje@deneb.cygnus.com>
6472
6473 * config.bfd: Add arm-*-coff.
6474 * configure.in, configure: Add armcoff_{little,big}_vec.
6475 * targets.c (armcoff_{little,big}_vec): Declare.
6476 (bfd_target_vector): Add armcoff_{little,big}_vec.
6477 * coff-arm.c (armcoff_{little,big}_vec): Always define.
6478
99062cfc
ILT
6479Wed Sep 27 10:37:14 1995 Ian Lance Taylor <ian@cygnus.com>
6480
6481 * targets.c (bfd_find_target): Remove debugging code.
6482
deacbe0f
KK
6483Wed Sep 27 07:23:39 1995 Kim Knuttila <krk@nellie>
6484
6485 * coff-ppc.c, pe-ppc.c, pei-ppc.c: Initial bfd for coff/PE
6486 support on powerpc.
6487 * Makefile.in: added *-ppc files
6488 * coffcode.h: ppc MAGIC, and use peicode.h rather than coffswap.h to
6489 allow pe based .o's to be shared with other tools on ppc/NT
6490 * config.bfd: added powerpc[le]-[pe|winnt] config support
6491 * configure, configure.in: added bfd_powerpc[le]_pe[i]_vec
6492 * peicode.h: Added more section flags for PE on ppc
6493 Added coff_swap_filehdr_out to allow peicode.h to be
6494 used for non-image PE files on ppc.
6495 Check for image, or not, before copying pe_opthdr
6496 * targets.c: Added new bfd's
30360a6f
KK
6497 * targets.c: Removed two inactive bfds that shouldn't have made it this
6498 far.
deacbe0f 6499
d22b02e0
MM
6500Tue Sep 26 14:06:41 1995 Michael Meissner <meissner@tiktok.cygnus.com>
6501
6502 * elf32-ppc.c (ppc_reloc_type): Rename from reloc_type, and use
6503 explicit values to initialize all relocs. Change all users.
6504 (ppc_elf_brtaken_inner): New function to handle branch predicition
6505 relocs.
6506 (ppc_elf_brtaken_reloc): Ditto.
6507 (ppc_elf_howto_raw): Use new functions. Make sure all unsupported
6508 relocs use ppc_elf_unsupported_reloc.
6509 (ppc_elf_merge_private_bfd_data): Keep track of whether an error
6510 needs to be reported.
6511 (ppc_elf_relocate_section): Support branch prediction relocs.
6512
fcf490c0
ILT
6513Tue Sep 26 12:48:05 1995 Ian Lance Taylor <ian@cygnus.com>
6514
e6cb7b41
ILT
6515 * bfd.c (bfd_assert): Remove \n from string passed to
6516 _bfd_error_handler.
6517
1af85fbb
ILT
6518 * coff-i386.c: (TWO_DATA_SECS): Don't define.
6519 * coffcode.h (bfd_coff_backend_data): Remove _bfd_make_section_hook.
6520 (bfd_coff_make_section_hook): Don't define.
6521 (coff_make_section_hook): Remove.
6522 (sec_to_styp_flags): Remove TWO_DATA_SECS case.
6523 (styp_to_sec_flags): Likewise.
6524 (coff_write_object_contents): Likewise.
6525 (bfd_coff_std_swap_table): Don't initialize make_section_hook
6526 field.
6527 * libcoff.h: Rebuild.
6528 * coffgen.c (make_a_section_from_file): Just call
6529 bfd_make_section_anyway, not bfd_make_section or
6530 bfd_coff_make_section_hook.
6531 * ecoff.c (_bfd_ecoff_make_section_hook): Remove.
6532 * libecoff.h (_bfd_ecoff_make_section_hook): Don't declare.
6533 * coff-alpha.c (alpha_ecoff_backend_data): Don't initialize
6534 make_section_hook field.
6535 * coff-mips.c (mips_ecoff_backend_data): Likewise.
6536
fcf490c0
ILT
6537 * aoutx.h (translate_from_native_sym_flags): Don't try to stuff
6538 pointers into value field for warning and indirect symbols; just
6539 leave the value field alone.
6540 * linker.c (generic_link_add_symbol_list): Use next symbol for
6541 warning and indirect symbols, rather than looking in symbol value.
6542 * ecoff.c (ecoff_set_symbol_info): Remove indirect_ptr_ptr
6543 parameter. Change all callers. Remove support for indirect
6544 symbols; it didn't work anyhow.
6545 (_bfd_ecoff_slurp_symbol_table): Remove indirect_ptr variable.
6546 * syms.c: Change comments about BSF_WARNING and BSF_INDIRECT.
6547 * bfd-in2.h: Rebuild.
6548
cc47d19a
MM
6549Mon Sep 25 16:04:09 1995 Michael Meissner <meissner@tiktok.cygnus.com>
6550
6551 * elf32-ppc.c (ppc_elf_howto_raw): For all 14-bit branch relocs,
6552 go back to telling the tools this reloc operates on 32 bits.
6553
81449d47
ILT
6554Mon Sep 25 11:48:02 1995 Ian Lance Taylor <ian@cygnus.com>
6555
7a7fbffb
ILT
6556 * aout-adobe.c (aout_adobe_callback): Use _bfd_error_handler
6557 rather than a direct fprintf.
6558 * archive.c (_bfd_write_archive_contents): Likewise.
6559 * coffcode.h (coff_slurp_symbol_table): Likewise.
6560 * elf32-ppc.c (ppc_elf_merge_private_bfd_data): Likewise.
6561 (ppc_elf_unsupported_reloc): Likewise.
6562 (ppc_elf_relocate_section): Likewise.
6563 * i386linux.c (linux_tally_symbols): Likewise.
6564 (linux_finish_dynamic_link): Likewise.
6565 * osf-core.c (osf_core_core_file_p): Likewise.
6566 * rs6000-core.c (rs6000coff_get_section_contents): Likewise.
6567 * som.c (som_sizeof_headers): Likewise.
6568 * srec.c (srec_bad_byte): Likewise.
6569 * bfd.c (bfd_assert): Likewise. Also change file to be const.
6570 * libbfd-in.h (bfd_assert): Declare first parameter const.
6571 * libbfd.h: Rebuild.
6572 * coff-a29k.c (a29k_reloc): Don't bother to fprintf; returning
6573 bfd_reloc_overflow is enough.
6574 * coff-h8300.c (rtype2howto): Don't bother to fprintf; just abort.
6575 * coff-h8500.c (rtype2howto): Likewise.
6576 * coff-z8k.c (rtype2howto): Likewise.
6577 * coffcode.h (dummy_reloc16_extra_cases): Likewise.
6578 * elf.c (_bfd_elf_get_lineno): Likewise.
6579 (_bfd_elf_no_info_to_howto): Likewise.
6580 (_bfd_elf_no_info_to_howto_rel): Likewise.
6581 * hp300hpux.c (convert_sym_type): Likewise.
6582 (MY(swap_std_reloc_in)): Likewise.
6583 * elf.c (bfd_section_from_shdr): Remove #if 0 sections.
6584
f1c6dd5d
ILT
6585 * libaout.h (struct aoutdata): Add line_buf field.
6586 * aoutx.h (NAME(aout,find_nearest_line)): Remove statics buffer
6587 and filename_buffer. Instead, use a malloc buffer stored in the
6588 new line_buf field. Remove length restrictions.
6589
f0500a41
ILT
6590 * coffgen.c (string_size): Remove static variable.
6591 (debug_string_size, debug_string_section): Likewise.
6592 (coff_fix_symbol_name): Add string_size_p, debug_string_section_p,
6593 and debug_string_size_p parameters. Use them instead of the
6594 global variables. Change all callers.
6595 (coff_write_symbol): Likewise.
6596 (coff_write_alien_symbol, coff_write_native_symbol): Likewise.
6597 (coff_write_symbols): Add local variables to replace removed
6598 global variables.
6599
25b5a53d
ILT
6600 * libcoff-in.h (struct coff_section_tdata): Add offset, i,
6601 function, and line_base fields.
6602 * libcoff.h: Rebuild.
6603 * coffgen.c (coff_find_nearest_line): Use section tdata to cache
6604 information, rather than using static variables.
6605
641ac26a
ILT
6606 * sunos.c (sunos_read_dynamic_info): Adjust offsets in an NMAGIC
6607 file. From Peter DeWolf <pld@amt.tay1.dec.com>.
6608
81449d47
ILT
6609 * init.c (initialized): Remove static variable.
6610 (bfd_init): Don't bother setting initialized.
6611 (bfd_check_init): Remove.
6612 * opncls.c (_bfd_new_bfd): Don't call bfd_check_init.
6613 * libbfd.h: Rebuild.
6614
138b9b81
PS
6615Sat Sep 23 01:22:23 1995 Peter Schauer (pes@regent.e-technik.tu-muenchen.de)
6616
6617 * rs6000-core.c (rs6000coff_core_p): Don't check the core file
6618 size for full core dumps. Copy core file header to private data.
6619 (rs6000coff_core_file_failing_command,
6620 rs6000coff_core_file_failing_signal): New functions to extract
6621 the file name and terminating signal from the core file.
6622 * coff-rs6000.c: Use them.
6623
2ffbb79a
ILT
6624Fri Sep 22 17:44:47 1995 Ian Lance Taylor <ian@cygnus.com>
6625
6626 Change arch info to be const, initialized at compile time.
6627 * archures.c: Reindent many functions. Change CONST to const.
6628 (bfd_arch_info_type): Make arch_name const. Remove disassemble;
6629 nothing set it anyhow. Make next const.
6630 (bfd_arch_info_list): Remove.
6631 (bfd_archures_list): Rename from archures_init_table. Change from
6632 a table of function pointers to a table of bfd_arch_info_type
6633 structure addresses.
6634 (bfd_scan_arch): Rewrite accordingly. Return a const pointer.
6635 (bfd_lookup_arch): Likewise.
6636 (bfd_set_arch_info): Rewrite accordingly. Change argument to be a
6637 const pointer.
6638 (bfd_default_arch_struct): Make const.
6639 (bfd_arch_init, bfd_arch_linkin): Remove.
6640 (bfd_get_arch_info): Return a const pointer.
6641 * init.c (bfd_init): Don't call bfd_arch_init.
6642 * bfd.c (struct _bfd): Make arch_info const.
6643 * bfd-in2.h: Rebuild.
6644 * libbfd.h: Rebuild.
6645 * configure.in: Put & before everything in $selarchs.
6646 * configure: Rebuild.
6647 * cpu-*.c: Change bfd_*_arch from a function which calls
6648 bfd_arch_linkin to a const structure.
6649 * ieee.c (ieee_object_p): Make arch const.
6650
02f85cda
MM
6651Fri Sep 22 16:23:18 1995 Michael Meissner <meissner@tiktok.cygnus.com>
6652
6653 * reloc.c (bfd_reloc_code_type): Add relocations to support all of
6654 PowerPC V.4.
6655 * bfd-in2.h: Regenerate.
6656 * libbfd.h: Regenerate.
6657
6658 * elf32-ppc.c (reloc_type): Update names to match current draft.
6659 (ppc_elf_howto_raw): Mark 14 bit relocs as short sized and PC
6660 relative. Update names to current V.4 draft.
6661 (ppc_elf_reloc_type_lookup): Add support for more relocations.
6662 (ppc_elf_relocate_section): Rename relocations to match draft.
6663
dd82c578
MM
6664Thu Sep 21 21:53:18 1995 Michael Meissner <meissner@cygnus.com>
6665
6666 * elf32-ppc.c (ppc_elf_merge_private_bfd_data): Allow modules
6667 compiled with -mrelocatable-lib to be linked with either normal
6668 modules or -mrelocatable modules.
6669
f69e888e
ILT
6670Wed Sep 20 12:03:26 1995 Ian Lance Taylor <ian@cygnus.com>
6671
e18c4e8f
ILT
6672 * coffcode.h (coff_write_object_contents): Clear the vstamp field
6673 in the a.out header.
6674
f69e888e
ILT
6675 * aoutx.h (NAME(aout,swap_ext_reloc_out)): Don't set r_extern for
6676 a reloc against a local symbol, even if it's not a section.
6677
a5655244
ILT
6678Tue Sep 19 17:02:26 1995 Ian Lance Taylor <ian@cygnus.com>
6679
6680 * targets.c (bfd_target): Remove unused align_power_min field.
6681 * bfd-in2.h: Rebuild.
6682 * All backends: Remove initialization of align_power_min.
6683
500d7394
SC
6684Tue Sep 19 14:02:21 1995 steve chamberlain <sac@slash.cygnus.com>
6685
6686 * peicode.h (coff_swap_scnhdr_out): Get sizes for BSS right.
500d7394 6687
049df0a8
ILT
6688Mon Sep 18 14:35:01 1995 Arne H. Juul <arnej@pvv.unit.no>
6689
6690 * config.bfd (mips-dec-netbsd*): New target.
6691 * configure.host (mips-dec-netbsd*): New host.
6692 * configure.in (mips-dec-netbsd*): New native.
6693 * configure: Rebuild.
6694
1862bbd8
ILT
6695Fri Sep 15 10:24:36 1995 Ian Lance Taylor <ian@cygnus.com>
6696
6697 Make the COFF backend linker merge common types:
6698 * cofflink.c (struct coff_debug_merge_element): Define.
6699 (struct coff_debug_merge_type): Define.
6700 (struct coff_debug_merge_hash_entry): Define.
6701 (struct coff_debug_merge_hash_table): Define.
6702 (coff_debug_merge_hash_table_init): Define.
6703 (coff_debug_merge_hash_table_free): Define.
6704 (coff_debug_merge_hash_lookup): Define.
6705 (struct coff_final_link_info): Add debug_merge field.
6706 (coff_debug_merge_hash_newfunc): New static function.
6707 (_bfd_coff_final_link): Allocate and free debug_merge table.
6708 (coff_link_input_bfd): Merge identical enum, struct and union
6709 types.
6710
a208a70f
ILT
6711Thu Sep 14 14:53:58 1995 Ian Lance Taylor <ian@cygnus.com>
6712
6713 Convert i960 COFF to use COFF backend linker.
6714 * coff-i960.c (coff_i960_relocate): Use a coff_section_data
6715 structure to store the symbol being used.
6716 (coff_i960_start_final_link): New static function.
6717 (coff_i960_relocate_section): New static function.
6718 (coff_i960_adjust_symndx): New static function.
6719 (coff_start_final_link): Define.
6720 (coff_relocate_section): Define.
6721 (coff_adjust_symndx): Define.
6722 * coffcode.h (bfd_coff_backend_data): Add new callback function
6723 _bfd_coff_start_final_link.
6724 (bfd_coff_start_final_link): Define.
6725 (coff_start_final_link): Define if not defined.
6726 (bfd_coff_std_swap_table): Add coff_start_final_link.
6727 * cofflink.c (_bfd_coff_internal_syment_name): Make globally
6728 visible.
6729 (_bfd_coff_final_link): Call bfd_coff_start_final_link if the
6730 function callback is not NULL.
6731 * libcoff-in.h (struct coff_section_tdata): Add tdata field.
6732 (_bfd_coff_internal_syment_name): Declare.
6733 * libcoff.h: Rebuild.
6734 * configure.in (icoff_big_vec): Add cofflink.o.
6735 (icoff_little_vec): Likewise.
6736 * configure: Rebuild.
6737
f0abedbe
FF
6738Wed Sep 13 17:38:23 1995 Fred Fish <fnf@rtl.cygnus.com>
6739
6740 * Makefile.in (clean-info): Remove extraneous tab from line
6741 following action.
6742
aa4b3dc5
ILT
6743Wed Sep 13 13:27:53 1995 Ian Lance Taylor <ian@cygnus.com>
6744
6745 * cofflink.c (coff_link_input_bfd): Fail if a section with no
6746 contents has relocs.
6747
4ca63811 6748Thu Sep 12 12:45:34 1995 steve chamberlain <sac@slash.cygnus.com>
beee31b1
SC
6749
6750 * coffcode.h (coff_compute_section_file_positions): Keep the
6751 raw size safe.
6752 (coff_write_object_contents): Remember if it's a relocatable
6753 file.
6754 * libcoff-in.h (pe_data_type): New member 'has_reloc_section'
6755 * peicode.h (coff_swap_filehdr_out): Clear not-reloc flag
6756 if relocatable file. Swap out saved raw size.
6757
ae115e51
ILT
6758Tue Sep 12 12:14:33 1995 Ian Lance Taylor <ian@cygnus.com>
6759
9521bac3
ILT
6760 * Makefile.in (do_maintainer_clean): Rename from do_realclean.
6761 (maintainer-clean): Rename from realclean, passing
6762 maintainer-clean down to subdirectories, but leave realclean as a
6763 synonym.
6764
4ca63811
ILT
6765 * linker.c (_bfd_generic_link_add_one_symbol): Pass symbol name to
6766 warning callback.
6767
5aa4c3ff
ILT
6768 * dep-in.sed: Remove config.h from generated dependencies.
6769
396aaeb2
ILT
6770 * sunos.c (sunos_slurp_dynamic_symtab): New static function,
6771 broken out of sunos_canonicalize_dynamic_symtab.
6772 (sunos_canonicalize_dynamic_symtab): Call new function
6773 sunos_slurp_dynamic_symtab.
6774 (sunos_add_dynamic_symbols): Add three new parameters. Return the
6775 dynamic symbol table to the caller.
6776 * aoutx.h (aout_link_add_symbols): Permit add_dynamic_symbols
6777 callback to override the symbols being read.
6778 * libaout.h (struct aout_backend_data): Add three new parameters
6779 to add_dynamic_symbols callback.
6780
ae115e51
ILT
6781 Extensive minor changes to avoid various gcc warnings. Also:
6782 * Makefile.in (BFD32_BACKENDS): Remove coff-arm.o.
6783 * archures.c (bfd_arch_info_type): Change mach field from long to
6784 unsigned long.
6785 (bfd_lookup_arch): Change machine parameter from long to unsigned
6786 long.
6787
b088e4b2
ILT
6788Mon Sep 11 10:55:47 1995 Ian Lance Taylor <ian@cygnus.com>
6789
6790 * sunos.c (sunos_scan_std_relocs): Fix BFD_ASSERT: it's OK to find
6791 a symbol with a non-zero plt_offset.
6792
1dff7902
ILT
6793Fri Sep 8 11:47:24 1995 Ian Lance Taylor <ian@cygnus.com>
6794
2b71e1e4
ILT
6795 * elfcode.h (align_file_position): Remove; not used.
6796
1dff7902
ILT
6797 * configure.in: Only check for <sys/procfs.h> on a native system,
6798 and make sure it defines prstatus_t.
6799 * configure: Rebuild.
6800
870015b1
ILT
6801Thu Sep 7 12:48:01 1995 Ian Lance Taylor <ian@cygnus.com>
6802
535c89f0
ILT
6803 * sunos.c (sunos_write_dynamic_symbol): Correct m68k abort test.
6804
936b870c
ILT
6805 * config.in: Rename from config.h.in.
6806 * configure.in: Call AC_CONFIG_HEADER with config.h:config.in.
a7873a6c 6807 Check for config.h:config.in when creating stamp-h.
936b870c 6808 * configure: Rebuild.
a7873a6c
ILT
6809 * Makefile.in (stamp-h): Depend upon config.in rather than
6810 config.h.in. Set CONFIG_HEADERS to config.h:config.in when
6811 calling config.status.
936b870c 6812
870015b1
ILT
6813 * Makefile.in (do_distclean): Remove config.h and stamp-h.
6814 (Makefile): Just rebuild Makefile.
6815 (config.h, stamp-h): New targets.
6816 * configure.in: Create stamp-h when rebuilding config.h.
6817 * configure: Rebuild.
6818
b7577823
ILT
6819Wed Sep 6 15:00:33 1995 Ian Lance Taylor <ian@cygnus.com>
6820
6821 * configure.in: Call AC_CONFIG_HEADER. Substitute
6822 HOST_64BIT_LONG. Check that various header files exist. Check
6823 that fcntl exists. Call BFD_BINARY_FOPEN. Check whether malloc
6824 and/or free need to be declared. Don't make a link to sysdep.h.
6825 Define TRAD_HEADER for various hosts.
6826 * configure: Rebuild.
6827 * configure.host: Don't set my_host. Add definitions taken from
6828 host header files for various entries. Remove entries which now
6829 do nothing.
6830 * acconfig.h: New file.
6831 * config.h.in: New file, built by autoheader.
6832 * sysdep.h: New file.
6833 * Makefile.in (do_distclean): Don't remove sysdep.h.
6834 (RECONFIG): Remove.
6835 (LOCAL_H_DEPS): New variable.
6836 ($(BFD_LIBS)): Use $(LOCAL_H_DEPS) rather than libbfd.h and
6837 $(RECONFIG).
6838 ($(BFD_MACHINES), $(BFD_BACKENDS)): Likewise.
6839 ($(OPTIONAL_BACKENDS)): Likewise.
6840 (stmp-bfd.h): Just substitute for BFD_HOST_64BIT_LONG, rather than
6841 looking through sysdep.h.
6842 * bfd-in.h (BFD_HOST_64BIT_LONG): Define; set by Makefile.
6843 (BFD_HOST_64_BIT): Define based on BFD_HOST_64BIT_LONG.
6844 (fprintf_vma, sprintf_vma): Likewise.
6845 (int64_type, uint64_type): Don't define.
6846 * bfd-in2.h: Rebuild.
6847 * archures.c, bfd.c, srec.c: Include <ctype.h>.
6848 * elfcore.h: Check HAVE_SYS_PROCFS_H rather than HAVE_PROCFS.
6849 * lynx-core.c: Include stuff from old hosts/lynx.h.
6850 * opncls.c (bfd_fdopenr): Check HAVE_FNCTL and defined (F_GETFL),
6851 rather than NO_FCNTL.
6852 * targets.c (bfd_target_list): Check HOST_HPPAHPUX and ! __STDC__
6853 rather than NATIVE_HPPAHPUX_COMPILER.
6854 * trad-core.c: Don't include <errno.h>. Include TRAD_HEADER if it
6855 is defined.
6856 * hosts/*.h: Remove all header files which merely include,
6857 declare, and define things. Leave header files which define
6858 information needed by trad-core.c.
6859
6860 * aclocal.m4 (BFD_BINARY_FOPEN): Define.
6861 (BFD_CC_FOR_BUILD): Define.
6862 * configure.in: Use BFD_CC_FOR_BUILD.
6863 * configure: Rebuild.
6864
7a93ebdd
ILT
6865Tue Sep 5 19:35:28 1995 Ian Lance Taylor <ian@cygnus.com>
6866
4c2e4d0e
ILT
6867 * aclocal.m4: Don't try to grep ../Makefile if it doesn't exist.
6868 * configure: Rebuild.
6869
7a93ebdd
ILT
6870 * coff-sparc.c (CALC_ADDEND): Don't set the addend to the value of
6871 a global symbol.
6872
866bb9e5
JM
6873Tue Sep 5 12:48:26 1995 Jason Molenda (crash@phydeaux.cygnus.com)
6874
6875 * config.bfd: i386pe_ve -> i386pe_vec.
6876
2b79a104
ILT
6877Mon Sep 4 14:02:43 1995 Ian Lance Taylor <ian@cygnus.com>
6878
f515fb2f
ILT
6879 * configure.host: Incorporate host Makefile fragments by setting
6880 shell variables.
6881 * configure.in: Call AC_PROG_CC. Substitute CFLAGS, HDEFINES and
6882 AR. Call AC_PROG_INSTALL. Substitute CC_FOR_BUILD, choosing a
6883 value based on whether the code is being compiled by a cross
6884 compiler. Don't substitute host_makefile_frag or frags.
6885 * aclocal.m4: New file to define local AC_PROG_CC.
6886 * configure: Rebuild.
6887 * Makefile.in (INSTALL): Set to @INSTALL@.
6888 (INSTALL_PROGRAM): Set to @INSTALL_PROGRAM@.
6889 (INSTALL_DATA): Set to @INSTALL_DATA@.
6890 (AR): Set to @AR@.
6891 (CC): Define as @CC@.
6892 (CFLAGS): Set to @CFLAGS@.
6893 (CC_FOR_BUILD): Set to @CC_FOR_BUILD@.
6894 (@host_makefile_frag@): Remove.
6895 (ALL_CFLAGS): Change $(HDEFINES) to @HDEFINES@. Move $(CFLAGS)
6896 after other options.
6897 (config.status): Remove dependency upon @frags@.
6898 * config/*.mh, config/README: Remove.
6899
2b79a104
ILT
6900 * config.bfd: Rewrite to incorporate the contents of the Makefile
6901 fragments by setting shell variables, rather than merely returning
6902 the name of a Makefile fragment.
6903 * configure.in: Use shell variables set by config.bfd rather than
6904 looking at the target Makefile fragment files. Don't substitute
6905 target_makefile_frag. Do substitute TDEFINES.
6906 * configure: Rebuild.
6907 * Makefile.in (@target_makefile_frag@): Remove.
6908 (ALL_CFLAGS): Change $(TDEFINES) to @TDEFINES@.
6909 * config/*.mt: Remove.
6910
2cb159a5
KR
6911Mon Sep 4 03:13:28 1995 Ken Raeburn <raeburn@cygnus.com>
6912
6913 * configure.in: Put changequote lines around "i[345]86" patterns
6914 section of core file support.
6915
ef07871c
JL
6916Sun Sep 3 11:31:58 1995 Jeff Law (law@snake.cs.utah.edu)
6917
6918 * som.c (som_bfd_print_private_bfd_data): Define to use the
6919 generic version.
6920
1613e075
SC
6921Fri Sep 1 17:08:40 1995 steve chamberlain <sac@slash.cygnus.com>
6922
6923 * peicode.h (coff_swap_aouthdr_in): Add ImageBase to
6924 entry, text_start and data_start.
6925
a52a3ce8
ILT
6926Fri Sep 1 18:06:28 1995 Ian Lance Taylor <ian@cygnus.com>
6927
a21227ef
ILT
6928 * Makefile.in (OFILES): Remove $(TDEPFILES).
6929 * config/apollo.mt (TDEPFILES): Remove.
6930 * config/README: Update.
6931
a52a3ce8
ILT
6932 * configure.in: For a native configuration, set COREFILE and
6933 COREFLAG based on the canonical host name.
6934 * configure: Rebuild.
6935 * Makefile.in: Rebuild dependencies.
6936 (ALL_CFLAGS): Add @COREFLAG@.
6937 (OFILES): Replace $(HDEPFILES) with @COREFILE@.
6938 * coff-rs6000.c: Check AIX_CORE rather than HOST_AIX for core file
6939 support routines. Check LYNX_CORE rather than HOST_LYNX.
6940 * lynx-core.c: Check LYNX_CORE rather than HOST_LYNX.
6941 * i386lynx.c: Likewise.
6942 * m68klynx.c: Likewise.
6943 * sparclynx.c: Likewise.
6944 * rs6000-core.c: Check AIX_CORE rather than HOST_AIX.
6945 * *-core.c: Comment changes.
6946 * config/decstation.mh (HDEPFILES): Remove.
6947 (HDEFINES): Remove -DTRAD_CORE.
6948 * config/irix3.mh (RANLIB): Remove.
6949 * config/irix4.mh (HDEPFILES, RANLIB): Remove.
6950 (HDEFINES): Remove -DIRIX_CORE.
6951 * config/riscos.mh (RANLIB, HDEPFILES): Remove.
6952 (HDEFINES): Remove -DTRAD_CORE.
6953 * config/ncr3000.mh (AR_FLAGS, RANLIB): Remove.
6954 * config/ultra3.mh (RANLIB): Remove.
6955 * config/aix4.mh, config/alphaosf.mh, config/amix.mh: Remove.
6956 * config/apollo.mh, config/delta68.mh, config/delta88.mh: Remove.
6957 * config/dpx2.mh, config/esix.mh, config/harris.mh: Remove.
6958 * config/hp300.mh, config/hp300bsd.mh, config/hppabsd.mh: Remove.
6959 * config/hppahpux.mh, config/hppaosf.mh: Remove.
6960 * config/i386aix.mh, config/i386bsd.mh: Remove.
6961 * config/i386linux.mh, config/i386mach3.mh: Remove.
6962 * config/i386sco.mh, config/i386v.mh, config/i386v4.mh: Remove.
6963 * config/irix5.mh, config/m88kmach3.mh, config/mipsbsd.mh: Remove.
6964 * config/mipsmach3.mh, config/news-mips.mh: Remove.
6965 * config/news.mh, config/pc532mach.mh, config/riscix.mh: Remove.
6966 * config/rs600.mh, config/rs6000lynx.mh: Remove.
6967 * config/solaris2.mh, config/stratus.mh: Remove.
6968 * config/symmetry.mh, config/sysv4.mh, config/tahoe.mh: Remove.
6969 * config/vaxbsd.mh, config/vaxult.mh, config/vaxult2.mh: Remove.
6970
d6f672b8
ILT
6971Fri Sep 1 15:18:50 1995 Kazumoto Kojima <kkojima@info.kanagawa-u.ac.jp>
6972
6973 * elflink.h (elf_bfd_final_link): Don't change a DT_INIT or
6974 DT_FINI entry if the appropriate symbol is not in the hash table.
6975
6976 * libelf.h (struct elf_backend_data): Add create_program_headers
6977 and want_hdr_in_seg fields.
6978 * elfxx-target.h (elf_backend_want_hdr_in_seg): Define if not
6979 defined.
6980 (elf_backend_create_program_headers): Likewise.
6981 (elfNN_bed): Initialize create_program_headers and
6982 want_hdr_in_seg.
6983 * elf.c (get_program_header_size): Call create_program_headers
6984 backend routine.
6985 (map_program_segments): Check want_hdr_in_seg backend field. Call
6986 create_program_headers backend routine.
6987
6988 * elf.c (assign_file_positions_except_relocs): Align non allocated
6989 sections when creating an executable.
6990
6991 * elfcode.h (elf_swap_phdr_in): Make non static.
6992 (elf_swap_phdr_out): Make non static.
6993 * libelf.h (bfd_elf32_swap_phdr_in): Declare.
6994 (bfd_elf32_swap_phdr_out): Declare.
6995 (bfd_elf64_swap_phdr_in): Declare.
6996 (bfd_elf64_swap_phdr_out): Declare.
6997
6998 * ecofflink.c (ecoff_collect_shuffle): New static function.
6999 (_bfd_ecoff_get_accumulated_pdr): New function.
7000 (_bfd_ecoff_get_accumulated_sym): New function.
7001 (_bfd_ecoff_get_accumulated_ss): New function.
7002 * libbfd-in.h (_bfd_ecoff_get_accumulated_pdr): Declare.
7003 (_bfd_ecoff_get_accumulated_sym): Declare.
7004 (_bfd_ecoff_get_accumulated_ss): Declare.
7005 * libbfd.h: Rebuild.
7006
0cb70568
ILT
7007Fri Sep 1 13:20:25 1995 Ian Lance Taylor <ian@cygnus.com>
7008
d6f672b8
ILT
7009 * libecoff.h (_bfd_ecoff_bfd_print_private_bfd_data): Fix typo.
7010
0cb70568
ILT
7011 * elflink.h (elf_link_add_object_symbols): Handle indirect and
7012 warning symbols. If any section is named .gnu.warning.XXX, treat
7013 the contents as a warning to be issued if the symbol XXX is
7014 referenced.
7015 (elf_link_output_extsym): For an indirect or warning symbol, just
7016 output the symbol it points to.
7017
7018 * linker.c (_bfd_link_hash_newfunc): Don't bother to set bfd_error
7019 if bfd_hash_allocate fails, since it will already be set.
7020 (generic_link_hash_newfunc): Likewise.
7021 (archive_hash_newfunc): Likewise.
7022 (hash_entry_bfd): New static function.
7023 (_bfd_generic_link_add_one_symbol): Pass new arguments to warning
7024 callback. Allocate a new warning using the hash table newfunc.
7025 Use bfd_hash_replace to update the entry in the hash table, rather
7026 than assuming we can copy the fields with structure assignment.
7027
7028 * hash.c (bfd_hash_replace): New function.
7029 * bfd-in.h (bfd_hash_replace): Declare.
7030 * bfd-in2.h: Rebuild.
7031
f14db880
JSC
7032Fri Sep 1 08:12:50 1995 James G. Smith <jsmith@beauty.cygnus.com>
7033
7034 * config.bfd: Add mips*vr4300-*-elf* target.
7035 * config/mipsbvr4300.mt: Added.
7036
1613e075 7037See file ChangeLog.2
e6d739eb 7038
41126f15
JK
7039\f
7040Local Variables:
c6c7035c 7041mode: change-log
41126f15 7042left-margin: 8
6ec3bb6a
ILT
7043fill-column: 74
7044version-control: never
7045End:
This page took 0.552136 seconds and 4 git commands to generate.