[Vm-dev] New kid on the block: gcc 4.6.1 & windows

Igor Stasenko siguctua at gmail.com
Tue Feb 28 16:15:39 UTC 2012


gcc -v
Using built-in specs.
COLLECT_GCC=C:\MinGW\bin\gcc.exe
COLLECT_LTO_WRAPPER=c:/mingw/bin/../libexec/gcc/mingw32/4.6.1/lto-wrapper.exe
Target: mingw32
Configured with: ../gcc-4.6.1/configure
--enable-languages=c,c++,fortran,objc,obj-c++
--disable-sjlj-exceptions --with-dwarf2 --enable-shared
--enable-libgomp --disable-win32-registry --enable-libstdcxx-debug
--enable-version-specific-runtime-libs --build=mingw32 --prefix=/mingw
Thread model: win32
gcc version 4.6.1 (GCC)


c:/MinGW/msys/1.0/home/sig/cog/blessed/platforms/win32/vm/sqWin32Intel.c:
In function 'squeakExceptionHandler':
c:/MinGW/msys/1.0/home/sig/cog/blessed/platforms/win32/vm/sqWin32Intel.c:128:18:
error: '_RC_NEAR' undeclared (first use in this function)
c:/MinGW/msys/1.0/home/sig/cog/blessed/platforms/win32/vm/sqWin32Intel.c:128:18:
note: each undeclared identifier is reported only once for each
function it appears in
c:/MinGW/msys/1.0/home/sig/cog/blessed/platforms/win32/vm/sqWin32Intel.c:128:18:
error: '_PC_53' undeclared (first use in this function)
c:/MinGW/msys/1.0/home/sig/cog/blessed/platforms/win32/vm/sqWin32Intel.c:128:18:
error: '_EM_INVALID' undeclared (first use in this function)
c:/MinGW/msys/1.0/home/sig/cog/blessed/platforms/win32/vm/sqWin32Intel.c:128:18:
error: '_EM_ZERODIVIDE' undeclared (first use in this function)
c:/MinGW/msys/1.0/home/sig/cog/blessed/platforms/win32/vm/sqWin32Intel.c:128:18:
error: '_EM_OVERFLOW' undeclared (first use in this function)
c:/MinGW/msys/1.0/home/sig/cog/blessed/platforms/win32/vm/sqWin32Intel.c:128:18:
error: '_EM_UNDERFLOW' undeclared (first use in this function)
c:/MinGW/msys/1.0/home/sig/cog/blessed/platforms/win32/vm/sqWin32Intel.c:128:18:
error: '_EM_INEXACT' undeclared (first use in this function)
c:/MinGW/msys/1.0/home/sig/cog/blessed/platforms/win32/vm/sqWin32Intel.c:128:18:
error: '_EM_DENORMAL' undeclared (first use in this function)
c:/MinGW/msys/1.0/home/sig/cog/blessed/platforms/win32/vm/sqWin32Intel.c:128:31:
error: '_MCW_EM' undeclared (first use in this function)
c:/MinGW/msys/1.0/home/sig/cog/blessed/platforms/win32/vm/sqWin32Intel.c:128:41:
error: '_MCW_RC' undeclared (first use in this function)
c:/MinGW/msys/1.0/home/sig/cog/blessed/platforms/win32/vm/sqWin32Intel.c:128:51:
error: '_MCW_PC' undeclared (first use in this function)
c:/MinGW/msys/1.0/home/sig/cog/blessed/platforms/win32/vm/sqWin32Intel.c:128:61:
error: '_MCW_IC' undeclared (first use in this function)
c:/MinGW/msys/1.0/home/sig/cog/blessed/platforms/win32/vm/sqWin32Intel.c:
In function 'sqMain':
c:/MinGW/msys/1.0/home/sig/cog/blessed/platforms/win32/vm/sqWin32Intel.c:1249:14:
error: '_RC_NEAR' undeclared (first use in this function)
c:/MinGW/msys/1.0/home/sig/cog/blessed/platforms/win32/vm/sqWin32Intel.c:1249:14:
error: '_PC_53' undeclared (first use in this function)
c:/MinGW/msys/1.0/home/sig/cog/blessed/platforms/win32/vm/sqWin32Intel.c:1249:14:
error: '_EM_INVALID' undeclared (first use in this function)
c:/MinGW/msys/1.0/home/sig/cog/blessed/platforms/win32/vm/sqWin32Intel.c:1249:14:
error: '_EM_ZERODIVIDE' undeclared (first use in this function)
c:/MinGW/msys/1.0/home/sig/cog/blessed/platforms/win32/vm/sqWin32Intel.c:1249:14:
error: '_EM_OVERFLOW' undeclared (first use in this function)
c:/MinGW/msys/1.0/home/sig/cog/blessed/platforms/win32/vm/sqWin32Intel.c:1249:14:
error: '_EM_UNDERFLOW' undeclared (first use in this function)
c:/MinGW/msys/1.0/home/sig/cog/blessed/platforms/win32/vm/sqWin32Intel.c:1249:14:
error: '_EM_INEXACT' undeclared (first use in this function)
c:/MinGW/msys/1.0/home/sig/cog/blessed/platforms/win32/vm/sqWin32Intel.c:1249:14:
error: '_EM_DENORMAL' undeclared (first use in this function)
c:/MinGW/msys/1.0/home/sig/cog/blessed/platforms/win32/vm/sqWin32Intel.c:1249:27:
error: '_MCW_EM' undeclared (first use in this function)
c:/MinGW/msys/1.0/home/sig/cog/blessed/platforms/win32/vm/sqWin32Intel.c:1249:37:
error: '_MCW_RC' undeclared (first use in this function)
c:/MinGW/msys/1.0/home/sig/cog/blessed/platforms/win32/vm/sqWin32Intel.c:1249:47:
error: '_MCW_PC' undeclared (first use in this function)
c:/MinGW/msys/1.0/home/sig/cog/blessed/platforms/win32/vm/sqWin32Intel.c:1249:57:
error: '_MCW_IC' undeclared (first use in this function)
make[2]: *** [CMakeFiles/CogVM.dir/C_/MinGW/msys/1.0/home/sig/cog/blessed/platforms/win32/vm/sqWin32Intel.c.obj]
Error 1
make[1]: *** [CMakeFiles/CogVM.dir/all] Error 2


googled a bit and found swift solution:

Modify the /mingw/lib/gcc/GCC-VERSION/mingw32/include/float.h file and add

#ifndef _MINGW_FLOAT_H_
#include_next <float.h>
#endif

(yeah, literally copy and paste at the end of that file)

Read here: http://sourceforge.net/mailarchive/message.php?msg_id=28824347

i wonder how to workaround this w/o modifying the file...

-- 
Best regards,
Igor Stasenko.


More information about the Vm-dev mailing list