Index: /issm/trunk/configure
===================================================================
--- /issm/trunk/configure	(revision 1072)
+++ /issm/trunk/configure	(revision 1073)
@@ -609,4 +609,6 @@
 PLAPACKLIB
 PLAPACKINCL
+MKLINCL
+MKLLIB
 BLASLAPACKINCL
 BLASLAPACKLIB
@@ -620,4 +622,6 @@
 METISLIB
 METISINCL
+DAKOTALIB
+DAKOTAINCL
 TRIANGLELIB
 TRIANGLEINCL
@@ -752,4 +756,5 @@
 with_matlab_dir
 with_triangle_dir
+with_dakota_dir
 with_metis_dir
 with_mpi_lib
@@ -760,4 +765,5 @@
 with_scalapack_dir
 with_blas_lapack_dir
+with_mkl_dir
 with_plapack_dir
 with_mumps_dir
@@ -1428,4 +1434,5 @@
   --with-triangle-dir = DIR
                           triangle root directory. necessary for serial build
+  --with-dakota-dir = DIR dakota root directory. necessary for serial build
   --with-metis-dir = DIR  metis root directory. necessary for serial build
   --with-mpi-lib = otions mpi options, for ex: "-L$MPIROOT -lmpich
@@ -1439,4 +1446,5 @@
   --with-blas-lapack-dir = DIR
                           blas-lapack root directory
+  --with-mkl-dir = DIR    mkl root directory
   --with-plapack-dir = DIR
                           plapack root directory
@@ -6909,4 +6917,36 @@
 
 
+# Check whether --with-dakota-dir was given.
+if test "${with_dakota_dir+set}" = set; then
+  withval=$with_dakota_dir; DAKOTA_ROOT=$withval
+else
+  DAKOTA_ROOT=""
+fi
+
+	{ $as_echo "$as_me:$LINENO: checking for Dakota " >&5
+$as_echo_n "checking for Dakota ... " >&6; }
+
+	if test -d "$DAKOTA_ROOT"; then
+
+				HAVE_DAKOTA=yes
+		DAKOTAINCL=-I$DAKOTA_ROOT/include
+		DAKOTALIB="-L$DAKOTA_ROOT/lib -ldakota -lteuchos -lpecos -lfftw3 -llhs  -levidence -lsurfpack -lconmin -lddace -lfsudace    -ljega -lcport -lopt -lpsuade -lnewmat    -lncsuopt -lgsl -lquadrature -lcoliny -lcolin -lpebbl     -lutilib -l3po -lnappspack -lappspack -lconveyor -lshared -lcdd -lamplsolver "
+
+
+
+cat >>confdefs.h <<\_ACEOF
+#define _HAVE_DAKOTA_ 1
+_ACEOF
+
+
+
+
+	else
+		HAVE_DAKOTA=no
+	fi
+	{ $as_echo "$as_me:$LINENO: result: $HAVE_DAKOTA" >&5
+$as_echo "$HAVE_DAKOTA" >&6; }
+
+
 
 # Check whether --with-metis-dir was given.
@@ -6969,6 +7009,6 @@
 		if test -z "$MPILIB" ; then
 		if test "$PARALLEL_VALUE" = "yes" ; then
-			{ { $as_echo "$as_me:$LINENO: error: empty --with-mpi-lib options! MPI is needed to run ISSM in paralle!" >&5
-$as_echo "$as_me: error: empty --with-mpi-lib options! MPI is needed to run ISSM in paralle!" >&2;}
+			{ { $as_echo "$as_me:$LINENO: error: empty --with-mpi-lib options! MPI is needed to run ISSM in parallel!" >&5
+$as_echo "$as_me: error: empty --with-mpi-lib options! MPI is needed to run ISSM in parallel!" >&2;}
    { (exit 1); exit 1; }; }
 		fi
@@ -6976,6 +7016,6 @@
 		if test -z "$MPI_INCLUDE" ; then
 			if test "$PARALLEL_VALUE" = "yes" ; then
-				{ { $as_echo "$as_me:$LINENO: error: empty --with-mpi-include directory! MPI is needed to run ISSM in paralle!" >&5
-$as_echo "$as_me: error: empty --with-mpi-include directory! MPI is needed to run ISSM in paralle!" >&2;}
+				{ { $as_echo "$as_me:$LINENO: error: empty --with-mpi-include directory! MPI is needed to run ISSM in parallel!" >&5
+$as_echo "$as_me: error: empty --with-mpi-include directory! MPI is needed to run ISSM in parallel!" >&2;}
    { (exit 1); exit 1; }; }
 			fi
@@ -6987,4 +7027,9 @@
 cat >>confdefs.h <<\_ACEOF
 #define _HAVE_MPI_ 1
+_ACEOF
+
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_MPI 1
 _ACEOF
 
@@ -7060,6 +7105,6 @@
 	if test $HAVE_PETSC = no; then
 		if test "$PARALLEL_VALUE" = "yes" ; then
-			{ { $as_echo "$as_me:$LINENO: error: could not find petsc. user should specify --with-petsc-dir and --with-petsc-arch options. Petsc is needed to run ISSM in paralle!" >&5
-$as_echo "$as_me: error: could not find petsc. user should specify --with-petsc-dir and --with-petsc-arch options. Petsc is needed to run ISSM in paralle!" >&2;}
+			{ { $as_echo "$as_me:$LINENO: error: could not find petsc. user should specify --with-petsc-dir and --with-petsc-arch options. Petsc is needed to run ISSM in parallel!" >&5
+$as_echo "$as_me: error: could not find petsc. user should specify --with-petsc-dir and --with-petsc-arch options. Petsc is needed to run ISSM in parallel!" >&2;}
    { (exit 1); exit 1; }; }
 		fi
@@ -7146,5 +7191,5 @@
 				HAVE_BLASLAPACK=yes
 		BLASLAPACKINCL=""
-		BLASLAPACKLIB=-L"$BLASLAPACK_ROOT -lmkl_lapack -lmkl -lguide"
+				BLASLAPACKLIB=-L"$BLASLAPACK_ROOT -lfblas -lflapack"
 
 
@@ -7161,4 +7206,33 @@
 $as_echo "$HAVE_BLASLAPACK" >&6; }
 
+
+# Check whether --with-mkl-dir was given.
+if test "${with_mkl_dir+set}" = set; then
+  withval=$with_mkl_dir; MKL_ROOT=$withval
+else
+  MKL_ROOT=""
+fi
+
+
+	{ $as_echo "$as_me:$LINENO: checking for mkl headers and libraries in $MKL_ROOT" >&5
+$as_echo_n "checking for mkl headers and libraries in $MKL_ROOT... " >&6; }
+	if test -d "$MKL_ROOT"; then
+
+				HAVE_MKL=yes
+		MKLINCL=""
+		MKLLIB=-L"$MKL_ROOT -lmkl_lapack -lmkl -lguide"
+
+
+cat >>confdefs.h <<\_ACEOF
+#define _HAVE_MKL_ 1
+_ACEOF
+
+
+
+	else
+		HAVE_MKL=no
+	fi
+	{ $as_echo "$as_me:$LINENO: result: $HAVE_MKL" >&5
+$as_echo "$HAVE_MKL" >&6; }
 
 
