From 6b082cfe9f9b5b2bea294918ad916c739490cea7 Mon Sep 17 00:00:00 2001 From: Marc Kleine-Budde Date: Sun, 13 Feb 2011 10:40:28 +0100 Subject: [PATCH] fix printf warnings MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 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 Signed-off-by: Sascha Hauer --- include/stdio.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/include/stdio.h b/include/stdio.h index c82476468..9b1f16135 100644 --- a/include/stdio.h +++ b/include/stdio.h @@ -8,6 +8,9 @@ * STDIO based functions (can always be used) */ +#define ORIG_printf printf +#undef printf + /* serial stuff */ 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 fgetc(int file); +#define printf ORIG_printf + #endif /* __STDIO_H */