Hello everybody,
After reading a bit of info pages on gsl ( gnu scientific library )
I tried to write and compile a test program shown below :
---------------------------------------------------------------------------
#include<stdio.h>
#include<gsl/gsl_matrix.h>
int main(){
int i,j;
float n=0.0;
gsl_matrix *m = gsl_matrix_alloc(10,3);
for (i=0;i<10;i++){
for(j=0;j<3;j++){
printf("Enter element (%d,%d) : ",i,j);
scanf("%d",n);
gsl_matrix_set(m,i,j,n);
}
}
for (i=0;i<10;i++)
for(j=0;j<3;j++)
printf("m(%d,%d) = %g\n",i,j,gsl_matrix_get(m,i,j));
return 0;
}
---------------------------------------------------------------------------------
The above program is given in the info itself. So, no errors there.
My /usr/lib contains, among other things, the following :
----------------------------------------------------------------------------------
[santagnu@localhost santagnu]$ ls /usr/lib/libgsl*
/usr/lib/libgsl.a /usr/lib/libgslblascblas.a
/usr/lib/libgslblasnative.a
/usr/lib/libgsl.so@ /usr/lib/libgslblascblas.so@
/usr/lib/libgslblasnative.so@
/usr/lib/libgsl.so.0@ /usr/lib/libgslblascblas.so.0@
/usr/lib/libgslblasnative.so.0@
/usr/lib/libgsl.so.0.0.0* /usr/lib/libgslblascblas.so.0.0.0*
/usr/lib/libgslblasnative.so.0.0.0*
--------------------------------------------------------------------------------------------------
I have my gsl related header files in /usr/include/gsl/
I gave the following command to compile and link the program ( named gsl_test.c )
gcc gsl_test.c -L/usr/lib -lgsl -lm -I/usr/include/gsl
and I got the following :
------------------------------------------------------------------------
/usr/lib/libgsl.so: undefined reference to `gsl_blas_raw_dgemm'
/usr/lib/libgsl.so: undefined reference to `gsl_blas_raw_srot'
/usr/lib/libgsl.so: undefined reference to `gsl_blas_raw_sspr2'
/usr/lib/libgsl.so: undefined reference to `gsl_blas_raw_ssymm'
:
:
:
/usr/lib/libgsl.so: undefined reference to `gsl_blas_raw_ztpmv'
/usr/lib/libgsl.so: undefined reference to `gsl_blas_raw_srotg'
collect2: ld returned 1 exit status
---------------------------------------------------------------------------
Am I missing something here ??
How do I rectify this problem ??
Please help.
I need gsl urgently.
Regards,
Santanu Chatterjee
[EMAIL PROTECTED]
_________________________________________________________
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com
_______________________________________________
linux-india-help mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/linux-india-help