shithub: scc

Download patch

ref: 4f219193c028b5e3b35d7317c2ead65b0f721b5e
parent: 1f0d365d97c2e1f57938d17e642c4e3496732b51
author: Roberto E. Vargas Caballero <k0ga@shike2.com>
date: Sat Feb 18 15:25:39 EST 2017

[libc] Add wchar_t to stdlib.h

--- a/libc/include/bits/amd64-sysv/arch/stdlib.h
+++ b/libc/include/bits/amd64-sysv/arch/stdlib.h
@@ -12,3 +12,8 @@
 #define EXIT_FAILURE 1
 #define EXIT_SUCCESS 0
 #define RAND_MAX     32767
+
+#ifndef _WCHAR_T
+typedef int wchar_t;
+#define _WCHAR_T
+#endif
--- a/libc/include/bits/i386-sysv/arch/stdlib.h
+++ b/libc/include/bits/i386-sysv/arch/stdlib.h
@@ -12,3 +12,8 @@
 #define EXIT_FAILURE 1
 #define EXIT_SUCCESS 0
 #define RAND_MAX     32767
+
+#ifndef _WCHAR_T
+typedef int wchar_t;
+#define _WCHAR_T
+#endif
--- a/libc/include/bits/qbe/arch/stdlib.h
+++ b/libc/include/bits/qbe/arch/stdlib.h
@@ -12,3 +12,8 @@
 #define EXIT_FAILURE 1
 #define EXIT_SUCCESS 0
 #define RAND_MAX     32767
+
+#ifndef _WCHAR_T
+typedef int wchar_t;
+#define _WCHAR_T
+#endif
--- a/libc/include/bits/z80/arch/stdlib.h
+++ b/libc/include/bits/z80/arch/stdlib.h
@@ -12,3 +12,8 @@
 #define EXIT_FAILURE 1
 #define EXIT_SUCCESS 0
 #define RAND_MAX     32767
+
+#ifndef _WCHAR_T
+typedef long wchar_t;
+#define _WCHAR_T
+#endif