-# use pthreads
-add_project_link_arguments('-pthread', language: 'c')
-dpdk_extra_ldflags += '-pthread'
+# use pthreads if available for the platform
+if not is_ms_linker
+ add_project_link_arguments('-pthread', language: 'c')
+ dpdk_extra_ldflags += '-pthread'
+endif