Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

imgui 1.43 MinGW missing header (alloca.h) #276

Closed
unpacklo opened this issue Jul 17, 2015 · 1 comment
Closed

imgui 1.43 MinGW missing header (alloca.h) #276

unpacklo opened this issue Jul 17, 2015 · 1 comment

Comments

@unpacklo
Copy link

I don't do normal development on Windows so I didn't catch this earlier, sorry!

I tried to update our game to 1.43 today and our build servers hit this error on Windows with MinGW:

imgui/imgui.cpp:474:34: fatal error: alloca.h: No such file or directory
 #include <alloca.h>     // alloca
                                  ^
compilation terminated.

It seems that MinGW does not supply this header. I ended up fixing this by using this #if sequence instead:

#if defined(_MSC_VER) || defined(__MINGW32__)
#include <malloc.h>     // alloca
#else
#include <alloca.h>     // alloca
#endif
ocornut added a commit that referenced this issue Jul 17, 2015
@ocornut
Copy link
Owner

ocornut commented Jul 17, 2015

Thanks!
I confirmed that bgfx was doing the same for MinGW too.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants