【问题标题】:python llvmlite installtion iisue - SVML not detectedpython llvmlite安装iisue-未检测到SVML
【发布时间】:2018-06-11 10:41:13
【问题描述】:

尝试在 ubuntu 14.0.4 上制作具有 numba 0.33.0 作为依赖项的 python 脚本。已安装 llvm 6.0 并将 llvm_config 变量设置为 llvm_config 位置。

构建 llvmlite 时遇到的问题

下面是堆栈跟踪

安装收集的包:llvmlite、numba 为 llvmlite 运行 setup.py install ... 错误 命令 /home/ubuntu/www/Spam_detection_algo/spam/bin/python3 -u -c "import setuptools, tokenize;file='/tmp/pip-install-lca77547/llvmlite/setup 的完整输出.py';f=getattr(tokenize, 'open', open)(文件);code=f.read().replace('\r\n', '\n'); f.close();exec(compile(code, file, 'exec'))" install --record /tmp/pip-record-a53bsnug/install-record.txt --single-version -externally-managed --compile --install-headers /home/ubuntu/www/Spam_detection_algo/spam/include/site/python3.4/llvmlite: 运行安装 运行构建 从文件 /tmp/pip-install-lca77547/llvmlite/llvmlite/_version.py {'full': '02bd87a8449bb2984e9791bdd1d653338442b6b8', 'version': '0.23.2'}

▽ 运行 build_ext /home/ubuntu/www/Spam_detection_algo/spam/bin/python3 /tmp/pip-install-lca77547/llvmlite/ffi/bu​​ild.py LLVM 版本... # static-libstdc++ 避免运行时依赖于 # 特定的 libstdc++ 版本。 g++ -shared -I/usr/lib/llvm-6.0/include -std=c++0x -fuse-ld=gold -Wl,--no-keep-files-mapped -Wl,--no-map-whole -files -fPIC -fvisibility-inlines-hidden -Werror=date-time -std=c++11 -Wall -W -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wno-missing-field-initializers - pedantic -Wno-long-long -Wno-maybe-uninitialized -Wdelete-non-virtual-dtor -Wno-comment -ffunction-sections -fdata-sections -O2 -DNDEBUG -fno-exceptions -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS - fno-rtti -g -flto assembly.cpp bitcode.cpp core.cpp initfini.cpp module.cpp value.cpp executionengine.cpp transforms.cpp passmanagers.cpp targets.cpp dylib.cpp linker.cpp object_file.cpp -o libllvmlite。所以 -L/usr/lib/llvm-6.0/lib -flto -Wl,--exclude-libs=ALL -lLLVM-6.0 cc1plus:错误:-Werror=date-time:没有选项-Wdate-time cc1plus:错误:-Werror=date-time:没有选项-Wdate-time cc1plus:错误:-Werror=date-time:没有选项-Wdate-time cc1plus:错误:-Werror=date-time:没有选项-Wdate-time cc1plus:错误:-Werror=date-time:没有选项-Wdate-time cc1plus:错误:-Werror=date-time:没有选项-Wdate-time cc1plus:错误:-Werror=date-time:没有选项-Wdate-time cc1plus:错误:-Werror=date-time:没有选项-Wdate-time cc1plus:错误:-Werror=date-time:没有选项-Wdate-time cc1plus:错误:-Werror=date-time:没有选项-Wdate-time cc1plus:错误:-Werror=date-time:没有选项-Wdate-time cc1plus:错误:-Werror=date-time:没有选项-Wdate-time cc1plus:错误:-Werror=date-time:没有选项-Wdate-time make: *** [libllvmlite.so] 错误 1 6.0.1

SVML not detected
Traceback (most recent call last):
  File "/tmp/pip-install-lca77547/llvmlite/ffi/build.py", line 153, in <module>
    main()
  File "/tmp/pip-install-lca77547/llvmlite/ffi/build.py", line 143, in main
    main_posix('linux', '.so')
  File "/tmp/pip-install-lca77547/llvmlite/ffi/build.py", line 135, in main_posix
    subprocess.check_call(['make', '-f', makefile])
  File "/usr/lib/python3.4/subprocess.py", line 561, in check_call
    raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['make', '-f', 'Makefile.linux']' returned non-zero exit status 2
error: command '/home/ubuntu/www/Spam_detection_algo/spam/bin/python3' failed with exit status 1

【问题讨论】:

    标签: python-3.x numba llvmlite


    【解决方案1】:

    请检查您的LLVM_CONFIG 环境变量,如here 所述。

    如果您的 LLVM 安装在非标准位置,请设置 LLVM_CONFIG 环境变量到对应的位置 llvm-config 或 llvm-config.exe 可执行文件。这个变量必须保持 到 llvmlite 的安装中——例如,到 Python 中 环境。

    示例:如果 LLVM 使用 llvm-config 安装在 /opt/llvm/ 位于 /opt/llvm/bin/llvm-config 的二进制文件,设置 LLVM_CONFIG=/opt/llvm/bin/llvm-config.

    【讨论】:

      猜你喜欢
      • 2020-08-09
      • 2019-02-26
      • 2021-04-24
      • 2015-08-07
      • 1970-01-01
      • 2014-03-12
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多