If you try to compile for debug multilib you get the warning below, which means that the program will crash trying to free() anything that's malloced since we've mixed debug and non-debug libs.
Linker Tools Warning LNK4098 defaultlib "library" conflicts with use of other libs; use /NODEFAULTLIB:library We can solve this by adding this /NODEFAULTLIB:msvcrt.lib to the linker lines for all the apps dsp files for the debug setting. For example in apps_app_wxluafreeze.dsp !ELSEIF "$(CFG)" == "app_wxluafreeze - Win32 Debug Multilib" # PROP BASE Use_MFC 0 # PROP BASE Use_Debug_Libraries 1 ... # ADD BASE LINK32 /NODEFAULTLIB:msvcrt.lib wxlua_msw28d_wxlua.lib ... # ADD LINK32 /NODEFAULTLIB:msvcrt.lib wxlua_msw28d_wxlua.lib ... I would guess that the reason why we need to do this (wxWidgets samples do not) is that modules_mod_lua.dsp generates a non-debug lua5.1.lib for the "debug" setting and MSVC gets confused and ignores the fact that we've set "Use_Debug_Libraries 1" and links to the non-debug msvcrt lib? When I change the lua5.1.lib to be debug by hand I no longer get the 4098 warning and the program doesn't crash, so I think my theory is correct. !ELSEIF "$(CFG)" == "mod_lua - Win32 Debug Multilib" # PROP BASE Use_MFC 0 # PROP BASE Use_Debug_Libraries 1 << change from 0 ... Change /MD to /MDd below # ADD BASE CPP /nologo /FD /MDd /W1 /GR /EHsc /D "WIN32" /D "_LIB" /c # ADD CPP /nologo /FD /MDd /W1 /GR /EHsc /D "WIN32" /D "_LIB" /c =============== Francesco, what do you think about this and which way makes more sense, add NODEFAULTLIB or change lua5.1.lib to be debug as well? Regards, John Labenski ------------------------------------------------------------------------- This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ _______________________________________________ wxlua-users mailing list wxlua-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wxlua-users