c++ - 我如何系统地检查可能的错误以使设置成为可能?
问题描述
[在这篇文章中提供了额外/修订的信息,以纳入可能的评论]
对于任何有经验的用户,
我想根据以下文档在我的 Mac OSX 中设置 MeTA 工具:https ://meta-toolkit.org/setup-guide.html
步骤1:brew update
第2步:brew install cmake jemalloc lzlib icu4c
输出 2:
> Warning: Treating cmake as a formula. For the cask, use
> homebrew/cask/cmake Warning: cmake 3.18.4 is already installed and
> up-to-date To reinstall 3.18.4, run `brew reinstall cmake` Warning:
> jemalloc 5.2.1_1 is already installed and up-to-date To reinstall
> 5.2.1_1, run `brew reinstall jemalloc` Warning: lzlib 1.11 is already installed and up-to-date To reinstall 1.11, run `brew reinstall lzlib`
> ==> Downloading https://homebrew.bintray.com/bottles/icu4c-67.1.high_sierra.bott
> ==> Downloading from https://d29vzk4ow07wi7.cloudfront.net/0720bd47f020d5ca895ae
> ######################################################################## 100.0%
> ==> Pouring icu4c-67.1.high_sierra.bottle.tar.gz
> ==> Caveats icu4c is keg-only, which means it was not symlinked into /usr/local, because macOS provides libicucore.dylib (but nothing
> else).
>
> If you need to have icu4c first in your PATH run: echo 'export
> PATH="/usr/local/opt/icu4c/bin:$PATH"' >>
> /Users/yuenfannie/.bash_profile echo 'export
> PATH="/usr/local/opt/icu4c/sbin:$PATH"' >>
> /Users/yuenfannie/.bash_profile
>
> For compilers to find icu4c you may need to set: export
> LDFLAGS="-L/usr/local/opt/icu4c/lib" export
> CPPFLAGS="-I/usr/local/opt/icu4c/include"
>
> ==> Summary /usr/local/Cellar/icu4c/67.1: 258 files, 71.4MB
> ==> `brew cleanup` has not been run in 30 days, running now... Error: Permission denied @ apply2files -
> /usr/local/share/ghostscript/9.07/Resource/Font/logo10.pfb
第 3 步:git clone https://github.com/meta-toolkit/meta.git
第4步:cd meta/
第 5 步:
# set up submodules
git submodule update --init --recursive
第 6 步:
mkdir build
cd build
cp ../config.toml .
第 7 步:
# configure and build the project
CXX=clang++ cmake ../ -DCMAKE_BUILD_TYPE=Release -DICU_ROOT=/usr/local/opt/icu4c
make
先前的输出 7:
-- The C compiler identification is AppleClang 10.0.0.10001145
-- The CXX compiler identification is AppleClang 10.0.0.10001145
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/cc - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Looking for pthread.h
-- Looking for pthread.h - found
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD - Success
-- Found Threads: TRUE
-- Found ZLIB: /usr/lib/libz.dylib (found version "1.2.11")
-- Looking for lzma_auto_decoder in /usr/local/lib/liblzma.dylib
-- Looking for lzma_auto_decoder in /usr/local/lib/liblzma.dylib - found
-- Looking for lzma_easy_encoder in /usr/local/lib/liblzma.dylib
-- Looking for lzma_easy_encoder in /usr/local/lib/liblzma.dylib - found
-- Looking for lzma_lzma_preset in /usr/local/lib/liblzma.dylib
-- Looking for lzma_lzma_preset in /usr/local/lib/liblzma.dylib - found
-- Found LibLZMA: /usr/local/lib/liblzma.dylib (found version "5.0.4")
-- Searching for ICU 58.2
CMake Warning (dev) at deps/meta-cmake/FindOrBuildICU.cmake:31 (find_package):
Policy CMP0074 is not set: find_package uses <PackageName>_ROOT variables.
Run "cmake --help-policy CMP0074" for policy details. Use the cmake_policy
command to set the policy and suppress this warning.
CMake variable ICU_ROOT is set to:
/usr/local/opt/icu4c
For compatibility, CMake is ignoring the variable.
Call Stack (most recent call first):
CMakeLists.txt:55 (FindOrBuildICU)
This warning is for project developers. Use -Wno-dev to suppress it.
-- ICU not found; attempting to build it...
-- ICU include dirs: /Users/yuenfannie/meta/build/deps/icu-58.2/include
-- ICU libraries: icui18n;icuuc;icudata
-- Locating libc++...
-- Located libc++: /usr/lib/libc++.dylib
-- Located libc++ include path: /Library/Developer/CommandLineTools/usr/include/c++/v1/
-- Locating libc++'s abi...
-- Found libc++abi: /usr/lib/libc++abi.dylib
-- Found LIBCXX: /usr/lib/libc++.dylib
-- Using regular malloc; consider installing jemalloc
-- Performing Test META_HAS_ALIGNED_ALLOC
-- Performing Test META_HAS_ALIGNED_ALLOC - Failed
-- Performing Test META_HAS_POSIX_MEMALIGN
-- Performing Test META_HAS_POSIX_MEMALIGN - Failed
CMake Error at deps/meta-cmake/kludges/AlignedAlloc.cmake:54 (message):
Failed to find a suitable aligned allocation routine
Call Stack (most recent call first):
deps/meta-cmake/CompilerKludges.cmake:18 (include)
CMakeLists.txt:120 (CompilerKludges)
-- Configuring incomplete, errors occurred!
See also "/Users/yuenfannie/meta/build/CMakeFiles/CMakeOutput.log".
See also "/Users/yuenfannie/meta/build/CMakeFiles/CMakeError.log".
电流输出 7:
-- Searching for ICU 58.2
CMake Warning (dev) at deps/meta-cmake/FindOrBuildICU.cmake:31 (find_package):
Policy CMP0074 is not set: find_package uses <PackageName>_ROOT variables.
Run "cmake --help-policy CMP0074" for policy details. Use the cmake_policy
command to set the policy and suppress this warning.
CMake variable ICU_ROOT is set to:
/usr/local/opt/icu4c
For compatibility, CMake is ignoring the variable.
Call Stack (most recent call first):
CMakeLists.txt:55 (FindOrBuildICU)
This warning is for project developers. Use -Wno-dev to suppress it.
-- Found ICU: /usr/local/opt/icu4c/lib/libicudata.dylib;/usr/local/opt/icu4c/lib/libicui18n.dylib;/usr/local/opt/icu4c/lib/libicuuc.dylib (Required is at least version "58.2")
-- ICU version found is 67.1.0, expected 58.2; attempting to build ICU from scratch...
-- ICU include dirs: /Users/yuenfannie/meta/build/deps/icu-58.2/include
-- ICU libraries: icui18n;icuuc;icudata
-- Locating libc++...
-- Located libc++: /usr/lib/libc++.dylib
-- Located libc++ include path: /Library/Developer/CommandLineTools/usr/include/c++/v1/
-- Locating libc++'s abi...
-- Found libc++abi: /usr/lib/libc++abi.dylib
-- Using jemalloc: /usr/local/lib/libjemalloc.dylib
CMake Error at deps/meta-cmake/kludges/AlignedAlloc.cmake:54 (message):
Failed to find a suitable aligned allocation routine
Call Stack (most recent call first):
deps/meta-cmake/CompilerKludges.cmake:18 (include)
CMakeLists.txt:120 (CompilerKludges)
-- Configuring incomplete, errors occurred!
See also "/Users/yuenfannie/meta/build/CMakeFiles/CMakeOutput.log".
See also "/Users/yuenfannie/meta/build/CMakeFiles/CMakeError.log".
我如何系统地检查可能的错误以使设置成为可能?欢迎您提出建议!
解决方案
推荐阅读
- r - 来自 SAS PROC SQL 条件连接的 R
- javascript - 使用角度 Observable 在数组中合并管道
- javascript - 如何输入一个数据,另一个数据自动完成?
- python - 如果我有两个匹配的单词,请单击特定单词链接
- java - loadInBackground() 的返回值传递给谁?
- c - 共享内存中的简单检查返回 SIGSEGV 错误 008b
- php - 表单未收集用户输入,即使我输入了有效的表和列,查询也无法正常工作
- java - 如何使用 Cucumber 和 Rally 集成自动更新 Rally 测试用例?
- bash - 如何在我的 git 环境中修复 pre-commit-msg?
- optimization - 如何使用严格的不等式比较浮点变量?