[PATCH] Set _POSIX_VDISABLE to _PC_VDISABLE on android, because the former does not exist

Nathan nathan.huesken at posteo.de
Thu Jan 24 15:39:52 CET 2013


---
 System/Posix/Terminal/Common.hsc |    5 +++++
 1 file changed, 5 insertions(+)

diff --git a/System/Posix/Terminal/Common.hsc b/System/Posix/Terminal/Common.hsc
index 5d718a8..74c1f44 100644
--- a/System/Posix/Terminal/Common.hsc
+++ b/System/Posix/Terminal/Common.hsc
@@ -267,6 +267,11 @@ data ControlCharacter
   | Stop		-- VSTOP
   | Suspend		-- VSUSP
 
+#ifdef __ANDROID__
+-- the android ndk does not define this symbol
+#define _POSIX_VDISABLE _PC_VDISABLE
+#endif
+
 controlChar :: TerminalAttributes -> ControlCharacter -> Maybe Char
 controlChar termios cc = unsafePerformIO $ do
   withTerminalAttributes termios $ \p -> do
-- 
1.7.10.4


--------------070004030200010403000704
Content-Type: text/x-patch;
 name="03_unix_telldir_seekdir.patch"
Content-Transfer-Encoding: 7bit
Content-Disposition: attachment;
 filename="03_unix_telldir_seekdir.patch"



More information about the ghc-devs mailing list