mirror of
https://git.savannah.gnu.org/git/gnulib.git
synced 2025-08-08 17:22:05 +03:00
Fix side effects from tests-related modules.
This commit is contained in:
31
ChangeLog
31
ChangeLog
@@ -1,3 +1,34 @@
|
|||||||
|
2010-04-08 Bruno Haible <bruno@clisp.org>
|
||||||
|
|
||||||
|
Fix side effects from tests-related modules.
|
||||||
|
* modules/dprintf-posix (Comment): New section.
|
||||||
|
* modules/fprintf-posix (Comment): Likewise.
|
||||||
|
* modules/obstack-printf-posix (Comment): Likewise.
|
||||||
|
* modules/printf-posix (Comment): Likewise.
|
||||||
|
* modules/snprintf-posix (Comment): Likewise.
|
||||||
|
* modules/sprintf-posix (Comment): Likewise.
|
||||||
|
* modules/vasnprintf-posix (Comment): Likewise.
|
||||||
|
* modules/vasprintf-posix (Comment): Likewise.
|
||||||
|
* modules/vdprintf-posix (Comment): Likewise.
|
||||||
|
* modules/vfprintf-posix (Comment): Likewise.
|
||||||
|
* modules/vprintf-posix (Comment): Likewise.
|
||||||
|
* modules/vsnprintf-posix (Comment): Likewise.
|
||||||
|
* modules/vsprintf-posix (Comment): Likewise.
|
||||||
|
* modules/xprintf-posix (Comment): Likewise.
|
||||||
|
* modules/xvasprintf-posix (Comment): Likewise.
|
||||||
|
* modules/ceilf-tests (Depends-on): Remove fprintf-posix.
|
||||||
|
* modules/floorf-tests (Depends-on): Likewise.
|
||||||
|
* modules/round-tests (Depends-on): Likewise.
|
||||||
|
* modules/roundf-tests (Depends-on): Likewise.
|
||||||
|
* modules/trunc-tests (Depends-on): Likewise.
|
||||||
|
* modules/truncf-tests (Depends-on): Likewise.
|
||||||
|
* tests/test-ceilf2.c (check): Don't invoke fprintf if the
|
||||||
|
'fprintf-posix' module is not present.
|
||||||
|
* tests/test-floorf2.c (check): Likewise.
|
||||||
|
* tests/test-trunc2.c (check): Likewise.
|
||||||
|
* tests/test-truncf2.c (check): Likewise.
|
||||||
|
* tests/test-round2.c (equal): Likewise.
|
||||||
|
|
||||||
2010-04-07 Karl Berry <karl@gnu.org>
|
2010-04-07 Karl Berry <karl@gnu.org>
|
||||||
|
|
||||||
* config/srclist.txt,
|
* config/srclist.txt,
|
||||||
|
@@ -10,7 +10,6 @@ float
|
|||||||
isnanf-nolibm
|
isnanf-nolibm
|
||||||
stdbool
|
stdbool
|
||||||
stdint
|
stdint
|
||||||
fprintf-posix
|
|
||||||
|
|
||||||
configure.ac:
|
configure.ac:
|
||||||
|
|
||||||
|
@@ -2,6 +2,12 @@ Description:
|
|||||||
POSIX compatible dprintf() function: print formatted output to a file
|
POSIX compatible dprintf() function: print formatted output to a file
|
||||||
descriptor
|
descriptor
|
||||||
|
|
||||||
|
Comment:
|
||||||
|
This module should not be used as a dependency from a test module,
|
||||||
|
otherwise when this module occurs as a tests-related module, it will
|
||||||
|
have side effects on the compilation of the 'vasnprintf' module, if
|
||||||
|
that module occurs among the main modules in lib/.
|
||||||
|
|
||||||
Files:
|
Files:
|
||||||
m4/dprintf-posix.m4
|
m4/dprintf-posix.m4
|
||||||
m4/printf.m4
|
m4/printf.m4
|
||||||
|
@@ -10,7 +10,6 @@ float
|
|||||||
isnanf-nolibm
|
isnanf-nolibm
|
||||||
stdbool
|
stdbool
|
||||||
stdint
|
stdint
|
||||||
fprintf-posix
|
|
||||||
|
|
||||||
configure.ac:
|
configure.ac:
|
||||||
|
|
||||||
|
@@ -1,6 +1,12 @@
|
|||||||
Description:
|
Description:
|
||||||
POSIX compatible fprintf() function: print formatted output to a stream
|
POSIX compatible fprintf() function: print formatted output to a stream
|
||||||
|
|
||||||
|
Comment:
|
||||||
|
This module should not be used as a dependency from a test module,
|
||||||
|
otherwise when this module occurs as a tests-related module, it will
|
||||||
|
have side effects on the compilation of the 'vasnprintf' module, if
|
||||||
|
that module occurs among the main modules in lib/.
|
||||||
|
|
||||||
Files:
|
Files:
|
||||||
lib/fprintf.c
|
lib/fprintf.c
|
||||||
m4/fprintf-posix.m4
|
m4/fprintf-posix.m4
|
||||||
|
@@ -1,6 +1,12 @@
|
|||||||
Description:
|
Description:
|
||||||
POSIX formatted printing into an obstack.
|
POSIX formatted printing into an obstack.
|
||||||
|
|
||||||
|
Comment:
|
||||||
|
This module should not be used as a dependency from a test module,
|
||||||
|
otherwise when this module occurs as a tests-related module, it will
|
||||||
|
have side effects on the compilation of the 'vasnprintf' module, if
|
||||||
|
that module occurs among the main modules in lib/.
|
||||||
|
|
||||||
Files:
|
Files:
|
||||||
m4/obstack-printf.m4
|
m4/obstack-printf.m4
|
||||||
m4/obstack-printf-posix.m4
|
m4/obstack-printf-posix.m4
|
||||||
|
@@ -1,6 +1,12 @@
|
|||||||
Description:
|
Description:
|
||||||
POSIX compatible printf() function: print formatted output to standard output
|
POSIX compatible printf() function: print formatted output to standard output
|
||||||
|
|
||||||
|
Comment:
|
||||||
|
This module should not be used as a dependency from a test module,
|
||||||
|
otherwise when this module occurs as a tests-related module, it will
|
||||||
|
have side effects on the compilation of the 'vasnprintf' module, if
|
||||||
|
that module occurs among the main modules in lib/.
|
||||||
|
|
||||||
Files:
|
Files:
|
||||||
lib/printf.c
|
lib/printf.c
|
||||||
m4/printf-posix-rpl.m4
|
m4/printf-posix-rpl.m4
|
||||||
|
@@ -9,7 +9,6 @@ Depends-on:
|
|||||||
isnand-nolibm
|
isnand-nolibm
|
||||||
stdbool
|
stdbool
|
||||||
stdint
|
stdint
|
||||||
fprintf-posix
|
|
||||||
verify
|
verify
|
||||||
|
|
||||||
configure.ac:
|
configure.ac:
|
||||||
|
@@ -12,7 +12,6 @@ floorf
|
|||||||
isnanf-nolibm
|
isnanf-nolibm
|
||||||
stdbool
|
stdbool
|
||||||
stdint
|
stdint
|
||||||
fprintf-posix
|
|
||||||
verify
|
verify
|
||||||
|
|
||||||
configure.ac:
|
configure.ac:
|
||||||
|
@@ -2,6 +2,12 @@ Description:
|
|||||||
POSIX compatible snprintf() function: print formatted output to a fixed length
|
POSIX compatible snprintf() function: print formatted output to a fixed length
|
||||||
string
|
string
|
||||||
|
|
||||||
|
Comment:
|
||||||
|
This module should not be used as a dependency from a test module,
|
||||||
|
otherwise when this module occurs as a tests-related module, it will
|
||||||
|
have side effects on the compilation of the 'vasnprintf' module, if
|
||||||
|
that module occurs among the main modules in lib/.
|
||||||
|
|
||||||
Files:
|
Files:
|
||||||
m4/snprintf-posix.m4
|
m4/snprintf-posix.m4
|
||||||
m4/printf.m4
|
m4/printf.m4
|
||||||
|
@@ -1,6 +1,12 @@
|
|||||||
Description:
|
Description:
|
||||||
POSIX compatible sprintf() function: print formatted output to a string
|
POSIX compatible sprintf() function: print formatted output to a string
|
||||||
|
|
||||||
|
Comment:
|
||||||
|
This module should not be used as a dependency from a test module,
|
||||||
|
otherwise when this module occurs as a tests-related module, it will
|
||||||
|
have side effects on the compilation of the 'vasnprintf' module, if
|
||||||
|
that module occurs among the main modules in lib/.
|
||||||
|
|
||||||
Files:
|
Files:
|
||||||
lib/sprintf.c
|
lib/sprintf.c
|
||||||
m4/sprintf-posix.m4
|
m4/sprintf-posix.m4
|
||||||
|
@@ -10,7 +10,6 @@ float
|
|||||||
isnand-nolibm
|
isnand-nolibm
|
||||||
stdbool
|
stdbool
|
||||||
stdint
|
stdint
|
||||||
fprintf-posix
|
|
||||||
|
|
||||||
configure.ac:
|
configure.ac:
|
||||||
|
|
||||||
|
@@ -10,7 +10,6 @@ float
|
|||||||
isnanf-nolibm
|
isnanf-nolibm
|
||||||
stdbool
|
stdbool
|
||||||
stdint
|
stdint
|
||||||
fprintf-posix
|
|
||||||
|
|
||||||
configure.ac:
|
configure.ac:
|
||||||
|
|
||||||
|
@@ -2,6 +2,12 @@ Description:
|
|||||||
POSIX compatible vsprintf with automatic memory allocation and bounded output
|
POSIX compatible vsprintf with automatic memory allocation and bounded output
|
||||||
size.
|
size.
|
||||||
|
|
||||||
|
Comment:
|
||||||
|
This module should not be used as a dependency from a test module,
|
||||||
|
otherwise when this module occurs as a tests-related module, it will
|
||||||
|
have side effects on the compilation of the 'vasnprintf' module, if
|
||||||
|
that module occurs among the main modules in lib/.
|
||||||
|
|
||||||
Files:
|
Files:
|
||||||
m4/vasnprintf-posix.m4
|
m4/vasnprintf-posix.m4
|
||||||
m4/printf.m4
|
m4/printf.m4
|
||||||
|
@@ -1,6 +1,12 @@
|
|||||||
Description:
|
Description:
|
||||||
POSIX compatible vsprintf with automatic memory allocation.
|
POSIX compatible vsprintf with automatic memory allocation.
|
||||||
|
|
||||||
|
Comment:
|
||||||
|
This module should not be used as a dependency from a test module,
|
||||||
|
otherwise when this module occurs as a tests-related module, it will
|
||||||
|
have side effects on the compilation of the 'vasnprintf' module, if
|
||||||
|
that module occurs among the main modules in lib/.
|
||||||
|
|
||||||
Files:
|
Files:
|
||||||
m4/vasprintf-posix.m4
|
m4/vasprintf-posix.m4
|
||||||
m4/printf.m4
|
m4/printf.m4
|
||||||
|
@@ -2,6 +2,12 @@ Description:
|
|||||||
POSIX compatible vdprintf() function: print formatted output to a file
|
POSIX compatible vdprintf() function: print formatted output to a file
|
||||||
descriptor
|
descriptor
|
||||||
|
|
||||||
|
Comment:
|
||||||
|
This module should not be used as a dependency from a test module,
|
||||||
|
otherwise when this module occurs as a tests-related module, it will
|
||||||
|
have side effects on the compilation of the 'vasnprintf' module, if
|
||||||
|
that module occurs among the main modules in lib/.
|
||||||
|
|
||||||
Files:
|
Files:
|
||||||
m4/vdprintf-posix.m4
|
m4/vdprintf-posix.m4
|
||||||
m4/printf.m4
|
m4/printf.m4
|
||||||
|
@@ -1,6 +1,12 @@
|
|||||||
Description:
|
Description:
|
||||||
POSIX compatible vfprintf() function: print formatted output to a stream
|
POSIX compatible vfprintf() function: print formatted output to a stream
|
||||||
|
|
||||||
|
Comment:
|
||||||
|
This module should not be used as a dependency from a test module,
|
||||||
|
otherwise when this module occurs as a tests-related module, it will
|
||||||
|
have side effects on the compilation of the 'vasnprintf' module, if
|
||||||
|
that module occurs among the main modules in lib/.
|
||||||
|
|
||||||
Files:
|
Files:
|
||||||
lib/vfprintf.c
|
lib/vfprintf.c
|
||||||
m4/vfprintf-posix.m4
|
m4/vfprintf-posix.m4
|
||||||
|
@@ -1,6 +1,12 @@
|
|||||||
Description:
|
Description:
|
||||||
POSIX compatible vprintf() function: print formatted output to standard output
|
POSIX compatible vprintf() function: print formatted output to standard output
|
||||||
|
|
||||||
|
Comment:
|
||||||
|
This module should not be used as a dependency from a test module,
|
||||||
|
otherwise when this module occurs as a tests-related module, it will
|
||||||
|
have side effects on the compilation of the 'vasnprintf' module, if
|
||||||
|
that module occurs among the main modules in lib/.
|
||||||
|
|
||||||
Files:
|
Files:
|
||||||
lib/vprintf.c
|
lib/vprintf.c
|
||||||
m4/vprintf-posix.m4
|
m4/vprintf-posix.m4
|
||||||
|
@@ -2,6 +2,12 @@ Description:
|
|||||||
POSIX compatible vsnprintf() function: print formatted output to a fixed length
|
POSIX compatible vsnprintf() function: print formatted output to a fixed length
|
||||||
string
|
string
|
||||||
|
|
||||||
|
Comment:
|
||||||
|
This module should not be used as a dependency from a test module,
|
||||||
|
otherwise when this module occurs as a tests-related module, it will
|
||||||
|
have side effects on the compilation of the 'vasnprintf' module, if
|
||||||
|
that module occurs among the main modules in lib/.
|
||||||
|
|
||||||
Files:
|
Files:
|
||||||
m4/vsnprintf-posix.m4
|
m4/vsnprintf-posix.m4
|
||||||
m4/printf.m4
|
m4/printf.m4
|
||||||
|
@@ -1,6 +1,12 @@
|
|||||||
Description:
|
Description:
|
||||||
POSIX compatible vsprintf() function: print formatted output to a string
|
POSIX compatible vsprintf() function: print formatted output to a string
|
||||||
|
|
||||||
|
Comment:
|
||||||
|
This module should not be used as a dependency from a test module,
|
||||||
|
otherwise when this module occurs as a tests-related module, it will
|
||||||
|
have side effects on the compilation of the 'vasnprintf' module, if
|
||||||
|
that module occurs among the main modules in lib/.
|
||||||
|
|
||||||
Files:
|
Files:
|
||||||
lib/vsprintf.c
|
lib/vsprintf.c
|
||||||
m4/vsprintf-posix.m4
|
m4/vsprintf-posix.m4
|
||||||
|
@@ -2,6 +2,12 @@ Description:
|
|||||||
A wrapper around printf with POSIX compatible format string interpretation,
|
A wrapper around printf with POSIX compatible format string interpretation,
|
||||||
that calls error upon ENOMEM or EILSEQ errors.
|
that calls error upon ENOMEM or EILSEQ errors.
|
||||||
|
|
||||||
|
Comment:
|
||||||
|
This module should not be used as a dependency from a test module,
|
||||||
|
otherwise when this module occurs as a tests-related module, it will
|
||||||
|
have side effects on the compilation of the 'vasnprintf' module, if
|
||||||
|
that module occurs among the main modules in lib/.
|
||||||
|
|
||||||
Files:
|
Files:
|
||||||
|
|
||||||
Depends-on:
|
Depends-on:
|
||||||
|
@@ -2,6 +2,12 @@ Description:
|
|||||||
vasprintf and asprintf with POSIX compatible format string interpretation and
|
vasprintf and asprintf with POSIX compatible format string interpretation and
|
||||||
with out-of-memory checking. Also see xalloc-die.
|
with out-of-memory checking. Also see xalloc-die.
|
||||||
|
|
||||||
|
Comment:
|
||||||
|
This module should not be used as a dependency from a test module,
|
||||||
|
otherwise when this module occurs as a tests-related module, it will
|
||||||
|
have side effects on the compilation of the 'vasnprintf' module, if
|
||||||
|
that module occurs among the main modules in lib/.
|
||||||
|
|
||||||
Files:
|
Files:
|
||||||
|
|
||||||
Depends-on:
|
Depends-on:
|
||||||
|
@@ -16,6 +16,9 @@
|
|||||||
|
|
||||||
/* Written by Bruno Haible <bruno@clisp.org>, 2007. */
|
/* Written by Bruno Haible <bruno@clisp.org>, 2007. */
|
||||||
|
|
||||||
|
/* When this test fails on some platform, build it together with the gnulib
|
||||||
|
module 'fprintf-posix' for optimal debugging output. */
|
||||||
|
|
||||||
#include <config.h>
|
#include <config.h>
|
||||||
|
|
||||||
#include <math.h>
|
#include <math.h>
|
||||||
@@ -119,8 +122,10 @@ check (float x)
|
|||||||
return 0;
|
return 0;
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
#if GNULIB_TEST_FPRINTF_POSIX
|
||||||
fprintf (stderr, "ceilf %g(%a) = %g(%a) or %g(%a)?\n",
|
fprintf (stderr, "ceilf %g(%a) = %g(%a) or %g(%a)?\n",
|
||||||
x, x, reference, reference, result, result);
|
x, x, reference, reference, result, result);
|
||||||
|
#endif
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -16,6 +16,9 @@
|
|||||||
|
|
||||||
/* Written by Bruno Haible <bruno@clisp.org>, 2007. */
|
/* Written by Bruno Haible <bruno@clisp.org>, 2007. */
|
||||||
|
|
||||||
|
/* When this test fails on some platform, build it together with the gnulib
|
||||||
|
module 'fprintf-posix' for optimal debugging output. */
|
||||||
|
|
||||||
#include <config.h>
|
#include <config.h>
|
||||||
|
|
||||||
#include <math.h>
|
#include <math.h>
|
||||||
@@ -119,8 +122,10 @@ check (float x)
|
|||||||
return 0;
|
return 0;
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
#if GNULIB_TEST_FPRINTF_POSIX
|
||||||
fprintf (stderr, "floorf %g(%a) = %g(%a) or %g(%a)?\n",
|
fprintf (stderr, "floorf %g(%a) = %g(%a) or %g(%a)?\n",
|
||||||
x, x, reference, reference, result, result);
|
x, x, reference, reference, result, result);
|
||||||
|
#endif
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -17,6 +17,9 @@
|
|||||||
/* Written by Ben Pfaff <blp@gnu.org>, 2007.
|
/* Written by Ben Pfaff <blp@gnu.org>, 2007.
|
||||||
Heavily based on code by Bruno Haible. */
|
Heavily based on code by Bruno Haible. */
|
||||||
|
|
||||||
|
/* When this test fails on some platform, build it together with the gnulib
|
||||||
|
module 'fprintf-posix' for optimal debugging output. */
|
||||||
|
|
||||||
/* Get the two reference implementations of round under the names
|
/* Get the two reference implementations of round under the names
|
||||||
round_reference1 and round_reference2.
|
round_reference1 and round_reference2.
|
||||||
|
|
||||||
@@ -62,8 +65,10 @@ equal (const char *message, DOUBLE x, DOUBLE y0, DOUBLE y1)
|
|||||||
return true;
|
return true;
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
#if GNULIB_TEST_FPRINTF_POSIX
|
||||||
fprintf (stderr, "%s: "FUNCTION"(%g(%a)) = %g(%a) or %g(%a)?\n",
|
fprintf (stderr, "%s: "FUNCTION"(%g(%a)) = %g(%a) or %g(%a)?\n",
|
||||||
message, x, x, y0, y0, y1, y1);
|
message, x, x, y0, y0, y1, y1);
|
||||||
|
#endif
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -16,6 +16,9 @@
|
|||||||
|
|
||||||
/* Written by Bruno Haible <bruno@clisp.org>, 2007. */
|
/* Written by Bruno Haible <bruno@clisp.org>, 2007. */
|
||||||
|
|
||||||
|
/* When this test fails on some platform, build it together with the gnulib
|
||||||
|
module 'fprintf-posix' for optimal debugging output. */
|
||||||
|
|
||||||
#include <config.h>
|
#include <config.h>
|
||||||
|
|
||||||
#include <math.h>
|
#include <math.h>
|
||||||
@@ -123,8 +126,10 @@ check (double x)
|
|||||||
return 0;
|
return 0;
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
#if GNULIB_TEST_FPRINTF_POSIX
|
||||||
fprintf (stderr, "trunc %g(%a) = %g(%a) or %g(%a)?\n",
|
fprintf (stderr, "trunc %g(%a) = %g(%a) or %g(%a)?\n",
|
||||||
x, x, reference, reference, result, result);
|
x, x, reference, reference, result, result);
|
||||||
|
#endif
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -16,6 +16,9 @@
|
|||||||
|
|
||||||
/* Written by Bruno Haible <bruno@clisp.org>, 2007. */
|
/* Written by Bruno Haible <bruno@clisp.org>, 2007. */
|
||||||
|
|
||||||
|
/* When this test fails on some platform, build it together with the gnulib
|
||||||
|
module 'fprintf-posix' for optimal debugging output. */
|
||||||
|
|
||||||
#include <config.h>
|
#include <config.h>
|
||||||
|
|
||||||
#include <math.h>
|
#include <math.h>
|
||||||
@@ -123,8 +126,10 @@ check (float x)
|
|||||||
return 0;
|
return 0;
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
#if GNULIB_TEST_FPRINTF_POSIX
|
||||||
fprintf (stderr, "truncf %g(%a) = %g(%a) or %g(%a)?\n",
|
fprintf (stderr, "truncf %g(%a) = %g(%a) or %g(%a)?\n",
|
||||||
x, x, reference, reference, result, result);
|
x, x, reference, reference, result, result);
|
||||||
|
#endif
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user