NetBSD 6.1.5 doesn't have ldexpl in math.h

Gary E. Miller gem at rellim.com
Thu Sep 7 19:47:42 UTC 2017


Yo Hal!

On Thu, 07 Sep 2017 01:37:30 -0700
Hal Murray <hmurray at megapathdsl.net> wrote:

> > Got a workaround?   
> 
> This seems to build and check:
> #include <math.h>       /* ldexpl() */
> #ifndef ldexpl
>   /* Missing in NetBSD 6.1.5 */
>   #define ldexpl ldexp
> #endif
> 
> Will that do the right conversions between double and long double?

Serious loss of precision, but maybe the best we can do.

> Do we want to work with old but still supported NetBSD or be sticky
> about requiring C99?

You brougth it up.  If yuo don't care we can drop that version of NetBSD.

> Eric:  Do we have a list of OSes and hardware where ntpsec is known
> to build and work?

buildbot.ntpsec.org.

> grep does find this in /usr/include/g++/cmath
>   inline long double
>   ldexp(long double __x, int __exp)
>   { return __builtin_ldexpl(__x, __exp); }

Is __builtin_ldexpl() defined anywhere?

RGDS
GARY
---------------------------------------------------------------------------
Gary E. Miller Rellim 109 NW Wilmington Ave., Suite E, Bend, OR 97703
	gem at rellim.com  Tel:+1 541 382 8588

	    Veritas liberabit vos. -- Quid est veritas?
    "If you can’t measure it, you can’t improve it." - Lord Kelvin
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 488 bytes
Desc: OpenPGP digital signature
URL: <https://lists.ntpsec.org/pipermail/devel/attachments/20170907/39f4c897/attachment.bin>


More information about the devel mailing list