This is the mail archive of the newlib@sourceware.org mailing list for the newlib project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[RFC 2/3] Cell SPU offloaded stdio: FILE related stuffs


Attached is a patch to implement SPU specific FILE structure and FILE
related functions.

2007-01-09  Kazunori Asayama <asayama@sm.sony.co.jp>

	* configure.host: Enable SPU specific stdio directory.
	* libc/include/stdio.h: Disable some stdio macros defined as
	functions on SPU.
	* libc/include/sys/reent.h: Define Cell SPU specific FILE
	structure.
	* libc/machine/spu/Makefile.am: Add objects.
	* libc/machine/spu/Makefile.in: Regenerated.
	* libc/machine/spu/c99ppe.h: Add macros and function
	declarations to initialize SPU specific stdio stuffs.
	* libc/machine/spu/stdio.c: Add functions to manage Cell SPU
	specific FILE structures.
	* libc/machine/spu/perror.c: Add initialization routine of
	stdio stuffs.
	* libc/machine/spu/printf.c: Ditto.
	* libc/machine/spu/putchar.c: Ditto.
	* libc/machine/spu/puts.c: Ditto.
	* libc/machine/spu/vprintf.c: Ditto.
	* libc/machine/spu/clearerr.c: New file. Add a stdio function
	implementation.
	* libc/machine/spu/feof.c: Ditto.
	* libc/machine/spu/ferror.c: Ditto.
	* libc/machine/spu/fileno.c: Ditto.
	* libc/machine/spu/fopen.c: Ditto.
	* libc/machine/spu/fclose.c: Ditto.
	* libc/machine/spu/freopen.c: Ditto.
	* libc/machine/spu/fflush.c: Ditto.
	* libc/machine/spu/fseek.c: Ditto.
	* libc/machine/spu/ftell.c: Ditto.
	* libc/machine/spu/rewind.c: Ditto.
	* libc/machine/spu/fgetpos.c: Ditto.
	* libc/machine/spu/fsetpos.c: Ditto.
	* libc/machine/spu/fread.c: Ditto.
	* libc/machine/spu/fwrite.c: Ditto.
	* libc/machine/spu/getc.c: Ditto.
	* libc/machine/spu/getchar.c: Ditto.
	* libc/machine/spu/gets.c: Ditto.
	* libc/machine/spu/fgetc.c: Ditto.
	* libc/machine/spu/fgets.c: Ditto.
	* libc/machine/spu/ungetc.c: Ditto.
	* libc/machine/spu/putc.c: Ditto.
	* libc/machine/spu/fputc.c: Ditto.
	* libc/machine/spu/fputs.c: Ditto.
	* libc/machine/spu/vfprintf.c: Ditto.
	* libc/machine/spu/vfscanf.c: Ditto.
	* libc/machine/spu/fprintf.c: Ditto.
	* libc/machine/spu/fscanf.c: Ditto.
	* libc/machine/spu/scanf.c: Ditto.
	* libc/machine/spu/vscanf.c: Ditto.
	* libc/machine/spu/setbuf.c: Ditto.
	* libc/machine/spu/setvbuf.c: Ditto.
	* libc/machine/spu/tmpfile.c: Ditto.
