[Lapackpp-devel] Re: Problems when try to build lapackpp on Debian Linux
Status: Beta
Brought to you by:
cstim
From: Christian S. <sti...@tu...> - 2005-08-22 10:17:44
|
Hello Hongwei, https://sourceforge.net/support/getsupport.php?group_id=99696 says: You may contact the lapackpp project by sending email to the lapackpp-devel mailing list at lap...@li.... In the future, please always address your question to that mailinglist, *never* only to individual developers. hon...@ag... schrieb: > Hello, Christian: > > I want to try the mimolib provided at URL: http://simthetic.sourceforge.net/. So I try to build lapackpp on my Debian Linux box. I noticed that prior installing lapackpp, I need to install lapack and blas. I have tried two approaches:1) using the lapack and Blas package of Debian Linux. 2) Build lapack from http://www.netlib.org/lapack/. I have met some problems with both approaches. The problems are the following: > > 1) With both approaches, the make and make install succeed. However, If I run make check. There will be an error saying that the lapack library not existing. In fact, they do exist. The error message for approach 2) is given below. For approach 1), the error is similar, it says that lapack.2.0 not found. > > make[3]: Entering directory `/hdb2/MIMO/lapackpp-2.3.0/blaspp/testing' > /bin/sh ../../libtool --tag=CXX --mode=link g++ -g -O2 -Wall -L../../blaspp/src -L../../src -llapackpp -l/hdb2/MIMO/LAPACK/lapack_LINUX.a -L/usr/lib -l/hdb2/MIMO/LAPACK/blas_LINUX.a -lf77blas.2.3 -latlas.2 -L/usr/lib/gcc-lib/i386-linux/2.95.4 -lg2c -lm -o tblasd++ tblasd++.o > g++ -g -O2 -Wall -o .libs/tblasd++ tblasd++.o -L/hdb2/MIMO/lapackpp-2.3.0/blaspp/src -L/hdb2/MIMO/lapackpp-2.3.0/src /hdb2/MIMO/lapackpp-2.3.0/src/.libs/liblapackpp.so -l/hdb2/MIMO/LAPACK/lapack_LINUX.a -L/usr/lib -l/hdb2/MIMO/LAPACK/blas_LINUX.a -lf77blas.2.3 -latlas.2 -L/usr/lib/gcc-lib/i386-linux/2.95.4 -lg2c -lm -Wl,--rpath -Wl,/usr/local/lib > /usr/bin/ld: cannot find -l/hdb2/MIMO/LAPACK/lapack_LINUX.a This means that lapack++ cannot link correctly against the LAPACK and BLAS libraries. This will also mean that any other project using lapack++ cannot run, as you have discovered with mimolib. You need to fix this first, otherwise the mimolib project will not work anyway. In any case, the problem is that your LAPACK and BLAS package have not been correctly installed. Somehow the lapack++ checks during its ./configure got the idea that the linker arguments for linking against LAPACK should be -l/hdb2/MIMO/LAPACK/lapack_LINUX.a . That location looks rather like the place where you compiled LAPACK, but not where you installed it, so I would guess you didn't use the correct way of installing the LAPACK package. Installing such a package should firstly be tried in your distribution's package manager. I would therefore strongly suggest you should use the LAPACK and BLAS packages of your Debian version (by the way you didn't say which version), but since I don't use Debian I can't tell you more than that. If in doubt, please ask on the Debian forums how to do that. But since you now already installed LAPACK and BLAS manually in addition to the Debian packages, you need to make sure that these two don't interfere with each other. It is a common mistake to install such an extra package manually (e.g. into /usr/lib/liblapack.so*) and then install it also by the package manager, but then some files in /usr/lib/... are from the package manager's packet and others are from the manual installation. This will almost surely result in a broken LAPACK installation such as you described one. Another common mistake is that you have one version of a library in /usr/lib/liblapack... and another version in /usr/local/lib/liblapack... and the files from both interfere with each other. You should make sure to have only one version of LAPACK installed, and the other version should be removed completely, especially files in /usr/lib/ and /usr/local/lib/. In any case, I'm also confused why your LAPACK library filenames end in ".a", i.e. they are static libraries. On a recent Linux you would always have ".so" files, shared object, i.e. dynamic libraries. This again looks like you didn't install the LAPACK package correctly. Again, please ask the Debian guys on how to do this correctly on Debian. > 2)I have no problem with building mimolib. However, when I try to run the examples under mimolib/src/parameter, there will be an error reporting > > > simthetic: relocation error: /usr/local/lib/liblapackpp.so.1: undefined symbol: zgemm_. As long as "make check" in lapack++ doesn't run correctly, mimolib will also not run correctly. > BTW, I don't know why during the ./configure stage, the check of cheev_ in lapack will fail no matter I use lapack library from Deian package or self-built lapack package. Thank you very much. If it were a problem then ./configure would abort and show an error message. If ./configure completes, things should be fine. Regards, Christian |