nappgui_src icon indicating copy to clipboard operation
nappgui_src copied to clipboard

Support for gcc / g++ for Windows

Open JoeyUson opened this issue 1 year ago • 1 comments

I would like to request for inclusion of gcc /g++ support for Windows 10 compilation. Using VSCode editor and cmake.

JoeyUson avatar May 20 '23 02:05 JoeyUson

I second this. Here's a possible update to the arch.hxx file to support mingw:

src\sewer\arch.hxx

#if defined (_WINDOWS) || defined (__MINGW32__)
    #if defined (_MSC_VER) && _MSC_VER <= 1500
        #define __STDC_LIMIT_MACROS
    #endif

    #define __WINDOWS__
    #define __DESKTOP__
    #if defined (_M_AMD64) || defined (__amd64__)
        #define __x64__
    #elif defined (_M_IX86) || defined (__i386__)
        #define __x86__
    #else
        #error Unknown processor
    #endif

Here's a list of useful defines for many compilers and platforms https://github.com/cpredef/predef, https://github.com/cpredef/predef/blob/master/Architectures.md

I think the best and most current up to date Mingw releases are these 2:

https://winlibs.com/ https://github.com/skeeto/w64devkit

I have used both successfully.

ragsaq avatar Dec 27 '23 15:12 ragsaq

The support for MinGW has been added in NAppGUI 1.4.2. Doc: https://nappgui.com/en/guide/win_mac_linux.html#h4 Commit: https://github.com/frang75/nappgui_src/commit/5f638074231f028a5eb8a07c2f0d232edad408c6 Thanks for the patience.

frang75 avatar May 19 '24 14:05 frang75