gpt4 book ai didi

python - 无法在 Fedora 21 系统上安装 python numba 依赖项 llvmlite

转载 作者:行者123 更新时间:2023-12-01 04:46:48 25 4
gpt4 key购买 nike

我正在尝试在运行 Fedora 21 的 PC 上安装 python numba。我正在运行 Python 2.7.8。

我在 Getting python Numba working on Ubuntu 14.10 or Fedora 21 with python 2.7 上找到了一些有用的信息并尝试了那里的建议,但它对我的情况不起作用。针对该特定查询的建议是

yum install zlib zlib-devel libstdc++-devel libstdc++ libstdc++-static llvm-3.5.0 llvm-devel-3.5.0 libedit libedit-devel
pip install enum34
pip install funcsigs
LLVM_CONFIG=/usr/bin/llvm-config pip install llvmlite
LLVM_CONFIG=/usr/bin/llvm-config pip install numba

该问题发生在安装 llvmlite 期间(上述步骤 4)。以下是运行 pip install llmvlite 时我在终端窗口中看到的一些消息

Downloading/unpacking llvmlite
Downloading llvmlite-0.2.2.tar.gz (75kB): 75kB downloaded
Running setup.py (path:/tmp/pip-build-1eUon1/llvmlite/setup.py) egg_info for package llvmlite

Installing collected packages: llvmlite
Running setup.py install for llvmlite
got version from file /tmp/pip-build-1eUon1/llvmlite/llvmlite/_version.py {'version': '0.2.2', 'full': 'c6e72f55cb10bccdcba2f31e9d52c528b12c5a0e'}
/usr/bin/python /tmp/pip-build-1eUon1/llvmlite/ffi/build.py
LLVM version... 3.5.0
# static-libstdc++ avoids runtime dependencies on a
# particular libstdc++ version.
g++ -static-libstdc++ -shared -flto `/usr/bin/llvm-config --cxxflags` -fno-rtti assembly.cpp bitcode.cpp core.cpp initfini.cpp module.cpp value.cpp executionengine.cpp transforms.cpp passmanagers.cpp targets.cpp dylib.cpp linker.cpp -o libllvmlite.so -flto `/usr/bin/llvm-config --ldflags` -Wl,--exclude-libs=ALL `/usr/bin/llvm-config --system-libs --libs all`
/bin/ld: cannot find -lLLVMLineEditor
/bin/ld: cannot find -lLLVMInstrumentation
/bin/ld: cannot find -lLLVMProfileData
/bin/ld: cannot find -lLLVMIRReader
/bin/ld: cannot find -lLLVMAsmParser
/bin/ld: cannot find -lLLVMDebugInfo
/bin/ld: cannot find -lLLVMOption
/bin/ld: cannot find -lLLVMJIT

等等...(未包含找不到消息的完整列表)

collect2: error: ld returned 1 exit status

Makefile.linux:17: recipe for target 'libllvmlite.so' failed

make: *** [libllvmlite.so] Error 1

Traceback (most recent call last):

File "/tmp/pip-build-mmSawV/llvmlite/ffi/build.py", line 112, in <module>

main()

File "/tmp/pip-build-mmSawV/llvmlite/ffi/build.py", line 104, in main

main_posix('linux', '.so')

File "/tmp/pip-build-mmSawV/llvmlite/ffi/build.py", line 96, in main_posix

subprocess.check_call(['make', '-f', makefile])

File "/usr/lib64/python2.7/subprocess.py", line 540, in check_call

raise CalledProcessError(retcode, cmd)

subprocess.CalledProcessError: Command '['make', '-f', 'Makefile.linux']' returned non-zero exit status 2

error: command '/usr/bin/python' failed with exit status 1

如有任何帮助,我们将不胜感激。

谢谢。

问候,

愿意。

最佳答案

刚刚修复了在Fedora 21上编译llvmlite的问题。您需要先安装LLVM的静态库(yum中的llvm-static包)。这将在/usr/lib64/llvm 中安装 LLVMLineEditor 等库。

关于python - 无法在 Fedora 21 系统上安装 python numba 依赖项 llvmlite,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/29239117/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com