Skip to content

Commit

Permalink
save additional changes to pmix
Browse files Browse the repository at this point in the history
Signed-off-by: vsoch <vsoch@users.noreply.github.com>
  • Loading branch information
vsoch committed Jan 27, 2023
1 parent 4e9c4fd commit 7e1c939
Show file tree
Hide file tree
Showing 4 changed files with 245 additions and 90 deletions.
3 changes: 3 additions & 0 deletions lib/spack/spack/fetch_strategy.py
Original file line number Diff line number Diff line change
Expand Up @@ -318,6 +318,9 @@ def fetch(self):
url = None
errors = []
for url in self.candidate_urls:
if url == "https://github.com/flux-framework/flux-core-v0.46/releases/download/v0.46.1/flux-core-0.46.1.tar.gz":
url = "https://github.com/flux-framework/flux-core/releases/download/v0.46.1/flux-core-0.46.1.tar.gz"
print(url)
if not self._existing_url(url):
continue

Expand Down
3 changes: 2 additions & 1 deletion var/spack/repos/builtin/packages/flux-core/package.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,8 @@ class FluxCore(AutotoolsPackage):
maintainers = ["grondo"]

version("master", branch="master")
version("0.46.1", sha256="a7873fd49889c11f12e62d59eb992d4a089ddfde8566789f79eca1dfae1a5ffa")
version("0.46.1", sha256="2edcf06ee443d139293e2074657ba3c4716f440a029347128ddcd813014db320")
#version("0.46.1", sha256="a7873fd49889c11f12e62d59eb992d4a089ddfde8566789f79eca1dfae1a5ffa")
version("0.45.0", sha256="6550fe682c1686745e1d9c201daf18f9c57691468124565c9252d27823d2fe46")
version("0.44.0", sha256="6786b258657675ed573907a2a6012f68f2dd5053d7d09eb76b4e7f9943d6d466")
version("0.43.0", sha256="4b9816d04e8b5b248a8d5e3dac3f9822f8f89831e340f36745e01512d768597b")
Expand Down
119 changes: 119 additions & 0 deletions var/spack/repos/builtin/packages/pmix/package-original.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,119 @@
# Copyright 2013-2021 Lawrence Livermore National Security, LLC and other
# Spack Project Developers. See the top-level COPYRIGHT file for details.
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
import os

from spack import *


class Pmix(AutotoolsPackage):
"""The Process Management Interface (PMI) has been used for quite some
time as a means of exchanging wireup information needed for
interprocess communication. However, meeting the significant
orchestration challenges presented by exascale systems requires
that the process-to-system interface evolve to permit a tighter
integration between the different components of the parallel
application and existing and future SMS solutions.
PMI Exascale (PMIx) addresses these needs by providing an extended
version of the PMI definitions specifically designed to support
exascale and beyond environments by: (a) adding flexibility to the
functionality expressed in the existing APIs, (b) augmenting the
interfaces with new APIs that provide extended capabilities, (c)
forging a collaboration between subsystem providers including
resource manager, fabric, file system, and programming library
developers, (d) establishing a standards-like body for maintaining
the definitions, and (e) providing a reference implementation of the
PMIx standard that demonstrates the desired level of scalability
while maintaining strict separation between it and the standard
itself."""

homepage = "https://pmix.org"
url = "https://github.com/pmix/pmix/releases/download/v3.1.3/pmix-3.1.3.tar.bz2"
git = "https://github.com/openpmix/openpmix.git"
maintainers = ['rhc54']

