dear all,
the GSL help pages give a simple example to include a function from
the GSL libraries thus
#include <stdio.h>
#include <gsl/gsl_sf_bessel.h>
int
main (void)
{
double x = 5.0;
double y = gsl_sf_bessel_J0 (x);
printf ("J0(%g) = %.18e\n", x, y);
return 0;
}
to compile and link it says
"f the directory is not installed on the standard search path of your
compiler you will also need to provide its location to the
preprocessor as a command line flag. The default location of the gsl
directory is /usr/local/include/gsl. A typical compilation command for
a source file example.c with the GNU C compiler gcc is,
$ gcc -Wall -I/usr/local/include -c example.c
This results in an object file example.o. The default include path for
gcc searches /usr/local/include automatically so the -I option can
actually be omitted when GSL is installed in its default location. "
This does not compile, also
$ gcc -Wall -I/usr/include -c example.c
and
$ gcc -Wall -I/usr/lib/ -c example.c
do not compile all with the error
gsl1.c:2:36: error: gsl/gsl_sf_bessel.h: No such file or directory
gsl1.c: In function 'main':
gsl1.c:8: warning: implicit declaration of function 'gsl_sf_bessel_J0'
Now on my debian box
$ find / -name gsl
/usr/include/gsl
but the gsl directory is empty. When I
$ locate gsl
i get, among other things
\snip
/usr/lib/libgslcblas.so.0
/usr/lib/libgslcblas.so.0.0.0
/usr/lib/libgsl.so.0
/usr/lib/libgsl.so.0.9.0
\snip
gsl is installed together with documentation using synaptic package
manager under
libgsl0
libgsl0ldbl
gsl-bin (apparently with example binaries that i cannot find)
gsl-ref-html
At this point i'm out of idea's. i'm new to this and any help is
greatfully recieved
--
comp.lang.c.moderated - moderation address: clcm@[EMAIL PROTECTED]
-- you must
have an appropriate newsgroups line in your header for your mail to be
seen,
or the newsgroup name in square brackets in the subject line. Sorry.