mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2026-04-21 23:17:16 +00:00
Work around gold bug http://sourceware.org/PR16794.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@205416 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -796,6 +796,11 @@ bool ELFObjectWriter::shouldRelocateWithSymbol(const MCSymbolRefExpr *RefA,
|
||||
if (Flags & ELF::SHF_MERGE) {
|
||||
if (C != 0)
|
||||
return true;
|
||||
|
||||
// It looks like gold has a bug (http://sourceware.org/PR16794) and can
|
||||
// only handle section relocations to mergeable sections if using RELA.
|
||||
if (!hasRelocationAddend())
|
||||
return true;
|
||||
}
|
||||
|
||||
// Most TLS relocations use a got, so they need the symbol. Even those that
|
||||
|
||||
Reference in New Issue
Block a user