I think you need to not specify -DCMAKE_C(XX)?_COMPILER on the second run. Cmake doesn't let you change compiler after the first run. Even though you're configuring it as the same compiler, it might just reject those options on a rerun. http://reviews.llvm.org/D5016