Hello MinGW,

I have been successfully using MinGW to build LuaJIT for a couple of years now. We have been using a version from early last year (--version reports 4.6.2) and we recently upgraded to the latest. This has caused our LuaJIT build process to fail. Here are the details that might be relevant:

Platform: Windows 8 and 7
MinGW: latest (--version 4.8.1), with all sub-modules installed via graphical installer
Build Target: LuaJIT 2.0.2 (using the Windows-specific Makefile in LuaJIT-2.02./src)
Error: "undefined reference to GetModuleHandleExA" in function clib_getsym in lj_clib.c

We haven't had any trouble building this with VS 2010 or with the older MinGW, which leads me to believe we might be doing something wrong using the latest MinGW.

So I'm wondering if there's any advice for working around this problem? Any thoughts on how to work around this problem would be appreciated.

Thank you in advance,
Demetri Spanos