aboutsummaryrefslogtreecommitdiff
path: root/ld/ldexp.c
diff options
context:
space:
mode:
authorTimothy Wall <twall@alum.mit.edu>2000-02-03 18:24:46 +0000
committerTimothy Wall <twall@alum.mit.edu>2000-02-03 18:24:46 +0000
commit4cbfc3ac1993f81485d00d28aa1d37f931269c25 (patch)
tree84be9ee0a4333567940c011586b282a59ae4e361 /ld/ldexp.c
parentbea9907b2a19c3ed94595a88003b8900938b0ad9 (diff)
downloadgdb-4cbfc3ac1993f81485d00d28aa1d37f931269c25.zip
gdb-4cbfc3ac1993f81485d00d28aa1d37f931269c25.tar.gz
gdb-4cbfc3ac1993f81485d00d28aa1d37f931269c25.tar.bz2
Add octets vs bytes functionality to LD.
Diffstat (limited to 'ld/ldexp.c')
-rw-r--r--ld/ldexp.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/ld/ldexp.c b/ld/ldexp.c
index 121ed88..0c38314 100644
--- a/ld/ldexp.c
+++ b/ld/ldexp.c
@@ -456,11 +456,12 @@ fold_name (tree, current_section, allocation_done, dot)
case SIZEOF:
if (allocation_done != lang_first_phase_enum)
{
+ int opb = bfd_octets_per_byte (output_bfd);
lang_output_section_statement_type *os;
os = lang_output_section_find (tree->name.name);
check (os, tree->name.name, "SIZEOF");
- result = new_abs (os->bfd_section->_raw_size);
+ result = new_abs (os->bfd_section->_raw_size / opb);
}
else
result = invalid ();