Skip to content
This repository was archived by the owner on Mar 28, 2020. It is now read-only.

Commit f163a95

Browse files
committed
tools like nm and ar only need register_claim_file and add_symbols. Don't abort
if other hooks are missing. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@64812 91177308-0d34-0410-b5e6-96231b3b80d8
1 parent 97b6e2c commit f163a95

File tree

1 file changed

+10
-5
lines changed

1 file changed

+10
-5
lines changed

tools/gold/gold-plugin.cpp

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -142,11 +142,16 @@ ld_plugin_status onload(ld_plugin_tv *tv) {
142142
}
143143
}
144144

145-
if (!registeredClaimFile || !registeredAllSymbolsRead || !registeredCleanup ||
146-
!add_symbols || !get_symbols || !add_input_file) {
147-
(*message)(LDPL_ERROR, "Not all hooks registered for LLVMgold.");
148-
return LDPS_ERR;
149-
}
145+
if (!registeredClaimFile)
146+
{
147+
(*message)(LDPL_ERROR, "register_claim_file not passed to LLVMgold.");
148+
return LDPS_ERR;
149+
}
150+
if (!add_symbols)
151+
{
152+
(*message)(LDPL_ERROR, "add_symbols not passed to LLVMgold.");
153+
return LDPS_ERR;
154+
}
150155

151156
return LDPS_OK;
152157
}

0 commit comments

Comments
 (0)