diff --git a/src/modules/spider/lock.c b/src/modules/spider/lock.c
index 049c7f090de80948f32839cd11848bf46bfbacc9..a22eaad5f906634c8305f1bb4ec4f1e4f54cc026 100644
--- a/src/modules/spider/lock.c
+++ b/src/modules/spider/lock.c
@@ -1,3 +1,4 @@
+#include "global.h"
 #if defined(HAVE_PTHREAD_MUTEX_UNLOCK) || defined(HAVE_MUTEX_UNLOCK)
 
 #include <sys/types.h>