automatically grab correct root dir in build script, so that it can be launched from any location.