diff --git a/meson.build b/meson.build
index 9a98f0c86a0..e40f95e79d8 100644
--- a/meson.build
+++ b/meson.build
@@ -897,12 +897,19 @@ endif
 
 lz4opt = get_option('lz4')
 if not lz4opt.disabled()
-  lz4 = dependency('liblz4', required: false)
-  # Unfortunately the dependency is named differently with cmake
-  if not lz4.found() # combine with above once meson 0.60.0 is required
-    lz4 = dependency('lz4', required: lz4opt,
-                     method: 'cmake', modules: ['LZ4::lz4_shared'],
-                    )
+  if host_system != 'windows'
+    lz4 = dependency('liblz4', required: false)
+    # Unfortunately the dependency is named differently with cmake
+    if not lz4.found() # combine with above once meson 0.60.0 is required
+      lz4 = dependency('lz4', required: lz4opt,
+                       method: 'cmake', modules: ['LZ4::lz4_shared'],
+                      )
+    endif
+  else
+    lz4 = dependency('liblz4', required: false)
+    if not lz4.found()
+      lz4 = cc.find_library('liblz4', required: lz4opt, dirs: postgres_lib_d)
+    endif
   endif
 
   if lz4.found()
