I have managed to compile the latest commit (at time of writing: 122fe39) under both Windows and Linux, but not without modification.
The issues I found and had to fix are as follows:
Windows/MSVC
Linux/GCC
I did not test Mac compilation because I do not have a Mac, but if Mac compilation didn't work before it should work now...
I have managed to compile the latest commit (at time of writing: 122fe39) under both Windows and Linux, but not without modification.
The issues I found and had to fix are as follows:
Windows/MSVC
windef.h's definition ofmin/maxmacros.I just did some substitution to replace any instance of
<...>::max(with(<...>::max)((same with min).I used this regex in VS Code to accomplish it: find
([^-{(\s]*)::m([ai][xn])\(replace($1::m$2)(There is a define,
NOMINMAX, that you could use, but I don't know where to put it for these.DEBUGis a macro under MSVC.What I did was rename
Box::DEBUGtoBox::ENABLE_DEBUGin this case.I discovered this hack through your issue on this repo (Conflict with some macros NanoMichael/MicroTeX#44), so I guess you're aware of it.
You may want to just depend on your own fork instead at this point.
Linux/GCC
I actually don't know what's wrong with these lines but I'm assuming that
Statusis some predefined macro under GCC likemin/max/DEBUGon MSVC as seen before. If someone could tell me why, that would be much appreciated. Until then, commenting out these lines works.return (void*)glfwGetX11Window(_mainWindow);and it works again.#include <cstring>somewhere at the top.Box2D/Box2D.htobox2d/box2d.h, because Linux is strict on capitalization.I did not test Mac compilation because I do not have a Mac, but if Mac compilation didn't work before it should work now...