fixes for in tree build