Reusing the LLVM cmake code is preferred. Once that is fixed up, LGTM. http://reviews.llvm.org/D6985 EMAIL PREFERENCES http://reviews.llvm.org/settings/panel/emailpreferences/