Index: src/net/conn_plain.c
--- src/net/conn_plain.c.orig	2020-12-22 15:08:32.941132000 +0100
+++ src/net/conn_plain.c	2020-12-22 15:08:52.448933000 +0100
@@ -6,6 +6,7 @@
 #include <unistd.h>
 #include <postgres.h>
 
+#include <sys/types.h>
 #include <sys/socket.h>
 #include <sys/time.h>
 
