gn build: Only build the TSan runtime on 64-bit platforms.
authorPeter Collingbourne <peter@pcc.me.uk>
Tue, 22 Jun 2021 21:43:58 +0000 (14:43 -0700)
committerPeter Collingbourne <peter@pcc.me.uk>
Wed, 23 Jun 2021 00:51:00 +0000 (17:51 -0700)
TSan only supports 64-bit platforms.

Differential Revision: https://reviews.llvm.org/D104755

llvm/utils/gn/secondary/compiler-rt/lib/BUILD.gn

index 5e1e9be..eff5bfe 100644 (file)
@@ -7,8 +7,10 @@ group("lib") {
     deps += [
       "//compiler-rt/lib/asan",
       "//compiler-rt/lib/builtins",
-      "//compiler-rt/lib/tsan",
       "//compiler-rt/lib/ubsan_minimal",
     ]
+    if (current_cpu == "x64" || current_cpu == "arm64") {
+      deps += [ "//compiler-rt/lib/tsan" ]
+    }
   }
 }