On Thu, 13 Dec 2018 09:02:05 +1300
Henri Menke
On 13/12/18 8:56 AM, Alan Braslau wrote:
On Wed, 12 Dec 2018 20:42:56 +0100 "Mikael P. Sundqvist"
wrote: Thanks, Alan! That looks very promising. I could not make it work, though, and I guess that is because I use linux and do not know what to change for what. I installed libcerf but I assume something else is missing. In any case, this is one of the things it would be nice to have, at least as a module. I have no idea on how to realize that, though.
/Mikael
You likely also need to install libffi - I do not know what package this is on your flavor of linux - Luigi is the ffi specialist!
FFI is integrated in LuaTeX >= 1.03
In you example you load libcerf but you are not using it. What you are actually using are the Bessel function from the C Standard library. GCC includes them as a GNU extension. https://www.gnu.org/software/libc/manual/html_node/Special-Functions.html#in... Your example also works if you remove libcerf (at least for me on Linux).
I had stripped-down my example, for in fact I use the voigt and error functions from libcerf, and yes the Bessel functions from the standard C math library. One should note, by the way, that the C math library is more or less complete depending on the system, and not everyone uses gcc nor gnu... Alan