Index: newlib/newlib/libc/include/stdio.h
===================================================================
--- newlib.orig/newlib/libc/include/stdio.h
+++ newlib/newlib/libc/include/stdio.h
@@ -395,6 +395,7 @@ FILE	*_EXFUN(funopen,(const _PTR _cookie
 #define	fwopen(cookie, fn) funopen(cookie, (int (*)())0, fn, (fpos_t (*)())0, (int (*)())0)
 #endif
 
+#ifndef __SPU__
 /*
  * The __sfoo macros are here so that we can 
  * define function versions in the C library.
@@ -471,6 +472,7 @@ static __inline int __sputc_r(struct _re
 #define putc(x, fp)	__sputc_r(_REENT, x, fp)
 #endif /* lint */
 #endif /* __CYGWIN__ */
+#endif /* !__SPU__ */
 
 #define	getchar()	getc(stdin)
 #define	putchar(x)	putc(x, stdout)
Index: newlib/newlib/libc/include/sys/reent.h
===================================================================
--- newlib.orig/newlib/libc/include/sys/reent.h
+++ newlib/newlib/libc/include/sys/reent.h
@@ -212,6 +212,15 @@ struct __sFILE {
 #endif
 };
 
+#ifdef __SPU__
+/*
+ * Cell SPE support
+ */
+struct __sFILE_spe {
+  int _fp; /* pseudo FILE pointer on PPE */
+};
+typedef struct __sFILE_spe __FILE;
+#else /* !__SPU__ */
 #ifdef __LARGE64_FILES
 struct __sFILE64 {
   unsigned char *_p;	/* current position in (some) buffer */
@@ -260,6 +269,7 @@ typedef struct __sFILE64 __FILE;
 #else
 typedef struct __sFILE   __FILE;
 #endif /* __LARGE64_FILES */
+#endif /* __SPU__ */
 
 struct _glue 
 {
Index: newlib/newlib/configure.host
===================================================================
--- newlib.orig/newlib/configure.host
+++ newlib/newlib/configure.host
@@ -257,6 +257,7 @@ case "${host_cpu}" in
 	machine_dir=z8k
 	;;
   spu)
+	stdio_dir=
 	machine_dir=spu
 	newlib_cflags="${newlib_cflags} -ffunction-sections -fdata-sections "
 	;;
Index: newlib/newlib/libc/machine/spu/c99ppe.h
===================================================================
--- newlib.orig/newlib/libc/machine/spu/c99ppe.h
+++ newlib/newlib/libc/machine/spu/c99ppe.h
@@ -115,3 +115,12 @@ send_to_ppe(int signalcode, int opcode, 
 	errno = ret->slot[3];
 	return;
 }
+
+void _EXFUN(__sinit,(struct _reent *));
+FILE  *_EXFUN(__sfp,(struct _reent *));
+#define __sfp_free(fp) ( (fp)->_fp = 0 )
+
+#define CHECK_INIT(ptr) \
+  do { if ((ptr) && !(ptr)->__sdidinit) __sinit (ptr); } while (0)
+#define CHECK_STD_INIT(ptr) /* currently, do nothing */
+#define CHECK_STR_INIT(ptr) /* currently, do nothing */
Index: newlib/newlib/libc/machine/spu/stdio.c
===================================================================
--- /dev/null
+++ newlib/newlib/libc/machine/spu/stdio.c
@@ -0,0 +1,53 @@
+#include <stdio.h>
+
+#include "c99ppe.h"
+
+
+static FILE __fp[SPE_FOPEN_MAX];
+
+FILE *
+_DEFUN (__sfp, (d),
+	struct _reent *d)
+{
+  int i;
+  for (i = 0; i < SPE_FOPEN_MAX; i++) {
+    if (!__fp[i]._fp) {
+      return &__fp[i];
+    }
+  }
+  d->_errno = EMFILE;
+  return NULL;
+}
+
+static _VOID
+_DEFUN (__cleanup, (s),
+	struct _reent *s)
+{
+  int i;
+  for (i = 0; i < SPE_FOPEN_MAX; i++) {
+    if (__fp[i]._fp) {
+      fclose(&__fp[i]);
+    }
+  }
+}
+
+_VOID
+_DEFUN (__sinit, (s),
+	struct _reent *s)
+{
+  if (!s || s->__sdidinit) {
+    return;
+  }
+
+  s->__cleanup = __cleanup;
+  s->__sdidinit = 1;
+
+  s->_stdin = &s->__sf[0];
+  s->_stdin->_fp = SPE_STDIN;
+
+  s->_stdout = &s->__sf[1];
+  s->_stdout->_fp = SPE_STDOUT;
+
+  s->_stderr = &s->__sf[2];
+  s->_stderr->_fp = SPE_STDERR;
+}
Index: newlib/newlib/libc/machine/spu/clearerr.c
===================================================================
--- /dev/null
+++ newlib/newlib/libc/machine/spu/clearerr.c
@@ -0,0 +1,22 @@
+#include <stdio.h>
+
+#include "c99ppe.h"
+
+#ifndef _REENT_ONLY
+
+_VOID
+_DEFUN (clearerr, (fp),
+	FILE * fp)
+
+{
+  int ret;
+
+  CHECK_INIT(_REENT);
+
+  ret = fp->_fp;
+
+  send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_CLEARERR, &ret);
+
+  return;
+}
+#endif /* ! _REENT_ONLY */
Index: newlib/newlib/libc/machine/spu/feof.c
===================================================================
--- /dev/null
+++ newlib/newlib/libc/machine/spu/feof.c
@@ -0,0 +1,22 @@
+#include <stdio.h>
+
+#include "c99ppe.h"
+
+#ifndef _REENT_ONLY
+
+int
+_DEFUN (feof, (fp),
+	FILE * fp)
+{
+  int result;
+
+  CHECK_INIT(_REENT);
+
+  result = fp->_fp;
+
+  send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_FEOF, &result);
+
+
+  return result;
+}
+#endif /* ! _REENT_ONLY */
Index: newlib/newlib/libc/machine/spu/ferror.c
===================================================================
--- /dev/null
+++ newlib/newlib/libc/machine/spu/ferror.c
@@ -0,0 +1,22 @@
+#include <stdio.h>
+
+#include "c99ppe.h"
+
+#ifndef _REENT_ONLY
+
+int
+_DEFUN (ferror, (fp),
+	FILE * fp)
+{
+  int result;
+
+  CHECK_INIT(_REENT);
+
+  result = fp->_fp;
+
+  send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_FERROR, &result);
+
+
+  return result;
+}
+#endif /* ! _REENT_ONLY */
Index: newlib/newlib/libc/machine/spu/fileno.c
===================================================================
--- /dev/null
+++ newlib/newlib/libc/machine/spu/fileno.c
@@ -0,0 +1,22 @@
+#include <stdio.h>
+
+#include "c99ppe.h"
+
+#ifndef _REENT_ONLY
+
+int
+_DEFUN (fileno, (fp),
+	FILE *fp)
+
+{
+  int ret;
+
+  CHECK_INIT(_REENT);
+
+  ret = fp->_fp;
+
+  send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_FILENO, &ret);
+
+  return ret;
+}
+#endif /* ! _REENT_ONLY */
Index: newlib/newlib/libc/machine/spu/fopen.c
===================================================================
--- /dev/null
+++ newlib/newlib/libc/machine/spu/fopen.c
@@ -0,0 +1,47 @@
+#include <_ansi.h>
+#include <stdio.h>
+
+#include "c99ppe.h"
+
+typedef struct
+{
+  _CONST char* fp;
+  unsigned int pad0[ 3 ];
+  _CONST char* mode;
+  unsigned int pad1[ 3 ];
+} c99_fopen_t;
+
+#ifndef _REENT_ONLY
+FILE *
+_DEFUN (fopen, (file, mode),
+	_CONST char *file _AND
+	_CONST char *mode)
+{
+  int *ret;
+  c99_fopen_t args;
+  FILE *fp;
+  struct _reent *ptr = _REENT;
+
+  CHECK_INIT(ptr);
+
+  fp = __sfp(ptr);
+  if (!fp) {
+    return NULL;
+  }
+
+  args.fp = file;
+  args.mode = mode;
+  ret = (int *) &args;
+
+  send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_FOPEN, &args);
+
+  if (*ret) {
+    fp->_fp = *ret;
+    return fp;
+  }
+  else {
+    __sfp_free(fp);
+    return NULL;
+  }
+}
+#endif /* ! _REENT_ONLY */
Index: newlib/newlib/libc/machine/spu/fclose.c
===================================================================
--- /dev/null
+++ newlib/newlib/libc/machine/spu/fclose.c
@@ -0,0 +1,23 @@
+#include <_ansi.h>
+#include <stdio.h>
+
+#include "c99ppe.h"
+
+#ifndef _REENT_ONLY
+int
+_DEFUN (fclose, (fp),
+	FILE * fp)
+{
+  int ret;
+
+  CHECK_INIT(_REENT);
+
+  ret = fp->_fp;
+
+  send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_FCLOSE, &ret);
+
+  __sfp_free(fp);
+
+  return ret;
+}
+#endif /* ! _REENT_ONLY */
Index: newlib/newlib/libc/machine/spu/freopen.c
===================================================================
--- /dev/null
+++ newlib/newlib/libc/machine/spu/freopen.c
@@ -0,0 +1,45 @@
+#include <_ansi.h>
+#include <stdio.h>
+
+#include "c99ppe.h"
+
+typedef struct
+{
+  _CONST char *file;
+  unsigned int pad0[ 3 ];
+  _CONST char *mode;
+  unsigned int pad1[ 3 ];
+  int fp;
+} c99_freopen_t;
+
+#ifndef _REENT_ONLY
+
+FILE *
+_DEFUN (freopen, (file, mode, fp),
+	const char *file _AND
+	const char *mode _AND
+	FILE *fp)
+{
+  int *ret;
+  c99_freopen_t args;
+
+  CHECK_INIT(_REENT);
+
+  args.file = file;
+  args.mode = mode;
+  args.fp = fp->_fp;
+  ret = (int *) &args;
+
+  send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_FREOPEN, &args);
+
+  if (*ret) {
+    fp->_fp = *ret;
+  }
+  else {
+    fp->_fp = 0;
+    fp = NULL;
+  }
+
+  return fp;
+}
+#endif /* ! _REENT_ONLY */
Index: newlib/newlib/libc/machine/spu/fflush.c
===================================================================
--- /dev/null
+++ newlib/newlib/libc/machine/spu/fflush.c
@@ -0,0 +1,21 @@
+#include <stdio.h>
+
+#include "c99ppe.h"
+
+#ifndef _REENT_ONLY
+int
+_DEFUN (fflush, (fp),
+	FILE * fp)
+{
+  int result;
+
+  CHECK_INIT(_REENT);
+
+  result = fp->_fp;
+
+  send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_FFLUSH, &result);
+
+
+  return result;
+}
+#endif /* ! _REENT_ONLY */
Index: newlib/newlib/libc/machine/spu/fseek.c
===================================================================
--- /dev/null
+++ newlib/newlib/libc/machine/spu/fseek.c
@@ -0,0 +1,37 @@
+#include <_ansi.h>
+#include <stdio.h>
+
+#include "c99ppe.h"
+
+typedef struct
+{
+  int fp;
+  unsigned int pad0[ 3 ];
+  long offset;
+  unsigned int pad1[ 3 ];
+  int whence;
+} c99_fseek_t;
+
+#ifndef _REENT_ONLY
+
+int
+_DEFUN (fseek, (fp, offset, whence),
+     register FILE *fp _AND
+     long offset _AND
+     int whence)
+{
+  int* ret;
+  c99_fseek_t args;
+
+  CHECK_INIT(_REENT);
+
+  args.fp = fp->_fp;
+  args.offset = offset;
+  args.whence = whence;
+  ret = (int*)&args;
+
+  send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_FSEEK, &args);
+
+  return *ret;
+}
+#endif /* ! _REENT_ONLY */
Index: newlib/newlib/libc/machine/spu/ftell.c
===================================================================
--- /dev/null
+++ newlib/newlib/libc/machine/spu/ftell.c
@@ -0,0 +1,22 @@
+#include <stdio.h>
+
+#include "c99ppe.h"
+
+
+#ifndef _REENT_ONLY
+
+long
+_DEFUN (ftell, (fp),
+	FILE * fp)
+{
+  long ret;
+
+  CHECK_INIT(_REENT);
+
+  ret = fp->_fp;
+
+  send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_FTELL, &ret);
+
+  return ret;
+}
+#endif /* ! _REENT_ONLY */
Index: newlib/newlib/libc/machine/spu/rewind.c
===================================================================
--- /dev/null
+++ newlib/newlib/libc/machine/spu/rewind.c
@@ -0,0 +1,22 @@
+#include <stdio.h>
+
+#include "c99ppe.h"
+
+#ifndef _REENT_ONLY
+
+void
+_DEFUN (rewind, (fp),
+	FILE * fp)
+{
+  int ret;
+
+  CHECK_INIT(_REENT);
+
+  ret = fp->_fp;
+
+  send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_REWIND, &ret);
+
+  return;
+}
+
+#endif /* ! _REENT_ONLY */
Index: newlib/newlib/libc/machine/spu/fgetpos.c
===================================================================
--- /dev/null
+++ newlib/newlib/libc/machine/spu/fgetpos.c
@@ -0,0 +1,34 @@
+#include <stdio.h>
+
+#include "c99ppe.h"
+
+typedef struct
+{
+  int fp;
+  unsigned int pad0[ 3 ];
+  _fpos_t * pos;
+} c99_fgetpos_t;
+
+#ifndef _REENT_ONLY
+
+int
+_DEFUN (fgetpos, (fp, pos),
+	FILE * fp _AND
+	_fpos_t * pos)
+{
+  c99_fgetpos_t arg;
+  int* result;
+
+  CHECK_INIT(_REENT);
+
+  result = (int*)&arg;
+
+  arg.fp = fp->_fp;
+  arg.pos = pos;
+
+  send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_FGETPOS, &arg);
+
+
+  return *result;
+}
+#endif /* ! _REENT_ONLY */
Index: newlib/newlib/libc/machine/spu/fsetpos.c
===================================================================
--- /dev/null
+++ newlib/newlib/libc/machine/spu/fsetpos.c
@@ -0,0 +1,33 @@
+#include <_ansi.h>
+#include <stdio.h>
+
+#include "c99ppe.h"
+
+typedef struct
+{
+  int fp;
+  unsigned int pad0[ 3 ];
+  _CONST _fpos_t *pos;
+} c99_fsetpos_t;
+
+#ifndef _REENT_ONLY
+
+int
+_DEFUN (fsetpos, (iop, pos),
+	FILE * iop _AND
+	_CONST _fpos_t * pos)
+{
+  int* ret;
+  c99_fsetpos_t args;
+
+  CHECK_INIT(_REENT);
+
+  args.fp = iop->_fp;
+  args.pos = pos;
+  ret = (int*)&args;
+
+  send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_FSETPOS, &args);
+
+  return *ret;
+}
+#endif /* ! _REENT_ONLY */
Index: newlib/newlib/libc/machine/spu/fread.c
===================================================================
--- /dev/null
+++ newlib/newlib/libc/machine/spu/fread.c
@@ -0,0 +1,41 @@
+#include <_ansi.h>
+#include <stdio.h>
+
+#include "c99ppe.h"
+
+typedef struct
+{
+  char* buf;
+  unsigned int pad0[ 3 ];
+  size_t size;
+  unsigned int pad1[ 3 ];
+  size_t count;
+  unsigned int pad2[ 3 ];
+  int fp;
+} c99_fread_t;
+
+#ifndef _REENT_ONLY
+
+size_t
+_DEFUN (fread, (buf, size, count, fp),
+	_PTR buf _AND
+	size_t size _AND
+	size_t count _AND
+	FILE * fp)
+{
+  size_t* ret;
+  c99_fread_t args;
+
+  CHECK_INIT(_REENT);
+
+  args.buf = buf;
+  args.size = size;
+  args.count = count;
+  args.fp = fp->_fp;
+  ret = (size_t*) &args;
+
+  send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_FREAD, &args);
+
+  return *ret;
+}
+#endif /* ! _REENT_ONLY */
Index: newlib/newlib/libc/machine/spu/fwrite.c
===================================================================
--- /dev/null
+++ newlib/newlib/libc/machine/spu/fwrite.c
@@ -0,0 +1,41 @@
+#include <_ansi.h>
+#include <stdio.h>
+
+#include "c99ppe.h"
+
+#ifndef _REENT_ONLY
+
+typedef struct
+{
+  _CONST char* buf;
+  unsigned int pad0[ 3 ];
+  size_t size;
+  unsigned int pad1[ 3 ];
+  size_t count;
+  unsigned int pad2[ 3 ];
+  int fp;
+} c99_fwrite_t;
+
+size_t
+_DEFUN (fwrite, (buf, size, count, fp),
+	_CONST _PTR buf _AND
+	size_t size _AND
+	size_t count _AND
+	FILE * fp)
+{
+  size_t* ret;
+  c99_fwrite_t args;
+
+  CHECK_INIT(_REENT);
+
+  args.buf = buf;
+  args.size = size;
+  args.count = count;
+  args.fp = fp->_fp;
+  ret = (size_t*) &args;
+
+  send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_FWRITE, &args);
+
+  return *ret;
+}
+#endif /* ! _REENT_ONLY */
Index: newlib/newlib/libc/machine/spu/getc.c
===================================================================
--- /dev/null
+++ newlib/newlib/libc/machine/spu/getc.c
@@ -0,0 +1,24 @@
+#include <stdio.h>
+
+#include "c99ppe.h"
+/*
+ * A subroutine version of the macro getc.
+ */
+
+#ifndef _REENT_ONLY
+
+int
+getc (fp)
+     FILE *fp;
+{
+  int ret;
+
+  CHECK_INIT(_REENT);
+
+  ret = fp->_fp;
+
+  send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_GETC, &ret);
+
+  return ret;
+}
+#endif /* ! _REENT_ONLY */
Index: newlib/newlib/libc/machine/spu/getchar.c
===================================================================
--- /dev/null
+++ newlib/newlib/libc/machine/spu/getchar.c
@@ -0,0 +1,20 @@
+#include <stdio.h>
+
+#include "c99ppe.h"
+
+#undef getchar
+
+#ifndef _REENT_ONLY
+
+int
+getchar ()
+{
+  int ret;
+
+  CHECK_STD_INIT(_REENT);
+
+  send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_GETCHAR, &ret);
+
+  return ret;
+}
+#endif /* ! _REENT_ONLY */
Index: newlib/newlib/libc/machine/spu/gets.c
===================================================================
--- /dev/null
+++ newlib/newlib/libc/machine/spu/gets.c
@@ -0,0 +1,19 @@
+#include <stdio.h>
+
+#include "c99ppe.h"
+
+#ifndef _REENT_ONLY
+
+char *
+gets (buf)
+     char *buf;
+{
+  CHECK_STD_INIT(_REENT);
+
+  /* The return value gets written over buf
+   */
+  send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_GETS, &buf);
+
+  return buf;
+}
+#endif /* ! _REENT_ONLY */
Index: newlib/newlib/libc/machine/spu/fgetc.c
===================================================================
--- /dev/null
+++ newlib/newlib/libc/machine/spu/fgetc.c
@@ -0,0 +1,21 @@
+#include <stdio.h>
+
+#include "c99ppe.h"
+
+#ifndef _REENT_ONLY
+
+int
+_DEFUN (fgetc, (fp),
+	FILE * fp)
+{
+  int result;
+
+  CHECK_INIT(_REENT);
+
+  result = fp->_fp;
+
+  send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_FGETC, &result);
+
+  return result;
+}
+#endif /* ! _REENT_ONLY */
Index: newlib/newlib/libc/machine/spu/fgets.c
===================================================================
--- /dev/null
+++ newlib/newlib/libc/machine/spu/fgets.c
@@ -0,0 +1,36 @@
+#include <stdio.h>
+
+#include "c99ppe.h"
+
+typedef struct
+{
+  char *buf;
+  unsigned int pad0[3];
+  int n;
+  unsigned int pad1[3];
+  int fp;
+} c99_fgets_t;
+
+#ifndef _REENT_ONLY
+
+char *
+_DEFUN (fgets, (buf, n, fp),
+	char *buf _AND
+	int n _AND
+	FILE * fp)
+{
+  char** ret;
+  c99_fgets_t args;
+
+  CHECK_INIT(_REENT);
+
+  args.buf = buf;
+  args.n = n;
+  args.fp = fp->_fp;
+  ret = (char**) &args;
+
+  send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_FGETS, &args);
+
+  return *ret;
+}
+#endif /* ! _REENT_ONLY */
Index: newlib/newlib/libc/machine/spu/ungetc.c
===================================================================
--- /dev/null
+++ newlib/newlib/libc/machine/spu/ungetc.c
@@ -0,0 +1,35 @@
+#include <_ansi.h>
+#include <stdio.h>
+
+#include "c99ppe.h"
+
+typedef struct
+{
+  int c;
+  unsigned int pad0[ 3 ];
+  int fp;
+  unsigned int pad1[ 3 ];
+} c99_ungetc_t;
+
+#ifndef _REENT_ONLY
+
+int
+ungetc (c, fp)
+     int c;
+     register FILE *fp;
+{
+  int* ret;
+  c99_ungetc_t args;
+
+  CHECK_INIT(_REENT);
+
+  args.c = c;
+  args.fp = fp->_fp;
+  ret = (int*)&args;
+
+  send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_UNGETC, &args);
+
+  return *ret;
+}
+
+#endif /* ! _REENT_ONLY */
Index: newlib/newlib/libc/machine/spu/putc.c
===================================================================
--- /dev/null
+++ newlib/newlib/libc/machine/spu/putc.c
@@ -0,0 +1,35 @@
+#include <_ansi.h>
+#include <stdio.h>
+
+#include "c99ppe.h"
+
+typedef struct
+{
+  int ch;
+  unsigned int pad0[ 3 ];
+  int fp;
+  unsigned int pad1[ 3 ];
+} c99_putc_t;
+
+#ifndef _REENT_ONLY
+
+int
+putc (c, fp)
+     int c;
+     register FILE *fp;
+{
+  int* ret;
+  c99_putc_t args;
+
+  CHECK_INIT(_REENT);
+
+  args.ch = c;
+  args.fp = fp->_fp;
+  ret = (int*)&args;
+
+  send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_PUTC, &args);
+
+  return *ret;
+}
+
+#endif /* ! _REENT_ONLY */
Index: newlib/newlib/libc/machine/spu/fputc.c
===================================================================
--- /dev/null
+++ newlib/newlib/libc/machine/spu/fputc.c
@@ -0,0 +1,34 @@
+#include <_ansi.h>
+#include <stdio.h>
+
+#include "c99ppe.h"
+
+typedef struct
+{
+  int ch;
+  unsigned int pad0[ 3 ];
+  int fp;
+  unsigned int pad1[ 3 ];
+} c99_fputc_t;
+
+#ifndef _REENT_ONLY
+
+int
+fputc (c, fp)
+     int c;
+     register FILE *fp;
+{
+  int* ret;
+  c99_fputc_t args;
+
+  CHECK_INIT(_REENT);
+
+  args.ch = c;
+  args.fp = fp->_fp;
+  ret = (int*)&args;
+
+  send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_FPUTC, &args);
+
+  return *ret;
+}
+#endif /* ! _REENT_ONLY */
Index: newlib/newlib/libc/machine/spu/fputs.c
===================================================================
--- /dev/null
+++ newlib/newlib/libc/machine/spu/fputs.c
@@ -0,0 +1,34 @@
+#include <_ansi.h>
+#include <stdio.h>
+
+#include "c99ppe.h"
+
+typedef struct
+{
+  _CONST char* s;
+  unsigned int pad0[ 3 ];
+  int fp;
+  unsigned int pad1[ 3 ];
+} c99_fputs_t;
+
+#ifndef _REENT_ONLY
+
+int
+_DEFUN (fputs, (s, fp),
+	char _CONST * s _AND
+	FILE * fp)
+{
+  int* ret;
+  c99_fputs_t args;
+
+  CHECK_INIT(_REENT);
+
+  args.s = s;
+  args.fp = fp->_fp;
+  ret = (int*)&args;
+
+  send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_FPUTS, &args);
+
+  return *ret;
+}
+#endif /* ! _REENT_ONLY */
Index: newlib/newlib/libc/machine/spu/vfprintf.c
===================================================================
--- /dev/null
+++ newlib/newlib/libc/machine/spu/vfprintf.c
@@ -0,0 +1,45 @@
+#include <_ansi.h>
+#include <stdio.h>
+
+#include "c99ppe.h"
+
+#ifdef _HAVE_STDC
+#include <stdarg.h>
+#else
+#include <varargs.h>
+#endif
+
+typedef struct
+{
+  int fp;
+  unsigned int pad0[ 3 ];
+  char* fmt;
+  unsigned int pad1[ 3 ];
+  va_list ap;
+} c99_vfprintf_t;
+
+#ifndef _REENT_ONLY
+
+int
+_DEFUN (vfprintf, (fp, fmt0, ap),
+	FILE * fp _AND
+	_CONST char *fmt0 _AND
+	va_list ap)
+{
+  int* ret;
+  c99_vfprintf_t args;
+
+  CHECK_INIT(_REENT);
+
+  ret = (int*) &args;
+
+  args.fp = fp->_fp;
+  args.fmt = (char*) fmt0;
+  va_copy(args.ap,ap);
+
+  send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_VFPRINTF, &args);
+
+  return *ret;
+}
+
+#endif /* ! _REENT_ONLY */
Index: newlib/newlib/libc/machine/spu/vfscanf.c
===================================================================
--- /dev/null
+++ newlib/newlib/libc/machine/spu/vfscanf.c
@@ -0,0 +1,45 @@
+#include <_ansi.h>
+#include <stdio.h>
+
+#include "c99ppe.h"
+
+#ifdef _HAVE_STDC
+#include <stdarg.h>
+#else
+#include <varargs.h>
+#endif
+
+typedef struct
+{
+  int fp;
+  unsigned int pad0[ 3 ];
+  char* fmt;
+  unsigned int pad1[ 3 ];
+  va_list ap;
+} c99_vfscanf_t;
+
+#ifndef _REENT_ONLY
+
+int
+_DEFUN (vfscanf, (fp, fmt, ap),
+    FILE *fp _AND
+    _CONST char *fmt _AND
+    va_list ap)
+{
+  int* ret;
+  c99_vfscanf_t args;
+
+  CHECK_INIT(_REENT);
+
+  ret = (int*) &args;
+
+  args.fp = fp->_fp;
+  args.fmt = (char*) fmt;
+  va_copy(args.ap,ap);
+
+  send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_VFSCANF, &args);
+
+  return *ret;
+}
+
+#endif /* ! _REENT_ONLY */
Index: newlib/newlib/libc/machine/spu/fprintf.c
===================================================================
--- /dev/null
+++ newlib/newlib/libc/machine/spu/fprintf.c
@@ -0,0 +1,47 @@
+#include <_ansi.h>
+#include <stdio.h>
+
+#include "c99ppe.h"
+
+#ifdef _HAVE_STDC
+#include <stdarg.h>
+#else
+#include <varargs.h>
+#endif
+
+typedef struct
+{
+  int fp;
+  unsigned int pad0[ 3 ];
+  _CONST char* fmt;
+  unsigned int pad1[ 3 ];
+  va_list ap;
+} c99_fprintf_t;
+
+#ifndef _REENT_ONLY
+
+int
+fprintf(FILE * fp, _CONST char *fmt,...)
+{
+  int* ret;
+  c99_fprintf_t args;
+
+  CHECK_INIT(_REENT);
+
+  ret = (int*) &args;
+
+  args.fp = fp->_fp;
+  args.fmt = (char*) fmt;
+
+#ifdef _HAVE_STDC
+  va_start (args.ap, args.fmt);
+#else
+  va_start (args.ap);
+#endif
+
+  send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_VFPRINTF, &args);
+
+  va_end (args.ap);
+  return *ret;
+}
+#endif /* ! _REENT_ONLY */
Index: newlib/newlib/libc/machine/spu/fscanf.c
===================================================================
--- /dev/null
+++ newlib/newlib/libc/machine/spu/fscanf.c
@@ -0,0 +1,46 @@
+#include <_ansi.h>
+#include <stdio.h>
+
+#include "c99ppe.h"
+
+#ifdef _HAVE_STDC
+#include <stdarg.h>
+#else
+#include <varargs.h>
+#endif
+
+typedef struct
+{
+  int fp;
+  unsigned int pad0[ 3 ];
+  _CONST char* fmt;
+  unsigned int pad1[ 3 ];
+  va_list ap;
+} c99_vfscanf_t;
+
+#ifndef _REENT_ONLY
+
+fscanf(FILE *fp, _CONST char *fmt, ...)
+{
+  int* ret;
+  c99_vfscanf_t args;
+
+  CHECK_INIT(_REENT);
+
+  ret = (int*) &args;
+
+  args.fp = fp->_fp;
+  args.fmt = (char*) fmt;
+#ifdef _HAVE_STDC
+  va_start (args.ap, args.fmt);
+#else
+  va_start (args.ap);
+#endif
+
+
+  send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_VFSCANF, &args);
+
+  va_end (args.ap);
+  return *ret;
+}
+#endif /* ! _REENT_ONLY */
Index: newlib/newlib/libc/machine/spu/scanf.c
===================================================================
--- /dev/null
+++ newlib/newlib/libc/machine/spu/scanf.c
@@ -0,0 +1,44 @@
+#include <_ansi.h>
+#include <stdio.h>
+
+#include "c99ppe.h"
+
+#ifdef _HAVE_STDC
+#include <stdarg.h>
+#else
+#include <varargs.h>
+#endif
+
+typedef struct
+{
+  _CONST char* fmt;
+  unsigned int pad0[ 3 ];
+  va_list ap;
+} c99_vscanf_t;
+
+#ifndef _REENT_ONLY
+
+scanf(_CONST char *fmt, ...)
+{
+  int* ret;
+  c99_vscanf_t args;
+
+  CHECK_STD_INIT(_REENT);
+
+  ret = (int*) &args;
+
+  args.fmt = (char*) fmt;
+#ifdef _HAVE_STDC
+  va_start (args.ap, args.fmt);
+#else
+  va_start (args.ap);
+#endif
+
+
+  send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_VSCANF, &args);
+
+  va_end (args.ap);
+  return *ret;
+}
+
+#endif /* ! _REENT_ONLY */
Index: newlib/newlib/libc/machine/spu/vscanf.c
===================================================================
--- /dev/null
+++ newlib/newlib/libc/machine/spu/vscanf.c
@@ -0,0 +1,41 @@
+#include <_ansi.h>
+#include <stdio.h>
+
+#include "c99ppe.h"
+
+#ifdef _HAVE_STDC
+#include <stdarg.h>
+#else
+#include <varargs.h>
+#endif
+
+typedef struct
+{
+  char* fmt;
+  unsigned int pad0[ 3 ];
+  va_list ap;
+} c99_vscanf_t;
+
+#ifndef _REENT_ONLY
+
+int
+_DEFUN (vscanf, (fmt, ap),
+     _CONST char *fmt _AND
+     va_list ap)
+{
+  int* ret;
+  c99_vscanf_t args;
+
+  CHECK_STD_INIT(_REENT);
+
+  ret = (int*) &args;
+
+  args.fmt = (char*) fmt;
+  va_copy(args.ap,ap);
+
+  send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_VSCANF, &args);
+
+  return *ret;
+}
+
+#endif /* ! _REENT_ONLY */
Index: newlib/newlib/libc/machine/spu/setbuf.c
===================================================================
--- /dev/null
+++ newlib/newlib/libc/machine/spu/setbuf.c
@@ -0,0 +1,33 @@
+#include <_ansi.h>
+#include <stdio.h>
+
+#include "c99ppe.h"
+
+typedef struct
+{
+  int fp;
+  unsigned int pad0[ 3 ];
+  char *buf;
+  unsigned int pad1[ 3 ];
+} c99_setbuf_t;
+
+#ifndef _REENT_ONLY
+
+void
+_DEFUN (setbuf, (fp, buf),
+	FILE * fp _AND
+	char *buf)
+{
+  c99_setbuf_t args;
+
+  CHECK_INIT(_REENT);
+
+  args.fp = fp->_fp;
+  args.buf = buf;
+
+  send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_SETBUF, &args);
+
+  return;
+}
+
+#endif /* ! _REENT_ONLY */
Index: newlib/newlib/libc/machine/spu/setvbuf.c
===================================================================
--- /dev/null
+++ newlib/newlib/libc/machine/spu/setvbuf.c
@@ -0,0 +1,43 @@
+#include <_ansi.h>
+#include <stdio.h>
+
+#include "c99ppe.h"
+
+typedef struct
+{
+  int fp;
+  unsigned int pad0[ 3 ];
+  char *buf;
+  unsigned int pad1[ 3 ];
+  int mode;
+  unsigned int pad2[ 3 ];
+  size_t size;
+  unsigned int pad3[ 3 ];
+} c99_setvbuf_t;
+
+#ifndef _REENT_ONLY
+
+int
+_DEFUN (setvbuf, (fp, buf, mode, size),
+	FILE * fp _AND
+	char *buf _AND
+	int mode _AND
+	size_t size)
+{
+  int* ret;
+  c99_setvbuf_t args;
+
+  CHECK_INIT(_REENT);
+
+  args.fp = fp->_fp;
+  args.buf = buf;
+  args.mode = mode;
+  args.size = size;
+  ret = (int*)&args;
+
+  send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_SETVBUF, &args);
+
+  return *ret;
+}
+
+#endif /* ! _REENT_ONLY */
Index: newlib/newlib/libc/machine/spu/tmpfile.c
===================================================================
--- /dev/null
+++ newlib/newlib/libc/machine/spu/tmpfile.c
@@ -0,0 +1,33 @@
+#include <stdio.h>
+
+#include "c99ppe.h"
+
+#ifndef _REENT_ONLY
+
+FILE *
+_DEFUN_VOID (tmpfile)
+{
+  int ret;
+  FILE* fp;
+  struct _reent *ptr = _REENT;
+
+  CHECK_INIT(ptr);
+
+  fp = __sfp(ptr);
+  if (!fp) {
+    return NULL;
+  }
+
+  send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_TMPFILE, &ret);
+
+  if (ret) {
+    fp->_fp = ret;
+    return fp;
+  }
+  else {
+    __sfp_free(fp);
+    return NULL;
+  }
+}
+
+#endif /* ! _REENT_ONLY */
Index: newlib/newlib/libc/machine/spu/perror.c
===================================================================
--- newlib.orig/newlib/libc/machine/spu/perror.c
+++ newlib/newlib/libc/machine/spu/perror.c
@@ -2,13 +2,17 @@
 
 #include "c99ppe.h"
 
