On 29.07.2010 18:56, Eric Blake wrote: > [again, please keep the lists in the loop; and splitting my reply to > multiple topics] Sorry, sometimes I forget to use "reply all" instead of "reply"... > On 07/29/2010 10:46 AM, Rainer Tammer wrote: >> Hello Eric, >> source: m4-1.4.14.6-ffa0 >>>> 1. The test-strtod is still failing >>>> >>>> # ./test-strtod (compiled and executet manually) >>>> test-strtod.c:389: assertion failed >>> With the system's strtod, or with gnulib's replacement? >> It looks like the replacement was used, but please see below... >>> I'm wondering if you may have missed some prerequisites in the process. >>> >>> How about running: >>> >>> cd tests && make -k check >>> >> /bin/sh: 7340286 IOT/Abort trap(coredump) >> FAIL: test-strtod >> =============================== >> 1 of 103 tests failed >> (6 tests were not run) >> See tests/test-suite.log >> Please report to bug...@gnu.org >> =============================== >> >> This is a other failure: >> >> test-strtod.c:389: assertion failed >> >> { >> const char input[] = "0x"; >> char *ptr; >> double result; >> errno = 0; >> result = strtod (input, &ptr); >> ASSERT (result == 0.0); >> ASSERT (!signbit (result)); >> -> ASSERT (ptr == input + 1); /* glibc-2.3.6, MacOS X 10.3, >> FreeBSD 6.2 */ >> ASSERT (errno == 0); >> } > Now that the replacement strtod() calls the system's strtod() under the > hood, this could very well be a bug in our replacement not massaging the > data enough to work around the underlying strtod() bug. I'll take a > closer look into it. Please see below. > By the way, the snapshot I provided gives more details about why > configure rejected your system strtod(); could you provide the exit > status contained in config.log at the point where it ran the ./conftest > for strtod()? >
This are all strtod() related messages: configure:13680: checking whether strtod is declared configure:13680: cc -qlanglvl=extc89 -qlanglvl=extc99 -c -g conftest.c >&5 configure:13680: $? = 0 configure:13680: result: yes configure:25374: checking whether strtod is declared without a macro configure:25398: cc -qlanglvl=extc89 -qlanglvl=extc99 -c -g conftest.c >&5 configure:25398: $? = 0 configure:25406: result: yes configure:25948: checking whether strtod obeys C99 configure:26060: cc -qlanglvl=extc89 -qlanglvl=extc99 -o conftest -g conftest.c >&5 configure:26060: $? = 0 configure:26060: ./conftest configure:26060: $? = 3 configure: program exited with status 3 configure: failed program was: | /* confdefs.h */ ... cut .. configure:26070: result: no ac_cv_have_decl_strtod=yes gl_cv_func_strtod_works=no gl_cv_have_raw_decl_strtod=yes GNULIB_STRTOD='1' HAVE_STRTOD='1' REPLACE_STRTOD='1' #define HAVE_DECL_STRTOD 1 #define HAVE_RAW_DECL_STRTOD 1 #define GNULIB_TEST_STRTOD 1 > Another thing that might be helpful is to find _all_ strtod bugs in your > system, to make sure our wrapper is being careful for all of them. If > you could apply this patch, then recompile and rerun test-strtod.c, that > would give us a better listing of all points of failure in your system's > strtod(), rather than just the first point of failure. > > diff --git i/tests/test-strtod.c w/tests/test-strtod.c > index cdb57b2..e13f91c 100644 > --- i/tests/test-strtod.c > +++ w/tests/test-strtod.c > @@ -28,6 +28,8 @@ SIGNATURE_CHECK (strtod, double, > #include <string.h> > > #include "isnand-nolibm.h" > +#define abort() /* no-op */ > +#undef strtod > #include "macros.h" > > /* Avoid requiring -lm just for fabs. */ > OK, this is the result (all line numbers are +2 in respect to the source from m4-1.4.14.6-ffa0.tar.gz): test-strtod.c:391: assertion failed <- this is also OS related test-strtod.c:413: assertion failed <- this is caught by the replacement test-strtod.c:424: assertion failed <- ... test-strtod.c:435: assertion failed <- ... test-strtod.c:446: assertion failed <- ... test-strtod.c:457: assertion failed <- ... test-strtod.c:468: assertion failed <- ... test-strtod.c:479: assertion failed <- ... test-strtod.c:670: assertion failed <- ... test-strtod.c:671: assertion failed <- ... test-strtod.c:691: assertion failed <- ... test-strtod.c:720: assertion failed <- ... test-strtod.c:721: assertion failed <- ... test-strtod.c:762: assertion failed <- ... test-strtod.c:772: assertion failed <- ... Bye Rainer