RuntimeError: <path> failed executing, please point LLVM_CONFIG to the path for llvm-config
Asked Answered
A

6

12

Trying to install llvmlite via pip by running

pip install llvmlite

constantly gives me this error:

    RuntimeError: <path> failed executing, please point LLVM_CONFIG to the path for llvm-config
    error: command '/Users/sfalk/miniconda3/envs/asr-service/bin/python' failed with exit status 1
    ----------------------------------------

Now, I am on Python 3.5

$ python --version
Python 3.5.6 :: Anaconda, Inc.

And just running pip install llvmlite will give me this:

 RuntimeError: Building llvmlite requires LLVM 7.0.x, 7.1.x or 8.0.x, got '10.0.0'. Be sure to set LLVM_CONFIG to the right executable path.

I installed LLVM 8 via brew

brew install llvm@8

Setting LLVM_CONFIG to either does not work.

  • /usr/local/opt/llvm@8/bin (were I assumed llvm-config to be), or
  • /usr/local/opt/llvm@8/Toolchains/LLVM8.0.1.xctoolchain/usr/bin (where I actually found llvm-config to be)

And I keep getting some version of:

RuntimeError: /usr/local/opt/llvm@8/Toolchains/LLVM8.0.1.xctoolchain/usr/bin failed executing, please point LLVM_CONFIG to the path for llvm-config

What am I missing here?

Allay answered 28/4, 2020 at 7:54 Comment(0)
R
12

And for those reviewing the post in search for a solution to installing numba, the version released on June 24, 2020 works: pip install numba==0.50.1

Russon answered 27/9, 2020 at 21:46 Comment(3)
Can you please elaborate on why installing numba answers the question?Genetics
Sorry, I am a newbie in contributing to stack overflow, so this might be a stretch. I was trying to install numba which depends on llvmlite, and the last stable release (of numba) uses the llvmlite version with the bug detailed in the question. My train of thought was that my comment might be helpful to those looking to solve the numba installation problem. In hindsight, I think it might have been more helpful to open a new question for numba specifically and answer that one.Russon
I still get the error even when using pip install numba==0.50.1Spangle
P
9

Looks like there is an issue with latest version of llvmlite. Please consider using 0.31.0 version.

>>pip install llvmlite==0.31.0

Collecting llvmlite==0.31.0
  Downloading 
https://files.pythonhosted.org/packages/10/31/aa315fbc2e0b7777b95ce166b7c988f53e4cdd4c33d06eea24f395539eb4/llvmlite-0.31.0-cp35-cp35m-macosx_10_9_x86_64.whl (15.9MB)
    100% |████████████████████████████████| 15.9MB 1.1MB/s 

Installing collected packages: llvmlite

Successfully installed llvmlite-0.31.0
Proclus answered 18/8, 2020 at 16:34 Comment(0)
S
7

You will have to install the required llvm package using and link the executable config

sudo apt install llvm-**X**

and then

sudo pip3 install llvmlite 
cd /usr/bin
sudo ln -s llvm-config-**X** llvm-config

This fixed the llvm issue of installing librosa on my raspberry pi (aarch64)

Shire answered 20/8, 2020 at 8:46 Comment(4)
What "X" did you use for your installation? Also, could you list the versions of numpy, numba, llvmlite, and librosa on your pi that ultimately were installed?Baptistery
It is the version number you have installed. e.g. X should be replaced with 10.0.0 if you have that version installed. I am sorry, I do not still have the environment I initially used. But I recall using numpy 1.16, librosa 0.7.X and lvmlite 7. Make sure your numba version is supported for the lvmliteShire
I was able to get it to work with LLVM-7, numpy 1.16.1, numba 0.49.0, llvmlite 0.32.0, and librosa 0.8.0! I think you can get newer LLVM versions to work, but you need to scale numba and llvmlite to match compatibility. Raspbian has an easily installable LLVM-7, so I went with the versions I mention above.Baptistery
In my case, for Ubuntu 18.04/Mint 19.3, I used apt install llvm-10, and then set the new llvm-config link. Then it worked! askubuntu.com/questions/1286131/…Susiesuslik
A
1

I was facing the same issue.

You will have to install the required llvm package using and link the executable config

sudo apt install llvm-X

and then

sudo pip3 install llvmlite cd /usr/bin sudo ln -s llvm-config-X llvm-config

did not work for me but I did notice we had the same output error

RuntimeError: <path> failed executing, please point LLVM_CONFIG to the path for llvm-config

So I thought: "why not point the LLVM_CONFIG to the proper llvm-config?".

And I did this simple fix:

export LLVM_CONFIG=/usr/bin/llvm-config-10
Annoyance answered 18/1, 2021 at 9:34 Comment(2)
For macOS, use brew install llvm@9 and then LLVM_CONFIG=/usr/local/opt/llvm@9/bin/llvm-config (or similar for other LLVM versions)Fro
This worked for me (note paths are different and LDFLAGS was important too) export LDFLAGS="-L/opt/homebrew/opt/llvm@11/lib" LLVM_CONFIG="/opt/homebrew/opt/llvm@11/bin/llvm-config" pip install numbaMiraflores
H
0

Running llvm-config, I got:

llvm-config: error while loading shared libraries: libtinfo.so.5: cannot open shared object file: No such file or directory

That seemed to be causing the problem, so after a quick search I found a SO post that provided this fix:

$ sudo apt install libncurses5

After running pip install llvmlite again it worked.

Haik answered 28/6, 2023 at 22:5 Comment(0)
T
0

This worked for me:

conda activate
conda create --name py37 python=3.7  # or just conda install python==3.7

And then the rest. I already had all the dependencies, when I got the errors you mentioned.

Tomboy answered 17/7, 2023 at 4:26 Comment(0)

© 2022 - 2025 — McMap. All rights reserved.