Added the 'gcc' compiler used in the 'About' window.
This patch is not 100%, because it doesn't detect if clang is used as compiler.
In 'StartHerePage::StartHerePage(...)' : no 'clang' detection, only 'GCC' Here is a simplistic version of 'clang' detection since compiler I can not check the 'clang' part.
This doesn't work. Clang presents itself as GCC. So it defines the GNUC define. :(
For the start page, probably it is better to unify those so they are done in a single place.
It was my goal, but I do not know how to do better !
May be I missed something, but what about this?:
#if defined (__clang__) + _T(" - clang ") + (wxString()<< __clang_major__ + _T(".") + (wxString()<< __clang_minor__) + _T(".") + (wxString()<< __clang_patchlevel__) #elif defined (__GNUC__) + _T(" - gcc ") + (wxString()<< __GNUC__) + _T(".") + (wxString()<< __GNUC_MINOR__) + _T(".") + (wxString()<< __GNUC_PATCHLEVEL__) #endif
Yes, this would probably work correctly.
Or again, which allows to add other GNUC compilers #ifdef __GNUC__ #ifdef __clang__ + _T(" - clang ") + (wxString()<< __clang_major__ + _T(".") + (wxString()<< __clang_minor__) + _T(".") + (wxString()<< __clang_patchlevel__) #else + _T(" - gcc ") + (wxString()<< __GNUC__) + _T(".") + (wxString()<< __GNUC_MINOR__) + _T(".") + (wxString()<< __GNUC_PATCHLEVEL__) #endif #endif
Applied (modified) in SVN. Thank you!
The check order in the applied patch must be changed, because (as Teodor Petrov said) Clang defines __GNUC__
__GNUC__
Log in to post a comment.
This patch is not 100%, because it doesn't detect if clang is used as compiler.
In 'StartHerePage::StartHerePage(...)' : no 'clang' detection, only 'GCC'
Here is a simplistic version of 'clang' detection since compiler
I can not check the 'clang' part.
Last edit: LETARTARE 2019-09-05
This doesn't work. Clang presents itself as GCC. So it defines the GNUC define. :(
For the start page, probably it is better to unify those so they are done in a single place.
It was my goal, but I do not know how to do better !
May be I missed something, but what about this?:
Yes, this would probably work correctly.
Applied (modified) in SVN. Thank you!
The check order in the applied patch must be changed, because (as Teodor Petrov said) Clang defines
__GNUC__
Last edit: Miguel Gimenez 2019-11-02