fixed dependency issues in build scripts