Remove all bashisms from install.sh

fixes #1290
This makes it possible to run install.sh under a POSIX sh, instead of
depending on bash.