cmake版本3.5.1
ubuntu 16.04LTS
我想在ubuntu上编译llvm,请遵循 git wiki:
$ git克隆-b llvm-4.0 https://github.com/obfuscator-llvm/obfuscator.git
$ mkdir 构建
$ cd 构建
$ cmake -DCMAKE_BUILD_TYPE=发布../obfuscator/
当我执行
cmake -DCMAKE_BUILD_TYPE=Release ../obfuscator/
时,报告ab错误:
-- Performing Test CXX_SUPPORTS_NO_NESTED_ANON_TYPES_FLAG
-- Performing Test CXX_SUPPORTS_NO_NESTED_ANON_TYPES_FLAG - Failed
CMake Error at cmake/modules/AddLLVM.cmake:1163 (add_custom_target):
add_custom_target cannot create target "check-llvm-bindings-ocaml"
because another target with the same name already exists.The
existing target is a custom target created in source directory
"/home/ryu/Ollvm/obfuscator/test". See documentation for policy
CMP0002 for more details.
Call Stack (most recent call first):
cmake/modules/AddLLVM.cmake:1226 (add_lit_target)
test/CMakeLists.txt:150 (add_lit_testsuites)
我不知道 check-llvm-bindings-ocaml 是什么,以及如何解决这个问题?你能帮助我吗?谢谢谢谢谢谢!!!
我遇到了同样的问题,下面的命令可以解决它:
cmake -G "Unix Makefiles" -DCMAKE_BUILD_TYPE=Release DLLVM_INCLUDE_TESTS=OFF
仅供参考: https://github.com/obfuscator-llvm/obfuscator/issues/71
亲爱的 Ebrahimi 错字:“DLLVM_INCLUDE_TESTS=OFF”前面漏掉了一个连字符!