Remove a bunch of copy-paste: use common config for sanitizer lit/unit tests llvm-svn: 183407
diff --git a/compiler-rt/lib/lit.common.unit.configured.in b/compiler-rt/lib/lit.common.unit.configured.in index c726bba..1eac25b 100644 --- a/compiler-rt/lib/lit.common.unit.configured.in +++ b/compiler-rt/lib/lit.common.unit.configured.in
@@ -4,10 +4,15 @@ # Generic config options for all compiler-rt unit tests. config.target_triple = "@TARGET_TRIPLE@" config.llvm_src_root = "@LLVM_SOURCE_DIR@" +config.llvm_obj_root = "@LLVM_BINARY_DIR@" +config.llvm_tools_dir = "@LLVM_TOOLS_DIR@" config.compiler_rt_src_root = "@COMPILER_RT_SOURCE_DIR@" config.llvm_build_mode = "@LLVM_BUILD_MODE@" +# LLVM tools dir and build mode can be passed in lit parameters, +# so try to apply substitution. try: + config.llvm_tools_dir = config.llvm_tools_dir % lit.params config.llvm_build_mode = config.llvm_build_mode % lit.params except KeyError,e: key, = e.args