/* Main program of GNU linker.
Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001,
- 2002, 2003
+ 2002, 2003, 2004
Free Software Foundation, Inc.
Written by Steve Chamberlain steve@cygnus.com
/* Nonzero means link in every member of an archive. */
bfd_boolean whole_archive;
+/* Nonzero means create DT_NEEDED entries only if a dynamic library
+ actually satisfies some reference in a regular object. */
+bfd_boolean as_needed;
+
/* TRUE if we should demangle symbol names. */
bfd_boolean demangling;
{
if (output_filename)
{
- if (output_bfd && output_bfd->iostream)
- fclose ((FILE *) (output_bfd->iostream));
+ if (output_bfd)
+ bfd_cache_close (output_bfd);
if (delete_output_file_on_failure)
unlink (output_filename);
}
and _fini symbols. We are compatible. */
link_info.init_function = "_init";
link_info.fini_function = "_fini";
- link_info.mpc860c0 = 0;
link_info.pei386_auto_import = -1;
link_info.pei386_runtime_pseudo_reloc = FALSE;
link_info.spare_dynamic_tags = 5;
link_info.flags = 0;
link_info.flags_1 = 0;
- link_info.relax_finalizing = FALSE;
+ link_info.need_relax_finalize = FALSE;
ldfile_add_arch ("");
{
if (command_line.gc_sections)
einfo ("%P%F: --gc-sections and -r may not be used together\n");
- if (link_info.mpc860c0)
- einfo (_("%P%F: -r and --mpc860c0 may not be used together\n"));
else if (command_line.relax)
einfo (_("%P%F: --relax and -r may not be used together\n"));
if (link_info.shared)