fix building the lib in the source tree