How to fix Dockerfile numba install error: ERROR: Dependency OpenBLAS not found
Problem
During a Docker build, you encounter the following error while installing the numba package using pip install numba or similar:
openblas_dependency_error.txt
../scipy/meson.build:216:9: ERROR: Dependency "OpenBLAS" not found, tried pkgconfigSolution
You need to install the gfortran package in the container:
install_openblas.sh
sudo apt -y install libopenblas-devAdd the following line to your Dockerfile (for deb-based distributions):
Dockerfile_add_openblas
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update && apt-get install -y gfortran libopenblas-dev && rm -rf /var/lib/apt/lists/*gfortran-dev is required in addition to gfortran to build numba.
If this post helped you, please consider buying me a coffee or donating via PayPal to support research & publishing of new posts on TechOverflow