Skip to content

Commit

Permalink
Add check for infiniband/iba/ib_types.h header (#692)
Browse files Browse the repository at this point in the history
Resolves #691
  • Loading branch information
morrone authored Apr 16, 2021
1 parent 0ac7b62 commit 7607df1
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
8 changes: 8 additions & 0 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -387,9 +387,17 @@ AS_IF([test "x$enable_infiniband" != xno],[
AS_IF([test "x$HAVE_LIBIBUMAD" = xno],
[AC_MSG_ERROR([libibumad or <infiniband/umad.h> not found])])
])
CPPFLAGS_BACKUP=$CPPFLAGS
CPPFLAGS="$CPPFLAGS -I/usr/include/infiniband"
AC_CHECK_HEADERS([iba/ib_types.h], [], [
AS_IF([test "x$enable_infiniband" != xcheck],
[AC_MSG_ERROR([Header <infiniband/iba/ib_types.h> not found ])])
])
CPPFLAGS=$CPPFLAGS_BACKUP
])
AM_CONDITIONAL([HAVE_LIBIBMAD], [test "x$HAVE_LIBIBMAD" = xyes])
AM_CONDITIONAL([HAVE_LIBIBUMAD], [test "x$HAVE_LIBIBUMAD" = xyes])
AM_CONDITIONAL([HAVE_IBA_IB_TYPES_H], [test "x$ac_cv_header_iba_ib_types_h" = xyes])

# enable tx2mon by default only when sensible.
AC_ARG_ENABLE([tx2mon],
Expand Down
2 changes: 2 additions & 0 deletions ldms/src/sampler/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -251,7 +251,9 @@ endif

if HAVE_LIBIBMAD
if HAVE_LIBIBUMAD
if HAVE_IBA_IB_TYPES_H
SUBDIRS += ibmad
endif

libsysclassib_la_SOURCES = sysclassib.c
libsysclassib_la_LIBADD = $(COMMON_LIBADD) $(LTLIBIBMAD) $(LTLIBIBUMAD)
Expand Down

0 comments on commit 7607df1

Please sign in to comment.