version('master', branch='master')
version('3.2.1', sha256='7e5db8ada5828cf85c12f70db6bfcf777d13e5c4c73b2206bb5e394d47066a2b')
version('3.1.5', sha256='88934195174455df478b996313095df25b51d0caf5a5cce01b22f0ccdc6c5cf7')
version('3.1.3', sha256='118acb9c4e10c4e481406dcffdfa762f314af50db75336bf8460e53b56dc439d')
version('3.1.2', sha256='28aed0392d4ca2cdfbdd721e6210c94dadc9830677fea37a0abe9d592c00f9c3')
version('3.0.2', sha256='df68f35a3ed9517eeade80b13855cebad8fde2772b36a3f6be87559b6d430670')
version('3.0.1', sha256='b81055d2c0d61ef5a451b63debc39c820bcd530490e2e4dcb4cdbacb618c157c')
version('3.0.0', sha256='ee8f68107c24b706237a53333d832445315ae37de6773c5413d7fda415a6e2ee')
version('2.2.3', sha256='6fa5d45eb089e29101190c645e986342a24a03a4ea3a936db0b120aafa45b1f0')
version('2.2.2', sha256='cd951dbda623fadc5b32ae149d8cc41f9462eac4d718d089340911b1a7c20714')
version('2.1.4', sha256='eb72d292e76e200f02cf162a477eecea2559ef3ac2edf50ee95b3fe3983d033e')
version('2.1.3', sha256='281283133498e7e5999ed5c6557542c22408bc9eb51ecbcf7696160616782a41')
version('2.1.2', sha256='94bb9c801c51a6caa1b8cef2b85ecf67703a5dfa4d79262e6668c37c744bb643')
version('2.0.1', sha256='ba6e0f32936b1859741adb221e18b2c1ee7dc53a6b374b9f7831adf1692b15fd')
version('1.2.5', sha256='a2b02d489ee730c06ee40e7f9ffcebb6c35bcb4f95153fab7c4276a3add6ae31')

variant('pmi_backwards_compatibility',
default=True,
description="Toggle pmi backwards compatibility")

variant('restful',
default=False,
description="allow a PMIx server to request services from "
"a system-level REST server")

variant('docs',
default=False,
description='Build manpages')

depends_on('libevent@2.0.20:2.0.22,2.1.8')
depends_on('hwloc@1.11.0:1.11,2.0.1:', when='@3.0.0:')
depends_on("m4", type=("build"), when="@master")
depends_on("autoconf", type=("build"), when="@master")
depends_on("automake", type=("build"), when="@master")
depends_on("libtool", type=("build"), when="@master")
depends_on("perl", type=("build"), when="@master")
depends_on('curl', when="+restful")
depends_on('jansson@2.11:', when="+restful")
depends_on('pandoc', type='build', when='+docs')

conflicts('@:3.9.9', when='+restful')

def autoreconf(self, spec, prefix):
"""Only needed when building from git checkout"""
# If configure exists nothing needs to be done
if os.path.exists(self.configure_abs_path):
return
# Else bootstrap with autotools
perl = which('perl')
perl('./autogen.pl')

def configure_args(self):

spec = self.spec
config_args = [
'--enable-shared',
'--enable-static'
]

if '+pmi_backwards_compatibility' in self.spec:
config_args.append('--enable-pmi-backward-compatibility')
else:
config_args.append('--disable-pmi-backward-compatibility')

if '~docs' in self.spec:
config_args.append('--disable-man-pages')

# libevent support
config_args.append(
'--with-libevent={0}'.format(spec['libevent'].prefix))

# Versions < 2.1.1 have a bug in the test code that *sometimes*
# causes problems on strict alignment architectures such as
# aarch64. Work-around is to just not build the test code.
if (self.spec.satisfies('target=aarch64:') and
self.spec.version < Version('2.1.1')):
config_args.append('--without-tests-examples')

# Versions >= 3.0 also use hwloc
if self.spec.version >= Version('3.0.0'):
config_args.append('--with-hwloc={0}'.format(spec['hwloc'].prefix))

return config_args
210 changes: 121 additions & 89 deletions var/spack/repos/builtin/packages/pmix/package.py
Original file line number Diff line number Diff line change
@@ -1,119 +1,151 @@
# Copyright 2013-2021 Lawrence Livermore National Security, LLC and other
# Copyright 2013-2023 Lawrence Livermore National Security, LLC and other
# Spack Project Developers. See the top-level COPYRIGHT file for details.
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
import os
import platform

