summaryrefslogtreecommitdiff
path: root/var
diff options
context:
space:
mode:
Diffstat (limited to 'var')
-rw-r--r--var/spack/repos/builtin/packages/p7zip/package.py9
1 files changed, 7 insertions, 2 deletions
diff --git a/var/spack/repos/builtin/packages/p7zip/package.py b/var/spack/repos/builtin/packages/p7zip/package.py
index 0f13335ae6..5a0728eb29 100644
--- a/var/spack/repos/builtin/packages/p7zip/package.py
+++ b/var/spack/repos/builtin/packages/p7zip/package.py
@@ -3,8 +3,6 @@
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
-from spack import *
-
class P7zip(MakefilePackage):
"""A Unix port of the 7z file archiver"""
@@ -17,6 +15,13 @@ class P7zip(MakefilePackage):
# all3 includes 7z, 7za, and 7zr
build_targets = ['all3']
+ def edit(self, spec, prefix):
+ if 'platform=darwin' in self.spec:
+ if '%gcc' in self.spec:
+ copy('makefile.macosx_gcc_64bits', 'makefile.machine')
+ elif '%apple-clang' in self.spec or '%clang' in self.spec:
+ copy('makefile.macosx_llvm_64bits', 'makefile.machine')
+
@property
def install_targets(self):
return ['DEST_HOME={0}'.format(self.prefix), 'install']