You need to prepare a debug LIB or DLL to link against your debug EXE. I'm creating a NuGet package to avoid this kind of trouble, but unfortunately NuGet doesn't support VC9.