--- a/pwcheck/pwcheck_getspnam.c
+++ b/pwcheck/pwcheck_getspnam.c
@@ -24,6 +24,7 @@
 ******************************************************************/
 
 #include <shadow.h>
+#include <string.h>
 
 extern char *crypt();
 
