From fd67da607e5476b767071dc37af66af6fd492452 Mon Sep 17 00:00:00 2001 From: Denis Davydov Date: Fri, 25 Mar 2016 08:32:14 +0100 Subject: [PATCH] make netcdf link against Spack's curl --- var/spack/repos/builtin/packages/netcdf/package.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/var/spack/repos/builtin/packages/netcdf/package.py b/var/spack/repos/builtin/packages/netcdf/package.py index 227362399a..b60a2c4e9a 100644 --- a/var/spack/repos/builtin/packages/netcdf/package.py +++ b/var/spack/repos/builtin/packages/netcdf/package.py @@ -43,6 +43,13 @@ def install(self, spec, prefix): "--enable-dap" ] + # Make sure Netcdf links against Spack's curl + # Otherwise it may pick up system's curl, which could lead to link errors: + # /usr/lib/x86_64-linux-gnu/libcurl.so: undefined reference to `SSL_CTX_use_certificate_chain_file@OPENSSL_1.0.0' + LIBS.append("-lcurl") + CPPFLAGS.append("-I%s" % spec['curl'].prefix.include) + LDFLAGS.append ("-L%s" % spec['curl'].prefix.lib) + if '+mpi' in spec: config_args.append('--enable-parallel4')