FreeCalypso > hg > freecalypso-sw
diff loadagent/libprintf/printf.c @ 3:45bf8af5f061
libprintf brought in from older PPC/m68k code, but fucking GCC
refuses to compile <varargs.h> - need to convert to Anshit C <stdarg.h>
author | Michael Spacefalcon <msokolov@ivan.Harhan.ORG> |
---|---|
date | Mon, 29 Apr 2013 07:00:22 +0000 |
parents | |
children | 5c7b3d5d5702 |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/loadagent/libprintf/printf.c Mon Apr 29 07:00:22 2013 +0000 @@ -0,0 +1,18 @@ +#include <varargs.h> + +extern void putchar(); + +int +printf(va_alist) + va_dcl +{ + va_list ap; + char *fmt; + int len; + + va_start(ap); + fmt = va_arg(ap, char *); + len = _doprnt(fmt, ap, &putchar); + va_end(ap); + return(len); +}