Override the default temporary directory (defaults to std::env::temp_dir). This function
changes the global default temporary directory for the entire program and should not be called
except in exceptional cases where it’s not configured correctly by the platform. Applications
should first check if the path returned by env::temp_dir is acceptable.