diff --git a/third_party/musl/arch/aarch64/bits/alltypes.h b/third_party/musl/arch/aarch64/bits/alltypes.h index 04d8c0bc33d4..77ff768a550b 100644 --- a/third_party/musl/arch/aarch64/bits/alltypes.h +++ b/third_party/musl/arch/aarch64/bits/alltypes.h @@ -11,10 +11,14 @@ #define __LONG_MAX 0x7fffffffffffffffL #ifndef __cplusplus +#if defined(USE_COBALT_CUSTOMIZATIONS) +typedef __WCHAR_TYPE__ wchar_t; +#else #if defined(__NEED_wchar_t) && !defined(__DEFINED_wchar_t) typedef unsigned wchar_t; #define __DEFINED_wchar_t #endif +#endif // defined(USE_COBALT_CUSTOMIZATIONS) #endif #if defined(__NEED_wint_t) && !defined(__DEFINED_wint_t) diff --git a/third_party/musl/arch/arm/bits/alltypes.h b/third_party/musl/arch/arm/bits/alltypes.h index 2bc88cd728b0..3993b1ea1b20 100644 --- a/third_party/musl/arch/arm/bits/alltypes.h +++ b/third_party/musl/arch/arm/bits/alltypes.h @@ -12,10 +12,14 @@ #define __LONG_MAX 0x7fffffffL #ifndef __cplusplus +#if defined(USE_COBALT_CUSTOMIZATIONS) +typedef __WCHAR_TYPE__ wchar_t; +#else #if defined(__NEED_wchar_t) && !defined(__DEFINED_wchar_t) typedef unsigned wchar_t; #define __DEFINED_wchar_t #endif +#endif // defined(USE_COBALT_CUSTOMIZATIONS) #endif diff --git a/third_party/musl/arch/x86_64/bits/alltypes.h b/third_party/musl/arch/x86_64/bits/alltypes.h index b5d6f523766e..2e3401f5e234 100644 --- a/third_party/musl/arch/x86_64/bits/alltypes.h +++ b/third_party/musl/arch/x86_64/bits/alltypes.h @@ -1,16 +1,18 @@ #define _Addr long #define _Int64 long #define _Reg long - #define __BYTE_ORDER 1234 #define __LONG_MAX 0x7fffffffffffffffL #ifndef __cplusplus +#if defined(USE_COBALT_CUSTOMIZATIONS) +typedef __WCHAR_TYPE__ wchar_t; +#else #if defined(__NEED_wchar_t) && !defined(__DEFINED_wchar_t) typedef int wchar_t; #define __DEFINED_wchar_t #endif - +#endif // defined(USE_COBALT_CUSTOMIZATIONS) #endif #if defined(__FLT_EVAL_METHOD__) && __FLT_EVAL_METHOD__ == 2