Index: /trunk/psModules/src/config/Makefile.am
===================================================================
--- /trunk/psModules/src/config/Makefile.am	(revision 11549)
+++ /trunk/psModules/src/config/Makefile.am	(revision 11550)
@@ -28,2 +28,4 @@
 pmErrorCodes.c : pmErrorCodes.dat pmErrorCodes.c.in pmErrorCodes.h
 	$(ERRORCODES) --data=pmErrorCodes.dat --outdir=. pmErrorCodes.c
+
+EXTRA_DIST = pmErrorCodes.h.in pmErrorCodes.dat pmErrorCodes.c.in
Index: /trunk/psModules/test/detrend/tap_pmShutterCorrection.c
===================================================================
--- /trunk/psModules/test/detrend/tap_pmShutterCorrection.c	(revision 11549)
+++ /trunk/psModules/test/detrend/tap_pmShutterCorrection.c	(revision 11550)
@@ -16,5 +16,5 @@
     {
         psMemId id = psMemGetId();
-        pmShutterCorrPars *pars = pmShutterCorrParsAlloc ();
+        pmShutterCorrection *pars = pmShutterCorrectionAlloc ();
 
         ok(pars != NULL, "pmShutterCorrPars successfully allocated");
@@ -44,5 +44,5 @@
         }
 
-        pmShutterCorrPars *pars = pmShutterCorrectionGuess (exptime, counts);
+        pmShutterCorrection *pars = pmShutterCorrectionGuess (exptime, counts);
 
         ok(pars != NULL, "pmShutterCorrPars successfully allocated");
@@ -81,8 +81,8 @@
         }
 
-        pmShutterCorrPars *pars = pmShutterCorrectionGuess (exptime, counts);
-
-        ok(pars != NULL, "pmShutterCorrPars successfully allocated");
-        skip_start(pars == NULL, 0, "Skipping tests because pmShutterCorrParsAlloc() failed");
+        pmShutterCorrection *pars = pmShutterCorrectionGuess (exptime, counts);
+
+        ok(pars != NULL, "pmShutterCorrection successfully allocated");
+        skip_start(pars == NULL, 0, "Skipping tests because pmShutterCorrectionAlloc() failed");
 
         // with fine linearly-spaced times large compared to TO and TK,
@@ -118,10 +118,10 @@
         }
 
-        pmShutterCorrPars *pars = pmShutterCorrectionGuess (exptime, counts);
-
-        // with fine log-spaced times well-sampling TO and TK,
-        // we can expect accurate guesses
-        ok(pars != NULL, "pmShutterCorrPars successfully allocated");
-        skip_start(pars == NULL, 0, "Skipping tests because pmShutterCorrParsAlloc() failed");
+        pmShutterCorrection *pars = pmShutterCorrectionGuess (exptime, counts);
+
+        // with fine log-spaced times well-sampling TO and TK,
+        // we can expect accurate guesses
+        ok(pars != NULL, "pmShutterCorrectionsuccessfully allocated");
+        skip_start(pars == NULL, 0, "Skipping tests because pmShutterCorrectionAlloc() failed");
         ok(fabs(pars->scale  - AK) < 0.01, "scale guess is close enough (got %f vs %f)",  pars->scale, AK);
         ok(fabs(pars->offset - TK) < 0.01, "offset guess is close enough (got %f vs %f)", pars->offset, TK);
@@ -154,8 +154,8 @@
         }
 
-        pmShutterCorrPars *pars = pmShutterCorrectionGuess (exptime, counts);
-
-        ok(pars != NULL, "pmShutterCorrPars successfully allocated");
-        skip_start(pars == NULL, 0, "Skipping tests because pmShutterCorrParsAlloc() failed");
+        pmShutterCorrection *pars = pmShutterCorrectionGuess (exptime, counts);
+
+        ok(pars != NULL, "pmShutterCorrection successfully allocated");
+        skip_start(pars == NULL, 0, "Skipping tests because pmShutterCorrectionAlloc() failed");
 
         // with coarse linearly-spaced times large compared to TO and TK,
@@ -191,8 +191,8 @@
         }
 
-        pmShutterCorrPars *pars = pmShutterCorrectionGuess (exptime, counts);
-
-        ok(pars != NULL, "pmShutterCorrPars successfully allocated");
-        skip_start(pars == NULL, 0, "Skipping tests because pmShutterCorrParsAlloc() failed");
+        pmShutterCorrection *pars = pmShutterCorrectionGuess (exptime, counts);
+
+        ok(pars != NULL, "pmShutterCorrection successfully allocated");
+        skip_start(pars == NULL, 0, "Skipping tests because pmShutterCorrectionsAlloc() failed");
 
         // with fine linearly-spaced times large compared to TO and TK,