+#ifndef _REENT_ONLY
+
 void
 _DEFUN (perror, (s),
 	_CONST char *s)
 
 {
+  CHECK_STD_INIT(_REENT);
+
   send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_PERROR, &s);
 
   return;
 }
-
+#endif /* ! _REENT_ONLY */
Index: newlib/newlib/libc/machine/spu/printf.c
===================================================================
--- newlib.orig/newlib/libc/machine/spu/printf.c
+++ newlib/newlib/libc/machine/spu/printf.c
@@ -34,6 +34,9 @@ printf (fmt, va_alist)
 {
   int* ret;
   c99_printf_t args;
+
+  CHECK_STD_INIT(_REENT);
+
   ret = (int*) &args;
 
   args.fmt = fmt;
@@ -44,7 +47,6 @@ printf (fmt, va_alist)
 #endif
 
 
-  /*  ret = vfprintf (_stdout_r (_REENT), fmt, ap);*/
   send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_VPRINTF, &args);
 
   va_end (args.ap);
Index: newlib/newlib/libc/machine/spu/putchar.c
===================================================================
--- newlib.orig/newlib/libc/machine/spu/putchar.c
+++ newlib/newlib/libc/machine/spu/putchar.c
@@ -4,10 +4,14 @@
 
 #undef putchar
 
