* ldlang.c (lang_process): Ifdef out final call to

lang_size_sections again (reverting change of Nove 2), since it
	breaks the Sun4 linker.
This commit is contained in:
Ian Lance Taylor 1993-12-11 22:46:15 +00:00
parent 2b5936ff87
commit 2c6635a46f
2 changed files with 34 additions and 16 deletions

View File

@ -1,3 +1,13 @@
Sat Dec 11 14:43:44 1993 Ian Lance Taylor (ian@deneb.cygnus.com)
* ldlang.c (lang_process): Ifdef out final call to
lang_size_sections again (reverting change of Nove 2), since it
breaks the Sun4 linker.
Thu Dec 2 16:31:47 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
* configure.in (alpha-*-netware*): New target; use alpha.
Wed Dec 1 14:04:20 1993 Ken Raeburn (raeburn@cygnus.com)
* configure.in: Group targets by CPU. Merge some m68k target

View File

@ -87,6 +87,7 @@ boolean delete_output_file_on_failure = false;
/* IMPORTS */
extern char *default_target;
extern CONST char *output_filename;
extern char *current_file;
extern bfd *output_bfd;
extern enum bfd_architecture ldfile_output_architecture;
@ -785,7 +786,6 @@ open_output (name)
extern unsigned long ldfile_output_machine;
extern enum bfd_architecture ldfile_output_architecture;
extern CONST char *output_filename;
bfd *output;
if (output_target == (char *) NULL)
@ -796,7 +796,6 @@ open_output (name)
output_target = default_target;
}
output = bfd_openw (name, output_target);
output_filename = name;
if (output == (bfd *) NULL)
{
@ -2131,9 +2130,11 @@ lang_common ()
com->section);
newsec = bfd_get_section_by_name (symbfd,
name);
/* BFD backend must provide this section. */
/* This section should have been created by
enter_file_symbols if it did not already
exist. */
if (newsec == (asection *) NULL)
einfo ("%P%F: no output section %s", name);
einfo ("%P%F: no output section %s\n", name);
com->section = newsec;
}
@ -2329,14 +2330,16 @@ ldlang_add_file (entry)
}
void
lang_add_output (name)
lang_add_output (name, from_script)
CONST char *name;
int from_script;
{
lang_output_statement_type *new = new_stat (lang_output_statement,
stat_ptr);
new->name = name;
had_output_filename = true;
/* Make -o on command line override OUTPUT in script. */
if (had_output_filename == false || !from_script)
{
output_filename = name;
had_output_filename = true;
}
}
@ -2409,12 +2412,10 @@ lang_enter_output_section_statement (output_section_statement_name,
void
lang_final ()
{
if (had_output_filename == false)
{
extern CONST char *output_filename;
lang_output_statement_type *new =
new_stat (lang_output_statement, stat_ptr);
lang_add_output (output_filename);
}
new->name = output_filename;
}
/* Reset the current counters in the regions */
@ -2570,10 +2571,17 @@ lang_process ()
/* Final stuffs */
ldemul_finish ();
#if 0
/* DO NOT REENABLE THIS CALL. IF THIS CALL IS MADE, THE SUN4 LINKER
CAN NOT BOOTSTRAP!! No, I don't know why, but don't change it
unless you fix it. */
/* Size up the sections. */
lang_size_sections (statement_list.head,
abs_output_section,
&(statement_list.head), 0, (bfd_vma) 0, false);
#endif
lang_finish ();
}
@ -2801,6 +2809,6 @@ lang_add_output_format (format, from_script)
CONST char *format;
int from_script;
{
if (!from_script || output_target == NULL)
if (output_target == NULL || !from_script)
output_target = format;
}