diff options
author | 2016-03-27 14:06:51 +0200 | |
---|---|---|
committer | 2016-03-27 17:35:23 +0200 | |
commit | 158c90cf1196f219e6a7c9c3e23ca47129429a7b (patch) | |
tree | 4630c4834544108f1ec74b5b48fe4d437d3efbeb /src/osd/modules/file/posixptty.cpp | |
parent | 5640305d0ecfdbf6a1a456688f48f6f0fe22adb3 (diff) |
Initial work to make MAME work on Android [Miodrag Milanovic]
Diffstat (limited to 'src/osd/modules/file/posixptty.cpp')
-rw-r--r-- | src/osd/modules/file/posixptty.cpp | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/osd/modules/file/posixptty.cpp b/src/osd/modules/file/posixptty.cpp index b84838c0578..f7842574312 100644 --- a/src/osd/modules/file/posixptty.cpp +++ b/src/osd/modules/file/posixptty.cpp @@ -22,7 +22,7 @@ #if defined(__FreeBSD__) || defined(__DragonFly__) #include <termios.h> #include <libutil.h> -#elif defined(__NetBSD__) || defined(__OpenBSD__) || defined(__APPLE__) +#elif defined(__NetBSD__) || defined(__OpenBSD__) || defined(__APPLE__) || defined(__ANDROID__) #include <termios.h> #include <util.h> #elif defined(__linux__) || defined(EMSCRIPTEN) @@ -141,7 +141,10 @@ osd_file::error posix_open_ptty(std::uint32_t openflags, osd_file::ptr &file, st ::close(masterfd); return errno_to_file_error(err); } -#else +#elif defined(__ANDROID__) + int masterfd = -1, slavefd = -1; + char slavepath[PATH_MAX]; +#else struct termios tios; std::memset(&tios, 0, sizeof(tios)); ::cfmakeraw(&tios); |