Hi,
I tried to compile R with openblas on a ubuntu 12.04 machine. I have to
say that I normally use the package system and that I have no experience
with compiling R.
I did the following:
./configure --enable-BLAS-shlib --enable-R-shlib LIBnn=lib
--with-blas="-L/usr/lib/openblas-base/ -lopenblas"
--enable-memory-profiling --with-x=yes
go the output:
R is now configured for x86_64-unknown-linux-gnu
Source directory: .
Installation directory: /usr/local
C compiler: gcc -std=gnu99 -g -O2
Fortran 77 compiler: gfortran -g -O2
C++ compiler: g++ -g -O2
C++ 11 compiler: g++ -std=c++0x -g -O2
Fortran 90/95 compiler: gfortran -g -O2
Obj-C compiler:
Interfaces supported: X11
External libraries: readline, BLAS(generic), lzma
Additional capabilities: PNG, JPEG, NLS
Options enabled: shared R library, shared BLAS, R
profiling, memory profiling
Recommended packages: yes
configure: WARNING: you cannot build info or HTML versions of the R manuals
Then: make - and then comes the error:
make[4]: Entering directory `/home/ab/Downloads/R-3.1.0/src/main'
make[4]: Leaving directory `/home/ab/Downloads/R-3.1.0/src/main'
make[3]: Leaving directory `/home/ab/Downloads/R-3.1.0/src/main'
make[3]: Entering directory `/home/ab/Downloads/R-3.1.0/src/main'
gcc -std=gnu99 -Wl,--export-dynamic -fopenmp -L/usr/local/lib -o R.bin
Rmain.o -L../../lib -lR -lRblas
../../lib/libR.so: undefined reference to `drot_'
../../lib/libR.so: undefined reference to `dtrsm_'
../../lib/libR.so: undefined reference to `dswap_'
../../lib/libR.so: undefined reference to `dcopy_'
../../lib/libR.so: undefined reference to `ddot_'
../../lib/libR.so: undefined reference to `dgemm_'
../../lib/libR.so: undefined reference to `dscal_'
../../lib/libR.so: undefined reference to `dnrm2_'
../../lib/libR.so: undefined reference to `dsyrk_'
../../lib/libR.so: undefined reference to `dasum_'
../../lib/libR.so: undefined reference to `daxpy_'
../../lib/libR.so: undefined reference to `drotg_'
../../lib/libR.so: undefined reference to `zgemm_'
collect2: ld returned 1 exit status
make[3]: *** [R.bin] Error 1
make[3]: Leaving directory `/home/ab/Downloads/R-3.1.0/src/main'
make[2]: *** [R] Error 2
make[2]: Leaving directory `/home/ab/Downloads/R-3.1.0/src/main'
make[1]: *** [R] Error 1
make[1]: Leaving directory `/home/ab/Downloads/R-3.1.0/src'
make: *** [R] Error 1
I am wondering why libR.so wants to find these functions and not
libRblas.so. The lib libRblas.so can be found in
> locate libRblas.so
/home/ab/Downloads/R-3.1.0/lib/libRblas.so
/home/ab/Downloads/R-3.1.0/src/extra/blas/libRblas.so
they have both the same size.
can anyone help me with this?
cheers,
alex