[PYTHON] Error resolution when installing numba on macOS

Premise

I'm installing LLVM with Homebrew.

numba installation error list

llvm-config path

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

Error Summary: Failed to run llvm-config. Set the path to LLVM_CONFIG.

When installing LLVM, an executable file called "llvm-config" is installed, so you can set the path to the environment variable LLVM_CONFIG.

Set environment variables with the following command before installing numba with pip3 etc. (Set the path of each llvm-config to LLVM_CONFIG)

export LLVM_CONFIG=/usr/local/Cellar/llvm@9/9.0.1_2/bin/llvm-config

My llvm-config was the following path.

/usr/local/Cellar/llvm@9/9.0.1_2/bin/llvm-config

If the path is unknown

If you installed LLVM with brew, an alias was created in usr / local / opt /, so follow it from there (Finder> Go> You can see the root directory on your computer. Find out how to display hidden folders yourself. Please give me).

If you find what you are looking for, right-click and press the Option key and you will see the item "Copy pathname for" llvm-config "" that you can click to copy.

LLVM version difference

RuntimeError: Building llvmlite requires LLVM 10.0.x or 9.0.x, got '11.0.0'. Be sure to set LLVM_CONFIG to the right executable path.
  Read the documentation at http://llvmlite.pydata.org/ for more information about building llvmlite.

Error Summary: The llvmlite build requires LLVM 10.0.x or LLVM 9.0.x but found 11.0.0. Set LLVM_CONFIG to the correct executable path.

If you do brew install llvm when installing LLVM with brew, the latest version will be installed. As of November 2020, LLVM 11.0.0 was installed. When installing a package with brew, you can specify the version with @ (at sign), so install version 9 LLVM with brew install llvm @ 9. (As of November 2020, there is no llvm @ 10 for some reason)

Recommended Posts

Error resolution when installing numba on macOS
Error handling when installing mecab-python
polyfit error when installing matplotlib
[python] Error when installing library ramkan
Support when installing pillow on python3.9
Error and solution when installing python3 with homebrew on mac (catalina 10.15)
Error when installing opencv-python on jetson nano (ModuleNotFoundError: No module named'skbuild')
A struggle when installing pyenv on Cygwin
Error, warning when using TensorFlow on Mac
Installing PIL with Python 3.x on macOS
Check! Troubleshooting when installing PyObjc on Mac
Linux "Install on / dev / sda" error resolution
Error when installing a module with Python pip
Error installing pandas_datareader
Eliminates SSL error when PIP Install on Windows.
Summary of error handling methods when installing TensorFlow (2)
I get an error when installing scipy on t2.micro because I don't have enough memory
When I try to import pandas on macOS I get the error No module named'_bz2'
Precautions when using sqlite3 on macOS Sierra (10.12) with multiprocessing
Error around GUI when using PyQt5 on Ubuntu (WSL2)
Matplotlib Runtime Error resolution
I got an error when pip install tweepy on macOS Sierra, so I dealt with it
What to do when you get an error saying "Name resolution temporarily failed" on linux
Install numba on CentOS 7.2
Stumbled when installing PyOCR
When I installed python on macOS and used it, I got an error when I put an https connection
Notes on installing PycURL
numba installation on mac
Installing pandas on python2.6
Precautions when installing fbprophet
Installing pyenv on ubuntu 16.04
Import error resolution record when touching Python code from VSCode
I get [Error 2055] when trying to connect to MySQL on Heroku
After installing CentOS8 with VirtualBox, an error occurs when restarting
Precautions and solutions when installing Ubuntu on NVIDIA GeForce PCs
(Note) Points to be addicted to when installing Scilab on ArchLinux