check for existing /dev folder before creating

This is to prevent emscripten trying to create /dev folder again if it has already been created for example in preRun()