[Top][All Lists]

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

[Octave-patch-tracker] [patch #9432] How to add new gsl functions to oct

From: Julien Bect
Subject: [Octave-patch-tracker] [patch #9432] How to add new gsl functions to octave?
Date: Fri, 18 Aug 2017 04:04:54 -0400 (EDT)
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Firefox/52.0

Follow-up Comment #1, patch #9432 (project octave):

The problem is easy to see if you build step by step.

First, if you just try to bootstrap with your patch:

cd src

you get the following error:

/bin/sed: can't read D_DD.template.cc: No such file or directory

The proper template to use would have been D_D since the function you're
interested in takes one double input and returns one double output.

If I simply fix that, I get another (more severe) problem at the make step.  

./bootstrap && ./configure && make

fails with:

/usr/bin/mkoctfile  gsl_sf.cc -lgsl
gsl_sf.cc: In function ‘octave_value_list Fgsl_sf_ran_landau_pdf(const
octave_value_list&, int)’:
gsl_sf.cc:34276:52: error: ‘gsl_ran_landau_pdf’ was not declared in this
           gsl_ran_landau_pdf (arg1_data[i], &result);
gsl_sf.cc:34290:52: error: ‘gsl_ran_landau_pdf’ was not declared in this
           gsl_ran_landau_pdf (arg1_data[i], &result);
Makefile:29 : la recette pour la cible « gsl_sf.oct » a échouée
make: *** [gsl_sf.oct] Erreur 1

This is because all the templates that are currently available expect the
signature of the gsl_sf_*_e functions, i.e., an int return type for the error
code and a final gsl_sf_result argument for the double return value.

If you want to add gsl_ran_landau_pdf to the gsl package, you must either
write a new kind of template, or wrap the gsl_ran_landau_pdf function inside
an gsl_ran_landau_pdf_e function to make it look like the others.


Reply to this item at:


  Message sent via/by Savannah

reply via email to

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