Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cygwin.com/git/newlib-cygwin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--newlib/ChangeLog7
-rw-r--r--newlib/libc/include/stdio.h4
-rw-r--r--newlib/libc/include/sys/config.h3
3 files changed, 13 insertions, 1 deletions
diff --git a/newlib/ChangeLog b/newlib/ChangeLog
index 539be4563..df9f43860 100644
--- a/newlib/ChangeLog
+++ b/newlib/ChangeLog
@@ -1,3 +1,10 @@
+2009-10-16 Jeff Johnston <jjohnstn@redhat.com>
+
+ * libc/include/sys/config.h[__CYGWIN__]: Set __USE_XOPEN2K flag
+ if not __STRICT_ANSI__ or stdc version C99 or greater.
+ * libc/include/stdio.h[__STRICT_ANSI__]: Add __USE_XOPEN2K check
+ for fseeko and ftello prototypes.
+
2009-10-15 Corinna Vinschen <corinna@vinschen.de>
* libc/include/wchar.h (struct tm0: Declare as incomplete type.
diff --git a/newlib/libc/include/stdio.h b/newlib/libc/include/stdio.h
index cf0be47b9..b9c8745bc 100644
--- a/newlib/libc/include/stdio.h
+++ b/newlib/libc/include/stdio.h
@@ -232,7 +232,7 @@ int _EXFUN(sprintf, (char *, const char *, ...)
int _EXFUN(remove, (const char *));
int _EXFUN(rename, (const char *, const char *));
#endif
-#ifndef __STRICT_ANSI__
+#if !defined(__STRICT_ANSI__) || defined(__USE_XOPEN2K)
#ifdef _COMPILING_NEWLIB
int _EXFUN(fseeko, (FILE *, _off_t, int));
_off_t _EXFUN(ftello, ( FILE *));
@@ -240,6 +240,8 @@ _off_t _EXFUN(ftello, ( FILE *));
int _EXFUN(fseeko, (FILE *, off_t, int));
off_t _EXFUN(ftello, ( FILE *));
#endif
+#endif
+#if !defined(__STRICT_ANSI__) || (__STDC_VERSION__ >= 199901L)
#ifndef _REENT_ONLY
int _EXFUN(asiprintf, (char **, const char *, ...)
_ATTRIBUTE ((__format__ (__printf__, 2, 3))));
diff --git a/newlib/libc/include/sys/config.h b/newlib/libc/include/sys/config.h
index 68d31a1ad..7572d13f2 100644
--- a/newlib/libc/include/sys/config.h
+++ b/newlib/libc/include/sys/config.h
@@ -186,6 +186,9 @@
#include <cygwin/config.h>
#define __LINUX_ERRNO_EXTENSIONS__ 1
#define _MB_EXTENDED_CHARSETS_ALL 1
+#if !defined (__STRICT_ANSI__) || (__STDC_VERSION__ >= 199901L)
+#define __USE_XOPEN2K 1
+#endif
#endif
#if defined(__rtems__)