question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

I can't install llvmlite on raspberry pi 4

See original GitHub issue
pi@raspberrypi:~$ pip3 install llvmlite
Looking in indexes: https://pypi.org/simple, https://www.piwheels.org/simple
Collecting llvmlite
  Using cached https://files.pythonhosted.org/packages/71/4e/b1086722f4fa0b52cf8c0d4b2c985fb3f95d2f1be1b010259497b2464c1d/llvmlite-0.33.0.tar.gz
Building wheels for collected packages: llvmlite
  Running setup.py bdist_wheel for llvmlite ... error
  Complete output from command /usr/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-install-sdekp53y/llvmlite/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" bdist_wheel -d /tmp/pip-wheel-ikvvuryb --python-tag cp37:
  running bdist_wheel
  /usr/bin/python3 /tmp/pip-install-sdekp53y/llvmlite/ffi/build.py
  LLVM version... Traceback (most recent call last):
    File "/tmp/pip-install-sdekp53y/llvmlite/ffi/build.py", line 105, in main_posix
      out = subprocess.check_output([llvm_config, '--version'])
    File "/usr/lib/python3.7/subprocess.py", line 395, in check_output
      **kwargs).stdout
    File "/usr/lib/python3.7/subprocess.py", line 472, in run
      with Popen(*popenargs, **kwargs) as process:
    File "/usr/lib/python3.7/subprocess.py", line 775, in __init__
      restore_signals, start_new_session)
    File "/usr/lib/python3.7/subprocess.py", line 1522, in _execute_child
      raise child_exception_type(errno_num, err_msg, err_filename)
  FileNotFoundError: [Errno 2] No such file or directory: 'llvm-config': 'llvm-config'
  
  During handling of the above exception, another exception occurred:
  
  Traceback (most recent call last):
    File "/tmp/pip-install-sdekp53y/llvmlite/ffi/build.py", line 191, in <module>
      main()
    File "/tmp/pip-install-sdekp53y/llvmlite/ffi/build.py", line 181, in main
      main_posix('linux', '.so')
    File "/tmp/pip-install-sdekp53y/llvmlite/ffi/build.py", line 108, in main_posix
      "to the path for llvm-config" % (llvm_config,))
  RuntimeError: llvm-config failed executing, please point LLVM_CONFIG to the path for llvm-config
  error: command '/usr/bin/python3' failed with exit status 1
  
  ----------------------------------------
  Failed building wheel for llvmlite
  Running setup.py clean for llvmlite
Failed to build llvmlite
Installing collected packages: llvmlite
  Running setup.py install for llvmlite ... error
    Complete output from command /usr/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-install-sdekp53y/llvmlite/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-record-8zgcbwp0/install-record.txt --single-version-externally-managed --compile --user --prefix=:
    running install
    running build
    got version from file /tmp/pip-install-sdekp53y/llvmlite/llvmlite/_version.py {'version': '0.33.0', 'full': '76c8ecba36e23fa8b6878505a1afc8a3d7a2c8a1'}
    running build_ext
    /usr/bin/python3 /tmp/pip-install-sdekp53y/llvmlite/ffi/build.py
    LLVM version... Traceback (most recent call last):
      File "/tmp/pip-install-sdekp53y/llvmlite/ffi/build.py", line 105, in main_posix
        out = subprocess.check_output([llvm_config, '--version'])
      File "/usr/lib/python3.7/subprocess.py", line 395, in check_output
        **kwargs).stdout
      File "/usr/lib/python3.7/subprocess.py", line 472, in run
        with Popen(*popenargs, **kwargs) as process:
      File "/usr/lib/python3.7/subprocess.py", line 775, in __init__
        restore_signals, start_new_session)
      File "/usr/lib/python3.7/subprocess.py", line 1522, in _execute_child
        raise child_exception_type(errno_num, err_msg, err_filename)
    FileNotFoundError: [Errno 2] No such file or directory: 'llvm-config': 'llvm-config'
    
    During handling of the above exception, another exception occurred:
    
    Traceback (most recent call last):
      File "/tmp/pip-install-sdekp53y/llvmlite/ffi/build.py", line 191, in <module>
        main()
      File "/tmp/pip-install-sdekp53y/llvmlite/ffi/build.py", line 181, in main
        main_posix('linux', '.so')
      File "/tmp/pip-install-sdekp53y/llvmlite/ffi/build.py", line 108, in main_posix
        "to the path for llvm-config" % (llvm_config,))
    RuntimeError: llvm-config failed executing, please point LLVM_CONFIG to the path for llvm-config
    error: command '/usr/bin/python3' failed with exit status 1
    
    ----------------------------------------
Command "/usr/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-install-sdekp53y/llvmlite/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-record-8zgcbwp0/install-record.txt --single-version-externally-managed --compile --user --prefix=" failed with error code 1 in /tmp/pip-install-sdekp53y/llvmlite/
pi@raspberrypi:~$ 

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:30 (8 by maintainers)

github_iconTop GitHub Comments

29reactions
JanLahmanncommented, Aug 30, 2020

FWIW, on an RPi4 with Raspbian Buster, the following worked for me to install llvmlite: sudo apt install llvm-9 LLVM_CONFIG=llvm-config-9 pip install llvmlite

2reactions
FardowsaRoblecommented, Jul 29, 2022

To solve this issue: I installed LLVM 11 because the llvm was not configured to the right path (“RuntimeError: Building llvmlite requires LLVM 11.x.x, got ‘9.0.1’. Be sure to set LLVM_CONFIG to the right executable path.”) – This is the Error I got.

Solution: 1: sudo apt install llvm-11 2: LLVM_CONFIG=llvm-config-11 pip3 install llvmlite 3: LLVM_CONFIG=llvm-config-11 pip3 install librosa

Result I got: “Successfully installed librosa-0.9.2 llvmlite-0.39.0 numba-0.56.0 resampy-0.3.1”

Hope this helps

Read more comments on GitHub >

github_iconTop Results From Across the Web

install librosa on raspberry pi 4, error with the wheel of llvmlite
I got mine running by installing llvmlite==0.31.0 , numba==0.48.0 , librosa==0.6.3 , colorama==0.3.9 . Command: # specify a valid dependency ...
Read more >
Failed building wheel for llvmlite for ARM64
can't install llvmlite package. After trying "pip3 install numba --user" Building wheels for collected packages: llvmlite
Read more >
Installation — llvmlite 0.40.0dev0-48-ged0f625-dirty ...
As a result, installing llvmlite from a binary package from the Numba channel does not also require the end user to install LLVM....
Read more >
llvm version 11 and librosa error - Raspberry Pi Stack Exchange
Try pointing LLVM to the installation: LLVM_CONFIG=/user/bin/llvm-config pip3 install llvmlite==0.37.0. You might need to run it with sudo ...
Read more >
numba/numba - Gitter
I first had to compile LLVM and subsequently pip install llvmlite to get to ... so all of our 32-bit ARM testing is...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found