Re: How to force using a module in Gnulib? (expl() on OpenBSD)

2014-04-15 Thread Pádraig Brady
On 04/15/2014 05:18 PM, Assaf Gordon wrote: > + dnl On some systems (OpenBSD5.4) the system's native expl() is buggy: > + dnl it returns 'nan' for small values. This test compares expl() to exp() . > + if test $gl_cv_func_expl_no_libm = yes \ > + || test $gl_cv_func_expl_in_libm = yes; then

Re: How to force using a module in Gnulib? (expl() on OpenBSD)

2014-04-15 Thread Assaf Gordon
Hello, On 04/15/2014 05:20 AM, Pádraig Brady wrote: On 04/15/2014 12:54 AM, Assaf Gordon wrote: It seems "expl()" is broken on OpenBSD5.4. You can set an override var for the configure run, <...> However, since you have a simple enough test it seems it would be better to incorporate that t

Re: [PATCH] physmem: use sysinfo on linux for physmem_total

2014-04-15 Thread Pádraig Brady
On 04/15/2014 03:43 PM, Natanael Copa wrote: > * lib/physmem.c (physmem_total): Some systems like musl libc does not > (yet) support _SC_PHYS_PAGES. Use the linux syscall sysinfo first and > fallback to sysconf with _SC_PHYS_PAGES and _SC_PAGESIZE. This looks good. I confirmed the values are the s

[PATCH] physmem: use sysinfo on linux for physmem_total

2014-04-15 Thread Natanael Copa
* lib/physmem.c (physmem_total): Some systems like musl libc does not (yet) support _SC_PHYS_PAGES. Use the linux syscall sysinfo first and fallback to sysconf with _SC_PHYS_PAGES and _SC_PAGESIZE. Signed-off-by: Natanael Copa --- lib/physmem.c | 13 - m4/physmem.m4 | 2 +- 2 files

physmem_total broken with musl libc

2014-04-15 Thread Natanael Copa
Hi, It seems like physmem_total is broken with musl libc since _SC_PHYS_PAGES is not implemented. Would it be an idea to use sysinfo from sys/sysinfo.h first and then fallback to the current _SC_PHYS_PAGES * _SC_PAGESIZE? Something like: diff --git a/lib/physmem.c b/lib/physmem.c index 7a67fb3

Re: How to force using a module in Gnulib? (expl() on OpenBSD)

2014-04-15 Thread Pádraig Brady
On 04/15/2014 12:54 AM, Assaf Gordon wrote: > 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