about summary refs log tree commit diff
path: root/src/librustc_tsan/build.rs
AgeCommit message (Collapse)AuthorLines
2020-01-09Remove sanitizer runtime cratesTomasz Miąsko-30/+0
2019-12-22Format the worldMark Rousskov-1/+1
2019-09-13Fix build script sanitizer check.Eric Huss-0/+1
2019-09-05Better way of conditioning the sanitizer buildsXimin Luo-0/+3
Previously the build would take the presence of the LLVM_CONFIG envvar to mean that the sanitizers should be built, but this is a common envvar that could be set for reasons unrelated to the rustc sanitizers. This commit adds a new envvar RUSTC_BUILD_SANITIZERS and uses it instead.
2019-02-06librustc_tsan => 2018Taiki Endo-3/+0
2019-01-26Workaround presence of LLVM library in stage0/libMark Rousskov-0/+2
This commit works around the newly-introduced LLVM shared library. This is needed such that llvm-config run from librustc_llvm's build script can correctly locate it's own LLVM, not the one in stage0/lib. The LLVM build system uses the DT_RUNPATH/RUNPATH header within the llvm-config binary, which we want to use, but because Cargo always adds the host compiler's "libdir" (stage0/lib in our case) to the dynamic linker's search path, we weren't properly finding the freshly-built LLVM in llvm/lib. By restoring the environment variable setting the search path to what bootstrap sees, the problem is resolved and librustc_llvm correctly links and finds the appropriate LLVM. Several run-make-fulldeps tests are also updated with similar handling.
2018-12-25Remove licensesMark Rousskov-10/+0
2018-09-29Rename sanitizer runtime libraries on OSXAlex Crichton-0/+1
Currently we ship sanitizer libraries as they're built, but these names unfortunately conflict with the names of the sanitizer libraries installed on the system. If a crate, for example, links in C code that wants to use the system sanitizer and the Rust code doesn't use sanitizers at all, then using `cargo` may accidentally pull in the Rust-installed sanitizer library due to a conflict in names. This change is intended to be entirely transparent for Rust users of sanitizers, it should only hopefully improve our story with other users! Closes #54134
2018-07-18Don't build twice the sanitizers on LinuxAlex Crichton-2/+2
This commit is an attempted fix at #50887. It was noticed that on that issue we're building both x86_64 and i386 versions of libraries, but we only actually need the x86_64 versions! This hopes that the build race condition exhibited in #50887 is connected to building both architectures and/or building a lot of libraries, so this should help us build precisely what we need and no more.
2017-06-30rustc_{a,l,m,t}san: re-run build script if env var LLVM_CONFIG changesVenkata Giri Reddy-0/+1
2017-04-25Support AddressSanitizer and ThreadSanitizer on x86_64-apple-darwin.kennytm-3/+2
ASan and TSan are supported on macOS, and this commit enables their support. The sanitizers are always built as *.dylib on Apple platforms, so they cannot be statically linked into the corresponding `rustc_?san.rlib`. The dylibs are directly copied to `lib/rustlib/x86_64-apple-darwin/lib/` instead. Note, although Xcode also ships with their own copies of ASan/TSan dylibs, we cannot use them due to version mismatch. There is a caveat: the sanitizer libraries are linked as @rpath, so the user needs to additionally pass `-C rpath`: rustc -Z sanitizer=address -C rpath file.rs ^~~~~~~~ Otherwise there will be a runtime error: dyld: Library not loaded: @rpath/libclang_rt.asan_osx_dynamic.dylib Referenced from: /path/to/executable Reason: image not found Abort trap: 6 The next commit includes a temporary change in compiler to force the linker to emit a usable @rpath.
2017-03-04Automate timestamp creation and build skipping for native librariesVadim Petrochenkov-9/+5
Add comments
2017-03-04Build compiler-rt and sanitizers only onceVadim Petrochenkov-9/+12
2017-03-04Add/remove `rerun-if-changed` when necessaryVadim Petrochenkov-2/+0
2017-02-08use helper function in the rebuild logic of the rustc_*san cratesJorge Aparicio-15/+4
2017-02-08sanitizer supportJorge Aparicio-0/+50