diff --git a/libglnx.m4 b/libglnx.m4
index 34caf204ac7d48407c5c50b60a26244f8254f76a..5922805bc7a014812d3da44c8d5b9f3b76a5eb59 100644
--- a/libglnx.m4
+++ b/libglnx.m4
@@ -7,6 +7,7 @@ AC_CHECK_DECLS([
         [], [], [[
 #include <sys/types.h>
 #include <unistd.h>
+#include <stdio.h>
 #include <sys/mount.h>
 #include <fcntl.h>
 #include <sched.h>