Check against $OSTYPE rather than uname -o
Consolidate $ERL assignment and use cygpath