It's not a real code review because I'm not an expert in cmake. Just want to say that I've checked this patch by the Clang cross-compilation for MIPS target. The patch solves the problem with liblzma. http://llvm-reviews.chandlerc.com/D1604