about summary refs log tree commit diff
path: root/sysdeps
diff options
context:
space:
mode:
authorH.J. Lu <hjl.tools@gmail.com>2012-05-31 20:35:10 -0700
committerH.J. Lu <hjl.tools@gmail.com>2012-05-31 20:35:10 -0700
commitebc64a18c07742ebb85d7ddeca376995c0e67593 (patch)
tree3b1acf747c60639020b18a75e105de57063569bf /sysdeps
parentedf2933a37d2c52b30e3730ae3df7b3d465dc958 (diff)
downloadglibc-ebc64a18c07742ebb85d7ddeca376995c0e67593.tar.gz
glibc-ebc64a18c07742ebb85d7ddeca376995c0e67593.tar.xz
glibc-ebc64a18c07742ebb85d7ddeca376995c0e67593.zip
Support __WORDSIZE == 64 in i386 bits/wchar.h
Diffstat (limited to 'sysdeps')
-rw-r--r--sysdeps/unix/sysv/linux/i386/bits/wchar.h15
1 files changed, 11 insertions, 4 deletions
diff --git a/sysdeps/unix/sysv/linux/i386/bits/wchar.h b/sysdeps/unix/sysv/linux/i386/bits/wchar.h
index b94fc7a3f2..ec0f34a476 100644
--- a/sysdeps/unix/sysv/linux/i386/bits/wchar.h
+++ b/sysdeps/unix/sysv/linux/i386/bits/wchar.h
@@ -1,5 +1,5 @@
-/* wchar_t type related definitions.
-   Copyright (C) 2000 Free Software Foundation, Inc.
+/* wchar_t type related definitions.  i386/x86-64 version.
+   Copyright (C) 2000-2012 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    The GNU C Library is free software; you can redistribute it and/or
@@ -19,7 +19,14 @@
 #ifndef _BITS_WCHAR_H
 #define _BITS_WCHAR_H	1
 
-#define __WCHAR_MIN	(-2147483647l - 1l)
-#define __WCHAR_MAX	(2147483647l)
+#include <bits/wordsize.h>
+
+#if __WORDSIZE == 64
+# define __WCHAR_MIN	(-2147483647 - 1)
+# define __WCHAR_MAX	(2147483647)
+#else
+# define __WCHAR_MIN	(-2147483647l - 1l)
+# define __WCHAR_MAX	(2147483647l)
+#endif
 
 #endif	/* bits/wchar.h */