diff --git a/var/spack/repos/builtin/packages/netcdf-c/package.py b/var/spack/repos/builtin/packages/netcdf-c/package.py index 0ccd9298fe..82d7d6792c 100644 --- a/var/spack/repos/builtin/packages/netcdf-c/package.py +++ b/var/spack/repos/builtin/packages/netcdf-c/package.py @@ -358,6 +358,8 @@ def patch_hdf5_pkgconfigcmake(self): due to incorrectly using hdf5 target names https://github.com/spack/spack/pull/42878 """ + if sys.platform == "win32": + return pkgconfig_file = find(self.prefix, "netcdf.pc", recursive=True) cmakeconfig_file = find(self.prefix, "netCDFTargets.cmake", recursive=True)