aboutsummaryrefslogtreecommitdiff
path: root/bfd/aout-target.h
diff options
context:
space:
mode:
authorIan Lance Taylor <ian@airs.com>1994-06-17 18:49:39 +0000
committerIan Lance Taylor <ian@airs.com>1994-06-17 18:49:39 +0000
commit785e2b52bc8455120b703e07b1db944915ecd2c3 (patch)
tree1116d394f6b78e8963276150f5efd37bf369a2e0 /bfd/aout-target.h
parentec88c42e5e4bb6daaa2b357e5347cbadef48c0cc (diff)
downloadgdb-785e2b52bc8455120b703e07b1db944915ecd2c3.zip
gdb-785e2b52bc8455120b703e07b1db944915ecd2c3.tar.gz
gdb-785e2b52bc8455120b703e07b1db944915ecd2c3.tar.bz2
* aout-target.h (MY(callback)): Set the alignments of the text,
data and bss sections after determining the architecture.
Diffstat (limited to 'bfd/aout-target.h')
-rw-r--r--bfd/aout-target.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/bfd/aout-target.h b/bfd/aout-target.h
index 2ee6ff4..cabdf0e 100644
--- a/bfd/aout-target.h
+++ b/bfd/aout-target.h
@@ -60,6 +60,15 @@ MY(callback) (abfd)
bfd_default_set_arch_mach(abfd, DEFAULT_ARCH, 0);
#endif
+ /* Now that we know the architecture, set the alignments of the
+ sections. This is normally done by NAME(aout,new_section_hook),
+ but when the initial sections were created the architecture had
+ not yet been set. */
+ obj_textsec (abfd)->alignment_power =
+ obj_datasec (abfd)->alignment_power =
+ obj_bsssec (abfd)->alignment_power =
+ bfd_get_arch_info (abfd)->section_align_power;
+
/* Don't set sizes now -- can't be sure until we know arch & mach.
Sizes get set in set_sizes callback, later. */
#if 0