[ELF] Loosen the condition that changes absolute relocation types to relative relocations for ARM and PPC64

Try fixing build bots after D63121

git-svn-id: https://llvm.org/svn/llvm-project/lld/trunk@363236 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/ELF/Relocations.cpp b/ELF/Relocations.cpp
index 702cac3..1398d33 100644
--- a/ELF/Relocations.cpp
+++ b/ELF/Relocations.cpp
@@ -930,7 +930,13 @@
   }
   bool CanWrite = (Sec.Flags & SHF_WRITE) || !Config->ZText;
   if (CanWrite) {
-    if ((!Sym.IsPreemptible && Type == Target->SymbolicRel) || Expr == R_GOT) {
+    // FIXME Improve the way we handle absolute relocation types that will
+    // change to relative relocations. ARM has a relocation type R_ARM_TARGET1
+    // that is similar to SymbolicRel. PPC64 may have similar relocation types.
+    if ((!Sym.IsPreemptible &&
+         (Config->EMachine == EM_ARM || Config->EMachine == EM_PPC64 ||
+          Type == Target->SymbolicRel)) ||
+        Expr == R_GOT) {
       // If this is a symbolic relocation to a non-preemptable symbol, or an
       // R_GOT, its address is its link-time value plus load address. Represent
       // it with a relative relocation.