diff --git a/contrib/sdk/sources/newlib/libc/Makefile b/contrib/sdk/sources/newlib/libc/Makefile index 783d7a598b..4fcc04d25f 100644 --- a/contrib/sdk/sources/newlib/libc/Makefile +++ b/contrib/sdk/sources/newlib/libc/Makefile @@ -78,6 +78,7 @@ CORE_SRCS:= \ ctype/iswupper.c \ ctype/iswxdigit.c \ ctype/isxdigit.c \ + ctype/jp2uc.c \ ctype/toascii.c \ ctype/tolower.c \ ctype/toupper.c \ diff --git a/contrib/sdk/sources/newlib/libc/Tupfile.lua b/contrib/sdk/sources/newlib/libc/Tupfile.lua index a215f40ebe..6ddd067d55 100644 --- a/contrib/sdk/sources/newlib/libc/Tupfile.lua +++ b/contrib/sdk/sources/newlib/libc/Tupfile.lua @@ -62,6 +62,7 @@ CORE_SRCS = { "ctype/iswupper.c", "ctype/iswxdigit.c", "ctype/isxdigit.c", + "ctype/jp2uc.c", "ctype/toascii.c", "ctype/tolower.c", "ctype/toupper.c", diff --git a/contrib/sdk/sources/newlib/libc/include/newlib.h b/contrib/sdk/sources/newlib/libc/include/newlib.h index 7585a3a0b4..a6e3d3963b 100644 --- a/contrib/sdk/sources/newlib/libc/include/newlib.h +++ b/contrib/sdk/sources/newlib/libc/include/newlib.h @@ -17,8 +17,6 @@ * printf/scanf enabled */ #define _WANT_IO_C99_FORMATS -#define __DYNAMIC_REENT__ - /* long long type support in IO functions like printf/scanf enabled */ #define _WANT_IO_LONG_LONG @@ -36,10 +34,10 @@ /* #undef _WANT_REENT_SMALL */ /* Multibyte supported */ -/* #undef _MB_CAPABLE */ +#define _MB_CAPABLE /* MB_LEN_MAX */ -#define _MB_LEN_MAX 1 +#define _MB_LEN_MAX 2 /* ICONV enabled */ /* #undef _ICONV_ENABLED */ @@ -64,6 +62,21 @@ /* True if long double supported and it is equal to double. */ /* #undef _LDBL_EQ_DBL */ +/* Define if wide char orientation is supported. */ +#define _WIDE_ORIENT 1 + +/* Define if unbuffered stream file optimization is supported. */ +#define _UNBUF_STREAM_OPT 1 + +/* Define if lite version of exit supported. */ +/* #undef _LITE_EXIT */ + +/* Define if declare atexit data as global. */ +/* #undef _REENT_GLOBAL_ATEXIT */ + +/* Define if small footprint nano-formatted-IO implementation used. */ +/* #undef _NANO_FORMATTED_IO */ + /* * Iconv encodings enabled ("to" direction) */ @@ -172,6 +185,8 @@ /* #undef _ICONV_FROM_ENCODING_WIN_1257 */ /* #undef _ICONV_FROM_ENCODING_WIN_1258 */ +#define __DYNAMIC_REENT__ + #ifdef STATIC_LIBC #define BUILD_LIBC #endif diff --git a/contrib/sdk/sources/newlib/libc/stdio/local.h b/contrib/sdk/sources/newlib/libc/stdio/local.h index 69d83d1aa6..b4e071460c 100644 --- a/contrib/sdk/sources/newlib/libc/stdio/local.h +++ b/contrib/sdk/sources/newlib/libc/stdio/local.h @@ -151,15 +151,15 @@ extern int _EXFUN(__svfwscanf_r,(struct _reent *,FILE *, _CONST wchar_t *,va_ extern int _EXFUN(__ssvfwscanf_r,(struct _reent *,FILE *, _CONST wchar_t *,va_list)); extern int _EXFUN(__svfiwscanf_r,(struct _reent *,FILE *, _CONST wchar_t *,va_list)); extern int _EXFUN(__ssvfiwscanf_r,(struct _reent *,FILE *, _CONST wchar_t *,va_list)); -int _EXFUN(_svfprintf_r,(struct _reent *, FILE *, const char *, +int _EXFUN(_svfprintf_r,(struct _reent *, FILE *, const char *, va_list) _ATTRIBUTE ((__format__ (__printf__, 3, 0)))); -int _EXFUN(_svfiprintf_r,(struct _reent *, FILE *, const char *, +int _EXFUN(_svfiprintf_r,(struct _reent *, FILE *, const char *, va_list) _ATTRIBUTE ((__format__ (__printf__, 3, 0)))); -int _EXFUN(_svfwprintf_r,(struct _reent *, FILE *, const wchar_t *, +int _EXFUN(_svfwprintf_r,(struct _reent *, FILE *, const wchar_t *, va_list)); -int _EXFUN(_svfiwprintf_r,(struct _reent *, FILE *, const wchar_t *, +int _EXFUN(_svfiwprintf_r,(struct _reent *, FILE *, const wchar_t *, va_list)); extern FILE *_EXFUN(__sfp,(struct _reent *)); extern int _EXFUN(__sflags,(struct _reent *,_CONST char*, int*)); @@ -263,14 +263,11 @@ extern _READ_WRITE_RETURN_TYPE _EXFUN(__swrite64,(struct _reent *, void *, #define ORIENT(fp,ori) \ do \ { \ - if (!((fp)->_flags & __SORD)) \ - { \ (fp)->_flags |= __SORD; \ if (ori > 0) \ (fp)->_flags2 |= __SWID; \ else \ (fp)->_flags2 &= ~__SWID; \ - } \ } \ while (0) #else