* som.c (som_begin_writing): Fix braino (one call to align
authorJeff Law <law@redhat.com>
Sun, 20 Mar 1994 19:22:04 +0000 (19:22 +0000)
committerJeff Law <law@redhat.com>
Sun, 20 Mar 1994 19:22:04 +0000 (19:22 +0000)
        space/subspace data was done unconditionally rather than
        just for executables.)

bfd/ChangeLog
bfd/som.c

index 1fff79b48218705d833da35d876839d7245b2a99..b756f6260574815c710a587b77e9beef07578adc 100644 (file)
@@ -1,5 +1,9 @@
 Sun Mar 20 09:24:36 1994  Jeffrey A. Law  (law@snake.cs.utah.edu)
 
+       * som.c (som_begin_writing): Fix braino (one call to align
+       space/subspace data was done unconditionally rather than
+       just for executables.)
+
        * som.c (som_begin_writing): Align text in all executables to
        make HPUX kernel happy.  Fixes strip/objcopy for shared
        executables.
index a355b75f866f5057ca6674fbbe360efb00f2f230..c5ba4d70953f020c2679e06387590fcbeabd3380 100644 (file)
--- a/bfd/som.c
+++ b/bfd/som.c
@@ -3077,7 +3077,8 @@ som_begin_writing (abfd)
       while (!som_is_space (section))
        section = section->next;
 
-      current_offset = SOM_ALIGN (current_offset, PA_PAGESIZE);
+      if (abfd->flags & EXEC_P)
+       current_offset = SOM_ALIGN (current_offset, PA_PAGESIZE);
 
       /* Now look for all its subspaces.  */
       for (subsection = abfd->sections;