Index: src/sockwrap/sockwrap.cpp
--- src/sockwrap/sockwrap.cpp.orig
+++ src/sockwrap/sockwrap.cpp
@@ -22,6 +22,7 @@
 #  include "sockwrap_tls.h"
 #endif
 #include "core/util.h"
+#include <unistd.h>
 
 namespace sock
 {
