Fix build script for SSH disabled case

Change-Id: Ie1c7dcc29b5767ce4d003c993add573822d1f591