Attempting to compile Firefox 45ESR with the latest GCC 9.2, I've come to the following build break.
make[3]: Entering directory `Y:/work/cc45-git/mozilla/obj-fb/ipc/chromium'
c++ -o string_util_os2.obj -c -IY:/work/cc45-git/mozilla/obj-fb/dist/stl_wrappers -DHAVE_CONFIG_H -DOS_POSIX=1 -DOS_OS2=1 -DSTATIC_EXPORTABLE_JS_API -DMOZILLA_INTERNAL_API -DIMPL_LIBXUL -IY:/work/cc45-git/mozilla/ipc/chromium -I. -IY:/work/cc45-git/mozilla/ipc/chromium/src/third_party/libevent -IY:/work/cc45-git/mozilla/ipc/chromium/src/third_party/libevent/include -IY:/work/cc45-git/mozilla/ipc/chromium/src/third_party/libevent/os2 -IY:/work/cc45-git/mozilla/ipc/chromium/src/third_party/libevent/os2 -I../../ipc/ipdl/_ipdlheaders -IY:/work/cc45-git/mozilla/ipc/chromium/src -IY:/work/cc45-git/mozilla/ipc/glue -I../../dist/include -I/@unixroot/usr/include/nspr4 -I/@unixroot/usr/include/nss3 -I/@unixroot/usr/include/pixman-1 -DMOZILLA_CLIENT -include ../../mozilla-config.h -Uunix -U__unix -U__unix__ -MD -MP -MF .deps/string_util_os2.obj.pp -idirafter K:/usr/include/os2tk45 -Wall -Wempty-body -Woverloaded-virtual -Wsign-compare -Wwrite-strings -Wno-invalid-offsetof -Wcast-align -Zomf -fno-exceptions -fno-strict-aliasing -Zomf -fno-rtti -fno-exceptions -fno-math-errno -std=gnu++0x -pthread -DNDEBUG -DTRIMMED -g -march=i686 -O2 -fomit-frame-pointer Y:/work/cc45-git/mozilla/ipc/chromium/src/base/string_util_os2.cc
In file included from ../../dist/include/mozilla/throw_gcc.h:13,
from Y:/work/cc45-git/mozilla/obj-fb/dist/stl_wrappers/cstdlib:76,
from O:/usr/include/c++/9/stdlib.h:36,
from O:/usr/include/sys/fmutex.h:11,
from Y:/work/cc45-git/mozilla/ipc/chromium/src/base/string_util_os2.cc:55:
O:/usr/lib/gcc/i686-pc-os2-emx/9/include-fixed/stdio.h:218:9: error: '_fmutex' does not name a type
218 | _fmutex __fsem;
| ^~~~~~~
In file included from Y:/work/cc45-git/mozilla/ipc/chromium/src/base/string_util_os2.cc:66:
O:/usr/include/emx/io.h: In function 'int stream_lock(__sFILE*)':
O:/usr/include/emx/io.h:246:43: error: 'union __sFILE::<unnamed>' has no member named '__fsem'
246 | || !_fmutex_is_owner(&stream->__u.__fsem))
| ^~~~~~
O:/usr/include/emx/io.h:248:42: error: 'union __sFILE::<unnamed>' has no member named '__fsem'
248 | if (_fmutex_request(&stream->__u.__fsem, _FMR_IGNINT) != 0)
| ^~~~~~
O:/usr/include/emx/io.h: In function 'int stream_trylock(__sFILE*)':
O:/usr/include/emx/io.h:265:43: error: 'union __sFILE::<unnamed>' has no member named '__fsem'
265 | || !_fmutex_is_owner(&stream->__u.__fsem))
| ^~~~~~
O:/usr/include/emx/io.h:267:42: error: 'union __sFILE::<unnamed>' has no member named '__fsem'
267 | if (_fmutex_request(&stream->__u.__fsem, _FMR_NOWAIT) != 0)
| ^~~~~~
O:/usr/include/emx/io.h: In function 'int stream_unlock(__sFILE*)':
O:/usr/include/emx/io.h:297:41: error: 'union __sFILE::<unnamed>' has no member named '__fsem'
297 | && _fmutex_release(&stream->__u.__fsem) != 0)
| ^~~~~~
In file included from Y:/work/cc45-git/mozilla/ipc/chromium/src/base/string_util_os2.cc:68:
O:/usr/include/InnoTekLIBC/locale.h: At global scope:
O:/usr/include/InnoTekLIBC/locale.h:130:16: error: redefinition of 'struct __libc_localeWCType'
130 | typedef struct __libc_localeWCType
| ^~~~~~~~~~~~~~~~~~~
In file included from O:/usr/lib/gcc/i686-pc-os2-emx/9/include-fixed/wchar.h:87,
from ../../dist/include/mozilla/TypeTraits.h:20,
from ../../dist/include/mozilla/TemplateLib.h:23,
from ../../dist/include/mozilla/mozalloc.h:23,
from Y:/work/cc45-git/mozilla/obj-fb/dist/stl_wrappers/cmath:62,
from O:/usr/include/c++/9/math.h:36,
from Y:/work/cc45-git/mozilla/ipc/chromium/src/base/string_util_os2.cc:62:
O:/usr/include/_ctype.h:65:21: note: previous definition of 'struct __libc_localeWCType'
65 | extern const struct __libc_localeWCType
| ^~~~~~~~~~~~~~~~~~~
In file included from Y:/work/cc45-git/mozilla/ipc/chromium/src/base/string_util_os2.cc:68:
O:/usr/include/InnoTekLIBC/locale.h:242:37: error: conflicting declaration '__LIBC_LOCALECTYPE __libc_GLocaleCtype'
242 | extern __LIBC_LOCALECTYPE __libc_GLocaleCtype;
| ^~~~~~~~~~~~~~~~~~~
In file included from O:/usr/lib/gcc/i686-pc-os2-emx/9/include-fixed/wchar.h:87,
from ../../dist/include/mozilla/TypeTraits.h:20,
from ../../dist/include/mozilla/TemplateLib.h:23,
from ../../dist/include/mozilla/mozalloc.h:23,
from Y:/work/cc45-git/mozilla/obj-fb/dist/stl_wrappers/cmath:62,
from O:/usr/include/c++/9/math.h:36,
from Y:/work/cc45-git/mozilla/ipc/chromium/src/base/string_util_os2.cc:62:
O:/usr/include/_ctype.h:46:3: note: previous declaration as '<unnamed struct> __libc_GLocaleCtype'
46 | } __libc_GLocaleCtype;
| ^~~~~~~~~~~~~~~~~~~
In file included from Y:/work/cc45-git/mozilla/ipc/chromium/src/base/string_util_os2.cc:68:
O:/usr/include/InnoTekLIBC/locale.h:244:37: error: conflicting declaration 'const __LIBC_LOCALECTYPE __libc_GLocaleCtypeDefault'
244 | extern const __LIBC_LOCALECTYPE __libc_GLocaleCtypeDefault;
| ^~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from O:/usr/lib/gcc/i686-pc-os2-emx/9/include-fixed/wchar.h:87,
from ../../dist/include/mozilla/TypeTraits.h:20,
from ../../dist/include/mozilla/TemplateLib.h:23,
from ../../dist/include/mozilla/mozalloc.h:23,
from Y:/work/cc45-git/mozilla/obj-fb/dist/stl_wrappers/cmath:62,
from O:/usr/include/c++/9/math.h:36,
from Y:/work/cc45-git/mozilla/ipc/chromium/src/base/string_util_os2.cc:62:
O:/usr/include/_ctype.h:59:3: note: previous declaration as 'const<unnamed struct> __libc_GLocaleCtypeDefault'
59 | } __libc_GLocaleCtypeDefault;
| ^~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from Y:/work/cc45-git/mozilla/ipc/chromium/src/base/string_util_os2.cc:68:
O:/usr/include/InnoTekLIBC/locale.h:246:37: error: conflicting declaration '__LIBC_LOCALEWCTYPE __libc_GLocaleWCtype'
246 | extern __LIBC_LOCALEWCTYPE __libc_GLocaleWCtype;
| ^~~~~~~~~~~~~~~~~~~~
In file included from O:/usr/lib/gcc/i686-pc-os2-emx/9/include-fixed/wchar.h:87,
from ../../dist/include/mozilla/TypeTraits.h:20,
from ../../dist/include/mozilla/TemplateLib.h:23,
from ../../dist/include/mozilla/mozalloc.h:23,
from Y:/work/cc45-git/mozilla/obj-fb/dist/stl_wrappers/cmath:62,
from O:/usr/include/c++/9/math.h:36,
from Y:/work/cc45-git/mozilla/ipc/chromium/src/base/string_util_os2.cc:62:
O:/usr/include/_ctype.h:77:3: note: previous declaration as 'const __libc_localeWCType __libc_GLocaleWCtype'
77 | } __libc_GLocaleWCtype;
| ^~~~~~~~~~~~~~~~~~~~
Y:/work/cc45-git/mozilla/ipc/chromium/src/base/string_util_os2.cc: In function 'int out_pad(olocal*, wchar_t, int)':
Y:/work/cc45-git/mozilla/ipc/chromium/src/base/string_util_os2.cc:288:9: warning: comparison of integer expressions of different signedness: 'int' and 'unsigned int' [-Wsign-compare]
288 | if (n > SIZEOF_ARRAY (buf))
| ^
Y:/work/cc45-git/mozilla/ipc/chromium/src/base/string_util_os2.cc: In function 'int _output_wchar(FILE*, const wchar_t*, char*)':
Y:/work/cc45-git/mozilla/ipc/chromium/src/base/string_util_os2.cc:990:7: warning: unused variable 'mbn' [-Wunused-variable]
990 | int mbn, shift;
| ^~~
Y:/work/cc45-git/mozilla/ipc/chromium/src/base/string_util_os2.cc: In function 'int vswprintf(wchar_t*, size_t, const wchar_t*, va_list)':
Y:/work/cc45-git/mozilla/ipc/chromium/src/base/string_util_os2.cc:1335:28: error: 'union __sFILE::<unnamed>' has no member named '__fsem'
1335 | _fmutex_dummy(&trick.__u.__fsem);
| ^~~~~~
make[3]: *** [string_util_os2.obj] Error 1
make[3]: Leaving directory `Y:/work/cc45-git/mozilla/obj-fb/ipc/chromium'
make[2]: *** [ipc/chromium/target] Error 2