Index: mmap.c
===================================================================
--- mmap.c	(revision 197056)
+++ mmap.c	(working copy)
@@ -36,6 +36,7 @@ POSSIBILITY OF SUCH DAMAGE.  */
 #include <string.h>
 #include <stdlib.h>
 #include <unistd.h>
+#include <sys/types.h>
 #include <sys/mman.h>
 
 #include "backtrace.h"
Index: alloc.c
===================================================================
--- alloc.c	(revision 197056)
+++ alloc.c	(working copy)
@@ -34,6 +34,7 @@ POSSIBILITY OF SUCH DAMAGE.  */
 
 #include <errno.h>
 #include <stdlib.h>
+#include <sys/types.h>
 
 #include "backtrace.h"
 #include "internal.h"
