In the last episode (Nov 10), Xavier Beaudouin said:
Le 8 nov. 04, à 18:07, Dan Nelson a écrit :
In the last episode (Nov 08), Xavier Beaudouin said:
I have the following error when compiling pike 7.2.570 on freebsd sparc64 :
Compiling peep_t.c svalue.o(.text+0x23bc): In function `is_lt': : undefined reference to `_Qp_cmp'
Can you tell me where is this comming from ?
It looks like gcc has decided to use a function call to implement a long double compare, but the function was never implemented. Could you see if you can generate a minimal testcase that produces this error? Something like
main() { long double a = 1.0; long double b = 2.0; return (a<b); }
I have just tryed this on my sparc machine and this work like a charm... No compilation error or whatever...
Right. This particular testcase works; I should have mentioned that I had someone with a FreeBSD/sparc64 system try it for me. It ends up calling _Qp_flt (the less-than comparison function). The problem is, I don't know in which cases gcc generates a generic compare (_Qp_cmp), but apparently something does. I've filed a bugreport on it and included a pointer to NetBSD's libc, since it looks like they have implemented all the functions. It's PR sparc64/73782.
Maybe on such machines --with-long-double-precision shoud not be applied ?
Well, a better fix would be to add the appropriate functions to libc :)