[CMake] Use ExternalProject to build MSan-ified version of libcxx for unit tests.

This change lets MSan rely on libcxx's own build system instead of manually
compiling its sources and setting up all the necessary compile flags. It would
also simplify compiling libcxx with another sanitizers (in particular, TSan).

The tricky part is to make sure libcxx is reconfigured/rebuilt when Clang or
MSan runtime library is changed. "clobber" step used in this patch works well
for me, but it's possible it would break for other configurations - will
watch the buildbots.


git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@208451 91177308-0d34-0410-b5e6-96231b3b80d8
InstrProf: Test the functions in the runtime

Check that the profile runtime works as expected.  This tests the
functions that are meant to be available to advanced users.

In particular, check that the `atexit()` hook can be disabled by
defining a custom `__llvm_profile_runtime` variable, that the libc
dependencies are optional, and that the various functions for writing
out files work for basic cases.

git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@208460 91177308-0d34-0410-b5e6-96231b3b80d8
InstrProf: Pacify buildbots after r208460

git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@208462 91177308-0d34-0410-b5e6-96231b3b80d8
InstrProf: Remove redundant declaration

git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@208464 91177308-0d34-0410-b5e6-96231b3b80d8