> 2 x FAIL: test-vsprintf-posix > 2 x FAIL: test-vsnprintf-posix > 2 x FAIL: test-sprintf-posix > 2 x FAIL: test-snprintf-posix
These failures on AIX occur when a precision > 998 is used on a floating-point number. Worked around through this fix: 2011-06-19 Bruno Haible <[email protected]> sprintf-posix: Fix test failure on AIX 7.1. * m4/printf.m4 (gl_PRINTF_PRECISION): Test against AIX bug. * doc/posix-functions/dprintf.texi: Mention limited precision problem on AIX. * doc/posix-functions/fprintf.texi: Likewise. * doc/posix-functions/printf.texi: Likewise. * doc/posix-functions/snprintf.texi: Likewise. * doc/posix-functions/sprintf.texi: Likewise. * doc/posix-functions/vdprintf.texi: Likewise. * doc/posix-functions/vfprintf.texi: Likewise. * doc/posix-functions/vprintf.texi: Likewise. * doc/posix-functions/vsnprintf.texi: Likewise. * doc/posix-functions/vsprintf.texi: Likewise. --- doc/posix-functions/dprintf.texi.orig Sun Jun 19 16:04:54 2011 +++ doc/posix-functions/dprintf.texi Sun Jun 19 15:56:29 2011 @@ -20,6 +20,10 @@ This function does not support the @samp{a} and @samp{A} directives on some platforms: glibc-2.3.6. +@item +This function does not support precisions larger than 512 or 1024 in integer, +floating-point and pointer output on some platforms: +AIX 7.1. @end itemize Portability problems not fixed by Gnulib: --- doc/posix-functions/fprintf.texi.orig Sun Jun 19 16:04:54 2011 +++ doc/posix-functions/fprintf.texi Sun Jun 19 15:56:29 2011 @@ -53,7 +53,7 @@ @item This function does not support precisions larger than 512 or 1024 in integer, floating-point and pointer output on some platforms: -Solaris 10/x86, mingw, BeOS. +AIX 7.1, Solaris 10/x86, mingw, BeOS. @item This function mishandles large floating point precisions (for example, formatting 1.0 with @samp{"%.511f"}) --- doc/posix-functions/printf.texi.orig Sun Jun 19 16:04:54 2011 +++ doc/posix-functions/printf.texi Sun Jun 19 15:56:30 2011 @@ -53,7 +53,7 @@ @item This function does not support precisions larger than 512 or 1024 in integer, floating-point and pointer output on some platforms: -Solaris 10/x86, mingw, BeOS. +AIX 7.1, Solaris 10/x86, mingw, BeOS. @item This function mishandles large floating point precisions (for example, formatting 1.0 with @samp{"%.511f"}) --- doc/posix-functions/snprintf.texi.orig Sun Jun 19 16:04:54 2011 +++ doc/posix-functions/snprintf.texi Sun Jun 19 15:56:30 2011 @@ -67,7 +67,7 @@ @item This function does not support precisions larger than 512 or 1024 in integer, floating-point and pointer output on some platforms: -Solaris 10/x86, mingw, BeOS. +AIX 7.1, Solaris 10/x86, mingw, BeOS. @item This function mishandles large floating point precisions (for example, formatting 1.0 with @samp{"%.511f"}) --- doc/posix-functions/sprintf.texi.orig Sun Jun 19 16:04:54 2011 +++ doc/posix-functions/sprintf.texi Sun Jun 19 15:56:30 2011 @@ -53,7 +53,7 @@ @item This function does not support precisions larger than 512 or 1024 in integer, floating-point and pointer output on some platforms: -Solaris 10/x86, mingw, BeOS. +AIX 7.1, Solaris 10/x86, mingw, BeOS. @item This function mishandles large floating point precisions (for example, formatting 1.0 with @samp{"%.511f"}) --- doc/posix-functions/vdprintf.texi.orig Sun Jun 19 16:04:54 2011 +++ doc/posix-functions/vdprintf.texi Sun Jun 19 15:55:32 2011 @@ -37,7 +37,7 @@ @item This function does not support precisions larger than 512 or 1024 in integer, floating-point and pointer output on some platforms: -BeOS. +AIX 7.1, BeOS. @end itemize Portability problems not fixed by Gnulib: --- doc/posix-functions/vfprintf.texi.orig Sun Jun 19 16:04:54 2011 +++ doc/posix-functions/vfprintf.texi Sun Jun 19 15:56:30 2011 @@ -53,7 +53,7 @@ @item This function does not support precisions larger than 512 or 1024 in integer, floating-point and pointer output on some platforms: -Solaris 10/x86, mingw, BeOS. +AIX 7.1, Solaris 10/x86, mingw, BeOS. @item This function mishandles large floating point precisions (for example, formatting 1.0 with @samp{"%.511f"}) --- doc/posix-functions/vprintf.texi.orig Sun Jun 19 16:04:54 2011 +++ doc/posix-functions/vprintf.texi Sun Jun 19 15:56:30 2011 @@ -53,7 +53,7 @@ @item This function does not support precisions larger than 512 or 1024 in integer, floating-point and pointer output on some platforms: -Solaris 10/x86, mingw, BeOS. +AIX 7.1, Solaris 10/x86, mingw, BeOS. @item This function mishandles large floating point precisions (for example, formatting 1.0 with @samp{"%.511f"}) --- doc/posix-functions/vsnprintf.texi.orig Sun Jun 19 16:04:54 2011 +++ doc/posix-functions/vsnprintf.texi Sun Jun 19 15:56:30 2011 @@ -67,7 +67,7 @@ @item This function does not support precisions larger than 512 or 1024 in integer, floating-point and pointer output on some platforms: -Solaris 10/x86, mingw, BeOS. +AIX 7.1, Solaris 10/x86, mingw, BeOS. @item This function mishandles large floating point precisions (for example, formatting 1.0 with @samp{"%.511f"}) --- doc/posix-functions/vsprintf.texi.orig Sun Jun 19 16:04:54 2011 +++ doc/posix-functions/vsprintf.texi Sun Jun 19 15:56:31 2011 @@ -53,7 +53,7 @@ @item This function does not support precisions larger than 512 or 1024 in integer, floating-point and pointer output on some platforms: -Solaris 10/x86, mingw, BeOS. +AIX 7.1, Solaris 10/x86, mingw, BeOS. @item This function mishandles large floating point precisions (for example, formatting 1.0 with @samp{"%.511f"}) --- m4/printf.m4.orig Sun Jun 19 16:04:54 2011 +++ m4/printf.m4 Sun Jun 19 16:04:50 2011 @@ -1,4 +1,4 @@ -# printf.m4 serial 42 +# printf.m4 serial 43 dnl Copyright (C) 2003, 2007-2011 Free Software Foundation, Inc. dnl This file is free software; the Free Software Foundation dnl gives unlimited permission to copy and/or distribute it, @@ -892,7 +892,8 @@ dnl floating-point or pointer output. On Solaris 10/x86, precisions larger dnl than 510 in floating-point output crash the program. On Solaris 10/SPARC, dnl precisions larger than 510 in floating-point output yield wrong results. -dnl On BeOS, precisions larger than 1044 crash the program. +dnl On AIX 7.1, precisions larger than 998 in floating-point output yield +dnl wrong results. On BeOS, precisions larger than 1044 crash the program. dnl Result is gl_cv_func_printf_precision. AC_DEFUN([gl_PRINTF_PRECISION], @@ -921,6 +922,9 @@ if (sprintf (buf, "%.511f %d", 1.0, 33, 44) < 511 + 5 || buf[0] != '1') result |= 4; + if (sprintf (buf, "%.999f %d", 1.0, 33, 44) < 999 + 5 + || buf[0] != '1') + result |= 4; return result; }]])], [gl_cv_func_printf_precision=yes], @@ -1465,7 +1469,8 @@ dnl Solaris 10 . . # # # . . # . . . # # . . . . . . . dnl Solaris 2.6 ... 9 # . # # # # . # . . . # # . . . # . . . dnl Solaris 2.5.1 # . # # # # . # . . . # . . # # # # # # -dnl AIX 5.2, 7.1 . . # # # . . . . . . # . . . . . . . . +dnl AIX 7.1 . . # # # . . . . . . # # . . . . . . . +dnl AIX 5.2 . . # # # . . . . . . # . . . . . . . . dnl AIX 4.3.2, 5.1 # . # # # # . . . . . # . . . . # . . . dnl HP-UX 11.31 . . . . # . . . . . . # . . . . # # . . dnl HP-UX 11.{00,11,23} # . . . # # . . . . . # . . . . # # . # -- In memoriam Alois Eliáš <http://en.wikipedia.org/wiki/Alois_Eliáš>
