$ clang -O4 -faddress-sanitizer a.c /usr/bin/x86_64-pc-linux-gnu-ld: error: cannot open /usr/bin/../lib/clang/3.1/lib/linux/libclang_rt.asan-x86_64.a: No such file or directory lto-llvm.o-WK9UAf:ld-temp.o:function asan.module_ctor: error: undefined reference to '__asan_init' clang: error: linker command failed with exit code 1 (use -v to see invocation) That's because it looks for it in /usr/lib, while it is installed to /usr/lib64. There's a lot of places in clang's sources where '../lib' is hardcoded. I wonder if it's easier to fix that all or just install clang into /usr/lib (much like gcc is installed on Gentoo).
With the --with-clang-resource-dir configuration option and a few additional seds in makefiles (and one test), I have it working in 3.3_rc3 (and 9999 ebuild, though with hardcoded version there)