diff --git a/ld/pe-dll.c b/ld/pe-dll.c
index d888a0b6373..f24b8716ae2 100644
--- a/ld/pe-dll.c
+++ b/ld/pe-dll.c
@@ -382,6 +382,8 @@ static const autofilter_entry_type autofilter_liblist[] =
   { STRING_COMMA_LEN ("libmsvcrt-os") },
   { STRING_COMMA_LEN ("libucrt") },
   { STRING_COMMA_LEN ("libucrtbase") },
+  { STRING_COMMA_LEN ("libpthread") },
+  { STRING_COMMA_LEN ("libwinpthread") },
   { NULL, 0 }
 };
 
