17
17
# and Technology (RIST). All rights reserved.
18
18
# Copyright (c) 2016 Los Alamos National Security, LLC. All rights
19
19
# reserved.
20
+ # Copyright (c) 2021 Triad National Security, LLC. All rights
21
+ # reserved.
22
+ #
20
23
# $COPYRIGHT$
21
24
#
22
25
# Additional copyrights may follow
@@ -65,10 +68,6 @@ AC_DEFUN([OMPI_CHECK_PSM2],[
65
68
[ompi_check_psm2_happy= " no" ])],
66
69
[ompi_check_psm2_happy= " no" ])
67
70
68
- CPPFLAGS=" $ompi_check_psm2_ $1 _save_CPPFLAGS"
69
- LDFLAGS=" $ompi_check_psm2_ $1 _save_LDFLAGS"
70
- LIBS=" $ompi_check_psm2_ $1 _save_LIBS"
71
-
72
71
AS_IF([test " $ompi_check_psm2_happy " = " yes" && test " $enable_progress_threads " = " yes" ],
73
72
[AC_MSG_WARN([PSM2 driver does not currently support progress threads. Disabling MTL.])
74
73
ompi_check_psm2_happy= " no" ])
@@ -81,15 +80,21 @@ AC_DEFUN([OMPI_CHECK_PSM2],[
81
80
ompi_check_psm2_happy= " no" ])])
82
81
83
82
AS_IF([test " $ompi_check_psm2_happy " = " yes" ],
84
- [AC_CHECK_DECL([PSM2_LIB_REFCOUNT_CAP],
83
+ [AS_IF([ test ! -z " $ompi_check_psm2_dir " ],
84
+ [CPPFLAGS= " -I $ompi_check_psm2_dir /include $CPPFLAGS " ])
85
+ AC_CHECK_DECL([PSM2_LIB_REFCOUNT_CAP],
85
86
[AC_DEFINE([HAVE_PSM2_LIB_REFCOUNT_CAP], [1],
86
87
[have PSM2_LIB_REFCOUNT_CAP in psm2.h])],
87
88
[AS_IF([test " x$enable_psm2_version_check " != " xno" ],
88
89
[ompi_check_psm2_happy= " no"
89
90
AC_MSG_WARN([PSM2 needs to be version 11.2.173 or later. Disabling MTL.])]
90
91
)],
91
- [# include <psm2.h>])
92
- ])
92
+ [# include <psm2.h>])]
93
+ )
94
+
95
+ CPPFLAGS= " $ompi_check_psm2_ $1 _save_CPPFLAGS"
96
+ LDFLAGS= " $ompi_check_psm2_ $1 _save_LDFLAGS"
97
+ LIBS= " $ompi_check_psm2_ $1 _save_LIBS"
93
98
94
99
OPAL_SUMMARY_ADD([[Transports]],[[Intel Omnipath (PSM2)]],[$1 ],[$ompi_check_psm2_happy ])
95
100
fi
0 commit comments