Avoid trailing slashes in strings (#48359)
This commit is contained in:
parent
7f9019c1ca
commit
0a03a92e78
@ -548,10 +548,9 @@ def ensure_winsdk_external_or_raise() -> None:
|
|||||||
missing_packages_lst.append("win-sdk")
|
missing_packages_lst.append("win-sdk")
|
||||||
missing_packages = " & ".join(missing_packages_lst)
|
missing_packages = " & ".join(missing_packages_lst)
|
||||||
raise RuntimeError(
|
raise RuntimeError(
|
||||||
f"Unable to find the {missing_packages}, please install these packages \
|
f"Unable to find the {missing_packages}, please install these packages via the Visual "
|
||||||
via the Visual Studio installer \
|
"Studio installer before proceeding with Spack or provide the path to a non standard "
|
||||||
before proceeding with Spack or provide the path to a non standard install with \
|
"install with 'spack external find --path'"
|
||||||
'spack external find --path'"
|
|
||||||
)
|
)
|
||||||
# wgl/sdk are not required for bootstrapping Spack, but
|
# wgl/sdk are not required for bootstrapping Spack, but
|
||||||
# are required for building anything non trivial
|
# are required for building anything non trivial
|
||||||
|
@ -232,8 +232,10 @@ def build_name(self, spec: Optional[spack.spec.Spec] = None) -> Optional[str]:
|
|||||||
|
|
||||||
Returns: (str) given spec's CDash build name."""
|
Returns: (str) given spec's CDash build name."""
|
||||||
if spec:
|
if spec:
|
||||||
build_name = f"{spec.name}@{spec.version}%{spec.compiler} \
|
build_name = (
|
||||||
hash={spec.dag_hash()} arch={spec.architecture} ({self.build_group})"
|
f"{spec.name}@{spec.version}%{spec.compiler} "
|
||||||
|
f"hash={spec.dag_hash()} arch={spec.architecture} ({self.build_group})"
|
||||||
|
)
|
||||||
tty.debug(f"Generated CDash build name ({build_name}) from the {spec.name}")
|
tty.debug(f"Generated CDash build name ({build_name}) from the {spec.name}")
|
||||||
return build_name
|
return build_name
|
||||||
|
|
||||||
|
@ -279,8 +279,10 @@ def test_add_config_path(mutable_config):
|
|||||||
assert "gcc" in compilers
|
assert "gcc" in compilers
|
||||||
|
|
||||||
# Try quotes to escape brackets
|
# Try quotes to escape brackets
|
||||||
path = "config:install_tree:projections:cmake:\
|
path = (
|
||||||
'{architecture}/{compiler.name}-{compiler.version}/{name}-{version}-{hash}'"
|
"config:install_tree:projections:cmake:"
|
||||||
|
"'{architecture}/{compiler.name}-{compiler.version}/{name}-{version}-{hash}'"
|
||||||
|
)
|
||||||
spack.config.add(path)
|
spack.config.add(path)
|
||||||
set_value = spack.config.get("config")["install_tree"]["projections"]["cmake"]
|
set_value = spack.config.get("config")["install_tree"]["projections"]["cmake"]
|
||||||
assert set_value == "{architecture}/{compiler.name}-{compiler.version}/{name}-{version}-{hash}"
|
assert set_value == "{architecture}/{compiler.name}-{compiler.version}/{name}-{version}-{hash}"
|
||||||
|
@ -1173,8 +1173,8 @@ def test_parse_specfile_dependency(default_mock_concretization, tmpdir):
|
|||||||
|
|
||||||
# Should also be accepted: "spack spec ../<cur-dir>/libelf.yaml"
|
# Should also be accepted: "spack spec ../<cur-dir>/libelf.yaml"
|
||||||
spec = SpecParser(
|
spec = SpecParser(
|
||||||
f"libdwarf^..{os.path.sep}{specfile.dirpath().basename}\
|
f"libdwarf^..{os.path.sep}{specfile.dirpath().basename}"
|
||||||
{os.path.sep}{specfile.basename}"
|
f"{os.path.sep}{specfile.basename}"
|
||||||
).next_spec()
|
).next_spec()
|
||||||
assert spec["libelf"] == s["libelf"]
|
assert spec["libelf"] == s["libelf"]
|
||||||
|
|
||||||
|
@ -259,8 +259,7 @@ def _system_7zip(archive_file):
|
|||||||
_7z = which("7z")
|
_7z = which("7z")
|
||||||
if not _7z:
|
if not _7z:
|
||||||
raise CommandNotFoundError(
|
raise CommandNotFoundError(
|
||||||
"7z unavailable,\
|
"7z unavailable, unable to extract %s files. 7z can be installed via Spack"
|
||||||
unable to extract %s files. 7z can be installed via Spack"
|
|
||||||
% llnl.url.extension_from_path(archive_file)
|
% llnl.url.extension_from_path(archive_file)
|
||||||
)
|
)
|
||||||
_7z.add_default_arg("e")
|
_7z.add_default_arg("e")
|
||||||
|
@ -52,26 +52,24 @@ def edit(self, spec, prefix):
|
|||||||
inc_var = "-"
|
inc_var = "-"
|
||||||
system_var = "ELPA_LIB = -L${ELPA_LIB_DIR} -lelpa -Wl,-rpath=${ELPA_LIB_DIR}"
|
system_var = "ELPA_LIB = -L${ELPA_LIB_DIR} -lelpa -Wl,-rpath=${ELPA_LIB_DIR}"
|
||||||
|
|
||||||
tempInc = (
|
tempInc = """
|
||||||
"\
|
FORTRAN = ifort
|
||||||
FORTRAN = ifort\n\
|
CPLUSPLUS = icpc
|
||||||
CPLUSPLUS = icpc\n\
|
CPLUSPLUS_MPI = mpiicpc
|
||||||
CPLUSPLUS_MPI = mpiicpc\n\
|
LAPACK_DIR = $(MKLROOT)
|
||||||
LAPACK_DIR = $(MKLROOT)\n\
|
FFTW_DIR = %s
|
||||||
FFTW_DIR = %s\n\
|
ELPA_DIR = %s
|
||||||
ELPA_DIR = %s\n\
|
ELPA_INCLUDE = -I${ELPA_DIR}/include/elpa%s%s
|
||||||
ELPA_INCLUDE = -I${ELPA_DIR}/include/elpa%s%s\n\
|
CEREAL_DIR = %s
|
||||||
CEREAL_DIR = %s\n\
|
OBJ_DIR = obj
|
||||||
OBJ_DIR = obj\n\
|
OBJ_DIR_serial = obj
|
||||||
OBJ_DIR_serial = obj\n\
|
NP = 14
|
||||||
NP = 14\n"
|
""" % (
|
||||||
% (
|
spec["fftw"].prefix,
|
||||||
spec["fftw"].prefix,
|
spec["elpa"].prefix,
|
||||||
spec["elpa"].prefix,
|
inc_var,
|
||||||
inc_var,
|
spec["elpa"].version,
|
||||||
f"{spec['elpa'].version}",
|
spec["cereal"].prefix,
|
||||||
spec["cereal"].prefix,
|
|
||||||
)
|
|
||||||
)
|
)
|
||||||
|
|
||||||
with open(self.build_directory + "/Makefile.vars", "w") as f:
|
with open(self.build_directory + "/Makefile.vars", "w") as f:
|
||||||
|
@ -75,8 +75,8 @@ class Axl(CMakePackage):
|
|||||||
variant(
|
variant(
|
||||||
"bbapi_fallback",
|
"bbapi_fallback",
|
||||||
default=False,
|
default=False,
|
||||||
description="Using BBAPI, if source or destination don't support \
|
description="Using BBAPI, if source or destination don't support "
|
||||||
file extents then fallback to pthreads",
|
"file extents then fallback to pthreads",
|
||||||
)
|
)
|
||||||
|
|
||||||
variant("dw", default=False, description="Enable Cray DataWarp support")
|
variant("dw", default=False, description="Enable Cray DataWarp support")
|
||||||
|
@ -86,16 +86,14 @@ class Babelstream(CMakePackage, CudaPackage, ROCmPackage, MakefilePackage):
|
|||||||
values=("cuda", "rocm"),
|
values=("cuda", "rocm"),
|
||||||
default="cuda",
|
default="cuda",
|
||||||
when="+thrust",
|
when="+thrust",
|
||||||
description="Which THRUST implementation to use, supported options include option= \
|
description="Which THRUST implementation to use",
|
||||||
- CUDA (via https://github.com/NVIDIA/thrust)\
|
|
||||||
- ROCM (via https://github.com/ROCmSoftwarePlatform/rocThrust)",
|
|
||||||
)
|
)
|
||||||
variant(
|
variant(
|
||||||
"thrust_backend",
|
"thrust_backend",
|
||||||
values=("cuda", "omp", "tbb"),
|
values=("cuda", "omp", "tbb"),
|
||||||
default="cuda",
|
default="cuda",
|
||||||
when="+thrust",
|
when="+thrust",
|
||||||
description="Which THRUST implementation to use, supported options include option",
|
description="Which THRUST implementation to use",
|
||||||
)
|
)
|
||||||
|
|
||||||
# Kokkos variant
|
# Kokkos variant
|
||||||
@ -146,8 +144,8 @@ class Babelstream(CMakePackage, CudaPackage, ROCmPackage, MakefilePackage):
|
|||||||
values=("nvhpc", "none"),
|
values=("nvhpc", "none"),
|
||||||
default="none",
|
default="none",
|
||||||
when="+std",
|
when="+std",
|
||||||
description="Enable offloading support (via the non-standard `-stdpar`)\
|
description="Enable offloading support (via the non-standard `-stdpar`) "
|
||||||
for the new NVHPC SDK",
|
"for the new NVHPC SDK",
|
||||||
)
|
)
|
||||||
variant(
|
variant(
|
||||||
"std_onedpl_backend",
|
"std_onedpl_backend",
|
||||||
@ -161,16 +159,16 @@ class Babelstream(CMakePackage, CudaPackage, ROCmPackage, MakefilePackage):
|
|||||||
values=(True, False),
|
values=(True, False),
|
||||||
default=False,
|
default=False,
|
||||||
when="+std",
|
when="+std",
|
||||||
description="No-op if ONE_TBB_DIR is set. Link against an in-tree oneTBB\
|
description="No-op if ONE_TBB_DIR is set. Link against an in-tree oneTBB "
|
||||||
via FetchContent_Declare, see top level CMakeLists.txt for details",
|
"via FetchContent_Declare, see top level CMakeLists.txt for details",
|
||||||
)
|
)
|
||||||
variant(
|
variant(
|
||||||
"std_use_onedpl",
|
"std_use_onedpl",
|
||||||
values=(True, False),
|
values=(True, False),
|
||||||
default=False,
|
default=False,
|
||||||
when="+std",
|
when="+std",
|
||||||
description="Link oneDPL which implements C++17 executor policies\
|
description="Link oneDPL which implements C++17 executor policies "
|
||||||
(via execution_policy_tag) for different backends",
|
"(via execution_policy_tag) for different backends",
|
||||||
)
|
)
|
||||||
# hip memory mode
|
# hip memory mode
|
||||||
variant(
|
variant(
|
||||||
@ -186,9 +184,9 @@ class Babelstream(CMakePackage, CudaPackage, ROCmPackage, MakefilePackage):
|
|||||||
values=(True, False),
|
values=(True, False),
|
||||||
default=False,
|
default=False,
|
||||||
when="+tbb",
|
when="+tbb",
|
||||||
description="Whether to use std::vector<T> for storage or use aligned_alloc. \
|
description="Whether to use std::vector<T> for storage or use aligned_alloc. "
|
||||||
C++ vectors are *zero* initialised where as aligned_alloc is \
|
"C++ vectors are *zero* initialised where as aligned_alloc is "
|
||||||
uninitialised before first use.",
|
"uninitialised before first use.",
|
||||||
)
|
)
|
||||||
|
|
||||||
# Thrust Conflict
|
# Thrust Conflict
|
||||||
@ -208,13 +206,7 @@ class Babelstream(CMakePackage, CudaPackage, ROCmPackage, MakefilePackage):
|
|||||||
values=("auto", "affinity", "static", "simple"),
|
values=("auto", "affinity", "static", "simple"),
|
||||||
default="auto",
|
default="auto",
|
||||||
when="+tbb",
|
when="+tbb",
|
||||||
description="Partitioner specifies how a loop template should partition its work among threads.\
|
description="Specifies how a loop template should partition its work among threads",
|
||||||
Possible values are:\
|
|
||||||
AUTO - Optimize range subdivision based on work-stealing events.\
|
|
||||||
AFFINITY - Proportional splitting that optimizes for cache affinity.\
|
|
||||||
STATIC - Distribute work uniformly with no additional load balancing.\
|
|
||||||
SIMPLE - Recursively split its range until it cannot be further subdivided.\
|
|
||||||
See https://spec.oneapi.com/versions/latest/elements/oneTBB/source/algorithms.html#partitioners",
|
|
||||||
)
|
)
|
||||||
|
|
||||||
# Kokkos & RAJA Dependency
|
# Kokkos & RAJA Dependency
|
||||||
|
@ -137,10 +137,9 @@ def edit(self, spec, prefix):
|
|||||||
# use parallelization in tests
|
# use parallelization in tests
|
||||||
filter_file(
|
filter_file(
|
||||||
r"cd testsuite \&\& \$\(MAKE\) check$",
|
r"cd testsuite \&\& \$\(MAKE\) check$",
|
||||||
"cd testsuite && export BGW_TEST_MPI_NPROCS=2 OMP_NUM_THREADS=2 \
|
"cd testsuite && export BGW_TEST_MPI_NPROCS=2 OMP_NUM_THREADS=2 "
|
||||||
SAVETESTDIRS=yes TEMPDIRPATH=%s && \
|
"SAVETESTDIRS=yes TEMPDIRPATH=%s && "
|
||||||
$(MAKE) check-parallel"
|
"$(MAKE) check-parallel" % join_path(self.build_directory, "tmp"),
|
||||||
% join_path(self.build_directory, "tmp"),
|
|
||||||
"Makefile",
|
"Makefile",
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@ -52,8 +52,7 @@ def setup_run_environment(self, env):
|
|||||||
def edit(self):
|
def edit(self):
|
||||||
# perl tools end up in a silly lib subdirectory, fixing that
|
# perl tools end up in a silly lib subdirectory, fixing that
|
||||||
filter_file(
|
filter_file(
|
||||||
r"set\(SUPPORT_LIBDIR lib\/breakdancer-max\$ \
|
r"set\(SUPPORT_LIBDIR lib\/breakdancer-max\$ \{EXE_VERSION_SUFFIX\}\)",
|
||||||
\{EXE_VERSION_SUFFIX\}\)",
|
|
||||||
"set(SUPPORT_LIBDIR lib)",
|
"set(SUPPORT_LIBDIR lib)",
|
||||||
join_path(self.stage.source_path, "perl", "CMakeLists.txt"),
|
join_path(self.stage.source_path, "perl", "CMakeLists.txt"),
|
||||||
)
|
)
|
||||||
|
@ -27,8 +27,7 @@ class CbtfArgonavis(CMakePackage):
|
|||||||
variant(
|
variant(
|
||||||
"crayfe",
|
"crayfe",
|
||||||
default=False,
|
default=False,
|
||||||
description="build only the FE tool using the runtime_dir \
|
description="build only the FE tool using the runtime_dir to point to target build.",
|
||||||
to point to target build.",
|
|
||||||
)
|
)
|
||||||
variant(
|
variant(
|
||||||
"runtime", default=False, description="build only the runtime libraries and collectors."
|
"runtime", default=False, description="build only the runtime libraries and collectors."
|
||||||
|
@ -48,8 +48,7 @@ class CbtfKrell(CMakePackage):
|
|||||||
variant(
|
variant(
|
||||||
"crayfe",
|
"crayfe",
|
||||||
default=False,
|
default=False,
|
||||||
description="build only the FE tool using the runtime_dir \
|
description="build only the FE tool using the runtime_dir to point to target build.",
|
||||||
to point to target build.",
|
|
||||||
)
|
)
|
||||||
|
|
||||||
# Dependencies for cbtf-krell
|
# Dependencies for cbtf-krell
|
||||||
|
@ -278,9 +278,7 @@ def install(self, spec, prefix):
|
|||||||
if not ("backend=mpi" in self.spec) or not ("backend=netlrts" in self.spec):
|
if not ("backend=mpi" in self.spec) or not ("backend=netlrts" in self.spec):
|
||||||
if self.spec.satisfies("+pthreads"):
|
if self.spec.satisfies("+pthreads"):
|
||||||
raise InstallError(
|
raise InstallError(
|
||||||
"The pthreads option is only\
|
"The pthreads option is only available on the Netlrts and MPI network layers."
|
||||||
available on the Netlrts and MPI \
|
|
||||||
network layers."
|
|
||||||
)
|
)
|
||||||
|
|
||||||
if (
|
if (
|
||||||
@ -290,10 +288,8 @@ def install(self, spec, prefix):
|
|||||||
):
|
):
|
||||||
if self.spec.satisfies("pmi=none"):
|
if self.spec.satisfies("pmi=none"):
|
||||||
raise InstallError(
|
raise InstallError(
|
||||||
"The UCX/OFI/GNI backends need \
|
"The UCX/OFI/GNI backends need PMI to run. Please add pmi=... "
|
||||||
PMI to run. Please add pmi=... \
|
"Note that PMIx is the preferred option."
|
||||||
Note that PMIx is the preferred \
|
|
||||||
option."
|
|
||||||
)
|
)
|
||||||
|
|
||||||
if (
|
if (
|
||||||
@ -303,10 +299,8 @@ def install(self, spec, prefix):
|
|||||||
):
|
):
|
||||||
if self.spec.satisfies("^openmpi"):
|
if self.spec.satisfies("^openmpi"):
|
||||||
raise InstallError(
|
raise InstallError(
|
||||||
"To use any process management \
|
"To use any process management interface other than PMIx, "
|
||||||
interface other than PMIx, \
|
"a non OpenMPI based MPI must be present on the system"
|
||||||
a non OpenMPI based MPI must be \
|
|
||||||
present on the system"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
target = spec.variants["build-target"].value
|
target = spec.variants["build-target"].value
|
||||||
|
@ -168,11 +168,10 @@ def cmake_args(self):
|
|||||||
]
|
]
|
||||||
)
|
)
|
||||||
if self.spec.satisfies("%icc"):
|
if self.spec.satisfies("%icc"):
|
||||||
cxxflags = "-Ofast -ffast-math -DNDEBUG -march=native\
|
cxxflags = "-Ofast -ffast-math -DNDEBUG -march=native -mtune=native "
|
||||||
-mtune=native -funroll-all-loops\
|
cxxflags += "-funroll-all-loops -qopt-multi-version-aggressive -ipo -parallel"
|
||||||
-qopt-multi-version-aggressive -ipo -parallel"
|
cflags = "-Ofast -ffast-math -DNDEBUG -march=native -mtune=native "
|
||||||
cflags = "-Ofast -ffast-math -DNDEBUG -march=native\
|
cflags += "-funroll-all-loops -ipo -parallel"
|
||||||
-mtune=native -funroll-all-loops -ipo -parallel"
|
|
||||||
fcflags = "-Ofast -march=native -mtune=native -ipo -parallel"
|
fcflags = "-Ofast -march=native -mtune=native -ipo -parallel"
|
||||||
args.extend(
|
args.extend(
|
||||||
[
|
[
|
||||||
|
@ -25,8 +25,8 @@ class FujitsuSsl2(Package):
|
|||||||
|
|
||||||
def install(self, spec, prefix):
|
def install(self, spec, prefix):
|
||||||
raise InstallError(
|
raise InstallError(
|
||||||
"Fujitsu SSL2 is not installable; it is vendor supplied \
|
"Fujitsu SSL2 is not installable; it is vendor supplied "
|
||||||
You need to specify it as an external package in packages.yaml"
|
"You need to specify it as an external package in packages.yaml"
|
||||||
)
|
)
|
||||||
|
|
||||||
@property
|
@property
|
||||||
|
@ -57,8 +57,7 @@ def autoreconf(self, spec, prefix):
|
|||||||
subprocess.check_call("./autogen.sh")
|
subprocess.check_call("./autogen.sh")
|
||||||
else:
|
else:
|
||||||
raise RuntimeError(
|
raise RuntimeError(
|
||||||
"Neither configure nor autogen.sh script exist.\
|
"Neither configure nor autogen.sh script exist. FxT Cannot configure."
|
||||||
FxT Cannot configure."
|
|
||||||
)
|
)
|
||||||
|
|
||||||
def configure_args(self):
|
def configure_args(self):
|
||||||
|
@ -42,8 +42,7 @@ class Graphblast(MakefilePackage, CudaPackage):
|
|||||||
conflicts(
|
conflicts(
|
||||||
"cuda_arch=none",
|
"cuda_arch=none",
|
||||||
when="+cuda",
|
when="+cuda",
|
||||||
msg='Must specify CUDA compute capabilities of your GPU. \
|
msg='Must specify CUDA compute capabilities of your GPU. See "spack info graphblast"',
|
||||||
See "spack info graphblast"',
|
|
||||||
)
|
)
|
||||||
|
|
||||||
def install(self, spec, prefix):
|
def install(self, spec, prefix):
|
||||||
|
@ -87,8 +87,7 @@ class Gunrock(CMakePackage, CudaPackage):
|
|||||||
conflicts(
|
conflicts(
|
||||||
"cuda_arch=none",
|
"cuda_arch=none",
|
||||||
when="+cuda",
|
when="+cuda",
|
||||||
msg='Must specify CUDA compute capabilities of your GPU. \
|
msg='Must specify CUDA compute capabilities of your GPU. See "spack info gunrock"',
|
||||||
See "spack info gunrock"',
|
|
||||||
)
|
)
|
||||||
|
|
||||||
def cmake_args(self):
|
def cmake_args(self):
|
||||||
|
@ -50,8 +50,7 @@ class HermesShm(CMakePackage):
|
|||||||
depends_on("mochi-thallium+cereal@0.10.1", when="+mochi")
|
depends_on("mochi-thallium+cereal@0.10.1", when="+mochi")
|
||||||
depends_on("cereal", when="+cereal")
|
depends_on("cereal", when="+cereal")
|
||||||
depends_on(
|
depends_on(
|
||||||
"boost@1.7: +context +fiber +coroutine +regex +system \
|
"boost@1.7:+context+fiber+coroutine+regex+system+filesystem+serialization+pic+math",
|
||||||
+filesystem +serialization +pic +math",
|
|
||||||
when="+boost",
|
when="+boost",
|
||||||
)
|
)
|
||||||
depends_on("mpi", when="+mpiio")
|
depends_on("mpi", when="+mpiio")
|
||||||
|
@ -29,8 +29,11 @@ class IsaacServer(CMakePackage):
|
|||||||
|
|
||||||
depends_on("cxx", type="build") # generated
|
depends_on("cxx", type="build") # generated
|
||||||
|
|
||||||
# variant('gstreamer', default=False, description= \
|
# variant(
|
||||||
# 'Support for RTP streams, e.g. to Twitch or Youtube')
|
# "gstreamer",
|
||||||
|
# default=False,
|
||||||
|
# description="Support for RTP streams, e.g. to Twitch or Youtube"
|
||||||
|
# )
|
||||||
|
|
||||||
depends_on("cmake@3.3:", type="build")
|
depends_on("cmake@3.3:", type="build")
|
||||||
depends_on("jpeg", type="link")
|
depends_on("jpeg", type="link")
|
||||||
|
@ -167,10 +167,7 @@ def install(self, spec, prefix):
|
|||||||
supported_compilers = {"gcc": "GCCPOWER"}
|
supported_compilers = {"gcc": "GCCPOWER"}
|
||||||
if self.compiler.name not in supported_compilers:
|
if self.compiler.name not in supported_compilers:
|
||||||
raise RuntimeError(
|
raise RuntimeError(
|
||||||
"{0} is not a supported compiler \
|
"{0} is not a supported compiler to compile Likwid".format(self.compiler.name)
|
||||||
to compile Likwid".format(
|
|
||||||
self.compiler.name
|
|
||||||
)
|
|
||||||
)
|
)
|
||||||
|
|
||||||
filter_file(
|
filter_file(
|
||||||
|
@ -31,8 +31,7 @@ class LlvmOpenmpOmpt(CMakePackage):
|
|||||||
variant(
|
variant(
|
||||||
"standalone",
|
"standalone",
|
||||||
default=False,
|
default=False,
|
||||||
description="Build llvm openmpi ompt library as a \
|
description="Build llvm openmpi ompt library as a stand alone entity.",
|
||||||
stand alone entity.",
|
|
||||||
)
|
)
|
||||||
# variant for building libomptarget
|
# variant for building libomptarget
|
||||||
variant(
|
variant(
|
||||||
|
@ -180,28 +180,20 @@ def _edit_arch_generic(self, spec, prefix):
|
|||||||
if self.spec.satisfies("^charmpp@:6.10.1"):
|
if self.spec.satisfies("^charmpp@:6.10.1"):
|
||||||
optims_opts = {
|
optims_opts = {
|
||||||
"gcc": m64
|
"gcc": m64
|
||||||
+ "-O3 -fexpensive-optimizations \
|
+ "-O3 -fexpensive-optimizations -ffast-math -lpthread "
|
||||||
-ffast-math -lpthread "
|
|
||||||
+ archopt,
|
+ archopt,
|
||||||
"intel": "-O2 -ip -qopenmp-simd" + archopt,
|
"intel": "-O2 -ip -qopenmp-simd" + archopt,
|
||||||
"clang": m64 + "-O3 -ffast-math -fopenmp " + archopt,
|
"clang": m64 + "-O3 -ffast-math -fopenmp " + archopt,
|
||||||
"aocc": m64
|
"aocc": m64 + "-O3 -ffp-contract=fast -ffast-math -fopenmp " + archopt,
|
||||||
+ "-O3 -ffp-contract=fast -ffast-math \
|
|
||||||
-fopenmp "
|
|
||||||
+ archopt,
|
|
||||||
}
|
}
|
||||||
else:
|
else:
|
||||||
optims_opts = {
|
optims_opts = {
|
||||||
"gcc": m64
|
"gcc": m64
|
||||||
+ "-O3 -fexpensive-optimizations \
|
+ "-O3 -fexpensive-optimizations -ffast-math -lpthread "
|
||||||
-ffast-math -lpthread "
|
|
||||||
+ archopt,
|
+ archopt,
|
||||||
"intel": "-O2 -ip " + archopt,
|
"intel": "-O2 -ip " + archopt,
|
||||||
"clang": m64 + "-O3 -ffast-math -fopenmp " + archopt,
|
"clang": m64 + "-O3 -ffast-math -fopenmp " + archopt,
|
||||||
"aocc": m64
|
"aocc": m64 + "-O3 -ffp-contract=fast -ffast-math " + archopt,
|
||||||
+ "-O3 -ffp-contract=fast \
|
|
||||||
-ffast-math "
|
|
||||||
+ archopt,
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if self.spec.satisfies("+avxtiles"):
|
if self.spec.satisfies("+avxtiles"):
|
||||||
|
@ -47,8 +47,8 @@ class OpenradiossEngine(CMakePackage):
|
|||||||
"%aocc",
|
"%aocc",
|
||||||
"%arm",
|
"%arm",
|
||||||
policy="one_of",
|
policy="one_of",
|
||||||
msg="Openradioss-starter can be built using GNU Fortran, Intel Fortran, AOCC, \
|
msg="Openradioss-starter can be built using GNU Fortran, Intel Fortran, AOCC, "
|
||||||
or Armflang compilers only.",
|
"or Armflang compilers only.",
|
||||||
)
|
)
|
||||||
|
|
||||||
build_directory = "engine"
|
build_directory = "engine"
|
||||||
|
@ -46,8 +46,8 @@ class OpenradiossStarter(CMakePackage):
|
|||||||
"%aocc",
|
"%aocc",
|
||||||
"%arm",
|
"%arm",
|
||||||
policy="one_of",
|
policy="one_of",
|
||||||
msg="Openradioss-starter can be built using GNU Fortran, Intel Fortran, AOCC, \
|
msg="Openradioss-starter can be built using GNU Fortran, Intel Fortran, AOCC, "
|
||||||
or Armflang compilers only.",
|
"or Armflang compilers only.",
|
||||||
)
|
)
|
||||||
|
|
||||||
build_directory = "starter"
|
build_directory = "starter"
|
||||||
|
@ -47,8 +47,7 @@ class OpenspeedshopUtils(CMakePackage):
|
|||||||
variant(
|
variant(
|
||||||
"crayfe",
|
"crayfe",
|
||||||
default=False,
|
default=False,
|
||||||
description="build only the FE tool using the runtime_dir \
|
description="build only the FE tool using the runtime_dir to point to target build.",
|
||||||
to point to target build.",
|
|
||||||
)
|
)
|
||||||
variant("cuda", default=False, description="build with cuda packages included.")
|
variant("cuda", default=False, description="build with cuda packages included.")
|
||||||
|
|
||||||
@ -63,26 +62,22 @@ class OpenspeedshopUtils(CMakePackage):
|
|||||||
variant(
|
variant(
|
||||||
"openmpi",
|
"openmpi",
|
||||||
default=False,
|
default=False,
|
||||||
description="Build mpi collector for openmpi \
|
description="Build mpi collector for openmpi MPI when variant is enabled.",
|
||||||
MPI when variant is enabled.",
|
|
||||||
)
|
)
|
||||||
variant(
|
variant(
|
||||||
"mpt",
|
"mpt",
|
||||||
default=False,
|
default=False,
|
||||||
description="Build mpi collector for SGI \
|
description="Build mpi collector for SGI MPT MPI when variant is enabled.",
|
||||||
MPT MPI when variant is enabled.",
|
|
||||||
)
|
)
|
||||||
variant(
|
variant(
|
||||||
"mvapich2",
|
"mvapich2",
|
||||||
default=False,
|
default=False,
|
||||||
description="Build mpi collector for mvapich2\
|
description="Build mpi collector for mvapich2 MPI when variant is enabled.",
|
||||||
MPI when variant is enabled.",
|
|
||||||
)
|
)
|
||||||
variant(
|
variant(
|
||||||
"mpich2",
|
"mpich2",
|
||||||
default=False,
|
default=False,
|
||||||
description="Build mpi collector for mpich2\
|
description="Build mpi collector for mpich2 MPI when variant is enabled.",
|
||||||
MPI when variant is enabled.",
|
|
||||||
)
|
)
|
||||||
|
|
||||||
depends_on("cmake@3.0.2:", type="build")
|
depends_on("cmake@3.0.2:", type="build")
|
||||||
|
@ -44,8 +44,7 @@ class Openspeedshop(CMakePackage):
|
|||||||
variant(
|
variant(
|
||||||
"crayfe",
|
"crayfe",
|
||||||
default=False,
|
default=False,
|
||||||
description="build only the FE tool using the runtime_dir \
|
description="build only the FE tool using the runtime_dir to point to target build.",
|
||||||
to point to target build.",
|
|
||||||
)
|
)
|
||||||
variant("cuda", default=False, description="build with cuda packages included.")
|
variant("cuda", default=False, description="build with cuda packages included.")
|
||||||
|
|
||||||
@ -67,26 +66,22 @@ class Openspeedshop(CMakePackage):
|
|||||||
variant(
|
variant(
|
||||||
"openmpi",
|
"openmpi",
|
||||||
default=False,
|
default=False,
|
||||||
description="Build mpi collector for openmpi \
|
description="Build mpi collector for openmpi MPI when variant is enabled.",
|
||||||
MPI when variant is enabled.",
|
|
||||||
)
|
)
|
||||||
variant(
|
variant(
|
||||||
"mpt",
|
"mpt",
|
||||||
default=False,
|
default=False,
|
||||||
description="Build mpi collector for SGI \
|
description="Build mpi collector for SGI MPT MPI when variant is enabled.",
|
||||||
MPT MPI when variant is enabled.",
|
|
||||||
)
|
)
|
||||||
variant(
|
variant(
|
||||||
"mvapich2",
|
"mvapich2",
|
||||||
default=False,
|
default=False,
|
||||||
description="Build mpi collector for mvapich2\
|
description="Build mpi collector for mvapich2 MPI when variant is enabled.",
|
||||||
MPI when variant is enabled.",
|
|
||||||
)
|
)
|
||||||
variant(
|
variant(
|
||||||
"mpich2",
|
"mpich2",
|
||||||
default=False,
|
default=False,
|
||||||
description="Build mpi collector for mpich2\
|
description="Build mpi collector for mpich2 MPI when variant is enabled.",
|
||||||
MPI when variant is enabled.",
|
|
||||||
)
|
)
|
||||||
|
|
||||||
depends_on("cmake@3.0.2:", type="build")
|
depends_on("cmake@3.0.2:", type="build")
|
||||||
|
@ -106,8 +106,8 @@ def libs(self):
|
|||||||
if libs:
|
if libs:
|
||||||
return libs
|
return libs
|
||||||
|
|
||||||
msg = f"Unable to recursively locate {'shared' if shared else 'static'} \
|
msg = f"Unable to recursively locate {'shared' if shared else 'static'} "
|
||||||
{self.spec.name} libraries in {self.spec.prefix}"
|
msg += f"{self.spec.name} libraries in {self.spec.prefix}"
|
||||||
raise NoLibrariesError(msg)
|
raise NoLibrariesError(msg)
|
||||||
|
|
||||||
@when("@master")
|
@when("@master")
|
||||||
|
@ -612,8 +612,8 @@ def configure_options(self):
|
|||||||
("superlu-dist", "superlu_dist", True, True),
|
("superlu-dist", "superlu_dist", True, True),
|
||||||
("scotch", "ptscotch", True, True),
|
("scotch", "ptscotch", True, True),
|
||||||
(
|
(
|
||||||
"suite-sparse:umfpack,klu,cholmod,btf,ccolamd,colamd,camd,amd, \
|
"suite-sparse:umfpack,klu,cholmod,btf,ccolamd,colamd,camd,amd,"
|
||||||
suitesparseconfig,spqr",
|
"suitesparseconfig,spqr",
|
||||||
"suitesparse",
|
"suitesparse",
|
||||||
True,
|
True,
|
||||||
True,
|
True,
|
||||||
|
@ -81,11 +81,7 @@ class Pumi(CMakePackage):
|
|||||||
depends_on("zoltan+int64", when="+zoltan+int64")
|
depends_on("zoltan+int64", when="+zoltan+int64")
|
||||||
simbase = "+base"
|
simbase = "+base"
|
||||||
simkernels = simbase + "+parasolid+acis+discrete"
|
simkernels = simbase + "+parasolid+acis+discrete"
|
||||||
simfull = (
|
simfull = simkernels + "+abstract+adv+advmodel+import+paralleladapt+parallelmesh"
|
||||||
simkernels
|
|
||||||
+ "+abstract+adv+advmodel\
|
|
||||||
+import+paralleladapt+parallelmesh"
|
|
||||||
)
|
|
||||||
depends_on("simmetrix-simmodsuite" + simbase, when="simmodsuite=base")
|
depends_on("simmetrix-simmodsuite" + simbase, when="simmodsuite=base")
|
||||||
depends_on("simmetrix-simmodsuite" + simkernels, when="simmodsuite=kernels")
|
depends_on("simmetrix-simmodsuite" + simkernels, when="simmodsuite=kernels")
|
||||||
depends_on("simmetrix-simmodsuite" + simfull, when="simmodsuite=full")
|
depends_on("simmetrix-simmodsuite" + simfull, when="simmodsuite=full")
|
||||||
|
@ -112,8 +112,10 @@ def make_qsci_python(self):
|
|||||||
# also add link statement to fix "undefined symbol _Z...Qsciprinter...
|
# also add link statement to fix "undefined symbol _Z...Qsciprinter...
|
||||||
link_qscilibs = "LIBS += -L" + self.prefix.lib + " -lqscintilla2_" + qtx
|
link_qscilibs = "LIBS += -L" + self.prefix.lib + " -lqscintilla2_" + qtx
|
||||||
tomlfile.write(
|
tomlfile.write(
|
||||||
f'\n[tool.sip.builder]\nqmake-settings = \
|
f"""
|
||||||
["QT += widgets", "QT += printsupport", "{link_qscilibs}"]\n'
|
[tool.sip.builder]
|
||||||
|
qmake-settings = ["QT += widgets", "QT += printsupport", "{link_qscilibs}"]
|
||||||
|
"""
|
||||||
)
|
)
|
||||||
|
|
||||||
mkdirp(os.path.join(self.prefix.share.sip, pyqtx))
|
mkdirp(os.path.join(self.prefix.share.sip, pyqtx))
|
||||||
|
@ -169,9 +169,11 @@ def build(self, spec, prefix):
|
|||||||
"""
|
"""
|
||||||
with working_dir(self.stage.source_path):
|
with working_dir(self.stage.source_path):
|
||||||
# modify Makefile not to git init submodules.
|
# modify Makefile not to git init submodules.
|
||||||
cmd = "/bin/sed -i.bak -r \
|
cmd = (
|
||||||
'/^# Rule for auto init submodules/,/git submodule update.*$/d' \
|
"/bin/sed -i.bak -r "
|
||||||
Makefile"
|
"'/^# Rule for auto init submodules/,/git submodule update.*$/d' "
|
||||||
|
"Makefile"
|
||||||
|
)
|
||||||
p = Popen(shlex.split(cmd))
|
p = Popen(shlex.split(cmd))
|
||||||
p.wait()
|
p.wait()
|
||||||
p.communicate()
|
p.communicate()
|
||||||
|
@ -150,8 +150,7 @@ class RocprofilerDev(CMakePackage):
|
|||||||
def patch(self):
|
def patch(self):
|
||||||
filter_file(
|
filter_file(
|
||||||
"${HSA_RUNTIME_LIB_PATH}/../include",
|
"${HSA_RUNTIME_LIB_PATH}/../include",
|
||||||
"${HSA_RUNTIME_LIB_PATH}/../include ${HSA_KMT_LIB_PATH}/..\
|
"${HSA_RUNTIME_LIB_PATH}/../include ${HSA_KMT_LIB_PATH}/../include",
|
||||||
/include",
|
|
||||||
"test/CMakeLists.txt",
|
"test/CMakeLists.txt",
|
||||||
string=True,
|
string=True,
|
||||||
)
|
)
|
||||||
|
@ -31,9 +31,9 @@ class Rocsolver(CMakePackage):
|
|||||||
variant(
|
variant(
|
||||||
"optimal",
|
"optimal",
|
||||||
default=True,
|
default=True,
|
||||||
description="This option improves performance at the cost of increased binary \
|
description="This option improves performance at the cost of increased binary "
|
||||||
size and compile time by adding specialized kernels \
|
"size and compile time by adding specialized kernels "
|
||||||
for small matrix sizes",
|
"for small matrix sizes",
|
||||||
)
|
)
|
||||||
variant("asan", default=False, description="Build with address-sanitizer enabled or disabled")
|
variant("asan", default=False, description="Build with address-sanitizer enabled or disabled")
|
||||||
|
|
||||||
|
@ -165,8 +165,8 @@ class Scr(CMakePackage):
|
|||||||
"bbapi_fallback",
|
"bbapi_fallback",
|
||||||
default=False,
|
default=False,
|
||||||
when="@3: +bbapi",
|
when="@3: +bbapi",
|
||||||
description="Using BBAPI, if source or destination don't support \
|
description="Using BBAPI, if source or destination don't support "
|
||||||
file extents then fallback to pthreads",
|
"file extents then fallback to pthreads",
|
||||||
)
|
)
|
||||||
depends_on("axl+bbapi+bbapi_fallback", when="@3: +bbapi_fallback")
|
depends_on("axl+bbapi+bbapi_fallback", when="@3: +bbapi_fallback")
|
||||||
|
|
||||||
@ -189,8 +189,8 @@ class Scr(CMakePackage):
|
|||||||
|
|
||||||
# Enabling SCR logging is a WIP, for which this will be needed
|
# Enabling SCR logging is a WIP, for which this will be needed
|
||||||
# MySQL currently having build issues
|
# MySQL currently having build issues
|
||||||
# variant('mysql', default=False, description='Build with MySQL to allow for \
|
# variant('mysql', default=False, description='Build with MySQL to allow for '
|
||||||
# capturing SCR and syslog messages in a database')
|
# 'capturing SCR and syslog messages in a database')
|
||||||
# depends_on('mysql', when='+mysql')
|
# depends_on('mysql', when='+mysql')
|
||||||
|
|
||||||
variant("shared", default=True, when="@3:", description="Build with shared libraries")
|
variant("shared", default=True, when="@3:", description="Build with shared libraries")
|
||||||
|
@ -40,24 +40,19 @@ def edit(self, spec, prefix):
|
|||||||
file.write(
|
file.write(
|
||||||
"FLINKER_mymachine = %s %s\n" % (self.spec["mpi"].mpifc, self.compiler.openmp_flag)
|
"FLINKER_mymachine = %s %s\n" % (self.spec["mpi"].mpifc, self.compiler.openmp_flag)
|
||||||
)
|
)
|
||||||
file.write(
|
file.write("DEBUG_mymachine = -g -ffpe-trap=invalid,zero -fcheck=bounds\n")
|
||||||
"DEBUG_mymachine = -g -ffpe-trap=invalid,zero \
|
|
||||||
-fcheck=bounds\n"
|
|
||||||
)
|
|
||||||
file.write("OPTIMIZE_mymachine = -O2\n")
|
file.write("OPTIMIZE_mymachine = -O2\n")
|
||||||
file.write("INCLUDE_HDF5_mymachine = \n")
|
file.write("INCLUDE_HDF5_mymachine = \n")
|
||||||
file.write("INCLUDE_LAPACK_mymachine = \n")
|
file.write("INCLUDE_LAPACK_mymachine = \n")
|
||||||
file.write("LIBRARIES_HDF5_mymachine = \n")
|
file.write("LIBRARIES_HDF5_mymachine = \n")
|
||||||
file.write("LIBRARIES_LAPACK_mymachine = \n")
|
file.write("LIBRARIES_LAPACK_mymachine = \n")
|
||||||
file.write(
|
file.write(
|
||||||
"export FORTRAN_mymachine FLINKER_mymachine \
|
"export FORTRAN_mymachine FLINKER_mymachine DEBUG_mymachine OPTIMIZE_mymachine\n"
|
||||||
DEBUG_mymachine OPTIMIZE_mymachine\n"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
file.write("all:\n")
|
file.write("all:\n")
|
||||||
file.write(
|
file.write(
|
||||||
"\t@$(MAKE) -C $(THORNADO_DIR)/DeleptonizationProblem/Executables \
|
"\t@$(MAKE) -C $(THORNADO_DIR)/DeleptonizationProblem/Executables -f Makefile\n"
|
||||||
-f Makefile\n"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
file.close()
|
file.close()
|
||||||
|
@ -110,9 +110,7 @@ def libs(self):
|
|||||||
|
|
||||||
def install(self, spec, prefix):
|
def install(self, spec, prefix):
|
||||||
raise RuntimeError(
|
raise RuntimeError(
|
||||||
"This package is not installable from Spack\
|
"This package is not installable from Spack and should be installed on the system "
|
||||||
and should be installed on the system prior to Spack use.\
|
"prior to Spack use. If not installed this package should be installed via the Visual "
|
||||||
If not installed this package should be installed via\
|
"Studio installer in order to use the MSVC compiler on Windows."
|
||||||
the Visual Studio installer in order to use the \
|
|
||||||
MSVC compiler on Windows."
|
|
||||||
)
|
)
|
||||||
|
@ -81,12 +81,10 @@ def determine_variants(cls, libs, ver_str):
|
|||||||
|
|
||||||
def install(self, spec, prefix):
|
def install(self, spec, prefix):
|
||||||
raise RuntimeError(
|
raise RuntimeError(
|
||||||
"This package is not installable from Spack\
|
"This package is not installable from Spack and should be installed on the system "
|
||||||
and should be installed on the system prior to Spack use.\
|
"prior to Spack use. If not installed this package should be installed via the Visual "
|
||||||
If not installed this package should be installed via\
|
"Studio installer in order to use the MSVC compiler on Windows. If absolutely "
|
||||||
the Visual Studio installer in order to use the \
|
"necessary this SDK can be installed directly from Microsoft but this approach is not "
|
||||||
MSVC compiler on Windows."
|
"recommended unless you know what you're doing or if you're on Windows 11 you have no "
|
||||||
"If absolutely neccesary this SDK can be installed directly from Microsoft\
|
"choice for the moment."
|
||||||
but this approach is not recommended unless you know what you're doing \
|
|
||||||
or if you're on Windows 11 you have no choice for the moment."
|
|
||||||
)
|
)
|
||||||
|
@ -33,9 +33,6 @@ def autoreconf(self, spec, prefix):
|
|||||||
bash = which("bash")
|
bash = which("bash")
|
||||||
bash(
|
bash(
|
||||||
"-c",
|
"-c",
|
||||||
"aclocal && autoreconf --install \
|
"aclocal && autoreconf --install && libtoolize && autoconf && "
|
||||||
&& libtoolize \
|
"automake --add-missing && automake",
|
||||||
&& autoconf \
|
|
||||||
&& automake --add-missing \
|
|
||||||
&& automake",
|
|
||||||
)
|
)
|
||||||
|
Loading…
Reference in New Issue
Block a user