updates to bin/emul.sh