summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoreugeneswalker <38933153+eugeneswalker@users.noreply.github.com>2023-07-24 12:56:32 -0700
committerGitHub <noreply@github.com>2023-07-24 12:56:32 -0700
commitfde1954c137aa50525bd1facc72c06cf38ef06ed (patch)
tree9e31196ec389225d7adacc9df3d0e4eca2fe9704
parent3ad65bbfc12fa83c0ae376da35eca2b97128a0af (diff)
downloadspack-fde1954c137aa50525bd1facc72c06cf38ef06ed.tar.gz
spack-fde1954c137aa50525bd1facc72c06cf38ef06ed.tar.bz2
spack-fde1954c137aa50525bd1facc72c06cf38ef06ed.tar.xz
spack-fde1954c137aa50525bd1facc72c06cf38ef06ed.zip
mvapich2@2.3.7-1: add torque patch (#39027)
-rw-r--r--var/spack/repos/builtin/packages/mvapich2/fix-torque.patch27
-rw-r--r--var/spack/repos/builtin/packages/mvapich2/package.py3
2 files changed, 30 insertions, 0 deletions
diff --git a/var/spack/repos/builtin/packages/mvapich2/fix-torque.patch b/var/spack/repos/builtin/packages/mvapich2/fix-torque.patch
new file mode 100644
index 0000000000..0f12f1931e
--- /dev/null
+++ b/var/spack/repos/builtin/packages/mvapich2/fix-torque.patch
@@ -0,0 +1,27 @@
+diff -ruN spack-src/src/pm/hydra/configure.ac spack-src-patched/src/pm/hydra/configure.ac
+--- spack-src/src/pm/hydra/configure.ac 2022-05-16 16:58:22.000000000 +0000
++++ spack-src-patched/src/pm/hydra/configure.ac 2023-07-20 15:23:21.802299913 +0000
+@@ -306,15 +306,16 @@
+ available_launchers="$available_launchers pbs"
+ PAC_APPEND_FLAG([-ltorque],[WRAPPER_LIBS])
+ fi
+- PAC_SET_HEADER_LIB_PATH(pbs)
+ PAC_PUSH_FLAG(LIBS)
+- PAC_CHECK_HEADER_LIB(tm.h, pbs, tm_init, have_pbs_launcher=yes,
++ if test "have_pbs_launcher" = "no" ; then
++ PAC_CHECK_HEADER_LIB(tm.h, pbs, tm_init, have_pbs_launcher=yes,
+ have_pbs_launcher=no)
+- PAC_POP_FLAG(LIBS)
+- if test "$have_pbs_launcher" = "yes" ; then
+- available_launchers="$available_launchers pbs"
+- PAC_APPEND_FLAG([-lpbs],[WRAPPER_LIBS])
+- AC_DEFINE(HAVE_PBS_PRO, 1, [Define if PBS Pro support is enabled])
++ PAC_POP_FLAG(LIBS)
++ if test "$have_pbs_launcher" = "yes" ; then
++ available_launchers="$available_launchers pbs"
++ PAC_APPEND_FLAG([-lpbs],[WRAPPER_LIBS])
++ AC_DEFINE(HAVE_PBS_PRO, 1, [Define if PBS Pro support is enabled])
++ fi
+ fi
+ available_rmks="$available_rmks pbs"
+ ;;
diff --git a/var/spack/repos/builtin/packages/mvapich2/package.py b/var/spack/repos/builtin/packages/mvapich2/package.py
index 0bcd81ec9a..6b7181a88d 100644
--- a/var/spack/repos/builtin/packages/mvapich2/package.py
+++ b/var/spack/repos/builtin/packages/mvapich2/package.py
@@ -117,6 +117,7 @@ class Mvapich2(AutotoolsPackage):
values=auto_or_any_combination_of("lustre", "gpfs", "nfs", "ufs"),
)
+ depends_on("automake@1.15", type="build") # needed for torque patch
depends_on("findutils", type="build")
depends_on("bison", type="build")
depends_on("pkgconfig", type="build")
@@ -139,6 +140,8 @@ class Mvapich2(AutotoolsPackage):
conflicts("fabrics=psm2", when="@:2.1") # psm2 support was added at version 2.2
+ patch("fix-torque.patch", when="@2.3.7-1")
+
filter_compiler_wrappers("mpicc", "mpicxx", "mpif77", "mpif90", "mpifort", relative_root="bin")
@classmethod