我收到以下消息時,我運行LLVM /鐺的cmake:cmake的錯誤建設LLVM/MacOS的
-- Performing Test COMPILER_RT_TARGET_HAS_ATOMICS - Success
CMake Error at cmake/modules/AddLLVM.cmake:589 (if):
if given arguments:
"LTO" "IN_LIST" "LLVM_DISTRIBUTION_COMPONENTS" "OR" "NOT" "LLVM_DISTRIBUTION_COMPONENTS"
Unknown arguments specified
Call Stack (most recent call first):
tools/lto/CMakeLists.txt:19 (add_llvm_library)
-- Configuring incomplete, errors occurred!
這裏是我使用的命令:
的cmake -G 「Unix的Makefile文件」 -DCMAKE_BUILD_TYPE =釋放 -DLLVM_ENABLE_LTO =在-Wno-dev的..
幾個月前,我成功地建立了LLVM /鐺5.0。但今天,我在各種目錄和子目錄上做了一個「git pull」以獲取最新的更改。
此外,我更新了我的cmake到3.8.2。但是這並沒有幫助。
每通過這裏評論者的請求是沒有no-dev
選項的輸出:
-- Performing Test COMPILER_RT_TARGET_HAS_ATOMICS - Success
CMake Warning (dev) at cmake/modules/AddLLVM.cmake:589 (if):
Policy CMP0057 is not set: Support new IN_LIST if() operator. Run "cmake
--help-policy CMP0057" for policy details. Use the cmake_policy command to
set the policy and suppress this warning.
IN_LIST will be interpreted as an operator when the policy is set to NEW.
Since the policy is not set the OLD behavior will be used.
Call Stack (most recent call first):
tools/lto/CMakeLists.txt:19 (add_llvm_library)
This warning is for project developers. Use -Wno-dev to suppress it.
CMake Error at cmake/modules/AddLLVM.cmake:589 (if):
if given arguments:
"LTO" "IN_LIST" "LLVM_DISTRIBUTION_COMPONENTS" "OR" "NOT" "LLVM_DISTRIBUTION_COMPONENTS"
Unknown arguments specified
Call Stack (most recent call first):
tools/lto/CMakeLists.txt:19 (add_llvm_library)
選項'Wno-dev'禁用警告,這可能會導致錯誤提示。 (可能''IN_LIST'不支持'cmake_minimum_required'中指定的版本。)不帶此選項運行'cmake'。 – Tsyvarev
@Tsyvarev:我已經更新了我的問題,並列出了沒有'no-dev'選項的輸出。 – Tal