Common: Include unistd.h before ctime on mingw.

This is required for localtime_r and similar to be available.
This commit is contained in:
Unknown W. Brackets
2021-02-14 09:49:14 -08:00
parent 7aa4b53422
commit 0ffac20fcd
7 changed files with 33 additions and 1 deletions

View File

@@ -16,6 +16,12 @@
// https://github.com/hrydgard/ppsspp and http://www.ppsspp.org/.
#include "ppsspp_config.h"
#ifdef __MINGW32__
#include <unistd.h>
#ifndef _POSIX_THREAD_SAFE_FUNCTIONS
#define _POSIX_THREAD_SAFE_FUNCTIONS 200112L
#endif
#endif
#include <ctime>
#include "Common/File/FileUtil.h"