2013-07-19 22:13:58 +00:00
|
|
|
# -*- shell-script -*-
|
|
|
|
#
|
|
|
|
# Copyright (c) 2004-2005 The Trustees of Indiana University and Indiana
|
|
|
|
# University Research and Technology
|
|
|
|
# Corporation. All rights reserved.
|
|
|
|
# Copyright (c) 2004-2005 The University of Tennessee and The University
|
|
|
|
# of Tennessee Research Foundation. All rights
|
|
|
|
# reserved.
|
|
|
|
# Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
|
|
|
|
# University of Stuttgart. All rights reserved.
|
|
|
|
# Copyright (c) 2004-2005 The Regents of the University of California.
|
|
|
|
# All rights reserved.
|
|
|
|
# Copyright (c) 2006 Sandia National Laboratories. All rights
|
|
|
|
# reserved.
|
2014-01-09 22:17:01 +00:00
|
|
|
# Copyright (c) 2010-2014 Cisco Systems, Inc. All rights reserved.
|
2013-07-19 22:13:58 +00:00
|
|
|
# $COPYRIGHT$
|
|
|
|
#
|
|
|
|
# Additional copyrights may follow
|
|
|
|
#
|
|
|
|
# $HEADER$
|
|
|
|
#
|
|
|
|
|
|
|
|
|
|
|
|
# MCA_btl_usnic_CONFIG([action-if-can-compile],
|
|
|
|
# [action-if-cant-compile])
|
|
|
|
# ------------------------------------------------
|
|
|
|
AC_DEFUN([MCA_ompi_btl_usnic_CONFIG],[
|
|
|
|
AC_CONFIG_FILES([ompi/mca/btl/usnic/Makefile])
|
|
|
|
|
|
|
|
OMPI_CHECK_OPENFABRICS([btl_usnic],
|
|
|
|
[btl_usnic_happy="yes"],
|
|
|
|
[btl_usnic_happy="no"])
|
|
|
|
|
2014-01-09 22:17:01 +00:00
|
|
|
# We only want to build on 64 bit Linux.
|
2013-07-19 22:13:58 +00:00
|
|
|
AS_IF([test "$btl_usnic_happy" = "yes"],
|
2014-01-09 22:17:01 +00:00
|
|
|
[AC_CHECK_SIZEOF([void *])
|
|
|
|
AC_MSG_CHECKING([for 64 bit Linux])
|
|
|
|
case $host_os in
|
|
|
|
*linux*)
|
|
|
|
AS_IF([test $ac_cv_sizeof_void_p -eq 8],
|
2013-07-19 22:13:58 +00:00
|
|
|
[btl_usnic_happy=yes],
|
|
|
|
[btl_usnic_happy=no])
|
2014-01-09 22:17:01 +00:00
|
|
|
;;
|
|
|
|
*)
|
|
|
|
btl_usnic_happy=no
|
|
|
|
;;
|
|
|
|
esac
|
|
|
|
AC_MSG_RESULT([$btl_usnic_happy])
|
|
|
|
]
|
|
|
|
)
|
2013-07-19 22:13:58 +00:00
|
|
|
|
|
|
|
# Do we have the IBV_TRANSPORT_USNIC / IBV_NODE_USNIC defines?
|
|
|
|
# (note: if we have one, we have both)
|
|
|
|
btl_usnic_have_ibv_usnic=0
|
|
|
|
btl_usnic_have_ibv_event_gid_change=0
|
|
|
|
AS_IF([test "$btl_usnic_happy" = "yes"],
|
|
|
|
[AC_CHECK_DECL([IBV_NODE_USNIC],
|
|
|
|
[btl_usnic_have_ibv_usnic=1],
|
|
|
|
[],
|
|
|
|
[ #include <infiniband/verbs.h>
|
|
|
|
])
|
|
|
|
|
|
|
|
AC_CHECK_DECL([IBV_EVENT_GID_CHANGE],
|
|
|
|
[btl_usnic_have_ibv_event_gid_change=1],
|
|
|
|
[],
|
|
|
|
[ #include <infiniband/verbs.h>
|
|
|
|
])
|
|
|
|
]
|
|
|
|
)
|
|
|
|
AC_DEFINE_UNQUOTED([BTL_USNIC_HAVE_IBV_USNIC],
|
|
|
|
[$btl_usnic_have_ibv_usnic],
|
|
|
|
[Whether we have IBV_NODE_USNIC / IBV_TRANSPORT_USNIC or not])
|
|
|
|
AC_DEFINE_UNQUOTED([BTL_USNIC_HAVE_IBV_EVENT_GID_CHANGE],
|
|
|
|
[$btl_usnic_have_ibv_event_gid_change],
|
|
|
|
[Whether we have IBV_EVENT_GID_CHANGE or not])
|
|
|
|
|
|
|
|
AS_IF([test "$btl_usnic_happy" = "yes"],
|
|
|
|
[btl_usnic_WRAPPER_EXTRA_LDFLAGS="$btl_usnic_LDFLAGS"
|
|
|
|
btl_usnic_WRAPPER_EXTRA_LIBS="$btl_usnic_LIBS"
|
|
|
|
$1],
|
|
|
|
[$2])
|
|
|
|
|
|
|
|
# Substitute in the things needed to build USNIC
|
|
|
|
AC_SUBST([btl_usnic_CPPFLAGS])
|
2013-11-04 22:51:35 +00:00
|
|
|
AC_SUBST([btl_usnic_CFLAGS])
|
2013-07-19 22:13:58 +00:00
|
|
|
AC_SUBST([btl_usnic_LDFLAGS])
|
|
|
|
AC_SUBST([btl_usnic_LIBS])
|
|
|
|
])dnl
|