* h8300hms.em, h8300hms.sc-sh: do the right thing for -r
* ldexp.c: lint * ldlang.c(open_output): set the target arch and machine as soon as we can. (lang_size_sections): use new macros for setting vma * ldwrite.c: lint
This commit is contained in:
parent
7634ebc804
commit
30d1a3904f
4 changed files with 35 additions and 20 deletions
|
@ -1,3 +1,11 @@
|
||||||
|
Thu Jun 18 09:38:56 1992 Steve Chamberlain (sac@thepub.cygnus.com)
|
||||||
|
|
||||||
|
* h8300hms.em, h8300hms.sc-sh: do the right thing for -r
|
||||||
|
* ldexp.c: lint
|
||||||
|
* ldlang.c(open_output): set the target arch and machine as soon
|
||||||
|
as we can. (lang_size_sections): use new macros for setting vma
|
||||||
|
* ldwrite.c: lint
|
||||||
|
|
||||||
Mon Jun 15 08:47:43 1992 Michael Tiemann (tiemann@rtl.cygnus.com)
|
Mon Jun 15 08:47:43 1992 Michael Tiemann (tiemann@rtl.cygnus.com)
|
||||||
|
|
||||||
* configure.in (my_target): Accept m680?0 for wrs as vxworks68.
|
* configure.in (my_target): Accept m680?0 for wrs as vxworks68.
|
||||||
|
|
|
@ -53,10 +53,10 @@ static char *h8300hms_script =
|
||||||
#include "h8300hms.x"
|
#include "h8300hms.x"
|
||||||
;
|
;
|
||||||
static char *h8300hms_script_option_Ur =
|
static char *h8300hms_script_option_Ur =
|
||||||
#include "h8300hms.xu"
|
#include "h8300hms.x"
|
||||||
;
|
;
|
||||||
static char *h8300hms_script_option_r =
|
static char *h8300hms_script_option_r =
|
||||||
#include "h8300hms.xr"
|
#include "h8300hms.x"
|
||||||
;
|
;
|
||||||
|
|
||||||
static char *h8300hms_get_script()
|
static char *h8300hms_get_script()
|
||||||
|
|
|
@ -16,23 +16,23 @@ SECTIONS
|
||||||
{
|
{
|
||||||
*(.text)
|
*(.text)
|
||||||
*(.strings)
|
*(.strings)
|
||||||
${RELOCATING+_etext = .;}
|
_etext = .;
|
||||||
} ${RELOCATING+ > ram}
|
} ${RELOCATING+ > ram}
|
||||||
.data :
|
.data :
|
||||||
{
|
{
|
||||||
*(.data)
|
*(.data)
|
||||||
${RELOCATING+_edata = .;}
|
_edata = .;
|
||||||
} ${RELOCATING+ > ram}
|
} ${RELOCATING+ > ram}
|
||||||
.bss :
|
.bss :
|
||||||
{
|
{
|
||||||
${RELOCATING+ _bss_start = .;}
|
${RELOCATING+ _bss_start = .};
|
||||||
*(.bss)
|
*(.bss)
|
||||||
*(COMMON)
|
*(COMMON)
|
||||||
${RELOCATING+ _end = .};
|
${RELOCATING+ _end = .};
|
||||||
} ${RELOCATING+ >ram}
|
} ${RELOCATING+ >ram}
|
||||||
.stack :
|
.stack :
|
||||||
{
|
{
|
||||||
${RELOCATING+_stack = .;}
|
_stack = .;
|
||||||
*(.stack)
|
*(.stack)
|
||||||
} ${RELOCATING+ > topram}
|
} ${RELOCATING+ > topram}
|
||||||
}
|
}
|
||||||
|
|
35
ld/ldlang.c
35
ld/ldlang.c
|
@ -714,30 +714,37 @@ static bfd *
|
||||||
DEFUN (open_output, (name),
|
DEFUN (open_output, (name),
|
||||||
CONST char *CONST name)
|
CONST char *CONST name)
|
||||||
{
|
{
|
||||||
|
extern unsigned long ldfile_output_machine;
|
||||||
|
extern enum bfd_architecture ldfile_output_architecture;
|
||||||
|
|
||||||
extern CONST char *output_filename;
|
extern CONST char *output_filename;
|
||||||
bfd *output;
|
bfd *output;
|
||||||
|
|
||||||
if (output_target == (char *) NULL)
|
if (output_target == (char *) NULL)
|
||||||
{
|
{
|
||||||
if (current_target != (char *) NULL)
|
if (current_target != (char *) NULL)
|
||||||
output_target = current_target;
|
output_target = current_target;
|
||||||
else
|
else
|
||||||
output_target = default_target;
|
output_target = default_target;
|
||||||
}
|
}
|
||||||
output = bfd_openw (name, output_target);
|
output = bfd_openw (name, output_target);
|
||||||
output_filename = name;
|
output_filename = name;
|
||||||
|
|
||||||
if (output == (bfd *) NULL)
|
if (output == (bfd *) NULL)
|
||||||
|
{
|
||||||
|
if (bfd_error == invalid_target)
|
||||||
{
|
{
|
||||||
if (bfd_error == invalid_target)
|
einfo ("%P%F target %s not found\n", output_target);
|
||||||
{
|
|
||||||
einfo ("%P%F target %s not found\n", output_target);
|
|
||||||
}
|
|
||||||
einfo ("%P%F problem opening output file %s, %E", name);
|
|
||||||
}
|
}
|
||||||
|
einfo ("%P%F problem opening output file %s, %E", name);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* output->flags |= D_PAGED;*/
|
||||||
|
|
||||||
/* output->flags |= D_PAGED;*/
|
|
||||||
bfd_set_format (output, bfd_object);
|
bfd_set_format (output, bfd_object);
|
||||||
|
bfd_set_arch_mach(output,
|
||||||
|
ldfile_output_architecture,
|
||||||
|
ldfile_output_machine);
|
||||||
return output;
|
return output;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1446,7 +1453,7 @@ DEFUN (lang_size_sections, (s, output_section_statement, prev, fill,
|
||||||
if (os->bfd_section == &bfd_abs_section)
|
if (os->bfd_section == &bfd_abs_section)
|
||||||
{
|
{
|
||||||
/* No matter what happens, an abs section starts at zero */
|
/* No matter what happens, an abs section starts at zero */
|
||||||
os->bfd_section->vma = 0;
|
bfd_set_section_vma (0, os->bfd_section, 0);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
@ -1481,7 +1488,7 @@ DEFUN (lang_size_sections, (s, output_section_statement, prev, fill,
|
||||||
|
|
||||||
|
|
||||||
dot = align_power (dot, os->bfd_section->alignment_power);
|
dot = align_power (dot, os->bfd_section->alignment_power);
|
||||||
os->bfd_section->vma = dot;
|
bfd_set_section_vma (0, os->bfd_section, dot);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue