debugger fixes and native library support, plus build fixes