Try this one

$ gcc -Wall -I/usr/include blasExample.c -lgsl -lgslcblas -lm
$ ./a.out

Since you are using BLAS you need to use the respective library.

See
http://www.gnu.org/software/gsl/manual/html_node/Linking-programs-with-the-library.html

or for an alternative BLAS library

http://www.gnu.org/software/gsl/manual/html_node/Linking-with-an-alternative-BLAS-library.html

I hope that helps you.

Ralph.


On Fri, Mar 7, 2008 at 11:29 PM, David Pleydell <[EMAIL PROTECTED]>
wrote:

> Hi I am trying to run the following BLAS example
>
> http://www.gnu.org/software/gsl/manual/html_node/BLAS-Examples.html
>
> I followed the compiliation example at
>
>
> http://www.gnu.org/software/gsl/manual/html_node/Compiling-and-Linking.html
>
> So I tried the comand
>
> gcc -Wall -I/usr/include -c blasExample.c
>
>
> But I get the following compile errors
>
> blasExample.c: In function 'main':
> blasExample.c:17: warning: useless type name in empty
> declaration
> blasExample.c:17: error: 'A' undeclared (first use in
> this function)
> blasExample.c:17: error: (Each undeclared identifier
> is reported only once
> blasExample.c:17: error: for each function it appears
> in.)
> blasExample.c:18: warning: useless type name in empty
> declaration
> blasExample.c:18: error: 'B' undeclared (first use in
> this function)
> blasExample.c:19: warning: useless type name in empty
> declaration
> blasExample.c:19: error: 'C' undeclared (first use in
> this function)
>
> This is a real C newbie question, but shouldn't the
> BLAS example contain some declaration lines, and if so
> what should they look like?
>
> Thanks
> Dave
>
>
>      __________________________________________________________
> Sent from Yahoo! Mail.
> The World's Favourite Email http://uk.docs.yahoo.com/nowyoucan.html
>
>
> _______________________________________________
> Help-gsl mailing list
> [email protected]
> http://lists.gnu.org/mailman/listinfo/help-gsl
>
_______________________________________________
Help-gsl mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/help-gsl

Reply via email to