[PATCH v2 10/12] arch: fix wchar_t & wint_t on SunOS/Solaris

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 32-bit sparc running SunOS or Solaris, wchar_t and wint_t
are long, not uint or int.

Add a special case to handle this.

Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@xxxxxxxxx>
---
 target.c | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/target.c b/target.c
index c89bb07d2..64e6533f6 100644
--- a/target.c
+++ b/target.c
@@ -98,7 +98,6 @@ void init_target(void)
 		}
 		break;
 	case MACH_M68K:
-	case MACH_SPARC32:
 	case MACH_PPC32:
 		wchar_ctype = &long_ctype;
 		break;
@@ -106,6 +105,12 @@ void init_target(void)
 	case MACH_ARM64:
 		wchar_ctype = &uint_ctype;
 		break;
+	case MACH_SPARC32:
+		if (arch_os == OS_SUNOS) {
+			wint_ctype = &long_ctype;
+			wchar_ctype = &long_ctype;
+		}
+		break;
 	default:
 		break;
 	}
-- 
2.24.0




[Index of Archives]     [Newbies FAQ]     [LKML]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Trinity Fuzzer Tool]

  Powered by Linux