From aec3589679022c658c2f554d3da156a31f7dec02 Mon Sep 17 00:00:00 2001 From: Tom Payerle Date: Tue, 28 Apr 2020 10:43:53 -0400 Subject: [PATCH] netcdf-c: Patch to support hdf linked against libtirpc (#15994) If hdf was built with +libtirpc, we need to add -ltirpc to our link flags. --- var/spack/repos/builtin/packages/netcdf-c/package.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/var/spack/repos/builtin/packages/netcdf-c/package.py b/var/spack/repos/builtin/packages/netcdf-c/package.py index 42c28e5321..62a3a43cbe 100644 --- a/var/spack/repos/builtin/packages/netcdf-c/package.py +++ b/var/spack/repos/builtin/packages/netcdf-c/package.py @@ -215,6 +215,9 @@ def configure_args(self): if '+szip' in hdf4: # This should also come from hdf4.libs libs.append('-lsz') + if '+libtirpc' in hdf4: + # This should also come from hdf4.libs + libs.append('-ltirpc') # Fortran support # In version 4.2+, NetCDF-C and NetCDF-Fortran have split.