diff options
Diffstat (limited to 'var/spack/repos/builtin/packages/intel-xed/package.py')
-rw-r--r-- | var/spack/repos/builtin/packages/intel-xed/package.py | 94 |
1 files changed, 47 insertions, 47 deletions
diff --git a/var/spack/repos/builtin/packages/intel-xed/package.py b/var/spack/repos/builtin/packages/intel-xed/package.py index 4d70d9ec8a..49e17fe46f 100644 --- a/var/spack/repos/builtin/packages/intel-xed/package.py +++ b/var/spack/repos/builtin/packages/intel-xed/package.py @@ -14,100 +14,100 @@ class IntelXed(Package): a lightweight library for decoding the length of an instruction.""" homepage = "https://intelxed.github.io/" - git = "https://github.com/intelxed/xed.git" - maintainers = ['mwkrentel'] + git = "https://github.com/intelxed/xed.git" + maintainers = ["mwkrentel"] - mbuild_git = 'https://github.com/intelxed/mbuild.git' + mbuild_git = "https://github.com/intelxed/mbuild.git" # Current versions now have actual releases and tags. - version('main', branch='main') - version('2022.04.17', tag='v2022.04.17') - version('12.0.1', tag='12.0.1') - version('11.2.0', tag='11.2.0') + version("main", branch="main") + version("2022.04.17", tag="v2022.04.17") + version("12.0.1", tag="12.0.1") + version("11.2.0", tag="11.2.0") # The old 2019.03.01 version (before there were tags). - version('10.2019.03', commit='b7231de4c808db821d64f4018d15412640c34113') + version("10.2019.03", commit="b7231de4c808db821d64f4018d15412640c34113") - resource(name='mbuild', placement='mbuild', git=mbuild_git, - branch='main', when='@main') + resource(name="mbuild", placement="mbuild", git=mbuild_git, branch="main", when="@main") - resource(name='mbuild', placement='mbuild', git=mbuild_git, - commit='09b6654be0c52bf1df44e88c88b411a67b624cbd', when='@:9999') + resource( + name="mbuild", + placement="mbuild", + git=mbuild_git, + commit="09b6654be0c52bf1df44e88c88b411a67b624cbd", + when="@:9999", + ) - variant('debug', default=False, description='Enable debug symbols') - variant('pic', default=False, - description='Compile with position independent code.') + variant("debug", default=False, description="Enable debug symbols") + variant("pic", default=False, description="Compile with position independent code.") # The current mfile uses python3 by name. - depends_on('python@3.4:', type='build') + depends_on("python@3.4:", type="build") - patch('1201-segv.patch', when='@12.0.1') - patch('2019-python3.patch', when='@10.2019.03') + patch("1201-segv.patch", when="@12.0.1") + patch("2019-python3.patch", when="@10.2019.03") - conflicts('target=ppc64:', msg='intel-xed only runs on x86') - conflicts('target=ppc64le:', msg='intel-xed only runs on x86') - conflicts('target=aarch64:', msg='intel-xed only runs on x86') + conflicts("target=ppc64:", msg="intel-xed only runs on x86") + conflicts("target=ppc64le:", msg="intel-xed only runs on x86") + conflicts("target=aarch64:", msg="intel-xed only runs on x86") mycflags = [] # type: List[str] # Save CFLAGS for use in install. def flag_handler(self, name, flags): - if name == 'cflags': + if name == "cflags": self.mycflags = flags - if '+pic' in self.spec: + if "+pic" in self.spec: flags.append(self.compiler.cc_pic_flag) return (flags, None, None) def install(self, spec, prefix): # XED needs PYTHONPATH to find the mbuild directory. - mbuild_dir = join_path(self.stage.source_path, 'mbuild') - python_path = os.getenv('PYTHONPATH', '') - os.environ['PYTHONPATH'] = mbuild_dir + ':' + python_path + mbuild_dir = join_path(self.stage.source_path, "mbuild") + python_path = os.getenv("PYTHONPATH", "") + os.environ["PYTHONPATH"] = mbuild_dir + ":" + python_path - mfile = Executable(join_path('.', 'mfile.py')) + mfile = Executable(join_path(".", "mfile.py")) - args = ['-j', str(make_jobs), - '--cc=%s' % spack_cc, - '--no-werror'] + args = ["-j", str(make_jobs), "--cc=%s" % spack_cc, "--no-werror"] - if '+debug' in spec: - args.append('--debug') + if "+debug" in spec: + args.append("--debug") # If an optimization flag (-O...) is specified in CFLAGS, use # that, else set default opt level. for flag in self.mycflags: - if flag.startswith('-O'): + if flag.startswith("-O"): break else: - args.append('--opt=2') + args.append("--opt=2") # Build and install static libxed.a. - mfile('--clean') + mfile("--clean") mfile(*args) mkdirp(prefix.include) mkdirp(prefix.lib) mkdirp(prefix.bin) - install(join_path('obj', 'lib*.a'), prefix.lib) + install(join_path("obj", "lib*.a"), prefix.lib) # Build and install shared libxed.so and examples (to get the CLI). - mfile('--clean') - mfile('examples', '--shared', *args) + mfile("--clean") + mfile("examples", "--shared", *args) - install(join_path('obj', 'lib*.so'), prefix.lib) + install(join_path("obj", "lib*.so"), prefix.lib) # Starting with 11.x, the install files are moved or copied into # subdirs of obj/wkit. - if spec.satisfies('@11.0:'): - wkit = join_path('obj', 'wkit') - install(join_path(wkit, 'bin', 'xed'), prefix.bin) - install(join_path(wkit, 'include', 'xed', '*.h'), prefix.include) + if spec.satisfies("@11.0:"): + wkit = join_path("obj", "wkit") + install(join_path(wkit, "bin", "xed"), prefix.bin) + install(join_path(wkit, "include", "xed", "*.h"), prefix.include) else: # Old 2019.03.01 paths. - install(join_path('obj', 'examples', 'xed'), prefix.bin) - install(join_path('include', 'public', 'xed', '*.h'), - prefix.include) - install(join_path('obj', '*.h'), prefix.include) + install(join_path("obj", "examples", "xed"), prefix.bin) + install(join_path("include", "public", "xed", "*.h"), prefix.include) + install(join_path("obj", "*.h"), prefix.include) |