link problem with a simple test program.

Post here if you have a question about linking your program with LAPACK or ScaLAPACK library

Re: link problem with a simple test program.

Postby cckuo0925 » Wed Feb 01, 2012 7:19 am

hdc1112 wrote:Thanks !
I put blas_LINUX.a to /usr/local/lib/libblas.a
and "g++ clapacktest.cc -lclapack -lcblas -lblas -llibf2c" works.
maybe this is a good start to CLAPACK, I'd like to try some matrix inversion program later. :)

admin wrote:Hi,
Could you try changing the linking sequence and adding a BLAS library
The cblas is just a C wrapper, it needs a BLAS library.
Code: Select all
g++ clapacktest.cc -lclapack  -lcblas -lblas -llibf2c



I have the same problem, but it is not solved. I got blas_LINUX.a lapack_LINUX.a libcblaswr.a tmglib_LINUX.a libf2c.a, by build the CLAPACK 3.2.1 . Then I rename blas_LINUX.a as libblas.a, lapack_LINUX.a as libclapack.a ,tmglib_LINUX.a as libtmglib.a, and put them into /my own path/lib.

when I tried to compile the test code, it didn't work.

g++ -lblas -lclapack -ltmglib -lf2c -L/my own path/lib

I wonder where the -lcblas comes from?? maybe that's the source of the problem.


The test code I used is the same as you and the error message is the same as you too.
cckuo0925
 
Posts: 1
Joined: Wed Feb 01, 2012 6:17 am

Previous

Return to Linking Problem

Who is online

Users browsing this forum: Bing [Bot] and 1 guest