diff --git a/lib/mempool.c b/lib/mempool.c
index 03a6e6b..0cb06b5 100644
--- a/lib/mempool.c
+++ b/lib/mempool.c
@@ -19,6 +19,7 @@
  */
 
 #include <stdlib.h>
+#include <stdint.h>
 
 #include "nest/bird.h"
 #include "lib/resource.h"
diff --git a/lib/resource.c b/lib/resource.c
index a4d8751..5ba23f1 100644
--- a/lib/resource.c
+++ b/lib/resource.c
@@ -8,6 +8,7 @@
 
 #include <stdio.h>
 #include <stdlib.h>
+#include <stdint.h>
 
 #include "nest/bird.h"
 #include "lib/resource.h"
diff --git a/lib/slab.c b/lib/slab.c
index 17511d2..8cce52f 100644
--- a/lib/slab.c
+++ b/lib/slab.c
@@ -26,6 +26,7 @@
  */
 
 #include <stdlib.h>
+#include <stdint.h>
 
 #include "nest/bird.h"
 #include "lib/resource.h"
diff --git a/nest/attrs.h b/nest/attrs.h
index eee6b37..16fb35a 100644
--- a/nest/attrs.h
+++ b/nest/attrs.h
@@ -9,6 +9,8 @@
 #ifndef _BIRD_ATTRS_H_
 #define _BIRD_ATTRS_H_
 
+#include <stdint.h>
+
 /* a-path.c */
 
 #define AS_PATH_SET		1	/* Types of path segments */
diff --git a/proto/bgp/bgp.h b/proto/bgp/bgp.h
index 9bbdab8..092c3b3 100644
--- a/proto/bgp/bgp.h
+++ b/proto/bgp/bgp.h
@@ -9,6 +9,7 @@
 #ifndef _BIRD_BGP_H_
 #define _BIRD_BGP_H_
 
+#include <stdint.h>
 #include "nest/route.h"
 
 struct linpool;
