Export TSAN_RUNTIME_LIBRARY make variable

TSAN_RUNTIME_LIBRARY is used by external/clang/Android.mk to get the
name of the per-arch TSAN runtime.  This CL also factors-out common code
out of functions that construct names of the sanitizer libraries.

Test: python external/clang/build.py with all CLs in this topic

Change-Id: Ie5fac242c0d5a9296ab8936db927a4c934061aa4
This commit is contained in:
Pirama Arumuga Nainar
2017-03-27 11:00:38 -07:00
parent e28c098504
commit 16b626b827
2 changed files with 12 additions and 7 deletions

View File

@@ -209,6 +209,7 @@ func makeVarsToolchain(ctx android.MakeVarsContext, secondPrefix string,
if target.Os.Class == android.Device {
ctx.Strict(secondPrefix+"ADDRESS_SANITIZER_RUNTIME_LIBRARY", strings.TrimSuffix(config.AddressSanitizerRuntimeLibrary(toolchain), ".so"))
ctx.Strict(secondPrefix+"UBSAN_RUNTIME_LIBRARY", strings.TrimSuffix(config.UndefinedBehaviorSanitizerRuntimeLibrary(toolchain), ".so"))
ctx.Strict(secondPrefix+"TSAN_RUNTIME_LIBRARY", strings.TrimSuffix(config.ThreadSanitizerRuntimeLibrary(toolchain), ".so"))
}
// This is used by external/gentoo/...