@@ -228,10 +228,10 @@
         }
 
-        pmShutterCorrPars *pars = pmShutterCorrectionGuess (exptime, counts);
-
-        // with fine log-spaced times well-sampling TO and TK,
-        // we can expect accurate guesses
-        ok(pars != NULL, "pmShutterCorrPars successfully allocated");
-        skip_start(pars == NULL, 0, "Skipping tests because pmShutterCorrParsAlloc() failed");
+        pmShutterCorrection *pars = pmShutterCorrectionGuess (exptime, counts);
+
+        // with fine log-spaced times well-sampling TO and TK,
+        // we can expect accurate guesses
+        ok(pars != NULL, "pmShutterCorrection successfully allocated");
+        skip_start(pars == NULL, 0, "Skipping tests because pmShutterCorrectionAlloc() failed");
         ok(fabs(pars->scale  - AK) < 0.01, "scale guess is close enough (got %f vs %f)",  pars->scale, AK);
         ok(fabs(pars->offset - TK) < 0.01, "offset guess is close enough (got %f vs %f)", pars->offset, TK);
@@ -266,12 +266,12 @@
         }
 
-        pmShutterCorrPars *guess = pmShutterCorrectionGuess (exptime, counts);
+        pmShutterCorrection *guess = pmShutterCorrectionGuess (exptime, counts);
         skip_start(guess == NULL, 0, "Skipping tests because pmShutterCorrectionGuess() failed");
-        pmShutterCorrPars *pars = pmShutterCorrectionFullFit (exptime, counts, cntErr, guess);
-
-        // with fine log-spaced times well-sampling TO and TK,
-        // we can expect accurate guesses
-        ok(pars != NULL, "pmShutterCorrPars successfully allocated by FullFit");
-        skip_start(pars == NULL, 0, "Skipping tests because pmShutterCorrParsAlloc() failed");
+        pmShutterCorrection *pars = pmShutterCorrectionFullFit (exptime, counts, cntErr, guess);
+
+        // with fine log-spaced times well-sampling TO and TK,
+        // we can expect accurate guesses
+        ok(pars != NULL, "pmShutterCorrection successfully allocated by FullFit");
+        skip_start(pars == NULL, 0, "Skipping tests because pmShutterCorrectionsAlloc() failed");
         ok(fabs(pars->scale  - AK) < 0.01, "scale fit is close enough (got %f vs %f)",  pars->scale, AK);
         ok(fabs(pars->offset - TK) < 0.01, "offset fit is close enough (got %f vs %f)", pars->offset, TK);
@@ -310,12 +310,12 @@
         }
 
-        pmShutterCorrPars *guess = pmShutterCorrectionGuess (exptime, counts);
+        pmShutterCorrection*guess = pmShutterCorrectionGuess (exptime, counts);
         skip_start(guess == NULL, 0, "Skipping tests because pmShutterCorrectionGuess() failed");
-        pmShutterCorrPars *pars = pmShutterCorrectionFullFit (exptime, counts, cntErr, guess);
-
-        // with fine log-spaced times well-sampling TO and TK,
-        // we can expect accurate guesses
-        ok(pars != NULL, "pmShutterCorrPars successfully allocated by FullFit");
-        skip_start(pars == NULL, 0, "Skipping tests because pmShutterCorrParsAlloc() failed");
+        pmShutterCorrection *pars = pmShutterCorrectionFullFit (exptime, counts, cntErr, guess);
+
+        // with fine log-spaced times well-sampling TO and TK,
+        // we can expect accurate guesses
+        ok(pars != NULL, "pmShutterCorrection successfully allocated by FullFit");
+        skip_start(pars == NULL, 0, "Skipping tests because pmShutterCorrectionAlloc() failed");
         ok(fabs(pars->scale  - AK) < 0.01, "scale fit is close enough (got %f vs %f)",  pars->scale, AK);
         ok(fabs(pars->offset - TK) < 0.01, "offset fit is close enough (got %f vs %f)", pars->offset, TK);
@@ -356,13 +356,13 @@
         }
 
-        pmShutterCorrPars *guess = pmShutterCorrectionGuess (exptime, counts);
+        pmShutterCorrection*guess = pmShutterCorrectionGuess (exptime, counts);
         skip_start(guess == NULL, 0, "Skipping tests because pmShutterCorrectionGuess() failed");
