GXX_BRAND
ac_ct_CXX
CXXFLAGS
-CXX
OBJEXT
EXEEXT
ac_ct_CC
LDFLAGS
CFLAGS
CC
+CXX
target_os
target_vendor
target_cpu
$as_echo "yes" >&6; }
if test "x$CXX" = "x" ; then
+ for ac_prog in mpic++ mpicxx mpiCC
+do
+ # Extract the first word of "$ac_prog", so it can be a program name with args.
+set dummy $ac_prog; ac_word=$2
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
+if ${ac_cv_prog_CXX+:} false; then :
+ $as_echo_n "(cached) " >&6
+else
+ if test -n "$CXX"; then
+ ac_cv_prog_CXX="$CXX" # Let the user override the test.
+else
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+ IFS=$as_save_IFS
+ test -z "$as_dir" && as_dir=.
+ for ac_exec_ext in '' $ac_executable_extensions; do
+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ ac_cv_prog_CXX="$ac_prog"
+ $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+ break 2
+ fi
+done
+ done
+IFS=$as_save_IFS
+
+fi
+fi
+CXX=$ac_cv_prog_CXX
+if test -n "$CXX"; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
+$as_echo "$CXX" >&6; }
+else
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+fi
+
+
+ test -n "$CXX" && break
+done
+
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for MPI C++ compiler" >&5
$as_echo_n "checking for MPI C++ compiler... " >&6; }
- if ((which mpiCC 2>&1) > /dev/null) ; then
- CXX=mpiCC ;
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: mpiCC" >&5
-$as_echo "mpiCC" >&6; }
+ if test "x$CXX" = "x" ; then
+ as_fn_error $? "none found" "$LINENO" 5
else
- if ((which mpicxx 2>&1) > /dev/null) ; then
- CXX=mpicxx ;
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: mpicxx" >&5
-$as_echo "mpicxx" >&6; }
- else
- as_fn_error $? "no MPI C++ compiler found" "$LINENO" 5
- fi
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
+$as_echo "$CXX" >&6; }
fi
fi
dnl See if the user has specified --enable-mpi. If so, and if $CXX and $CC have
-dnl not been set to a particular value, then override them with 'mpiCC' and
-dnl 'mpicc'. The latter should always work, but sometimes the former is
-dnl called 'mpicxx' instead :-(
+dnl not been set to a particular value, then override them.
+dnl
+dnl While for the C compiler the issue is simple (it should be 'mpicc', the
+dnl issue is not quite as trivial for the C++ compiler: 'mpiCC' should in
+dnl principle work, but we've seen systems where that refers to the C
+dnl compiler, so try 'mpic++' and 'mpicxx' first as these should really
+dnl be unambiguous names although they may not be available on all systems.
AC_ARG_ENABLE(mpi,
AS_HELP_STRING([--enable-mpi],
[Select MPI-enabled compilers and MPI support in deal.II.]),
AC_MSG_RESULT(yes)
if test "x$CXX" = "x" ; then
+ AC_CHECK_PROGS(CXX,[mpic++ mpicxx mpiCC])
AC_MSG_CHECKING(for MPI C++ compiler)
- if ((which mpiCC 2>&1) > /dev/null) ; then
- CXX=mpiCC ;
- AC_MSG_RESULT(mpiCC)
+ if test "x$CXX" = "x" ; then
+ AC_MSG_ERROR(none found)
else
- if ((which mpicxx 2>&1) > /dev/null) ; then
- CXX=mpicxx ;
- AC_MSG_RESULT(mpicxx)
- else
- AC_MSG_ERROR(no MPI C++ compiler found)
- fi
+ AC_MSG_RESULT([$CXX])
fi
fi
<h3>General</h3>
<ol>
+<li> Fixed: On some systems, <code>mpiCC</code> turns out to alias the
+C compiler, not the C++ compiler as expected. Consequently, try to use
+<code>mpic++</code> or <code>mpicxx</code> before <code>mpiCC</code> as
+these should really be unambiguous.
+<br>
+(Wolfgang Bangerth, 2011/11/05)
+
<li> Fixed: Intel's ICC compiler identifies itself as <code>icpc version
12.1.0 (gcc version 4.2.1 compatibility)</code> which we mistook as being
GCC version 4.2. This is now fixed.