gcc complains that fclose() is too big to be inlined with -Os, so
humour it and move fclose() out of line.
{
(void)__m; return __create_file(__fd);
}
-static __inline__ int fclose(FILE *__f)
-{
- extern int close(int);
- return close(fileno(__f));
-}
-
+__extern int fclose(FILE *__f);
__extern int fputs(const char *, FILE *);
__extern int puts(const char *);
__extern int fputc(int, FILE *);
LIBOBJS = \
abort.o atexit.o atoi.o atol.o atoll.o calloc.o creat.o \
ctypes.o errno.o fgetc.o fgets.o fopen.o fprintf.o fputc.o \
- putchar.o setjmp.o \
+ fclose.o putchar.o setjmp.o \
fputs.o fread2.o fread.o free.o fwrite2.o fwrite.o getopt.o \
lrand48.o malloc.o stack.o memccpy.o memchr.o memcmp.o \
memcpy.o mempcpy.o memmem.o memmove.o memset.o memswap.o \
--- /dev/null
+/*
+ * fclose.c
+ */
+
+#include <stdio.h>
+#include <unistd.h>
+
+int fclose(FILE *__f)
+{
+ return close(fileno(__f));
+}