improve handling of debug/release build types