Source: openblas
Version: 0.1.1-6
Severity: normal

When installing both libopenblas-base and libopenblas-dev with the libblas
alternatives set to auto, I see the following:

$ gcc -o blastest blastest.c -lblas
$ ./blastest 1
0.00 1.00 2.00 3.00 4.00 5.00 6.00 7.00
$ sudo apt-get -yqq install libopenblas-dev
Selecting previously unselected package libopenblas-base.
(Reading database ... 297113 files and directories currently installed.)
Unpacking libopenblas-base (from .../libopenblas-base_0.1.1-6_amd64.deb) ...
Selecting previously unselected package libopenblas-dev.
Unpacking libopenblas-dev (from .../libopenblas-dev_0.1.1-6_amd64.deb) ...
Setting up libopenblas-base (0.1.1-6) ...
update-alternatives: using /usr/lib/openblas-base/libopenblas.so.0 to provide
/usr/lib/libblas.so.3 (libblas.so.3) in auto mode
Setting up libopenblas-dev (0.1.1-6) ...
update-alternatives: using /usr/lib/openblas-base/libopenblas.so to provide
/usr/lib/libblas.so (libblas.so) in auto mode
$ gcc -o blastest blastest.c -lblas
$ ./blastest 1
../blastest: error while loading shared libraries: libopenblas.so.0: cannot open
shared object file: No such file or directory

I think this is because ldconfig is not being run when the openblas packages
are installed, due to

DEB_DH_MAKESHLIBS_ARGS_libopenblas-base = -n

in debian/rules. If I run ldconfig the program runs fine.

I don't think this is too serious because no packages depend on libopenblas-
dev, and if I had not manually installed it there would have been no error.



-- System Information:
Debian Release: wheezy/sid
  APT prefers testing
  APT policy: (500, 'testing'), (1, 'experimental'), (1, 'unstable')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 3.5-trunk-amd64 (SMP w/4 CPU cores)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
#include <cblas.h>
#include <stdio.h>
#include <stdlib.h>

int main(int argc, char *argv[])
{
    double x[8] = { 0, 1, 2, 3, 4, 5, 6, 7 };
    double y[8] = { 0 };
    double a = 0;
    int i;

    if (argc > 1)
        a = atof(argv[1]);

    cblas_daxpy(8, a, x, 1, y, 1);

    for (i = 0; i < 8; i++)
        printf("%.2f ", y[i]);
    printf("\n");
    return 0;
}

Reply via email to