void
Symbol::set_undefined()
{
- gold_assert(this->is_predefined_);
this->source_ = IS_UNDEFINED;
this->is_predefined_ = false;
}
gold_assert(ret != NULL);
was_undefined = ret->is_undefined();
- was_common = ret->is_common();
+ // Commons from plugins are just placeholders.
+ was_common = ret->is_common() && ret->object()->pluginobj() == NULL;
this->resolve(ret, sym, st_shndx, is_ordinary, orig_st_shndx, object,
version);
ret = this->get_sized_symbol<size>(insdefault.first->second);
was_undefined = ret->is_undefined();
- was_common = ret->is_common();
+ // Commons from plugins are just placeholders.
+ was_common = ret->is_common() && ret->object()->pluginobj() == NULL;
this->resolve(ret, sym, st_shndx, is_ordinary, orig_st_shndx, object,
version);
}
// Keep track of common symbols, to speed up common symbol
- // allocation.
- if (!was_common && ret->is_common())
+ // allocation. Don't record commons from plugin objects;
+ // we need to wait until we see the real symbol in the
+ // replacement file.
+ if (!was_common && ret->is_common() && ret->object()->pluginobj() == NULL)
{
if (ret->type() == elfcpp::STT_TLS)
this->tls_commons_.push_back(ret);
const char* name = sym_names + st_name;
+ if (strcmp (name, "__gnu_lto_slim") == 0)
+ gold_info(_("%s: plugin needed to handle lto object"),
+ relobj->name().c_str());
+
bool is_ordinary;
unsigned int st_shndx = relobj->adjust_sym_shndx(i + symndx_offset,
sym.get_st_shndx(),