Failed to building (svn/git/dev version) cross-compiling for powerpc

I’m interested in PowerPC development and I tried to build LLVM for cross-compiling today and I got the following error:

[ 94%] Building CXX object tools/llvm-config/CMakeFiles/llvm-config.dir/llvm-config.cpp.o
/home/vinicius/Projetos/llvm/tools/llvm-config/llvm-config.cpp:45:35: fatal error: No such file or directory
 #include ""
compilation terminated.
tools/llvm-config/CMakeFiles/llvm-config.dir/build.make:58: recipe for target 'tools/llvm-config/CMakeFiles/llvm-config.dir/llvm-config.cpp.o' failed
make[2]: *** [tools/llvm-config/CMakeFiles/llvm-config.dir/llvm-config.cpp.o] Error 1
CMakeFiles/Makefile2:7101: recipe for target 'tools/llvm-config/CMakeFiles/llvm-config.dir/all' failed
make[1]: *** [tools/llvm-config/CMakeFiles/llvm-config.dir/all] Error 2
Makefile:136: recipe for target 'all' failed
make: *** [all] Error 2

I don’t know how to fix and I’d appreciate any help.

The options I used to compile were:


The “version” I’m using is from the git mirror:

commit 94b3a88395ff0ea6c253efe5dd2b9d400ffe7c9d
Author: Jordan Rose <>
Date:   Wed Jan 29 19:14:23 2014 +0000

    Remove C++11ism from r200407.
    git-svn-id: []( 91177308-0d34-0410-b5e6-96231b3b80d8

I already have a “normal” (non cross-compiling) and stable (3.4) llvm installed on my system (ArchLinux, where everything is at the latest release, there is no separation of *-dev packages and they avoid to apply local patches on top of upstream code).

[…] and I got the following error: […]

I figured out my problem. I solved it using:

cmake -DPYTHON_EXECUTABLE=/usr/bin/python2

So, it wasn’t related to cross-compiling at all.

For anyone who encounters a problem with similar characteristics, the solution could be the same.