Hello, How do I force using the GnuLib implementation of a module, despite the platform having the function ?
Case in point: It seems "expl()" is broken on OpenBSD5.4. Others have noticed the same: http://openbsd.7691.n7.nabble.com/exp-expl-on-Linux-and-OpenBSD-expl-bug-td242556.html But a simple test-case is: ====== $ cat 1.c #include <math.h> #include <stdio.h> #include <stdlib.h> int main() { const long double x = 0.705084 ; const long double x2 = -x/2; const long double e = exp(x2); const long double el = expl(x2); printf("x = %Lg\n", x); printf("-x/2 = %Lg\n", x2); printf("exp(-x/2) = %Lg\n", e); printf("expl(-x/2) = %Lg\n", el); return 0; } $ cc -O2 -pipe -lm -o 1 1.c $ ./1 x = 0.705084 -x/2 = -0.352542 exp(-x/2) = 0.702899 expl(-x/2) = nan ======== Notice "expl" returns "nan", whereas every other system I've tried returns the correct value of "0.702" instead of "nan" . The system is ===== $ uname -a OpenBSD obsd.my.domain 5.4 GENERIC#37 amd64 $ cc --version cc (GCC) 4.2.1 20070719 ===== In my project, the "expl" module from Gnulib is included in the distribution, but during "configure" it is determined that it is not needed, and it is not compiled. How can I override that ? Thank you, -gordon