Use temporary files instead of JSON serialization to spidermonkey