aboutsummaryrefslogtreecommitdiff
path: root/frontend/common/posix.h
diff options
context:
space:
mode:
authornotaz2010-12-09 18:56:03 +0200
committernotaz2010-12-14 15:25:04 +0200
commit698517be481301b4525c29873134a67b8343af3c (patch)
tree69de537c8f4f1bf34803c8a3c94108c7f3c44908 /frontend/common/posix.h
parent1972732abfea710d3d7b61180971580d9e5081ce (diff)
downloadpcsx_rearmed-698517be481301b4525c29873134a67b8343af3c.tar.gz
pcsx_rearmed-698517be481301b4525c29873134a67b8343af3c.tar.bz2
pcsx_rearmed-698517be481301b4525c29873134a67b8343af3c.zip
pull in more code from PicoDrive
Diffstat (limited to 'frontend/common/posix.h')
-rw-r--r--frontend/common/posix.h23
1 files changed, 23 insertions, 0 deletions
diff --git a/frontend/common/posix.h b/frontend/common/posix.h
new file mode 100644
index 0000000..33ca96c
--- /dev/null
+++ b/frontend/common/posix.h
@@ -0,0 +1,23 @@
+/* define POSIX stuff: dirent, scandir, getcwd, mkdir */
+#if defined(__linux__) || defined(__MINGW32__)
+
+#include <dirent.h>
+#include <unistd.h>
+#include <sys/stat.h>
+#include <sys/types.h>
+
+#ifdef __MINGW32__
+#warning hacks!
+#define mkdir(pathname,mode) mkdir(pathname)
+#define d_type d_ino
+#define DT_REG 0
+#define DT_DIR 0
+#endif
+
+#else
+
+#error "must provide posix"
+
+#endif
+
+