Minimize printf/scanf size on platforms that don't need C99.
* acconfig.h (_WANT_IO_C99_FORMATS): New macro. * newlib.hin (_WANT_IO_C99_FORMATS): Likewise. * configure.in (newlib-io-c99-formats): New configure option. (_WANT_IO_C99_FORMATS): Define appropriately. * configure.host (*-linux*, cygwin): Default c99-formats to yes. * libc/stdio/vfprintf.c (_VFPRINTF_R) [!_WANT_IO_C99_FORMATS]: Cripple ' flag; hh, z, j, t sizes; a, A, F, C, S specifiers. * libc/stdio/vfscanf.c (_VFSCANF_R) [!_WANT_IO_C99_FORMATS]: Likewise. * configure: Regenerate.
This commit is contained in:
@ -9,6 +9,10 @@
|
||||
/* Newlib version */
|
||||
#undef _NEWLIB_VERSION
|
||||
|
||||
/* C99 formats support (such as %a, %zu, ...) in IO functions like
|
||||
* printf/scanf enabled */
|
||||
#undef _WANT_IO_C99_FORMATS
|
||||
|
||||
/* long long type support in IO functions like printf/scanf enabled */
|
||||
#undef _WANT_IO_LONG_LONG
|
||||
|
||||
@ -154,4 +158,3 @@
|
||||
#undef _ICONV_FROM_ENCODING_WIN_1258
|
||||
|
||||
#endif /* !__NEWLIB_H__ */
|
||||
|
||||
|
Reference in New Issue
Block a user