Fixing stm spawning for linux