Wrap #include <unistd.h> inside an #ifdef HAVE_UNISTD_H.
authorJonathan Chambers <joncham@gmail.com>
Wed, 7 Mar 2012 02:46:51 +0000 (21:46 -0500)
committerJonathan Chambers <joncham@gmail.com>
Wed, 7 Mar 2012 02:46:51 +0000 (21:46 -0500)
mono/metadata/lock-tracer.c
mono/utils/lock-free-queue.c

index 95a878f6251d9ca8334acfea418f467a07fa67ef..f7623db73f5f19d2747e2dacbca5b843203ff0fa 100644 (file)
 #include <string.h>
 
 #include <sys/types.h>
+
+#ifdef HAVE_UNISTD_H
 #include <unistd.h>
+#endif
 
 #ifdef HAVE_EXECINFO_H
 #include <execinfo.h>
index f275d1d55017c4494ed1dd72377a8e0351c9b8cb..3f539d7ffe847f50e82c44922ccc58e4b60077f9 100644 (file)
@@ -47,7 +47,9 @@
  */
 
 #include <stdlib.h>
+#ifdef HAVE_UNISTD_H
 #include <unistd.h>
+#endif
 
 #include <mono/utils/mono-membar.h>
 #include <mono/utils/hazard-pointer.h>