Index: /trunk/ArchTOIPipe/configure
===================================================================
--- /trunk/ArchTOIPipe/configure	(revision 1754)
+++ /trunk/ArchTOIPipe/configure	(revision 1755)
@@ -922,8 +922,9 @@
 fi
 
+if test -x /usr/bin/ar; then
 # Extract the first word of "ar", so it can be a program name with args.
 set dummy ar; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:928: checking for $ac_word" >&5
+echo "configure:929: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_AR'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -958,8 +959,40 @@
 fi
  
+else
+# Extract the first word of "ar", so it can be a program name with args.
+set dummy ar; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:966: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  if test -n "$AR"; then
+  ac_cv_prog_AR="$AR" # Let the user override the test.
+else
+  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
+  ac_dummy="$PATH"
+  for ac_dir in $ac_dummy; do
+    test -z "$ac_dir" && ac_dir=.
+    if test -f $ac_dir/$ac_word; then
+      ac_cv_prog_AR=""
+      break
+    fi
+  done
+  IFS="$ac_save_ifs"
+fi
+fi
+AR="$ac_cv_prog_AR"
+if test -n "$AR"; then
+  echo "$ac_t""$AR" 1>&6
+else
+  echo "$ac_t""no" 1>&6
+fi
+
+fi
+if test -x /usr/bin/ranlib; then
 # Extract the first word of "ranlib", so it can be a program name with args.
 set dummy ranlib; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:964: checking for $ac_word" >&5
+echo "configure:997: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_RANLIB'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -994,4 +1027,36 @@
 fi
  
+else
+# Extract the first word of "ranlib", so it can be a program name with args.
+set dummy ranlib; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:1034: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  if test -n "$RANLIB"; then
+  ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
+else
+  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
+  ac_dummy="$PATH"
+  for ac_dir in $ac_dummy; do
+    test -z "$ac_dir" && ac_dir=.
+    if test -f $ac_dir/$ac_word; then
+      ac_cv_prog_RANLIB="ranlib"
+      break
+    fi
+  done
+  IFS="$ac_save_ifs"
+  test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
+fi
+fi
+RANLIB="$ac_cv_prog_RANLIB"
+if test -n "$RANLIB"; then
+  echo "$ac_t""$RANLIB" 1>&6
+else
+  echo "$ac_t""no" 1>&6
+fi
+
+fi
 ac_aux_dir=
 for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
@@ -1025,5 +1090,5 @@
 # ./install, which can be erroneously created by make from ./install.sh.
 echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:1028: checking for a BSD compatible install" >&5
+echo "configure:1093: checking for a BSD compatible install" >&5
 if test -z "$INSTALL"; then
 if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
@@ -1086,5 +1151,5 @@
 
 echo $ac_n "checking size of short""... $ac_c" 1>&6
-echo "configure:1089: checking size of short" >&5
+echo "configure:1154: checking size of short" >&5
 if eval "test \"`echo '$''{'ac_cv_sizeof_short'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -1094,5 +1159,5 @@
 else
   cat > conftest.$ac_ext <<EOF
-#line 1097 "configure"
+#line 1162 "configure"
 #include "confdefs.h"
 #include <stdio.h>
@@ -1105,5 +1170,5 @@
 }
 EOF
