bug-gsl
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug-gsl]Re: Bug#179665: /usr/include/gsl/gsl_chebyshev.h:81: syntax err


From: Dirk Eddelbuettel
Subject: [Bug-gsl]Re: Bug#179665: /usr/include/gsl/gsl_chebyshev.h:81: syntax error before '*' token
Date: Mon, 3 Feb 2003 19:33:05 -0600
User-agent: Mutt/1.2.5i

Hi Paolo,

Thanks for the report.

On Mon, Feb 03, 2003 at 10:33:45PM +0100, Paolo Redaelli wrote:
> Package: libgsl0-dev
> Version: 1.3-1
> Severity: normal
> File: /usr/include/gsl/gsl_chebyshev.h
> 
> compiling this 
> =======
> #include "gsl.h"

You are supposed to include  #include <gsl/gsl_$SOMEFILE.h>, see the manual.

> int main ( void) {
>   printf("test");
> }
> =======
> with the following gsl.h gives you:
> address@hidden:~/Eiffel/Progetti/egsl$ gcc test.c  -I /usr/include/gsl/
> In file included from gsl.h:9,
>                  from test.c:1:
> /usr/include/gsl/gsl_chebyshev.h:81: syntax error before '*' token

Well, while this could be seen as a bug, your test program is also less than
ideal. First, as stated above, you are constructing the header file the
wrong way. Secondly, you are building it in a less than ideal way. Lastly,
the library invites modularity. Nobody should include all header files just
for the fun of it. 

See for this working example:

address@hidden:/tmp/gsl> cat paolo.c
#include <gsl/gsl_math.h>

int main ( void) {
     printf("test\n");
}
address@hidden:/tmp/gsl> gcc -o paolo paolo.c -lm -lgsl -lgslcblas
address@hidden:/tmp/gsl> ./paolo
test

Can you create an example using the chebyshev header file which actually
fails?  Compiling the actual example from the manual work just fine:

address@hidden:/tmp/gsl> head -10 cheb.c
#include <stdio.h>
#include <gsl/gsl_math.h>
#include <gsl/gsl_chebyshev.h>

double
f (double x, void *p)
{
  if (x < 0.5)
    return 0.25;
  else
address@hidden:/tmp/gsl> gcc -o cheb cheb.c -lm -lgsl -lgslcblas
address@hidden:/tmp/gsl> ./cheb | wc -l
  10000

So unless you can substantiate the bug report, I will probably just close it. 
But I'll pass this on to Brian just in case.

Regards, Dirk



> 
> =====gsl.h=======
> /* Include file for  */
> /* Eiffel Gnu Scientific Library */
> 
> 
> #include <gsl_blas.h>
> #include <gsl_blas_types.h>
> #include <gsl_block.h>
> #include <gsl_cblas.h>
> #include <gsl_chebyshev.h>
> #include <gsl_combination.h>
> #include <gsl_complex.h>
> #include <gsl_complex_math.h>
> #include <gsl_const_cgs.h>
> #include <gsl_const.h>
> #include <gsl_const_mks.h>
> #include <gsl_const_num.h>
> #include <gsl_dft_complex_float.h>
> #include <gsl_dft_complex.h>
> #include <gsl_dht.h>
> #include <gsl_diff.h>
> #include <gsl_eigen.h>
> #include <gsl_errno.h>
> #include <gsl_fft.h>
> #include <gsl_fit.h>
> #include <gsl_heapsort.h>
> #include <gsl_histogram2d.h>
> #include <gsl_histogram.h>
> #include <gsl_ieee_utils.h>
> #include <gsl_integration.h>
> #include <gsl_interp.h>
> #include <gsl_linalg.h>
> #include <gsl_machine.h>
> #include <gsl_math.h>
> #include <gsl_matrix.h>
> #include <gsl_message.h>
> #include <gsl_min.h>
> #include <gsl_mode.h>
> #include <gsl_monte.h>
> #include <gsl_monte_miser.h>
> #include <gsl_monte_plain.h>
> #include <gsl_monte_vegas.h>
> #include <gsl_multifit.h>
> #include <gsl_multifit_nlin.h>
> #include <gsl_multimin.h>
> #include <gsl_multiroots.h>
> #include <gsl_nan.h>
> #include <gsl_ntuple.h>
> #include <gsl_odeiv.h>
> #include <gsl_permutation.h>
> #include <gsl_permute.h>
> #include <gsl_permute_vector.h>
> #include <gsl_poly.h>
> #include <gsl_pow_int.h>
> #include <gsl_precision.h>
> #include <gsl_qrng.h>
> #include <gsl_randist.h>
> #include <gsl_rng.h>
> #include <gsl_roots.h>
> #include <gsl_sf.h>
> #include <gsl_siman.h>
> #include <gsl_sort.h>
> #include <gsl_sort_vector.h>
> #include <gsl_specfunc.h>
> #include <gsl_spline.h>
> #include <gsl_statistics.h>
> #include <gsl_sum.h>
> #include <gsl_sys.h>
> #include <gsl_test.h>
> #include <gsl_types.h>
> #include <gsl_vector.h>
> #include <gsl_version.h>
> ==============================
> 
> -- System Information:
> Debian Release: testing/unstable
> Architecture: powerpc
> Kernel: Linux antares 2.4.20-pre7-ben0 #4 SMP Thu Oct 3 21:17:24 CEST 2002 ppc
> Locale: LANG=it_IT, LC_CTYPE=it_IT
> 
> Versions of packages libgsl0-dev depends on:
> ii  libgsl0                       1.3-1      The GNU Scientific Library (GSL) 
> -
> 
> -- no debconf information
> 
> 

-- 
Three out of two people have difficulties with fractions.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]