CMake build of LLVM clang fails with “Unexpected f

2019-03-24 16:56发布

问题:

I want to build LLVM clang compiler, but CMake ends up with the following error message:

CMake Error at CMakeLists.txt:256 (message):
  Unexpected failure executing llvm-build: Traceback (most recent call
last):

    File "C:/.../llvm/utils/llvm-build/llvm-build", line 3, in
<module>
      import llvmbuild
    File "C:\...\llvm\utils\llvm-build\llvmbuild\__init__.py",
line 1, in
<module>
      from main import main

  ImportError: No module named main


-- Configuring incomplete, errors occurred!

I've got all needed tools installed.

  • OS: Windows 7 x64
  • Python: 3.2.2 (x86-64)
  • GnuWin32: 0.6.3

回答1:

I've found the solution.

I've just installed another version of Python: 2.x (2.72), (still x86-64)