Improve error detection and handling in make_factory_toolkit.sh

Check that the output directory exists and that a board has been specified.
Previously the script mysteriously aborted when cd failed, and an unspecified
board was just treated as empty.

TEST=manual
BUG=none
Change-Id: I8843bbe0200e6a1293fa116d04cf3ece459a929f
Reviewed-on: https://chromium-review.googlesource.com/202610
Reviewed-by: Vic Yang <victoryang@chromium.org>
Commit-Queue: <pca@chromium.org>
Tested-by: <pca@chromium.org>
1 file changed