+#ifndef _REENT_ONLY
+
 int
 putchar (c)
      int c;
 {
+  CHECK_STD_INIT(_REENT);
+
   /* c gets overwritten before return */
 
   send_to_ppe(SPE_C99_SIGNALCODE, SPE_C99_PUTCHAR, &c);
@@ -15,3 +19,4 @@ putchar (c)
   return c;
 }
 
+#endif /* ! _REENT_ONLY */
Index: newlib/newlib/libc/machine/spu/puts.c
===================================================================
--- newlib.orig/newlib/libc/machine/spu/puts.c
+++ newlib/newlib/libc/machine/spu/puts.c
@@ -2,10 +2,13 @@
 
 #include "c99ppe.h"
 
+#ifndef _REENT_ONLY
+
 int
 _DEFUN (puts, (s),
 	char _CONST * s)
 {
+  CHECK_STD_INIT(_REENT);
 
   /* The return value gets written over s
    */
@@ -14,3 +17,4 @@ _DEFUN (puts, (s),
   return (int)s;
 }
 
+#endif /* ! _REENT_ONLY */
Index: newlib/newlib/libc/machine/spu/vprintf.c
===================================================================
--- newlib.orig/newlib/libc/machine/spu/vprintf.c
+++ newlib/newlib/libc/machine/spu/vprintf.c
@@ -26,6 +26,9 @@ _DEFUN (vprintf, (fmt, ap),
 {
   int* ret;
   c99_vprintf_t args;
+
+  CHECK_STD_INIT(_REENT);
+
   ret = (int*) &args;
 
   args.fmt = (char*) fmt;
Index: newlib/newlib/libc/machine/spu/Makefile.am
===================================================================
--- newlib.orig/newlib/libc/machine/spu/Makefile.am
+++ newlib/newlib/libc/machine/spu/Makefile.am
@@ -8,12 +8,19 @@ noinst_LIBRARIES = lib.a
 
 AM_CCASFLAGS = $(INCLUDES)
 
-lib_a_SOURCES = setjmp.S memcpy.c memmove.c memset.c strcat.c strchr.c strcmp.c strcpy.c strcspn.c strlen.c strncat.c strncmp.c strncpy.c strpbrk.c strrchr.c strspn.c strxfrm.c printf.c perror.c putchar.c puts.c vsnprintf.c vprintf.c vsprintf.c
+lib_a_SOURCES = setjmp.S memcpy.c memmove.c memset.c strcat.c strchr.c strcmp.c strcpy.c strcspn.c strlen.c strncat.c strncmp.c strncpy.c strpbrk.c strrchr.c strspn.c strxfrm.c \
+	stdio.c clearerr.c feof.c ferror.c fileno.c fopen.c fclose.c freopen.c \
+	fflush.c fseek.c ftell.c rewind.c fgetpos.c fsetpos.c fread.c fwrite.c \
+	getc.c putc.c fgetc.c fgets.c fputc.c fputs.c ungetc.c \
+	fprintf.c fscanf.c vfprintf.c vfscanf.c \
+	perror.c gets.c getchar.c putchar.c puts.c \
+	printf.c scanf.c vprintf.c vscanf.c \
+	setbuf.c setvbuf.c tmpfile.c \
+	vsnprintf.c vsprintf.c
 
 lib_a_CCASFLAGS = $(AM_CCASFLAGS)
 lib_a_CFLAGS = $(AM_CFLAGS)
 
 ACLOCAL_AMFLAGS = -I ../../.. 
-AM_CFLAGS = -I $(srcdir)/../../stdio -I $(srcdir)/../../stdlib
 CONFIG_STATUS_DEPENDENCIES = $(newlib_basedir)/configure.host
 
Index: newlib/newlib/libc/machine/spu/Makefile.in
===================================================================
--- newlib.orig/newlib/libc/machine/spu/Makefile.in
+++ newlib/newlib/libc/machine/spu/Makefile.in
@@ -51,6 +51,23 @@ DIST_COMMON = $(srcdir)/../../../../conf
 	$(srcdir)/../../../../compile $(srcdir)/../../../../compile \
 	$(srcdir)/../../../../compile $(srcdir)/../../../../compile \
 	$(srcdir)/../../../../compile $(srcdir)/../../../../compile \
+	$(srcdir)/../../../../compile $(srcdir)/../../../../compile \
+	$(srcdir)/../../../../compile $(srcdir)/../../../../compile \
+	$(srcdir)/../../../../compile $(srcdir)/../../../../compile \
+	$(srcdir)/../../../../compile $(srcdir)/../../../../compile \
+	$(srcdir)/../../../../compile $(srcdir)/../../../../compile \
+	$(srcdir)/../../../../compile $(srcdir)/../../../../compile \
+	$(srcdir)/../../../../compile $(srcdir)/../../../../compile \
+	$(srcdir)/../../../../compile $(srcdir)/../../../../compile \
+	$(srcdir)/../../../../compile $(srcdir)/../../../../compile \
+	$(srcdir)/../../../../compile $(srcdir)/../../../../compile \
+	$(srcdir)/../../../../compile $(srcdir)/../../../../compile \
+	$(srcdir)/../../../../compile $(srcdir)/../../../../compile \
+	$(srcdir)/../../../../compile $(srcdir)/../../../../compile \
+	$(srcdir)/../../../../compile $(srcdir)/../../../../compile \
+	$(srcdir)/../../../../compile $(srcdir)/../../../../compile \
+	$(srcdir)/../../../../compile $(srcdir)/../../../../compile \
+	$(srcdir)/../../../../compile $(srcdir)/../../../../compile \
 	$(srcdir)/../../../../compile
 subdir = .
 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
@@ -74,10 +91,27 @@ am_lib_a_OBJECTS = lib_a-setjmp.$(OBJEXT
 	lib_a-strncat.$(OBJEXT) lib_a-strncmp.$(OBJEXT) \
 	lib_a-strncpy.$(OBJEXT) lib_a-strpbrk.$(OBJEXT) \
 	lib_a-strrchr.$(OBJEXT) lib_a-strspn.$(OBJEXT) \
-	lib_a-strxfrm.$(OBJEXT) lib_a-printf.$(OBJEXT) \
-	lib_a-perror.$(OBJEXT) lib_a-putchar.$(OBJEXT) \
-	lib_a-puts.$(OBJEXT) lib_a-vsnprintf.$(OBJEXT) \
-	lib_a-vprintf.$(OBJEXT) lib_a-vsprintf.$(OBJEXT)
+	lib_a-strxfrm.$(OBJEXT) lib_a-stdio.$(OBJEXT) \
+	lib_a-clearerr.$(OBJEXT) lib_a-feof.$(OBJEXT) \
+	lib_a-ferror.$(OBJEXT) lib_a-fileno.$(OBJEXT) \
+	lib_a-fopen.$(OBJEXT) lib_a-fclose.$(OBJEXT) \
+	lib_a-freopen.$(OBJEXT) lib_a-fflush.$(OBJEXT) \
+	lib_a-fseek.$(OBJEXT) lib_a-ftell.$(OBJEXT) \
+	lib_a-rewind.$(OBJEXT) lib_a-fgetpos.$(OBJEXT) \
+	lib_a-fsetpos.$(OBJEXT) lib_a-fread.$(OBJEXT) \
+	lib_a-fwrite.$(OBJEXT) lib_a-getc.$(OBJEXT) \
+	lib_a-putc.$(OBJEXT) lib_a-fgetc.$(OBJEXT) \
+	lib_a-fgets.$(OBJEXT) lib_a-fputc.$(OBJEXT) \
+	lib_a-fputs.$(OBJEXT) lib_a-ungetc.$(OBJEXT) \
+	lib_a-fprintf.$(OBJEXT) lib_a-fscanf.$(OBJEXT) \
+	lib_a-vfprintf.$(OBJEXT) lib_a-vfscanf.$(OBJEXT) \
+	lib_a-perror.$(OBJEXT) lib_a-gets.$(OBJEXT) \
+	lib_a-getchar.$(OBJEXT) lib_a-putchar.$(OBJEXT) \
+	lib_a-puts.$(OBJEXT) lib_a-printf.$(OBJEXT) \
+	lib_a-scanf.$(OBJEXT) lib_a-vprintf.$(OBJEXT) \
+	lib_a-vscanf.$(OBJEXT) lib_a-setbuf.$(OBJEXT) \
+	lib_a-setvbuf.$(OBJEXT) lib_a-tmpfile.$(OBJEXT) \
+	lib_a-vsnprintf.$(OBJEXT) lib_a-vsprintf.$(OBJEXT)
 lib_a_OBJECTS = $(am_lib_a_OBJECTS)
 DEFAULT_INCLUDES = -I. -I$(srcdir)
 depcomp =
@@ -202,11 +236,19 @@ AUTOMAKE_OPTIONS = cygnus
 INCLUDES = $(NEWLIB_CFLAGS) $(CROSS_CFLAGS) $(TARGET_CFLAGS)
 noinst_LIBRARIES = lib.a
 AM_CCASFLAGS = $(INCLUDES)
-lib_a_SOURCES = setjmp.S memcpy.c memmove.c memset.c strcat.c strchr.c strcmp.c strcpy.c strcspn.c strlen.c strncat.c strncmp.c strncpy.c strpbrk.c strrchr.c strspn.c strxfrm.c printf.c perror.c putchar.c puts.c vsnprintf.c vprintf.c vsprintf.c
+lib_a_SOURCES = setjmp.S memcpy.c memmove.c memset.c strcat.c strchr.c strcmp.c strcpy.c strcspn.c strlen.c strncat.c strncmp.c strncpy.c strpbrk.c strrchr.c strspn.c strxfrm.c \
+	stdio.c clearerr.c feof.c ferror.c fileno.c fopen.c fclose.c freopen.c \
+	fflush.c fseek.c ftell.c rewind.c fgetpos.c fsetpos.c fread.c fwrite.c \
+	getc.c putc.c fgetc.c fgets.c fputc.c fputs.c ungetc.c \
+	fprintf.c fscanf.c vfprintf.c vfscanf.c \
+	perror.c gets.c getchar.c putchar.c puts.c \
+	printf.c scanf.c vprintf.c vscanf.c \
+	setbuf.c setvbuf.c tmpfile.c \
+	vsnprintf.c vsprintf.c
+
 lib_a_CCASFLAGS = $(AM_CCASFLAGS)
 lib_a_CFLAGS = $(AM_CFLAGS)
 ACLOCAL_AMFLAGS = -I ../../.. 
-AM_CFLAGS = -I $(srcdir)/../../stdio -I $(srcdir)/../../stdlib
 CONFIG_STATUS_DEPENDENCIES = $(newlib_basedir)/configure.host
 all: all-am
 
@@ -373,11 +415,167 @@ lib_a-strxfrm.o: strxfrm.c
 lib_a-strxfrm.obj: strxfrm.c
 	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-strxfrm.obj `if test -f 'strxfrm.c'; then $(CYGPATH_W) 'strxfrm.c'; else $(CYGPATH_W) '$(srcdir)/strxfrm.c'; fi`
 
-lib_a-printf.o: printf.c
-	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-printf.o `test -f 'printf.c' || echo '$(srcdir)/'`printf.c
+lib_a-stdio.o: stdio.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-stdio.o `test -f 'stdio.c' || echo '$(srcdir)/'`stdio.c
 
-lib_a-printf.obj: printf.c
-	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-printf.obj `if test -f 'printf.c'; then $(CYGPATH_W) 'printf.c'; else $(CYGPATH_W) '$(srcdir)/printf.c'; fi`
+lib_a-stdio.obj: stdio.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-stdio.obj `if test -f 'stdio.c'; then $(CYGPATH_W) 'stdio.c'; else $(CYGPATH_W) '$(srcdir)/stdio.c'; fi`
+
+lib_a-clearerr.o: clearerr.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-clearerr.o `test -f 'clearerr.c' || echo '$(srcdir)/'`clearerr.c
+
+lib_a-clearerr.obj: clearerr.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-clearerr.obj `if test -f 'clearerr.c'; then $(CYGPATH_W) 'clearerr.c'; else $(CYGPATH_W) '$(srcdir)/clearerr.c'; fi`
+
+lib_a-feof.o: feof.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-feof.o `test -f 'feof.c' || echo '$(srcdir)/'`feof.c
+
+lib_a-feof.obj: feof.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-feof.obj `if test -f 'feof.c'; then $(CYGPATH_W) 'feof.c'; else $(CYGPATH_W) '$(srcdir)/feof.c'; fi`
+
+lib_a-ferror.o: ferror.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-ferror.o `test -f 'ferror.c' || echo '$(srcdir)/'`ferror.c
+
+lib_a-ferror.obj: ferror.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-ferror.obj `if test -f 'ferror.c'; then $(CYGPATH_W) 'ferror.c'; else $(CYGPATH_W) '$(srcdir)/ferror.c'; fi`
+
+lib_a-fileno.o: fileno.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-fileno.o `test -f 'fileno.c' || echo '$(srcdir)/'`fileno.c
+
+lib_a-fileno.obj: fileno.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-fileno.obj `if test -f 'fileno.c'; then $(CYGPATH_W) 'fileno.c'; else $(CYGPATH_W) '$(srcdir)/fileno.c'; fi`
+
+lib_a-fopen.o: fopen.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-fopen.o `test -f 'fopen.c' || echo '$(srcdir)/'`fopen.c
+
+lib_a-fopen.obj: fopen.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-fopen.obj `if test -f 'fopen.c'; then $(CYGPATH_W) 'fopen.c'; else $(CYGPATH_W) '$(srcdir)/fopen.c'; fi`
+
+lib_a-fclose.o: fclose.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-fclose.o `test -f 'fclose.c' || echo '$(srcdir)/'`fclose.c
+
+lib_a-fclose.obj: fclose.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-fclose.obj `if test -f 'fclose.c'; then $(CYGPATH_W) 'fclose.c'; else $(CYGPATH_W) '$(srcdir)/fclose.c'; fi`
+
+lib_a-freopen.o: freopen.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-freopen.o `test -f 'freopen.c' || echo '$(srcdir)/'`freopen.c
+
+lib_a-freopen.obj: freopen.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-freopen.obj `if test -f 'freopen.c'; then $(CYGPATH_W) 'freopen.c'; else $(CYGPATH_W) '$(srcdir)/freopen.c'; fi`
+
+lib_a-fflush.o: fflush.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-fflush.o `test -f 'fflush.c' || echo '$(srcdir)/'`fflush.c
+
+lib_a-fflush.obj: fflush.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-fflush.obj `if test -f 'fflush.c'; then $(CYGPATH_W) 'fflush.c'; else $(CYGPATH_W) '$(srcdir)/fflush.c'; fi`
+
+lib_a-fseek.o: fseek.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-fseek.o `test -f 'fseek.c' || echo '$(srcdir)/'`fseek.c
+
+lib_a-fseek.obj: fseek.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-fseek.obj `if test -f 'fseek.c'; then $(CYGPATH_W) 'fseek.c'; else $(CYGPATH_W) '$(srcdir)/fseek.c'; fi`
+
+lib_a-ftell.o: ftell.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-ftell.o `test -f 'ftell.c' || echo '$(srcdir)/'`ftell.c
+
+lib_a-ftell.obj: ftell.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-ftell.obj `if test -f 'ftell.c'; then $(CYGPATH_W) 'ftell.c'; else $(CYGPATH_W) '$(srcdir)/ftell.c'; fi`
+
+lib_a-rewind.o: rewind.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-rewind.o `test -f 'rewind.c' || echo '$(srcdir)/'`rewind.c
+
+lib_a-rewind.obj: rewind.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-rewind.obj `if test -f 'rewind.c'; then $(CYGPATH_W) 'rewind.c'; else $(CYGPATH_W) '$(srcdir)/rewind.c'; fi`
+
+lib_a-fgetpos.o: fgetpos.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-fgetpos.o `test -f 'fgetpos.c' || echo '$(srcdir)/'`fgetpos.c
+
+lib_a-fgetpos.obj: fgetpos.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-fgetpos.obj `if test -f 'fgetpos.c'; then $(CYGPATH_W) 'fgetpos.c'; else $(CYGPATH_W) '$(srcdir)/fgetpos.c'; fi`
+
+lib_a-fsetpos.o: fsetpos.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-fsetpos.o `test -f 'fsetpos.c' || echo '$(srcdir)/'`fsetpos.c
+
+lib_a-fsetpos.obj: fsetpos.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-fsetpos.obj `if test -f 'fsetpos.c'; then $(CYGPATH_W) 'fsetpos.c'; else $(CYGPATH_W) '$(srcdir)/fsetpos.c'; fi`
+
+lib_a-fread.o: fread.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-fread.o `test -f 'fread.c' || echo '$(srcdir)/'`fread.c
+
+lib_a-fread.obj: fread.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-fread.obj `if test -f 'fread.c'; then $(CYGPATH_W) 'fread.c'; else $(CYGPATH_W) '$(srcdir)/fread.c'; fi`
+
+lib_a-fwrite.o: fwrite.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-fwrite.o `test -f 'fwrite.c' || echo '$(srcdir)/'`fwrite.c
+
+lib_a-fwrite.obj: fwrite.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-fwrite.obj `if test -f 'fwrite.c'; then $(CYGPATH_W) 'fwrite.c'; else $(CYGPATH_W) '$(srcdir)/fwrite.c'; fi`
+
+lib_a-getc.o: getc.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-getc.o `test -f 'getc.c' || echo '$(srcdir)/'`getc.c
+
+lib_a-getc.obj: getc.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-getc.obj `if test -f 'getc.c'; then $(CYGPATH_W) 'getc.c'; else $(CYGPATH_W) '$(srcdir)/getc.c'; fi`
+
+lib_a-putc.o: putc.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-putc.o `test -f 'putc.c' || echo '$(srcdir)/'`putc.c
+
+lib_a-putc.obj: putc.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-putc.obj `if test -f 'putc.c'; then $(CYGPATH_W) 'putc.c'; else $(CYGPATH_W) '$(srcdir)/putc.c'; fi`
+
+lib_a-fgetc.o: fgetc.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-fgetc.o `test -f 'fgetc.c' || echo '$(srcdir)/'`fgetc.c
+
+lib_a-fgetc.obj: fgetc.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-fgetc.obj `if test -f 'fgetc.c'; then $(CYGPATH_W) 'fgetc.c'; else $(CYGPATH_W) '$(srcdir)/fgetc.c'; fi`
+
+lib_a-fgets.o: fgets.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-fgets.o `test -f 'fgets.c' || echo '$(srcdir)/'`fgets.c
+
+lib_a-fgets.obj: fgets.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-fgets.obj `if test -f 'fgets.c'; then $(CYGPATH_W) 'fgets.c'; else $(CYGPATH_W) '$(srcdir)/fgets.c'; fi`
+
+lib_a-fputc.o: fputc.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-fputc.o `test -f 'fputc.c' || echo '$(srcdir)/'`fputc.c
+
+lib_a-fputc.obj: fputc.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-fputc.obj `if test -f 'fputc.c'; then $(CYGPATH_W) 'fputc.c'; else $(CYGPATH_W) '$(srcdir)/fputc.c'; fi`
+
+lib_a-fputs.o: fputs.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-fputs.o `test -f 'fputs.c' || echo '$(srcdir)/'`fputs.c
+
+lib_a-fputs.obj: fputs.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-fputs.obj `if test -f 'fputs.c'; then $(CYGPATH_W) 'fputs.c'; else $(CYGPATH_W) '$(srcdir)/fputs.c'; fi`
+
+lib_a-ungetc.o: ungetc.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-ungetc.o `test -f 'ungetc.c' || echo '$(srcdir)/'`ungetc.c
+
+lib_a-ungetc.obj: ungetc.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-ungetc.obj `if test -f 'ungetc.c'; then $(CYGPATH_W) 'ungetc.c'; else $(CYGPATH_W) '$(srcdir)/ungetc.c'; fi`
+
+lib_a-fprintf.o: fprintf.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-fprintf.o `test -f 'fprintf.c' || echo '$(srcdir)/'`fprintf.c
+
+lib_a-fprintf.obj: fprintf.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-fprintf.obj `if test -f 'fprintf.c'; then $(CYGPATH_W) 'fprintf.c'; else $(CYGPATH_W) '$(srcdir)/fprintf.c'; fi`
+
+lib_a-fscanf.o: fscanf.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-fscanf.o `test -f 'fscanf.c' || echo '$(srcdir)/'`fscanf.c
+
+lib_a-fscanf.obj: fscanf.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-fscanf.obj `if test -f 'fscanf.c'; then $(CYGPATH_W) 'fscanf.c'; else $(CYGPATH_W) '$(srcdir)/fscanf.c'; fi`
+
+lib_a-vfprintf.o: vfprintf.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-vfprintf.o `test -f 'vfprintf.c' || echo '$(srcdir)/'`vfprintf.c
+
+lib_a-vfprintf.obj: vfprintf.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-vfprintf.obj `if test -f 'vfprintf.c'; then $(CYGPATH_W) 'vfprintf.c'; else $(CYGPATH_W) '$(srcdir)/vfprintf.c'; fi`
+
+lib_a-vfscanf.o: vfscanf.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-vfscanf.o `test -f 'vfscanf.c' || echo '$(srcdir)/'`vfscanf.c
+
+lib_a-vfscanf.obj: vfscanf.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-vfscanf.obj `if test -f 'vfscanf.c'; then $(CYGPATH_W) 'vfscanf.c'; else $(CYGPATH_W) '$(srcdir)/vfscanf.c'; fi`
 
 lib_a-perror.o: perror.c
 	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-perror.o `test -f 'perror.c' || echo '$(srcdir)/'`perror.c
@@ -385,6 +583,18 @@ lib_a-perror.o: perror.c
 lib_a-perror.obj: perror.c
 	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-perror.obj `if test -f 'perror.c'; then $(CYGPATH_W) 'perror.c'; else $(CYGPATH_W) '$(srcdir)/perror.c'; fi`
 
+lib_a-gets.o: gets.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-gets.o `test -f 'gets.c' || echo '$(srcdir)/'`gets.c
+
+lib_a-gets.obj: gets.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-gets.obj `if test -f 'gets.c'; then $(CYGPATH_W) 'gets.c'; else $(CYGPATH_W) '$(srcdir)/gets.c'; fi`
+
+lib_a-getchar.o: getchar.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-getchar.o `test -f 'getchar.c' || echo '$(srcdir)/'`getchar.c
+
+lib_a-getchar.obj: getchar.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-getchar.obj `if test -f 'getchar.c'; then $(CYGPATH_W) 'getchar.c'; else $(CYGPATH_W) '$(srcdir)/getchar.c'; fi`
+
 lib_a-putchar.o: putchar.c
 	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-putchar.o `test -f 'putchar.c' || echo '$(srcdir)/'`putchar.c
 
@@ -397,11 +607,17 @@ lib_a-puts.o: puts.c
 lib_a-puts.obj: puts.c
 	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-puts.obj `if test -f 'puts.c'; then $(CYGPATH_W) 'puts.c'; else $(CYGPATH_W) '$(srcdir)/puts.c'; fi`
 
-lib_a-vsnprintf.o: vsnprintf.c
-	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-vsnprintf.o `test -f 'vsnprintf.c' || echo '$(srcdir)/'`vsnprintf.c
+lib_a-printf.o: printf.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-printf.o `test -f 'printf.c' || echo '$(srcdir)/'`printf.c
 
-lib_a-vsnprintf.obj: vsnprintf.c
-	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-vsnprintf.obj `if test -f 'vsnprintf.c'; then $(CYGPATH_W) 'vsnprintf.c'; else $(CYGPATH_W) '$(srcdir)/vsnprintf.c'; fi`
+lib_a-printf.obj: printf.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-printf.obj `if test -f 'printf.c'; then $(CYGPATH_W) 'printf.c'; else $(CYGPATH_W) '$(srcdir)/printf.c'; fi`
+
+lib_a-scanf.o: scanf.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-scanf.o `test -f 'scanf.c' || echo '$(srcdir)/'`scanf.c
+
+lib_a-scanf.obj: scanf.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-scanf.obj `if test -f 'scanf.c'; then $(CYGPATH_W) 'scanf.c'; else $(CYGPATH_W) '$(srcdir)/scanf.c'; fi`
 
 lib_a-vprintf.o: vprintf.c
 	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-vprintf.o `test -f 'vprintf.c' || echo '$(srcdir)/'`vprintf.c
@@ -409,6 +625,36 @@ lib_a-vprintf.o: vprintf.c
 lib_a-vprintf.obj: vprintf.c
 	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-vprintf.obj `if test -f 'vprintf.c'; then $(CYGPATH_W) 'vprintf.c'; else $(CYGPATH_W) '$(srcdir)/vprintf.c'; fi`
 
+lib_a-vscanf.o: vscanf.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-vscanf.o `test -f 'vscanf.c' || echo '$(srcdir)/'`vscanf.c
+
+lib_a-vscanf.obj: vscanf.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-vscanf.obj `if test -f 'vscanf.c'; then $(CYGPATH_W) 'vscanf.c'; else $(CYGPATH_W) '$(srcdir)/vscanf.c'; fi`
+
+lib_a-setbuf.o: setbuf.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-setbuf.o `test -f 'setbuf.c' || echo '$(srcdir)/'`setbuf.c
+
+lib_a-setbuf.obj: setbuf.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-setbuf.obj `if test -f 'setbuf.c'; then $(CYGPATH_W) 'setbuf.c'; else $(CYGPATH_W) '$(srcdir)/setbuf.c'; fi`
+
+lib_a-setvbuf.o: setvbuf.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-setvbuf.o `test -f 'setvbuf.c' || echo '$(srcdir)/'`setvbuf.c
+
+lib_a-setvbuf.obj: setvbuf.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-setvbuf.obj `if test -f 'setvbuf.c'; then $(CYGPATH_W) 'setvbuf.c'; else $(CYGPATH_W) '$(srcdir)/setvbuf.c'; fi`
+
+lib_a-tmpfile.o: tmpfile.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-tmpfile.o `test -f 'tmpfile.c' || echo '$(srcdir)/'`tmpfile.c
+
+lib_a-tmpfile.obj: tmpfile.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-tmpfile.obj `if test -f 'tmpfile.c'; then $(CYGPATH_W) 'tmpfile.c'; else $(CYGPATH_W) '$(srcdir)/tmpfile.c'; fi`
+
+lib_a-vsnprintf.o: vsnprintf.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-vsnprintf.o `test -f 'vsnprintf.c' || echo '$(srcdir)/'`vsnprintf.c
+
+lib_a-vsnprintf.obj: vsnprintf.c
+	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-vsnprintf.obj `if test -f 'vsnprintf.c'; then $(CYGPATH_W) 'vsnprintf.c'; else $(CYGPATH_W) '$(srcdir)/vsnprintf.c'; fi`
+
 lib_a-vsprintf.o: vsprintf.c
 	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(lib_a_CFLAGS) $(CFLAGS) -c -o lib_a-vsprintf.o `test -f 'vsprintf.c' || echo '$(srcdir)/'`vsprintf.c
 

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]