[R-sig-Debian] Installing package fails at "testing if installed package can be loaded from temporary location"

Sam H @@m@hhh1 @end|ng |rom gm@||@com
Thu Oct 8 20:37:37 CEST 2020


Hi,

I can not install packages from source which links to RcppArmadillo on
Ubuntu 20.04 (after upgrading from 18.04). The following problem occurs:

** testing if installed package can be loaded from temporary location
Error: package or namespace load failed for 'myPackage' in
dyn.load(file, DLLpath = DLLpath, ...):
 unable to load shared object
'/usr/local/lib/R/site-library/00LOCK-my_package/00new/myPackage/libs/myPackage.so':
  /usr/local/lib/R/site-library/00LOCK-my_package/00new/myPackge/libs/myPackage.so:
undefined symbol: dgesvx_
Error: loading failed
Execution halted
ERROR: loading failed

This dgesvx_ looked to me like a LAPACK problem (
https://www.netlib.org/lapack/explore-html/d7/d3b/group__double_g_esolve_ga9d90ccf6e340cacd08b7bbbb502ceb21.html#ga9d90ccf6e340cacd08b7bbbb502ceb21
).

I was playing with different BLAS/LAPACK versions on my system and
researching this for a couple of days now but without success.

I was first looking at which LAPACK and BLAS R is "using"

user using user:~$ ps aux | grep exec/R
user+   11663  1.9  1.7 1030952 415240 pts/0  Sl+  06:33   0:13
/usr/lib/R/bin/exec/R --vanilla --quiet
user+   13836  2.5  0.2 441664 52024 pts/1    Sl+  06:44   0:00
/usr/lib/R/bin/exec/R
user+   13932  0.0  0.0   8900   660 pts/2    S+   06:45   0:00 grep exec/R
user using user:~$ lsof -p 13836 | grep 'blas\|lapack'
R       13836 user  mem    REG    8,1 33562376  3961750
/usr/lib/x86_64-linux-gnu/openblas-pthread/liblapack.so.3
R       13836 user  mem    REG    8,1 27200552  3961749
/usr/lib/x86_64-linux-gnu/openblas-pthread/libblas.so.3
user using user:~$ ls -l /usr/lib/x86_64-linux-gnu/openblas-pthread/libblas.so.3
-rw-r--r-- 1 root root 27200552 Jun  2 06:55
/usr/lib/x86_64-linux-gnu/openblas-pthread/libblas.so.3
user using user:~$ ls -l /usr/lib/x86_64-linux-gnu/openblas-pthread/liblapack.so.3
-rw-r--r-- 1 root root 33562376 Jun  2 06:55
/usr/lib/x86_64-linux-gnu/openblas-pthread/liblapack.so.3

And then tried different versions:

user using user:~$ sudo update-alternatives --config libblas.so.3-x86_64-linux-gnu
There are 4 choices for the alternative libblas.so.3-x86_64-linux-gnu
(providing /usr/lib/x86_64-linux-gnu/libblas.so.3).

  Selection    Path
Priority   Status
------------------------------------------------------------
* 0            /usr/lib/x86_64-linux-gnu/openblas-pthread/libblas.so.3
100       auto mode
  1            /usr/lib/x86_64-linux-gnu/atlas/libblas.so.3              35
       manual mode
  2            /usr/lib/x86_64-linux-gnu/blas/libblas.so.3               10
       manual mode
  3            /usr/lib/x86_64-linux-gnu/openblas-openmp/libblas.so.3    95
       manual mode
  4            /usr/lib/x86_64-linux-gnu/openblas-pthread/libblas.so.3
100       manual mode

Press <enter> to keep the current choice[*], or type selection number: 3
update-alternatives: using
/usr/lib/x86_64-linux-gnu/openblas-openmp/libblas.so.3 to provide
/usr/lib/x86_64-linux-gnu/libblas.so.3 (libblas.so.3-x86_64-linux-gnu) in
manual mode
user using user:~$ sudo update-alternatives --config
liblapack.so.3-x86_64-linux-gnu
There are 4 choices for the alternative liblapack.so.3-x86_64-linux-gnu
(providing /usr/lib/x86_64-linux-gnu/liblapack.so.3).

  Selection    Path
Priority   Status
------------------------------------------------------------
* 0            /usr/lib/x86_64-linux-gnu/openblas-pthread/liblapack.so.3
100       auto mode
  1            /usr/lib/x86_64-linux-gnu/atlas/liblapack.so.3
 35        manual mode
  2            /usr/lib/x86_64-linux-gnu/lapack/liblapack.so.3
10        manual mode
  3            /usr/lib/x86_64-linux-gnu/openblas-openmp/liblapack.so.3
 95        manual mode
  4            /usr/lib/x86_64-linux-gnu/openblas-pthread/liblapack.so.3
100       manual mode

Press <enter> to keep the current choice[*], or type selection number: 3
update-alternatives: using
/usr/lib/x86_64-linux-gnu/openblas-openmp/liblapack.so.3 to provide
/usr/lib/x86_64-linux-gnu/liblapack.so.3 (liblapack.so.3-x86_64-linux-gnu)
in manual mode
user using user:~$ sudo update-alternatives --config libblas.so.3-x86_64-linux-gnu
There are 4 choices for the alternative libblas.so.3-x86_64-linux-gnu
(providing /usr/lib/x86_64-linux-gnu/libblas.so.3).

  Selection    Path
Priority   Status
------------------------------------------------------------
  0            /usr/lib/x86_64-linux-gnu/openblas-pthread/libblas.so.3
100       auto mode
  1            /usr/lib/x86_64-linux-gnu/atlas/libblas.so.3              35
       manual mode
  2            /usr/lib/x86_64-linux-gnu/blas/libblas.so.3               10
       manual mode
* 3            /usr/lib/x86_64-linux-gnu/openblas-openmp/libblas.so.3    95
       manual mode
  4            /usr/lib/x86_64-linux-gnu/openblas-pthread/libblas.so.3
100       manual mode

Press <enter> to keep the current choice[*], or type selection number: 2
update-alternatives: using /usr/lib/x86_64-linux-gnu/blas/libblas.so.3 to
provide /usr/lib/x86_64-linux-gnu/libblas.so.3
(libblas.so.3-x86_64-linux-gnu) in manual mode
user using user:~$ sudo update-alternatives --config
liblapack.so.3-x86_64-linux-gnu
There are 4 choices for the alternative liblapack.so.3-x86_64-linux-gnu
(providing /usr/lib/x86_64-linux-gnu/liblapack.so.3).

  Selection    Path
Priority   Status
------------------------------------------------------------
  0            /usr/lib/x86_64-linux-gnu/openblas-pthread/liblapack.so.3
100       auto mode
  1            /usr/lib/x86_64-linux-gnu/atlas/liblapack.so.3
 35        manual mode
  2            /usr/lib/x86_64-linux-gnu/lapack/liblapack.so.3
10        manual mode
* 3            /usr/lib/x86_64-linux-gnu/openblas-openmp/liblapack.so.3
 95        manual mode
  4            /usr/lib/x86_64-linux-gnu/openblas-pthread/liblapack.so.3
100       manual mode

Press <enter> to keep the current choice[*], or type selection number: 2
update-alternatives: using /usr/lib/x86_64-linux-gnu/lapack/liblapack.so.3
to provide /usr/lib/x86_64-linux-gnu/liblapack.so.3
(liblapack.so.3-x86_64-linux-gnu) in manual mode
I have no idea what could be wrong here... Thanks in advance for hints and
help on what to do here.

Best regards,
Sam

	[[alternative HTML version deleted]]



More information about the R-SIG-Debian mailing list