From fcf99be939630324275fff44e7fe6bcdfab21a4d Mon Sep 17 00:00:00 2001 From: Scott McMillan Date: Wed, 20 Jan 2021 21:42:53 -0600 Subject: [PATCH] openssl: remove preprocessor flags incompatible with NVIDIA HPC SDK (#21180) * openssl: remove preprocessor flags incompatible with NVIDIA HPC SDK * Update var/spack/repos/builtin/packages/openssl/package.py Co-authored-by: Adam J. Stewart Co-authored-by: Scott McMillan Co-authored-by: Adam J. Stewart --- var/spack/repos/builtin/packages/openssl/package.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/var/spack/repos/builtin/packages/openssl/package.py b/var/spack/repos/builtin/packages/openssl/package.py index e205da7108..133d88fd98 100644 --- a/var/spack/repos/builtin/packages/openssl/package.py +++ b/var/spack/repos/builtin/packages/openssl/package.py @@ -172,5 +172,13 @@ def link_system_certs(self): os.rmdir(pkg_certs) os.symlink(sys_certs, pkg_certs) + def patch(self): + if self.spec.satisfies('%nvhpc'): + # Remove incompatible preprocessor flags + filter_file('-MF ', '', + 'Configurations/unix-Makefile.tmpl', string=True) + filter_file(r'-MT \$\@ ', '', + 'Configurations/unix-Makefile.tmpl', string=True) + def setup_build_environment(self, env): env.set('PERL', self.spec['perl'].prefix.bin.perl)