numba: [FreeBSD] ImportError: /lib/libgcc_s.so.1
When running in ipython, starting with one of the numba examples:
from numba import jit
the following error shows up:
ImportError: /lib/libgcc_s.so.1: version GCC_4.6.0 required by /usr/local/lib/gcc48/libgfortran.so.3 not found
Restarting ipython, an running:
import numpy
from numba import jit
Seems to fix the problem, and the example code executes correctly. I am assuming this is not an issue with Anaconda. However I am porting numba and llvmlite to Freebsd, and this seems to be an issue. Any help would be great!
About this issue
- Original URL
- State: closed
- Created 8 years ago
- Comments: 18 (7 by maintainers)
Okay thanks! A manual fix for FreeBSD is for the user to map the libgcc_s.so.1 using the /etc/libmap.conf file as such:
echo "libgcc_s.so.1 gcc48/libgcc_s.so.1" >> /etc/libmap.confHowever, this is only a manual/temporary fix. I checked numba’s .so’s using
readelf -d /usr/local/lib/python2.7/site-packages/numba/**/*.soand got the following:So _typeconv.so is using libgcc_s.so.1, although the rpath is set which is wierd.
Ah, I see some confusion has arisen due to me not being specific.
I am not using Anaconda, as I assumed it would be more challenging to port over. However I just installed llvmlite-0.12.1 from source using LLVM 3.7, and documentation says LLVM 3.8 for v0.12+, but the 0.12.1 branch clearly wants LLVM 3.7 due to build error indication. llvmlite installed just fine no hiccups, then moved onto numba-0.27.0, everything installed just fine, just using the base packages provided by the FreeBSD ports system.
Fast forward to a few days ago, I decided to make an installable port for the FreeBSD ports system which allows for use of the native package manager, due to Anaconda not being present. All available packages aside from llvmlite were in the ports tree. However the default version of python in the ports tree is Python 2.7, and most scientific packages work just fine this way. This allows a user to either use
or
pkg install py27-numbato install numba on the system. Using numba however requires that the user input either
or
to use the features provided by numba, otherwise if you try to
import numbafirst, you get:and all subsequent imports report the same error, unless you restart the interpreter.
Based on post by @stuartarchibald, it sounds like the conda environment pre-loads scipy in the environment when an interpreter is run? Correct me if I am wrong as I do not have Anaconda or use it.
Funny thing is last year it was a bit tricky to get numba working nicely on a Ubuntu system, however it installs quite effortlessly on FreeBSD. It is just odd that
import numpyneeds to be imported first, but everything works great, it just seems to me that numba requires numpy, or scipy, but doesn’t check if they are loaded upon loading itself.Again, thanks for being patient with me on this, I appreciate all of the help.