From Cary Coutant: preliminary shared library support.

This commit is contained in:
Ian Lance Taylor
2007-10-16 23:23:08 +00:00
parent a360aedd0f
commit 436ca963fd
9 changed files with 114 additions and 30 deletions

View File

@ -411,7 +411,7 @@ void
Layout::create_initial_dynamic_sections(const Input_objects* input_objects,
Symbol_table* symtab)
{
if (!input_objects->any_dynamic())
if (parameters->doing_static_link())
return;
const char* dynamic_name = this->namepool_.add(".dynamic", false, NULL);
@ -545,7 +545,7 @@ Layout::finalize(const Input_objects* input_objects, Symbol_table* symtab)
this->create_note_section();
Output_segment* phdr_seg = NULL;
if (input_objects->any_dynamic())
if (!parameters->doing_static_link())
{
// There was a dynamic object in the link. We need to create
// some information for the dynamic linker.