ld: Issue an error for GC on __patchable_function_entries section
[binutils-gdb.git] / ld / ldexp.c
index 1fda65d714836f12a8b2351d0c5162ca554d631a..6d1457b929abd027d413b882cf058e874178ffe2 100644 (file)
@@ -730,7 +730,10 @@ fold_name (etree_type *tree)
                                            tree->name.name,
                                            TRUE, FALSE, TRUE);
          if (!h)
-           einfo (_("%F%P: bfd_link_hash_lookup failed: %E\n"));
+           {
+             if (expld.phase != lang_first_phase_enum)
+               einfo (_("%F%P: bfd_link_hash_lookup failed: %E\n"));
+           }
          else if (h->type == bfd_link_hash_defined
                   || h->type == bfd_link_hash_defweak)
            {