-if { (eval echo configure:1108: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:1173: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_sizeof_short=`cat conftestval`
@@ -1125,5 +1190,5 @@
 
 echo $ac_n "checking size of int""... $ac_c" 1>&6
-echo "configure:1128: checking size of int" >&5
+echo "configure:1193: checking size of int" >&5
 if eval "test \"`echo '$''{'ac_cv_sizeof_int'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -1133,5 +1198,5 @@
 else
   cat > conftest.$ac_ext <<EOF
-#line 1136 "configure"
+#line 1201 "configure"
 #include "confdefs.h"
 #include <stdio.h>
@@ -1144,5 +1209,5 @@
 }
 EOF
-if { (eval echo configure:1147: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:1212: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_sizeof_int=`cat conftestval`
@@ -1164,5 +1229,5 @@
 
 echo $ac_n "checking size of long""... $ac_c" 1>&6
-echo "configure:1167: checking size of long" >&5
+echo "configure:1232: checking size of long" >&5
 if eval "test \"`echo '$''{'ac_cv_sizeof_long'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -1172,5 +1237,5 @@
 else
   cat > conftest.$ac_ext <<EOF
-#line 1175 "configure"
+#line 1240 "configure"
 #include "confdefs.h"
 #include <stdio.h>
@@ -1183,5 +1248,5 @@
 }
 EOF
-if { (eval echo configure:1186: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:1251: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_sizeof_long=`cat conftestval`
@@ -1203,5 +1268,5 @@
 
 echo $ac_n "checking size of long long""... $ac_c" 1>&6
-echo "configure:1206: checking size of long long" >&5
+echo "configure:1271: checking size of long long" >&5
 if eval "test \"`echo '$''{'ac_cv_sizeof_long_long'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -1211,5 +1276,5 @@
 else
   cat > conftest.$ac_ext <<EOF
-#line 1214 "configure"
+#line 1279 "configure"
 #include "confdefs.h"
 #include <stdio.h>
@@ -1222,5 +1287,5 @@
 }
 EOF
-if { (eval echo configure:1225: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:1290: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_sizeof_long_long=`cat conftestval`
@@ -1242,5 +1307,5 @@
 
 echo $ac_n "checking size of float""... $ac_c" 1>&6
-echo "configure:1245: checking size of float" >&5
+echo "configure:1310: checking size of float" >&5
 if eval "test \"`echo '$''{'ac_cv_sizeof_float'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -1250,5 +1315,5 @@
 else
   cat > conftest.$ac_ext <<EOF
-#line 1253 "configure"
+#line 1318 "configure"
 #include "confdefs.h"
 #include <stdio.h>
@@ -1261,5 +1326,5 @@
 }
 EOF
-if { (eval echo configure:1264: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:1329: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_sizeof_float=`cat conftestval`
@@ -1281,5 +1346,5 @@
 
 echo $ac_n "checking size of double""... $ac_c" 1>&6
-echo "configure:1284: checking size of double" >&5
+echo "configure:1349: checking size of double" >&5
 if eval "test \"`echo '$''{'ac_cv_sizeof_double'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -1289,5 +1354,5 @@
 else
   cat > conftest.$ac_ext <<EOF
-#line 1292 "configure"
+#line 1357 "configure"
 #include "confdefs.h"
 #include <stdio.h>
@@ -1300,5 +1365,5 @@
 }
 EOF
-if { (eval echo configure:1303: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:1368: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_sizeof_double=`cat conftestval`
@@ -1320,5 +1385,5 @@
 
 echo $ac_n "checking size of long double""... $ac_c" 1>&6
-echo "configure:1323: checking size of long double" >&5
+echo "configure:1388: checking size of long double" >&5
 if eval "test \"`echo '$''{'ac_cv_sizeof_long_double'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -1328,5 +1393,5 @@
 else
   cat > conftest.$ac_ext <<EOF
-#line 1331 "configure"
+#line 1396 "configure"
 #include "confdefs.h"
 #include <stdio.h>
@@ -1339,5 +1404,5 @@
 }
 EOF
-if { (eval echo configure:1342: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:1407: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_sizeof_long_double=`cat conftestval`
@@ -1361,5 +1426,5 @@
 
 echo $ac_n "checking "for cfitsio lib"""... $ac_c" 1>&6
-echo "configure:1364: checking "for cfitsio lib"" >&5
+echo "configure:1429: checking "for cfitsio lib"" >&5
 MACHDIR=`uname`-$CXX
 if test -f $ARCHBASEREP/$MACHDIR/Libs/libcfitsio.a; then
@@ -1388,5 +1453,5 @@
 
 echo $ac_n "checking "for cfitsio includes"""... $ac_c" 1>&6
-echo "configure:1391: checking "for cfitsio includes"" >&5
+echo "configure:1456: checking "for cfitsio includes"" >&5
 if test -f $CFITSIODIR/fitsio.h; then
   cfitsincdir='-I$(CFITSIODIR)'
@@ -1402,5 +1467,5 @@
 
 echo $ac_n "checking for sin in -lm""... $ac_c" 1>&6
-echo "configure:1405: checking for sin in -lm" >&5
+echo "configure:1470: checking for sin in -lm" >&5
 ac_lib_var=`echo m'_'sin | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
@@ -1410,5 +1475,5 @@
 LIBS="-lm  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 1413 "configure"
+#line 1478 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
@@ -1421,5 +1486,5 @@
 ; return 0; }
 EOF
-if { (eval echo configure:1424: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1489: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
@@ -1449,5 +1514,5 @@
 
 echo $ac_n "checking for pthread_create in -lpthread""... $ac_c" 1>&6
-echo "configure:1452: checking for pthread_create in -lpthread" >&5
+echo "configure:1517: checking for pthread_create in -lpthread" >&5
 ac_lib_var=`echo pthread'_'pthread_create | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
@@ -1457,5 +1522,5 @@
 LIBS="-lpthread  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 1460 "configure"
+#line 1525 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
@@ -1468,5 +1533,5 @@
 ; return 0; }
 EOF
-if { (eval echo configure:1471: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1536: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
@@ -1496,5 +1561,5 @@
 
 echo $ac_n "checking for scopy_ in -lblas""... $ac_c" 1>&6
-echo "configure:1499: checking for scopy_ in -lblas" >&5
+echo "configure:1564: checking for scopy_ in -lblas" >&5
 ac_lib_var=`echo blas'_'scopy_ | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
@@ -1504,5 +1569,5 @@
 LIBS="-lblas  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 1507 "configure"
+#line 1572 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
@@ -1515,5 +1580,5 @@
 ; return 0; }
 EOF
-if { (eval echo configure:1518: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1583: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
@@ -1543,5 +1608,5 @@
 
 echo $ac_n "checking for s_copy in -lg2c""... $ac_c" 1>&6
-echo "configure:1546: checking for s_copy in -lg2c" >&5
+echo "configure:1611: checking for s_copy in -lg2c" >&5
 ac_lib_var=`echo g2c'_'s_copy | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
@@ -1551,5 +1616,5 @@
 LIBS="-lg2c  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 1554 "configure"
+#line 1619 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
@@ -1562,5 +1627,5 @@
 ; return 0; }
 EOF
-if { (eval echo configure:1565: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1630: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
@@ -1591,5 +1656,5 @@
 
 echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
-echo "configure:1594: checking how to run the C preprocessor" >&5
+echo "configure:1659: checking how to run the C preprocessor" >&5
 # On Suns, sometimes $CPP names a directory.
 if test -n "$CPP" && test -d "$CPP"; then
@@ -1606,5 +1671,5 @@
   # not just through cpp.
   cat > conftest.$ac_ext <<EOF
-#line 1609 "configure"
+#line 1674 "configure"
 #include "confdefs.h"
 #include <assert.h>
@@ -1612,5 +1677,5 @@
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1615: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:1680: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
@@ -1623,5 +1688,5 @@
   CPP="${CC-cc} -E -traditional-cpp"
   cat > conftest.$ac_ext <<EOF
-#line 1626 "configure"
+#line 1691 "configure"
 #include "confdefs.h"
 #include <assert.h>
@@ -1629,5 +1694,5 @@
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1632: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:1697: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
@@ -1640,5 +1705,5 @@
   CPP="${CC-cc} -nologo -E"
   cat > conftest.$ac_ext <<EOF
-#line 1643 "configure"
+#line 1708 "configure"
 #include "confdefs.h"
 #include <assert.h>
@@ -1646,5 +1711,5 @@
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1649: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:1714: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
@@ -1671,10 +1736,10 @@
 
 echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
-echo "configure:1674: checking for ANSI C header files" >&5
+echo "configure:1739: checking for ANSI C header files" >&5
 if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 1679 "configure"
+#line 1744 "configure"
 #include "confdefs.h"
 #include <stdlib.h>
@@ -1684,5 +1749,5 @@
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1687: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:1752: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
@@ -1701,5 +1766,5 @@
   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
 cat > conftest.$ac_ext <<EOF
-#line 1704 "configure"
+#line 1769 "configure"
 #include "confdefs.h"
 #include <string.h>
@@ -1719,5 +1784,5 @@
   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
 cat > conftest.$ac_ext <<EOF
-#line 1722 "configure"
+#line 1787 "configure"
 #include "confdefs.h"
 #include <stdlib.h>
@@ -1740,5 +1805,5 @@
 else
   cat > conftest.$ac_ext <<EOF
-#line 1743 "configure"
+#line 1808 "configure"
 #include "confdefs.h"
 #include <ctype.h>
@@ -1751,5 +1816,5 @@
 
 EOF
-if { (eval echo configure:1754: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:1819: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   :
@@ -1778,15 +1843,15 @@
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:1781: checking for $ac_hdr" >&5
+echo "configure:1846: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 1786 "configure"
+#line 1851 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1791: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:1856: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
Index: /trunk/ArchTOIPipe/configure.in
===================================================================
--- /trunk/ArchTOIPipe/configure.in	(revision 1754)
+++ /trunk/ArchTOIPipe/configure.in	(revision 1755)
@@ -31,6 +31,14 @@
 AC_PROG_CC
 AC_PROG_CXX
+if test -x /usr/bin/ar; then
 AC_PATH_PROG(AR, ar, /usr/bin/ar, /usr/bin:$PATH) 
+else
+AC_CHECK_PROG(AR, ar)
+fi
+if test -x /usr/bin/ranlib; then
 AC_PATH_PROG(RANLIB, ranlib, /usr/bin/ranlib, /usr/bin:$PATH) 
+else
+AC_PROG_RANLIB
+fi
 AC_PROG_INSTALL
 
