Index: /issm/trunk-jpl/externalpackages/dakota/install-6.2-macosx64.sh
===================================================================
--- /issm/trunk-jpl/externalpackages/dakota/install-6.2-macosx64.sh	(revision 23425)
+++ /issm/trunk-jpl/externalpackages/dakota/install-6.2-macosx64.sh	(revision 23426)
@@ -22,8 +22,10 @@
 rm -rf dakota-${DAK_VER}.0.src
 
-# Set up Dakota cmake variables and config
-DAK_BUILD=$ISSM_DIR/externalpackages/dakota/build
-DAK_INSTALL=$ISSM_DIR/externalpackages/dakota/install
-DAK_SRC=$ISSM_DIR/externalpackages/dakota/src
+# Set up Dakota and CMake variables
+export DAK_PATH=$ISSM_DIR/externalpackages/dakota
+
+export DAK_BUILD=$DAK_PATH/build
+export DAK_INSTALL=$DAK_PATH/install
+export DAK_SRC=$DAK_PATH/src
 export MPIHOME=$ISSM_DIR/externalpackages/mpich/install
 export BOOST_ROOT=$ISSM_DIR/externalpackages/boost/install
@@ -38,6 +40,5 @@
 patch src/packages/pecos/src/pecos_global_defs.hpp configs/$DAK_VER/pecos_global_defs.hpp.patch
 
-# Configure dakota
-# Set your local gcc compiler here
+# Configure and build Dakota
 cd $DAK_BUILD
 cmake \
@@ -58,9 +59,4 @@
 	$DAK_SRC
 
-# Snowleopard: Mpi should be made with these compilers
-#-DCMAKE_CXX_COMPILER=/usr/bin/g++ -DCMAKE_CC_COMPILER=/usr/bin/gcc \
-#-DCMAKE_Fortran_COMPILER=/usr/local/gfortran/bin/x86_64-apple-darwin10-gfortran \
-
-#Compile and install dakota
 if [ $# -eq 0 ];
 then
@@ -71,2 +67,6 @@
 	make -j $1 install
 fi
+
+# Set paths and library paths
+export PATH=$DAK_INSTALL/bin:$DAK_INSTALL/test:$PATH
+export DYLD_LIBRARY_PATH=$DAK_INSTALL/lib:$DAK_INSTALL/bin:$DYLD_LIBRARY_PATH
Index: /issm/trunk-jpl/scripts/download_external_package.bash
===================================================================
--- /issm/trunk-jpl/scripts/download_external_package.bash	(revision 23425)
+++ /issm/trunk-jpl/scripts/download_external_package.bash	(revision 23426)
@@ -1,10 +1,16 @@
 #!/bin/bash
 #
+# download_external_package.bash
+# Generally, used to download a hosted file from a URL
+# URL - Location of file to download
+# file - File to write to (including path)
+# usage: download_external_package.bash URL file
 
 ## Constants
 #
-ERR_NO_GET_CMD="No supported file download command was found"
-ERR_NUM_ARGS="Illegal number of args"
-ERR_USAGE=""
+MSG_ERR_NO_GET_CMD="No supported file download command was found"
+MSG_USAGE="usage: $(basename ${0}) [-h] URL file
+  URL  : Location of file to download
+  file : File to write to (including path)"
 
 ## Variables
@@ -13,9 +19,11 @@
 URL=""
 
-## Check number of args
+## Check that number of args is 2 (note that this also handles case where user
+#	explicitly requests help)
 #
 if [ $# != 2 ]
 then
-	echo $ERR_NUM_ARGS
+	echo "$MSG_USAGE"
+	exit 0
 fi
 
@@ -37,10 +45,10 @@
 if [ ! -z `which wget` ]
 then
-	wget --no-check-certificate -O $OUT_FILE $URL
+	wget --quiet -O $OUT_FILE $URL
 elif [ ! -z `which curl` ]
 then
-	curl $URL -o $OUT_FILE
+	curl --silent $URL -o $OUT_FILE
 else
-	echo $ERR_NO_GET_CMD
+	echo $MSG_ERR_NO_GET_CMD
 	exit 0
 fi
