diff --git a/src/plugins/auth-pam/auth-pam.c b/src/plugins/auth-pam/auth-pam.c
index 0cd201d..72c047d 100644
--- a/src/plugins/auth-pam/auth-pam.c
+++ b/src/plugins/auth-pam/auth-pam.c
@@ -32,6 +32,7 @@
 #include <security/pam_appl.h>
 
 #ifdef USE_PAM_DLOPEN
+#include <dlfcn.h>
 #include "pamdl.h"
 #endif
 
