This is the mail archive of the newlib-cvs@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]

[newlib-cygwin] Guard langinfo.h nl_item from multiple typedefs


https://sourceware.org/git/gitweb.cgi?p=newlib-cygwin.git;h=bd62f539defbbd16f73e99ff20d2daa6d6c18d9e

commit bd62f539defbbd16f73e99ff20d2daa6d6c18d9e
Author: Yaakov Selkowitz <yselkowi@redhat.com>
Date:   Thu Jan 18 23:53:18 2018 -0600

    Guard langinfo.h nl_item from multiple typedefs
    
    This is a prerequisite of adding nl_types.h support to Cygwin.
    
    Signed-off-by: Yaakov Selkowitz <yselkowi@redhat.com>

Diff:
---
 newlib/libc/include/langinfo.h | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/newlib/libc/include/langinfo.h b/newlib/libc/include/langinfo.h
index 59381d6..458b925 100644
--- a/newlib/libc/include/langinfo.h
+++ b/newlib/libc/include/langinfo.h
@@ -36,7 +36,10 @@
 #include <xlocale.h>
 #endif
 
+#ifndef _NL_ITEM_DECLARED
 typedef int nl_item;
+#define _NL_ITEM_DECLARED
+#endif
 
 enum __nl_item
 {


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