Implement --just-symbols, including -R FILE. Fix symbol values when
[deliverable/binutils-gdb.git] / gold / object.cc
index f82827c3b2f36299ec26810c5bef8cbde4f1da3a..1adb851ba1dd9f2e4f251cb7aaa75f7da6363511 100644 (file)
@@ -574,6 +574,17 @@ Sized_relobj<size, big_endian>::do_layout(Symbol_table* symtab,
   std::vector<Map_to_output>& map_sections(this->map_to_output());
   map_sections.resize(shnum);
 
+  // If we are only linking for symbols, then there is nothing else to
+  // do here.
+  if (this->input_file()->just_symbols())
+    {
+      delete sd->section_headers;
+      sd->section_headers = NULL;
+      delete sd->section_names;
+      sd->section_names = NULL;
+      return;
+    }
+
   // Whether we've seen a .note.GNU-stack section.
   bool seen_gnu_stack = false;
   // The flags of a .note.GNU-stack section.
This page took 0.027234 seconds and 4 git commands to generate.