fixes for OpenMP.
This commit is contained in:
parent
7fc23ea139
commit
fa9842083b
18
config.h.in
18
config.h.in
@ -22,25 +22,11 @@
|
|||||||
|
|
||||||
/* What MPI libraries are there? */
|
/* What MPI libraries are there? */
|
||||||
#define HAVE_LIBMPI 0
|
#define HAVE_LIBMPI 0
|
||||||
#define HAVE_LIBMPICH 0
|
#define HAVE_LIBMPICH
|
||||||
|
|
||||||
/* Should we use MPI ? */
|
|
||||||
#if HAVE_LIBMPI || HAVE_LIBMPICH
|
|
||||||
#define HAVE_MPI 1
|
|
||||||
#else
|
|
||||||
#define HAVE_MPI 0
|
|
||||||
#endif
|
|
||||||
|
|
||||||
/* Is there an MPE library? */
|
/* Is there an MPE library? */
|
||||||
#define HAVE_LIBMPE 0
|
#define HAVE_LIBMPE 0
|
||||||
|
|
||||||
/* Should we use MPE ? */
|
|
||||||
#if HAVE_LIBMPE && HAVE_MPI
|
|
||||||
#define HAVE_MPE 1
|
|
||||||
#else
|
|
||||||
#define HAVE_MPE 0
|
|
||||||
#endif
|
|
||||||
|
|
||||||
/* does the compiler support inline ? */
|
/* does the compiler support inline ? */
|
||||||
#undef inline
|
#undef inline
|
||||||
|
|
||||||
@ -325,7 +311,7 @@
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* Should we use MPI ? */
|
/* Should we use MPI ? */
|
||||||
#if defined(HAVE_MPI_H) && (HAVE_LIBMPI || HAVE_LIBMPICH)
|
#if defined(HAVE_MPI_H) && (defined(HAVE_LIBMPI) || defined(HAVE_LIBMPICH))
|
||||||
#define HAVE_MPI 1
|
#define HAVE_MPI 1
|
||||||
#else
|
#else
|
||||||
#define HAVE_MPI 0
|
#define HAVE_MPI 0
|
||||||
|
84
configure
vendored
84
configure
vendored
@ -4793,6 +4793,10 @@ fi
|
|||||||
# Check whether --with-mpi was given.
|
# Check whether --with-mpi was given.
|
||||||
if test "${with_mpi+set}" = set; then :
|
if test "${with_mpi+set}" = set; then :
|
||||||
withval=$with_mpi; if test "$withval" = yes; then
|
withval=$with_mpi; if test "$withval" = yes; then
|
||||||
|
if test -e /usr/lib/openmpi; then
|
||||||
|
CPPFLAGS="$CPPFLAGS -I/usr/openmpi/include"
|
||||||
|
LDFLAGS="$LDFLAGS -L/usr/openmpi/lib"
|
||||||
|
fi
|
||||||
yap_cv_mpi=yes
|
yap_cv_mpi=yes
|
||||||
elif test "$withval" = no; then
|
elif test "$withval" = no; then
|
||||||
yap_cv_mpi=no
|
yap_cv_mpi=no
|
||||||
@ -6937,6 +6941,46 @@ fi
|
|||||||
CC=${OLD_CC}
|
CC=${OLD_CC}
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
OLD_CC=${CC}
|
||||||
|
CC=${LAM_MPI_CC}
|
||||||
|
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -llam" >&5
|
||||||
|
$as_echo_n "checking for main in -llam... " >&6; }
|
||||||
|
if ${ac_cv_lib_lam_main+:} false; then :
|
||||||
|
$as_echo_n "(cached) " >&6
|
||||||
|
else
|
||||||
|
ac_check_lib_save_LIBS=$LIBS
|
||||||
|
LIBS="-llam $LIBS"
|
||||||
|
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
|
||||||
|
/* end confdefs.h. */
|
||||||
|
|
||||||
|
|
||||||
|
int
|
||||||
|
main ()
|
||||||
|
{
|
||||||
|
return main ();
|
||||||
|
;
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
_ACEOF
|
||||||
|
if ac_fn_c_try_link "$LINENO"; then :
|
||||||
|
ac_cv_lib_lam_main=yes
|
||||||
|
else
|
||||||
|
ac_cv_lib_lam_main=no
|
||||||
|
fi
|
||||||
|
rm -f core conftest.err conftest.$ac_objext \
|
||||||
|
conftest$ac_exeext conftest.$ac_ext
|
||||||
|
LIBS=$ac_check_lib_save_LIBS
|
||||||
|
fi
|
||||||
|
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lam_main" >&5
|
||||||
|
$as_echo "$ac_cv_lib_lam_main" >&6; }
|
||||||
|
if test "x$ac_cv_lib_lam_main" = xyes; then :
|
||||||
|
LAMOBJS=yap_mpi."$SO"
|
||||||
|
else
|
||||||
|
LAMOBJS=no
|
||||||
|
fi
|
||||||
|
|
||||||
|
CC=${OLD_CC}
|
||||||
|
|
||||||
ac_ext=c
|
ac_ext=c
|
||||||
ac_cpp='$CPP $CPPFLAGS'
|
ac_cpp='$CPP $CPPFLAGS'
|
||||||
ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
|
ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
|
||||||
@ -7881,46 +7925,6 @@ fi
|
|||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
OLD_CC=${CC}
|
|
||||||
CC=${LAM_MPI_CC}
|
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -llam" >&5
|
|
||||||
$as_echo_n "checking for main in -llam... " >&6; }
|
|
||||||
if ${ac_cv_lib_lam_main+:} false; then :
|
|
||||||
$as_echo_n "(cached) " >&6
|
|
||||||
else
|
|
||||||
ac_check_lib_save_LIBS=$LIBS
|
|
||||||
LIBS="-llam $LIBS"
|
|
||||||
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
|
|
||||||
/* end confdefs.h. */
|
|
||||||
|
|
||||||
|
|
||||||
int
|
|
||||||
main ()
|
|
||||||
{
|
|
||||||
return main ();
|
|
||||||
;
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
_ACEOF
|
|
||||||
if ac_fn_c_try_link "$LINENO"; then :
|
|
||||||
ac_cv_lib_lam_main=yes
|
|
||||||
else
|
|
||||||
ac_cv_lib_lam_main=no
|
|
||||||
fi
|
|
||||||
rm -f core conftest.err conftest.$ac_objext \
|
|
||||||
conftest$ac_exeext conftest.$ac_ext
|
|
||||||
LIBS=$ac_check_lib_save_LIBS
|
|
||||||
fi
|
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lam_main" >&5
|
|
||||||
$as_echo "$ac_cv_lib_lam_main" >&6; }
|
|
||||||
if test "x$ac_cv_lib_lam_main" = xyes; then :
|
|
||||||
LAMOBJS=yap_mpi."$SO"
|
|
||||||
else
|
|
||||||
LAMOBJS=no
|
|
||||||
fi
|
|
||||||
|
|
||||||
CC=${OLD_CC}
|
|
||||||
|
|
||||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
|
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
|
||||||
$as_echo_n "checking for ANSI C header files... " >&6; }
|
$as_echo_n "checking for ANSI C header files... " >&6; }
|
||||||
if ${ac_cv_header_stdc+:} false; then :
|
if ${ac_cv_header_stdc+:} false; then :
|
||||||
|
21
configure.in
21
configure.in
@ -356,6 +356,11 @@ AC_ARG_WITH(matlab,
|
|||||||
AC_ARG_WITH(mpi,
|
AC_ARG_WITH(mpi,
|
||||||
[ --with-mpi[=DIR] use MPI library in DIR],
|
[ --with-mpi[=DIR] use MPI library in DIR],
|
||||||
if test "$withval" = yes; then
|
if test "$withval" = yes; then
|
||||||
|
dnl handle UBUNTU systems
|
||||||
|
if test -e /usr/lib/openmpi; then
|
||||||
|
CPPFLAGS="$CPPFLAGS -I/usr/openmpi/include"
|
||||||
|
LDFLAGS="$LDFLAGS -L/usr/openmpi/lib"
|
||||||
|
fi
|
||||||
yap_cv_mpi=yes
|
yap_cv_mpi=yes
|
||||||
elif test "$withval" = no; then
|
elif test "$withval" = no; then
|
||||||
yap_cv_mpi=no
|
yap_cv_mpi=no
|
||||||
@ -1067,6 +1072,14 @@ then
|
|||||||
CC=${OLD_CC}
|
CC=${OLD_CC}
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
dnl LAM
|
||||||
|
OLD_CC=${CC}
|
||||||
|
CC=${LAM_MPI_CC}
|
||||||
|
AC_CHECK_LIB([lam], [main],
|
||||||
|
LAMOBJS=yap_mpi."$SO",
|
||||||
|
LAMOBJS=no)
|
||||||
|
CC=${OLD_CC}
|
||||||
|
|
||||||
AC_PROG_CPP
|
AC_PROG_CPP
|
||||||
|
|
||||||
if test "$cross_compiling" = "yes"
|
if test "$cross_compiling" = "yes"
|
||||||
@ -1565,14 +1578,6 @@ AC_SUBST(ZLIB_INSTALL)
|
|||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
dnl LAM
|
|
||||||
OLD_CC=${CC}
|
|
||||||
CC=${LAM_MPI_CC}
|
|
||||||
AC_CHECK_LIB([lam], [main],
|
|
||||||
LAMOBJS=yap_mpi."$SO",
|
|
||||||
LAMOBJS=no)
|
|
||||||
CC=${OLD_CC}
|
|
||||||
|
|
||||||
dnl Checks for header files.
|
dnl Checks for header files.
|
||||||
AC_HEADER_STDC
|
AC_HEADER_STDC
|
||||||
AC_HEADER_SYS_WAIT
|
AC_HEADER_SYS_WAIT
|
||||||
|
Reference in New Issue
Block a user