Revert "Use std::filesystem in c10 tempfile and tempdir (#106656)"
This reverts commit 7b91f762b65ea250b87aaa2e2b67e429a9d29f16.
Reverted https://github.com/pytorch/pytorch/pull/106656 on behalf of https://github.com/huydhn due to Sorry for reverting your change, but it is failing internal iOS build. This was missed by period mobile build I think ([comment](https://github.com/pytorch/pytorch/pull/106656#issuecomment-1707187814))