I can build a 64-bit executable linked to the TclTk85 libraries, but if I also include an rc object (produced by the 64 bit version of windres) when linking it, the resulting .exe fails to start. Instead I get the error "Application failed to initiate properly 0xc000007b". This diagnosed as the result of mixing 32 and 64 bit dll dependencies so I got Dependency Walker and had a look. Sure enough, if the app is built with rc.o linked, it depends on tk85.dll and that depends on a 32-bit version of COMCTL32.DLL. If the app is built with no rc.o, it depends on _the_same_ version of tk85.dll (same filename and everything) but that now depends on the correct 64-bit COMCTL32.DLL -- and it starts and runs OK! WTF?
$ gcc -v
Using built-in specs.
Configured with: ../../../build/gcc/src/configure --target=x86_64-w64-mingw32 --prefix=/c/bb/vista64-mingw32/mingw-x86-x86_64/build/build/root --with-sysroot=/c/bb/vista64-mingw32/mingw-x86-x86_64/build/build/root --enable-languages=all,obj-c++ --enable-fully-dynamic-string --disable-multilib
Thread model: win32
gcc version 4.5.2 20101015 (prerelease) (GCC)
$ ld -v
GNU ld (GNU Binutils) 126.96.36.19901015
$ uname -a
MINGW32_NT-6.1 SPACEHOPPER 1.0.11(0.46/3/2) 2009-07-11 17:46 i686 Msys
Log in to post a comment.