fixed startup script for Mac