fixed various bugs in glclient-build script