aboutsummaryrefslogtreecommitdiff
path: root/ld/ldmain.c
diff options
context:
space:
mode:
authorSteve Chamberlain <sac@cygnus>1992-05-04 23:38:42 +0000
committerSteve Chamberlain <sac@cygnus>1992-05-04 23:38:42 +0000
commitbfbdc80f0adfc6000accbc468ed1764f5aeb8aae (patch)
tree5a9f6bdd80f730a1019bf33ed93fde37b1c20cad /ld/ldmain.c
parentf7ebd77dba70ddecdf1588f384666f9f5e4de535 (diff)
downloadgdb-bfbdc80f0adfc6000accbc468ed1764f5aeb8aae.zip
gdb-bfbdc80f0adfc6000accbc468ed1764f5aeb8aae.tar.gz
gdb-bfbdc80f0adfc6000accbc468ed1764f5aeb8aae.tar.bz2
* ldver.c: Bumped version to 1.96 - new release, resync with the
bfd too #. * ldexp.c, ldlang.c: now build memory shape tree in obstacks rather than with raw malloc, makes it easier to track where memory is going. * ldsym.h, ldsym.c: create obstack for all global symbols too. * ldwrite.c (ldwrite): moved malloc so only used when needed. * sa29200-sc.sh: added support for .lit, data1 and data2 sections.
Diffstat (limited to 'ld/ldmain.c')
-rw-r--r--ld/ldmain.c15
1 files changed, 8 insertions, 7 deletions
diff --git a/ld/ldmain.c b/ld/ldmain.c
index 8903936..62c7757 100644
--- a/ld/ldmain.c
+++ b/ld/ldmain.c
@@ -130,6 +130,7 @@ main (argc, argv)
output_filename = "a.out";
bfd_init();
+
#ifdef GNU960
{
int i;
@@ -158,7 +159,7 @@ main (argc, argv)
command_line.force_common_definition = false;
init_bfd_error_vector();
-
+ldsym_init();
ldfile_add_arch("");
ldfile_add_library_path("./");
config.make_executable = true;
@@ -221,14 +222,14 @@ main (argc, argv)
symbols, and possibly multiple definitions */
- if (config.text_read_only) {
- /* Look for a text section and mark the readonly attribute in it */
- asection *found = bfd_get_section_by_name(output_bfd, ".text");
- if (found == (asection *)NULL) {
- einfo("%P%F: text marked read only, but no text section present");
- }
+ if (config.text_read_only)
+ {
+ /* Look for a text section and mark the readonly attribute in it */
+ asection *found = bfd_get_section_by_name(output_bfd, ".text");
+ if (found != (asection *)NULL) {
found->flags |= SEC_READONLY;
}
+ }
if (config.relocateable_output) {
output_bfd->flags &= ~EXEC_P;