I am trying to use BLAS, CBLAS, Lapack and Lapacke as shared libraries for a foreign-functions interface. I successfully build and install the shared libraries, but then when loading them using the FFI:
- Code: Select all
vicare> (dlopen "/usr/local/lib/libblas.so")
#<pointer #x08071310>
vicare> (dlopen "/usr/local/lib/libcblas.so")
#<pointer #x08073A28>
vicare> (dlopen "/usr/local/lib/liblapack.so")
#<pointer #x08073DA8>
*vicare> (dlopen "/usr/local/lib/liblapacke.so")
#f
vicare> (dlerror)
"/usr/local/lib/liblapacke.so: undefined symbol: cgbrfsx_"
the problem appears to be that Lapacke is built including all the object files, in so doing it includes also some object files that should be included only when Lapack is built defining the USEXBLAS makefile library. The Makefile for Lapacke must be fixed for a better user experience.

