diff --git a/src/clients/flagmanager.cpp b/src/clients/flagmanager.cpp
index d9f3cbf..82eb978 100644
--- a/src/clients/flagmanager.cpp
+++ b/src/clients/flagmanager.cpp
@@ -25,6 +25,8 @@
 #define BOBLIGHT_DLOPEN_EXTERN
 #include "../lib/boblight.h"
 
+#include <unistd.h>
+
 using namespace std;
 
 //very simple, store a copy of argc and argv
