Cygwin uses 'unsigned short' for its wchar_t. So, use -fshort-wchar for it. Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@xxxxxxxxx> --- cgcc | 1 + 1 file changed, 1 insertion(+) diff --git a/cgcc b/cgcc index 201fbc9a0..239f713da 100755 --- a/cgcc +++ b/cgcc @@ -252,6 +252,7 @@ sub add_specs { return ' -Dunix=1 -D__unix=1 -D__unix__=1'; } elsif ( $spec =~ /^cygwin/) { return &add_specs ('unix') . + ' -fshort-wchar' . ' -D__CYGWIN__=1 -D__CYGWIN32__=1' . " -D'_cdecl=__attribute__((__cdecl__))'" . " -D'__cdecl=__attribute__((__cdecl__))'" . -- 2.24.0