Index: test/lit.cfg =================================================================== --- test/lit.cfg +++ test/lit.cfg @@ -53,6 +53,11 @@ config.test_exec_root = os.path.join(obj_root, 'test') +# Check if we have produced a Clang with this build (in-tree) +this_clang = os.path.join(obj_root, '../../bin/clang++') +if os.path.exists(this_clang): + config.cxx_under_test = this_clang + cfg_variant = getattr(config, 'configuration_variant', 'libcxxabi') if cfg_variant: print 'Using configuration variant: %s' % cfg_variant