andlabs / andlabs/ui

Master issue for MinGW-w64 ABI issues

Aperta
#281 3 commenti 0 reazioni 0 assegnatari Vedi su GitHub
Lingua principale
Go
Stelle
8.4k
Fork
639
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Descrizione

libui on Windows is written in C++, which introduces a number of ABI issues. These vary in nature, but they cause a headache for package ui because we have no way of knowing ahead of time what MinGW people are going to use with it, and for some people, MinGW could have been installed for them by an IDE (like Code::Blocks).

The issues include:

- missing implementations of `operator new`
- missing implementations of `std::ostringstream`
- incompatible exception model — this is the biggest one, and the source of errors involving `__gxx_personality_seh0`, `_Unwind_Resume`, etc.

But unlike #279, I have no idea what to do about this (which is why this is a separate issue), or where to begin with resolving this. The go tool won't help here, and I'm not sure if any facet of the above (and things not listed above) can be handled with, say, preprocessor options.

The issue with exception handling is that MinGW can be built to generate code using three possible C++ exception handling models (DWARF, SJLJ, and SEH), and IIRC there is no way to check at compile time which is being used (if there is this might be slightly easier), nor is there any way to build a multi-model binary (if there is I wouldn't know what it is).

I do wonder whether I need to strictly require MinGW-w64 or if any MinGW could do now that libui is statically linked into package ui.

(Now I'm starting to wonder if I have the same problems lurking around the corner in libui with MSVC...)

Minor note: some people seem to think the gcc version and the MinGW-w64 version are the same thing; they are not. Will need to point this out in the documentation that comes out of this issue and #279 as well...

Guida per i contributori

Nessuna guida per i contributori indicizzata per questo repository

Valutazione

Questa issue non è ancora stata valutata.

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.