fix printf warnings
With sandbox printf is redefined as barebox_printf so that it does not collide with the glibc printf. This leads to tons of include/stdio.h:12:1: warning: ‘barebox_printf’ is an unrecognized format function type warnings. This patch fixes this. Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
This commit is contained in:
parent
ca43e15a57
commit
6b082cfe9f
|
@ -8,6 +8,9 @@
|
||||||
* STDIO based functions (can always be used)
|
* STDIO based functions (can always be used)
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#define ORIG_printf printf
|
||||||
|
#undef printf
|
||||||
|
|
||||||
/* serial stuff */
|
/* serial stuff */
|
||||||
void serial_printf(const char *fmt, ...) __attribute__ ((format(printf, 1, 2)));
|
void serial_printf(const char *fmt, ...) __attribute__ ((format(printf, 1, 2)));
|
||||||
|
|
||||||
|
@ -60,4 +63,6 @@ int fputc(int file, const char c);
|
||||||
int ftstc(int file);
|
int ftstc(int file);
|
||||||
int fgetc(int file);
|
int fgetc(int file);
|
||||||
|
|
||||||
|
#define printf ORIG_printf
|
||||||
|
|
||||||
#endif /* __STDIO_H */
|
#endif /* __STDIO_H */
|
||||||
|
|
Loading…
Reference in New Issue