From e628f1b4eb4cd9968b14c16018cf14276e74ad19 Mon Sep 17 00:00:00 2001 From: "Mark W. Krentel" Date: Tue, 30 Jul 2019 15:01:33 -0500 Subject: unzip: fix build for cray back-end Fixes #12007. The Cray cc wrappers don't handle the -s flag (strip) cleanly, It's not essential to strip the binary, so just remove the flag on Cray. Note: the default build on Cray is for the back end and the unzip binary won't run on the front end. To build for FE, use something like arch=cray-fe-x86_64. --- var/spack/repos/builtin/packages/unzip/package.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'var') diff --git a/var/spack/repos/builtin/packages/unzip/package.py b/var/spack/repos/builtin/packages/unzip/package.py index 49477e1b5c..6abcd42248 100644 --- a/var/spack/repos/builtin/packages/unzip/package.py +++ b/var/spack/repos/builtin/packages/unzip/package.py @@ -14,9 +14,12 @@ class Unzip(MakefilePackage): version('6.0', '62b490407489521db863b523a7f86375') - conflicts('platform=cray', msg='Unzip does not currently build on Cray') + # The Cray cc wrapper doesn't handle the '-s' flag (strip) cleanly. + @when('platform=cray') + def patch(self): + filter_file(r'^LFLAGS2=.*', 'LFLAGS2=', join_path('unix', 'configure')) - make_args = ['-f', 'unix/Makefile'] + make_args = ['-f', join_path('unix', 'Makefile')] build_targets = make_args + ['generic'] def url_for_version(self, version): -- cgit v1.2.3-70-g09d2