configure: fix multiple issues in build configuration