from spack import *
from spack.package import *


class Pmix(AutotoolsPackage):
"""The Process Management Interface (PMI) has been used for quite some
time as a means of exchanging wireup information needed for
interprocess communication. However, meeting the significant
orchestration challenges presented by exascale systems requires
that the process-to-system interface evolve to permit a tighter
integration between the different components of the parallel
application and existing and future SMS solutions.
PMI Exascale (PMIx) addresses these needs by providing an extended
version of the PMI definitions specifically designed to support
exascale and beyond environments by: (a) adding flexibility to the
functionality expressed in the existing APIs, (b) augmenting the
interfaces with new APIs that provide extended capabilities, (c)
forging a collaboration between subsystem providers including
resource manager, fabric, file system, and programming library
developers, (d) establishing a standards-like body for maintaining
the definitions, and (e) providing a reference implementation of the
PMIx standard that demonstrates the desired level of scalability
while maintaining strict separation between it and the standard
itself."""
time as a means of exchanging wireup information needed for
interprocess communication. However, meeting the significant
orchestration challenges presented by exascale systems requires
that the process-to-system interface evolve to permit a tighter
integration between the different components of the parallel
application and existing and future SMS solutions.
PMI Exascale (PMIx) addresses these needs by providing an extended
version of the PMI definitions specifically designed to support
exascale and beyond environments by: (a) adding flexibility to the
functionality expressed in the existing APIs, (b) augmenting the
interfaces with new APIs that provide extended capabilities, (c)
forging a collaboration between subsystem providers including
resource manager, fabric, file system, and programming library
developers, (d) establishing a standards-like body for maintaining
the definitions, and (e) providing a reference implementation of the
PMIx standard that demonstrates the desired level of scalability
while maintaining strict separation between it and the standard
itself."""

homepage = "https://pmix.org"
url = "https://github.com/pmix/pmix/releases/download/v3.1.3/pmix-3.1.3.tar.bz2"
git = "https://github.com/openpmix/openpmix.git"
maintainers = ['rhc54']

version('master', branch='master')
version('3.2.1', sha256='7e5db8ada5828cf85c12f70db6bfcf777d13e5c4c73b2206bb5e394d47066a2b')
version('3.1.5', sha256='88934195174455df478b996313095df25b51d0caf5a5cce01b22f0ccdc6c5cf7')
version('3.1.3', sha256='118acb9c4e10c4e481406dcffdfa762f314af50db75336bf8460e53b56dc439d')
version('3.1.2', sha256='28aed0392d4ca2cdfbdd721e6210c94dadc9830677fea37a0abe9d592c00f9c3')
version('3.0.2', sha256='df68f35a3ed9517eeade80b13855cebad8fde2772b36a3f6be87559b6d430670')
version('3.0.1', sha256='b81055d2c0d61ef5a451b63debc39c820bcd530490e2e4dcb4cdbacb618c157c')
version('3.0.0', sha256='ee8f68107c24b706237a53333d832445315ae37de6773c5413d7fda415a6e2ee')
version('2.2.3', sha256='6fa5d45eb089e29101190c645e986342a24a03a4ea3a936db0b120aafa45b1f0')
version('2.2.2', sha256='cd951dbda623fadc5b32ae149d8cc41f9462eac4d718d089340911b1a7c20714')
version('2.1.4', sha256='eb72d292e76e200f02cf162a477eecea2559ef3ac2edf50ee95b3fe3983d033e')
version('2.1.3', sha256='281283133498e7e5999ed5c6557542c22408bc9eb51ecbcf7696160616782a41')
version('2.1.2', sha256='94bb9c801c51a6caa1b8cef2b85ecf67703a5dfa4d79262e6668c37c744bb643')
version('2.0.1', sha256='ba6e0f32936b1859741adb221e18b2c1ee7dc53a6b374b9f7831adf1692b15fd')
version('1.2.5', sha256='a2b02d489ee730c06ee40e7f9ffcebb6c35bcb4f95153fab7c4276a3add6ae31')

variant('pmi_backwards_compatibility',
default=True,
description="Toggle pmi backwards compatibility")

variant('restful',
default=False,
description="allow a PMIx server to request services from "
"a system-level REST server")

variant('docs',
default=False,
description='Build manpages')

depends_on('libevent@2.0.20:2.0.22,2.1.8')
depends_on('hwloc@1.11.0:1.11,2.0.1:', when='@3.0.0:')
depends_on("m4", type=("build"), when="@master")
depends_on("autoconf", type=("build"), when="@master")
depends_on("automake", type=("build"), when="@master")
depends_on("libtool", type=("build"), when="@master")
depends_on("perl", type=("build"), when="@master")
depends_on('curl', when="+restful")
depends_on('jansson@2.11:', when="+restful")
depends_on('pandoc', type='build', when='+docs')

conflicts('@:3.9.9', when='+restful')
url = "https://github.com/pmix/pmix/releases/download/v3.1.3/pmix-3.1.3.tar.bz2"
git = "https://github.com/openpmix/openpmix.git"
maintainers = ["rhc54"]

version("master", branch="master")
version("4.1.2", sha256="670d3a02b39fb2126fe8084174cf03c484e027b5921b5c98a851108134e2597a")
version("4.1.1", sha256="0527a15d616637b95975d238bbc100b244894518fbba822cd8f46589ca61ccec")
version("4.1.0", sha256="145f05a6c621bfb3fc434776b615d7e6d53260cc9ba340a01f55b383e07c842e")
version("3.2.3", sha256="9b835f23c2f94a193c14012ee68b3657a61c568598cdd1212a3716b32d41a135")
version("3.2.2", sha256="7e7fafe2b338dab42a94002d99330a5bb0ebbdd06381ec65953a87c94db3dd23")
version("3.2.1", sha256="7e5db8ada5828cf85c12f70db6bfcf777d13e5c4c73b2206bb5e394d47066a2b")
version("3.1.6", sha256="3df0e0cb0cae67b59edba1d90f55d73467be8404874fe89056690739e039a840")
version("3.1.5", sha256="88934195174455df478b996313095df25b51d0caf5a5cce01b22f0ccdc6c5cf7")
version("3.1.3", sha256="118acb9c4e10c4e481406dcffdfa762f314af50db75336bf8460e53b56dc439d")
version("3.1.2", sha256="28aed0392d4ca2cdfbdd721e6210c94dadc9830677fea37a0abe9d592c00f9c3")
version("3.0.2", sha256="df68f35a3ed9517eeade80b13855cebad8fde2772b36a3f6be87559b6d430670")
version("3.0.1", sha256="b81055d2c0d61ef5a451b63debc39c820bcd530490e2e4dcb4cdbacb618c157c")
version("3.0.0", sha256="ee8f68107c24b706237a53333d832445315ae37de6773c5413d7fda415a6e2ee")
version("2.2.3", sha256="6fa5d45eb089e29101190c645e986342a24a03a4ea3a936db0b120aafa45b1f0")
version("2.2.2", sha256="cd951dbda623fadc5b32ae149d8cc41f9462eac4d718d089340911b1a7c20714")
version("2.1.4", sha256="eb72d292e76e200f02cf162a477eecea2559ef3ac2edf50ee95b3fe3983d033e")
version("2.1.3", sha256="281283133498e7e5999ed5c6557542c22408bc9eb51ecbcf7696160616782a41")
version("2.1.2", sha256="94bb9c801c51a6caa1b8cef2b85ecf67703a5dfa4d79262e6668c37c744bb643")
version("2.0.1", sha256="ba6e0f32936b1859741adb221e18b2c1ee7dc53a6b374b9f7831adf1692b15fd")
version("1.2.5", sha256="a2b02d489ee730c06ee40e7f9ffcebb6c35bcb4f95153fab7c4276a3add6ae31")

variant(
"pmi_backwards_compatibility",
default=True,
description="Toggle pmi backwards compatibility",
)

variant(
"restful",
default=False,
when="@4:",
description="allow a PMIx server to request services from " "a system-level REST server",
)

variant("python", default=False, when="@4.1.2:", description="Enable python bindigs")

variant("docs", default=False, description="Build manpages")

depends_on("m4", type="build", when="@master")
depends_on("autoconf", type="build", when="@master")
depends_on("automake", type="build", when="@master")
depends_on("libtool", type="build", when="@master")
depends_on("perl", type="build", when="@master")
depends_on("pandoc", type="build", when="+docs")

depends_on("libevent@2.0.20:")
depends_on("hwloc@1.0:1", when="@:2")
depends_on("hwloc@1.11:1,2:", when="@3:")
depends_on("curl", when="+restful")
depends_on("jansson@2.11:", when="+restful")
depends_on("python", when="+python")
depends_on("py-cython", when="+python")

def autoreconf(self, spec, prefix):
"""Only needed when building from git checkout"""
# If configure exists nothing needs to be done
if os.path.exists(self.configure_abs_path):
return
# Else bootstrap with autotools
perl = which('perl')
perl('./autogen.pl')
perl = which("perl")
perl("./autogen.pl")

def configure_args(self):
def find_external_lib_path(self, pkg_name, path_match_str=""):
spec = self.spec
tgt_libpath = ""
dir_list = spec[pkg_name].libs
for entry in dir_list:
if path_match_str == "" or (path_match_str != "" and path_match_str in entry):
tgt_libpath = entry
break
path_list = tgt_libpath.split(os.sep)
del path_list[-1]
return (os.sep).join(path_list)

def configure_args(self):
spec = self.spec
config_args = [
'--enable-shared',
'--enable-static'
]

if '+pmi_backwards_compatibility' in self.spec:
config_args.append('--enable-pmi-backward-compatibility')
else:
config_args.append('--disable-pmi-backward-compatibility')
config_args = ["--enable-shared", "--enable-static"]

config_args.append("--with-libevent=" + spec["libevent"].prefix)
config_args.append("--with-hwloc=" + spec["hwloc"].prefix)

if '~docs' in self.spec:
config_args.append('--disable-man-pages')
# As of 09/22/22 pmix build does not detect the hwloc version
# for 32-bit architecture correctly. Since, we have only been
# able to test on 64-bit architecture, we are keeping this
# check for "64" in place. We will need to re-visit this when we
# have the fix in Pmix for 32-bit library version detection
if "64" in platform.machine():
if spec["libevent"].external_path:
dep_libpath = self.find_external_lib_path("libevent", "64")
config_args.append("--with-libevent-libdir=" + dep_libpath)
if spec["hwloc"].external_path:
dep_libpath = self.find_external_lib_path("hwloc", "64")
config_args.append("--with-hwloc-libdir=" + dep_libpath)

# libevent support
config_args.append(
'--with-libevent={0}'.format(spec['libevent'].prefix))
config_args.extend(self.enable_or_disable("python-bindings", variant="python"))

config_args.extend(
self.enable_or_disable(
"pmi-backward-compatibility", variant="pmi_backwards_compatibility"
)
)

if "~docs" in self.spec:
config_args.append("--disable-man-pages")

# Versions < 2.1.1 have a bug in the test code that *sometimes*
# causes problems on strict alignment architectures such as
# aarch64. Work-around is to just not build the test code.
if (self.spec.satisfies('target=aarch64:') and
self.spec.version < Version('2.1.1')):
config_args.append('--without-tests-examples')

# Versions >= 3.0 also use hwloc
if self.spec.version >= Version('3.0.0'):
config_args.append('--with-hwloc={0}'.format(spec['hwloc'].prefix))
if spec.satisfies("@:2.1.0 target=aarch64:"):
config_args.append("--without-tests-examples")

return config_args

0 comments on commit 7e1c939

Please sign in to comment.