-        pmShutterCorrPars *full = pmShutterCorrectionFullFit (exptime, counts, cntErr, guess);
-        pmShutterCorrPars *pars = pmShutterCorrectionLinFit (exptime, counts, cntErr, full->offref);
-
-        // with fine log-spaced times well-sampling TO and TK,
-        // we can expect accurate guesses
-        ok(pars != NULL, "pmShutterCorrPars successfully allocated by FullFit");
-        skip_start(pars == NULL, 0, "Skipping tests because pmShutterCorrParsAlloc() failed");
+        pmShutterCorrection *full = pmShutterCorrectionFullFit (exptime, counts, cntErr, guess);
+        pmShutterCorrection *pars = pmShutterCorrectionLinFit (exptime, counts, cntErr, NULL, full->offref, 1, 5, 0);
+
+        // with fine log-spaced times well-sampling TO and TK,
+        // we can expect accurate guesses
+        ok(pars != NULL, "pmShutterCorrection successfully allocated by FullFit");
+        skip_start(pars == NULL, 0, "Skipping tests because pmShutterCorrectionAlloc() failed");
         ok(fabs(pars->scale  - AK) < 0.01, "scale fit is close enough (got %f vs %f)",  pars->scale, AK);
         ok(fabs(pars->offset - TK) < 0.01, "offset fit is close enough (got %f vs %f)", pars->offset, TK);
@@ -402,13 +402,13 @@
         }
 
-        pmShutterCorrPars *guess = pmShutterCorrectionGuess (exptime, counts);
+        pmShutterCorrection *guess = pmShutterCorrectionGuess (exptime, counts);
         skip_start(guess == NULL, 0, "Skipping tests because pmShutterCorrectionGuess() failed");
-        pmShutterCorrPars *full = pmShutterCorrectionFullFit (exptime, counts, cntErr, guess);
-        pmShutterCorrPars *pars = pmShutterCorrectionLinFit (exptime, counts, cntErr, full->offref);
-
-        // with fine log-spaced times well-sampling TO and TK,
-        // we can expect accurate guesses
-        ok(pars != NULL, "pmShutterCorrPars successfully allocated by FullFit");
-        skip_start(pars == NULL, 0, "Skipping tests because pmShutterCorrParsAlloc() failed");
+        pmShutterCorrection *full = pmShutterCorrectionFullFit (exptime, counts, cntErr, guess);
+        pmShutterCorrection *pars = pmShutterCorrectionLinFit (exptime, counts, cntErr, NULL, full->offref, 1, 5, 0);
+
+        // with fine log-spaced times well-sampling TO and TK,
+        // we can expect accurate guesses
+        ok(pars != NULL, "pmShutterCorrection successfully allocated by FullFit");
+        skip_start(pars == NULL, 0, "Skipping tests because pmShutterCorrectionAlloc() failed");
         ok(fabs(pars->scale  - AK) < 0.01, "scale fit is close enough (got %f vs %f)",  pars->scale, AK);
         ok(fabs(pars->offset - TK) < 0.01, "offset fit is close enough (got %f vs %f)", pars->offset, TK);
Index: /trunk/psModules/test/tap/Makefile.am
===================================================================
--- /trunk/psModules/test/tap/Makefile.am	(revision 11549)
+++ /trunk/psModules/test/tap/Makefile.am	(revision 11550)
@@ -1,3 +1,4 @@
-SUBDIRS  = src tests
+SUBDIRS  = src
+#SUBDIRS += tests
 
 prove:
Index: /trunk/psModules/test/tap/configure.in
===================================================================
--- /trunk/psModules/test/tap/configure.in	(revision 11549)
+++ /trunk/psModules/test/tap/configure.in	(revision 11550)
@@ -3,4 +3,5 @@
 AM_INIT_AUTOMAKE([foreign])
 AC_CONFIG_HEADERS([src/config.h])
+AC_GNU_SOURCE
 AC_PROG_CC
 AC_PROG_LIBTOOL
@@ -40,22 +41,4 @@
 AC_CONFIG_FILES([Makefile
 		 src/Makefile
-		 tests/Makefile
-		 tests/diag/Makefile
-		 tests/fail/Makefile
-		 tests/ok/Makefile
-		 tests/ok/ok-hash/Makefile
-		 tests/ok/ok-numeric/Makefile
-		 tests/ok/ok/Makefile
-		 tests/pass/Makefile
-		 tests/plan/Makefile
-		 tests/plan/no-tests/Makefile
-		 tests/plan/no_plan/Makefile
-		 tests/plan/not-enough-tests/Makefile
-		 tests/plan/sane/Makefile
-		 tests/plan/skip_all/Makefile
-		 tests/plan/too-many-plans/Makefile
-		 tests/plan/too-many-tests/Makefile
-		 tests/skip/Makefile
-		 tests/todo/Makefile
 		])
 AC_OUTPUT
Index: /trunk/psModules/test/tap/src/tap.c
===================================================================
--- /trunk/psModules/test/tap/src/tap.c	(revision 11549)
+++ /trunk/psModules/test/tap/src/tap.c	(revision 11550)
@@ -25,4 +25,8 @@
  */
 
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
 #include <ctype.h>
 #include <stdarg.h>
