我正试图使用edpFree 7.3-2在ubuntu 12.04上安装llvmpy

# uname -a
Linux svnserver 3.2.0-38-generic #61-Ubuntu SMP Tue Feb 19 12:18:21 UTC 2013 x86_64 x86_64 x86_64 GNU/Linux

# lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 12.04.2 LTS
Release:    12.04
Codename:   precise

在pip命令之后,我收到一个错误:
#./pip install llvmpy
Downloading/unpacking llvmpy
  Running setup.py egg_info for package llvmpy
    LLVM version = u'3.0'
    Generate intrinsic IDs
    Searching shared library libLLVM-3.0 in /usr/lib/llvm-3.0/lib
    Using PTX
    Traceback (most recent call last):
      File "<string>", line 16, in <module>
      File "/tmp/pip-build/llvmpy/setup.py", line 136, in <module>
        + extra_components)
      File "/tmp/pip-build/llvmpy/setup.py", line 41, in get_libs_and_objs
        parts = run_llvm_config(['--libs'] + components).split()
      File "/tmp/pip-build/llvmpy/setup.py", line 34, in run_llvm_config
        raise Exception("%r stderr is:\n%s" % (args, stderr.decode()))
    Exception: ['llvm-config', '--libs', 'core', 'analysis', 'scalaropts', 'executionengine', 'jit', 'native', 'interpreter', 'bitreader', 'bitwriter', 'instrumentation', 'ipa', 'ipo', 'transformutils', 'asmparser', 'linker', 'support', 'vectorize', 'ptxdesc', 'ptxcodegen', 'ptxasmprinter', 'ptxinfo', 'ptx'] stderr is:
    llvm-config: unknown component name: vectorize

    Complete output from command python setup.py egg_info:
    LLVM version = u'3.0'

Generate intrinsic IDs

Searching shared library libLLVM-3.0 in /usr/lib/llvm-3.0/lib

Using PTX

Traceback (most recent call last):

  File "<string>", line 16, in <module>

  File "/tmp/pip-build/llvmpy/setup.py", line 136, in <module>

    + extra_components)

  File "/tmp/pip-build/llvmpy/setup.py", line 41, in get_libs_and_objs

    parts = run_llvm_config(['--libs'] + components).split()

  File "/tmp/pip-build/llvmpy/setup.py", line 34, in run_llvm_config

    raise Exception("%r stderr is:\n%s" % (args, stderr.decode()))

Exception: ['llvm-config', '--libs', 'core', 'analysis', 'scalaropts', 'executionengine', 'jit', 'native', 'interpreter', 'bitreader', 'bitwriter', 'instrumentation', 'ipa', 'ipo', 'transformutils', 'asmparser', 'linker', 'support', 'vectorize', 'ptxdesc', 'ptxcodegen', 'ptxasmprinter', 'ptxinfo', 'ptx'] stderr is:

llvm-config: unknown component name: vectorize

问题出在矢量化组件上!
作为先决条件,我安装了(使用能力):
llvm-3.0
llvm-3.0-dev
llvm-3.0-runtime
libllvm3.0

可能3.0必须替换为3.1?
你能帮助我吗?

最佳答案

您至少希望llvm-3.1包含声明为丢失的组件:

$ llvm-config --libs vectorize
-lLLVMVectorize -lLLVMInstCombine -lLLVMTransformUtils -lLLVMipa -lLLVMAnalysis -lLLVMTarget -lLLVMMC -lLLVMObject -lLLVMCore -lLLVMSupport
$ llvm-config --version
3.1

不过,如果可能的话,我会考虑3.3版本,因为这是它的开发似乎有reached a reasonable point的地方。
编辑:看起来llvmpy-0.11.0正在被拉入,希望llvm-3.2。使用:
pip install -I llvmpy==0.10.0

而是获取绑定到llvm-3.1的版本。测试时间:
$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 12.10
Release:        12.10
Codename:       quantal

08-28 02:20