OSDN Git Service

make parse_printf_format() depend on UCLIBC_HAS_GLIBC_CUSTOM_PRINTF
authorPeter S. Mazinger <ps.m@gmx.net>
Wed, 2 Mar 2011 14:31:00 +0000 (15:31 +0100)
committerPeter S. Mazinger <ps.m@gmx.net>
Thu, 3 Mar 2011 17:22:50 +0000 (18:22 +0100)
we already remove the printf.h header if this option is disabled

Signed-off-by: Peter S. Mazinger <ps.m@gmx.net>
extra/Configs/Config.in
libc/stdio/_vfprintf.c

index 15da168..4d2c870 100644 (file)
@@ -1499,6 +1499,7 @@ config UCLIBC_HAS_GLIBC_CUSTOM_PRINTF
        help
          Answer Y to support glibc's register_printf_function() to allow an
          application to add its own printf conversion specifiers.
+         parse_printf_format() is also enabled.
 
          NOTE: Limits the number or registered specifiers to 10.
          NOTE: Requires new conversion specifiers to be ASCII
index fa5dc44..3db8cdf 100644 (file)
@@ -417,6 +417,8 @@ extern uintmax_t _load_inttype(int desttype, const void *src, int uflag) attribu
 /**********************************************************************/
 #ifdef L_parse_printf_format
 
+#ifdef __UCLIBC_HAS_GLIBC_CUSTOM_PRINTF__
+
 /* NOTE: This function differs from the glibc version in that parsing stops
  * upon encountering an invalid conversion specifier.  Since this is the way
  * my printf functions work, I think it makes sense to do it that way here.
@@ -485,6 +487,8 @@ size_t parse_printf_format(register const char *template,
 }
 
 #endif
+
+#endif
 /**********************************************************************/
 #ifdef L__ppfs_init