--- Linux-PAM-1.1.8.orig/modules/pam_group/pam_group.c	2013-06-18 16:11:21.000000000 +0200
+++ Linux-PAM-1.1.8/modules/pam_group/pam_group.c	2013-12-21 18:30:19.000000000 +0100
@@ -655,10 +655,13 @@ static int check_account(pam_handle_t *p
 	    continue;
 	}
 	/* If buffer starts with @, we are using netgroups */
+#ifdef HAVE_INNETGR
 	if (buffer[0] == '@')
 	  good &= innetgr (&buffer[1], NULL, user, NULL);
 	/* otherwise, if the buffer starts with %, it's a UNIX group */
-	else if (buffer[0] == '%')
+	else
+#endif
+	if (buffer[0] == '%')
           good &= pam_modutil_user_in_group_nam_nam(pamh, user, &buffer[1]);
 	else
 	  good &= logic_field(pamh,user, buffer, count, is_same);
