c47edit icon indicating copy to clipboard operation
c47edit copied to clipboard

Fix building c47edit using MinGW on Linux

Open madebr opened this issue 1 year ago • 5 comments

These patches fix building c47edit on Linux using a MinGW toolchain.

madebr avatar Sep 24 '24 16:09 madebr

Thanks for the PR! It's indeed useful to support other compilers, and also make it compile on Linux (and run with Wine), because you never know how Windows will become these days...

But at the same time I would have to be more careful to not introduce some compile errors that would only trigger GCC/Clang but not VC++ :)

I will review it, there's some things I need to ask.

AdrienTD avatar Sep 25 '24 20:09 AdrienTD

AppVeyor build failed

Aztec2012 avatar Oct 09 '24 13:10 Aztec2012

error C2338: static_assert failed: 'Unicode support requires compiling with /utf-8'

Since it is happening in libfmt, I suppose this has nothing to do with this pr but with the dependency. I'll apply a patch similar to this one to the vcxproj

madebr avatar Oct 09 '24 13:10 madebr

With these 2 last commits, the only error remaining for targeting Linux are the windows.h includes (and its use of the win api).

If https://github.com/0danny/re47 ever gets somewhere, it should be easy to port everything to a platform agnostic toolkit, such as SDL.

madebr avatar Oct 29 '24 18:10 madebr

The commit "Avoid windows-only _wfopen_s" 89e34e1 needs to be reverted, as this breaks the code.

I removed it from the patch set.

madebr avatar Dec 02 '24 09:12 madebr