[R-pkg-devel] Lapack: undefined symbol: zgbsv_

Baptiste Auguie baptiste.auguie at gmail.com
Tue Feb 13 05:49:25 CET 2018

On 13 February 2018 at 01:05, Dirk Eddelbuettel <edd at debian.org> wrote:

> On 12 February 2018 at 22:16, Baptiste Auguie wrote:
> | As far as I can tell Armadillo added specialised methods for banded
> | matrices; the routines used to solve non-banded matrices probably haven't
> | changed.
> |
> | Coming back to the error itself, what puzzles me is that it seems to be
> | precisely the OSes relying on external Lapack that have a problem. It
> | compiles fine on Windows,
> | https://builder.r-hub.io/status/isolve_1.0.tar.gz-e3da3c1b83
> | 26e62e4e14a913e5bbb5a4
> |
> | So it seems the problem is distinct from the previous issues with missing
> | Lapack routines.
> Maybe we are setting a more global "no advanced lapack" for Windows that
> assures success when we assume that the other system will always have it.

it sounds plausible, but it would be nice to know for sure. In particular,
it doesn't explain why the external Lapack on linux appears to be missing
these symbols (they're not very recent, as far as I can tell). I don't
really know how to figure this out, but it seems to be key.

> One thing you could try is to write a configure test in your package so
> that
> at build time a compile+link for the particular symbol is made.

I have no idea how to do this, and if did...

> If the test succeeeds, export a new HAVE_XYZ_BANDED_ROUTINE define and then
> convince Conrad to respect that flag.  Otherwise have the code fall back to
> alternatives just like the Windows build.

... IIRC Conrad made it clear in the past that he would not consider
further special cases for crippled Lapacks.

> Or, be brutal, and set '#define ARMA_CRIPPLED_LAPACK 1' everywhere.  See
> lines 67 to 95 of RcppArmadillo's configure.ac:
> https://github.com/RcppCore/RcppArmadillo/blob/master/configure.ac#L67-L95

while this might solve the CRAN problem, it doesn't feel right to enforce
the use of suboptimal routines throughout and on all platforms, including
those that do in fact provide a full-fledged external Lapack.

> I could generalize the use in inst/include/RcppArmadilloConf
> igGenerated.h.in
> by respecting prior definitions, ie wrapping #ifndef around them.
> Dirk
> --
> http://dirk.eddelbuettel.com | @eddelbuettel | edd at debian.org


	[[alternative HTML version deleted]]

More information about the R-package-devel mailing list