--- src5.1.3/MED_SRC_5.1.3/adm_local/unix/config_files/check_scotch.m4.orig 2009-09-27 23:07:31.245061430 +0200 +++ src5.1.3/MED_SRC_5.1.3/adm_local/unix/config_files/check_scotch.m4 2009-09-27 23:11:02.080868671 +0200 @@ -28,6 +28,10 @@ SCOTCH_CPPFLAGS="" SCOTCH_LIBSUFFIX="" +case "$build_cpu" in +x86_64*) SCOTCH_LIBSUFFIX="64" ;; +*) SCOTCH_LIBSUFFIX="" ;; +esac SCOTCH_LIBS="" ENABLE_SCOTCH="no" @@ -43,8 +47,8 @@ LIBS_old=$LIBS if test "x${SCOTCHDIR}" != "x" ; then - SCOTCH_CPPFLAGS="-DENABLE_SCOTCH -I${SCOTCHDIR}" - SCOTCH_LIBS="-L${SCOTCHDIR}/bin -lscotch -lscotcherr" + SCOTCH_CPPFLAGS="-DENABLE_SCOTCH -I${SCOTCHDIR}/include/scotch" + SCOTCH_LIBS="-L${SCOTCHDIR}/lib${SCOTCH_LIBSUFFIX} -lscotch -lscotcherr" fi scotch_ok=no @@ -57,14 +61,14 @@ scotch_include_dir_ok=yes if test "x${SCOTCHDIR}" != "x" ; then - AC_CHECK_FILE(${SCOTCHDIR}/bin/scotch.h, + AC_CHECK_FILE(${SCOTCHDIR}/include/scotch/scotch.h, scotch_include_dir_ok=yes, scotch_include_dir_ok=no) fi if test "x${scotch_include_dir_ok}" = "xyes" ; then AC_TRY_COMPILE([#include - #include ], + #include ], [SCOTCH_Graph* graph; SCOTCH_graphInit(graph)], scotch_headers_ok=yes, @@ -83,12 +87,12 @@ AC_CHECKING(for SCOTCH binaries) scotch_lib_dir_ok=yes if test "x${SCOTCHDIR}" != "x" ; then - AC_CHECK_FILE(${SCOTCHDIR}/bin/libscotch.a, + AC_CHECK_FILE(${SCOTCHDIR}/lib${SCOTCH_LIBSUFFIX}/libscotch.a, scotch_lib_dir_ok=yes, scotch_lib_dir_ok=no) if test "x${scotch_lib_dir_ok}" = "xno" ; then SCOTCH_LIBSUFFIX="" - AC_CHECK_FILE(${SCOTCHDIR}/bin/libscotch.a, + AC_CHECK_FILE(${SCOTCHDIR}/lib${SCOTCH_LIBSUFFIX}/libscotch.a, scotch_lib_dir_ok=yes, scotch_lib_dir_ok=no) fi @@ -96,7 +100,7 @@ if test "x${scotch_lib_dir_ok}" = "xyes" ; then LIBS="${LIBS_old} ${SCOTCH_LIBS}" AC_TRY_LINK([#include - #include ], + #include ], [SCOTCH_Graph* graph; SCOTCH_graphInit(graph)], scotch_binaries_ok=yes, @@ -105,7 +109,7 @@ SCOTCH_LIBSUFFIX="" LIBS="${LIBS_old} ${SCOTCH_LIBS} " AC_TRY_LINK([#include - #include ], + #include ], [SCOTCH_Graph* graph; SCOTCH_graphInit(graph)], scotch_binaries_ok=yes,