You can simply override the path to the main executable via VisualGDB Project Properties -> Debug Settings so that VisualGDB will launch the .Net runtime with the correct parameters. As long as the library is loaded into the same address space, you should be able to debug it.