Build dir and detach handling

Fixed the disconnect feature so that when the box is detached the core
and UI handle it appropriately

Added the build dir for OS X and Windows