This is not how this should be done in the end… we should use mktemp to generate unique and fresh temp files. For now this restores functionality to build from r/o folders.