Index: /branches/eam_branches/ipp-20120601/ippTools/src/addtool.c
===================================================================
--- /branches/eam_branches/ipp-20120601/ippTools/src/addtool.c	(revision 34033)
+++ /branches/eam_branches/ipp-20120601/ippTools/src/addtool.c	(revision 34034)
@@ -724,5 +724,5 @@
 
     // required
-    PXOPT_LOOKUP_S64(add_id, config->args, "-add_id", true, false);
+    // PXOPT_LOOKUP_S64(add_id, config->args, "-add_id", true, false);
 
     // optional
@@ -733,4 +733,5 @@
     PXOPT_LOOKUP_S16(fault,         config->args, "-fault", false, false);
     PXOPT_LOOKUP_S64(stage_extra1, config->args, "-stage_extra1", false, false);
+
     // generate restrictions
     psMetadata *where = psMetadataAlloc();
@@ -1536,5 +1537,5 @@
 
     // required
-  PXOPT_LOOKUP_U64(minidvodb_id, config->args, "-minidvodb_id", true, false);
+  // PXOPT_LOOKUP_U64(minidvodb_id, config->args, "-minidvodb_id", true, false);
   PXOPT_LOOKUP_STR(minidvodb_group, config->args, "-minidvodb_group", true, false);
 
@@ -1791,5 +1792,5 @@
   psMetadata *where = psMetadataAlloc();
 
-  PXOPT_LOOKUP_U64(minidvodb_id,  config->args, "-minidvodb_id", true, false);
+  // PXOPT_LOOKUP_U64(minidvodb_id,  config->args, "-minidvodb_id", true, false);
   PXOPT_LOOKUP_S16(fault,  config->args, "-set_fault", false, false);
   PXOPT_LOOKUP_F32(dtime_relphot,  config->args, "-set_dtime_relphot", false, false);
Index: /branches/eam_branches/ipp-20120601/ippTools/src/bgtool.c
===================================================================
--- /branches/eam_branches/ipp-20120601/ippTools/src/bgtool.c	(revision 34033)
+++ /branches/eam_branches/ipp-20120601/ippTools/src/bgtool.c	(revision 34034)
@@ -935,5 +935,5 @@
 
     // chip_bg_id is required
-    PXOPT_LOOKUP_S64(chip_bg_id, config->args, "-chip_bg_id", true, false);
+    // PXOPT_LOOKUP_S64(chip_bg_id, config->args, "-chip_bg_id", true, false);
 
     PXOPT_LOOKUP_U64(limit, config->args, "-limit", false, false);
@@ -1052,5 +1052,5 @@
     PS_ASSERT_PTR_NON_NULL(config, NULL);
 
-    PXOPT_LOOKUP_S64(chip_bg_id, config->args, "-chip_bg_id", true, false);
+    // PXOPT_LOOKUP_S64(chip_bg_id, config->args, "-chip_bg_id", true, false);
     PXOPT_LOOKUP_U64(limit, config->args, "-limit", false, false);
     PXOPT_LOOKUP_BOOL(simple, config->args, "-simple", false);
@@ -1169,5 +1169,5 @@
 
     // required
-    PXOPT_LOOKUP_S64(chip_bg_id, config->args, "-chip_bg_id", true, false);
+    // PXOPT_LOOKUP_S64(chip_bg_id, config->args, "-chip_bg_id", true, false);
     PXOPT_LOOKUP_STR(class_id, config->args, "-class_id", true, false);
 
@@ -1222,5 +1222,5 @@
     PS_ASSERT_PTR_NON_NULL(config, false);
 
-    PXOPT_LOOKUP_S64(chip_bg_id, config->args, "-chip_bg_id", true,  false);
+    // PXOPT_LOOKUP_S64(chip_bg_id, config->args, "-chip_bg_id", true,  false);
     PXOPT_LOOKUP_STR(outfile, config->args, "-outfile", true,  false);
     PXOPT_LOOKUP_BOOL(clean,  config->args, "-clean", false);
@@ -2017,5 +2017,5 @@
     PS_ASSERT_PTR_NON_NULL(config, NULL);
 
-    PXOPT_LOOKUP_S64(warp_bg_id, config->args, "-warp_bg_id", true, false);
+    // PXOPT_LOOKUP_S64(warp_bg_id, config->args, "-warp_bg_id", true, false);
     PXOPT_LOOKUP_U64(limit, config->args, "-limit", false, false);
     PXOPT_LOOKUP_BOOL(simple, config->args, "-simple", false);
@@ -2133,5 +2133,5 @@
     PS_ASSERT_PTR_NON_NULL(config, false);
 
-    PXOPT_LOOKUP_S64(warp_bg_id, config->args, "-warp_bg_id", true,  false);
+    // PXOPT_LOOKUP_S64(warp_bg_id, config->args, "-warp_bg_id", true,  false);
     PXOPT_LOOKUP_STR(outfile, config->args, "-outfile", true,  false);
     PXOPT_LOOKUP_BOOL(clean,  config->args, "-clean", false);
Index: /branches/eam_branches/ipp-20120601/ippTools/src/camtool.c
===================================================================
--- /branches/eam_branches/ipp-20120601/ippTools/src/camtool.c	(revision 34033)
+++ /branches/eam_branches/ipp-20120601/ippTools/src/camtool.c	(revision 34034)
@@ -1270,5 +1270,5 @@
   PS_ASSERT_PTR_NON_NULL(config, NULL);
 
-  PXOPT_LOOKUP_S64(det_id, config->args, "-cam_id", true,  false);
+  // PXOPT_LOOKUP_S64(det_id, config->args, "-cam_id", true,  false);
   PXOPT_LOOKUP_STR(outfile, config->args, "-outfile", true,  false);
   PXOPT_LOOKUP_U64(limit,   config->args, "-limit",   false, false);
Index: /branches/eam_branches/ipp-20120601/ippTools/src/chiptool.c
===================================================================
--- /branches/eam_branches/ipp-20120601/ippTools/src/chiptool.c	(revision 34033)
+++ /branches/eam_branches/ipp-20120601/ippTools/src/chiptool.c	(revision 34034)
@@ -254,5 +254,5 @@
     PS_ASSERT_PTR_NON_NULL(config, NULL);
 
-    PXOPT_LOOKUP_S64(exp_id, config->args, "-exp_id", false, false);
+    // PXOPT_LOOKUP_S64(exp_id, config->args, "-exp_id", false, false);
 
     psMetadata *where = psMetadataAlloc();
@@ -346,5 +346,5 @@
     PS_ASSERT_PTR_NON_NULL(config, NULL);
 
-    PXOPT_LOOKUP_S64(exp_id, config->args, "-exp_id", false, false);
+    // PXOPT_LOOKUP_S64(exp_id, config->args, "-exp_id", false, false);
 
     psMetadata *where = psMetadataAlloc();
@@ -1017,8 +1017,8 @@
     PXOPT_COPY_S64(config->args, where, "-cam_id", "cam_id", "==");
 
-    PXOPT_LOOKUP_S64(cam_id, config->args, "-cam_id", false, false);
+    // PXOPT_LOOKUP_S64(cam_id, config->args, "-cam_id", false, false);
     // if cam_id is not supplied chip_id is required
-    PXOPT_LOOKUP_S64(chip_id, config->args, "-chip_id", cam_id ? false : true, false);
-    PXOPT_LOOKUP_S64(class_id, config->args, "-class_id", true, false);
+    // PXOPT_LOOKUP_S64(chip_id, config->args, "-chip_id", cam_id ? false : true, false);
+    // PXOPT_LOOKUP_S64(class_id, config->args, "-class_id", true, false);
     PXOPT_LOOKUP_S16(quality, config->args, "-set_quality", true, false);
 
@@ -1774,5 +1774,5 @@
   PS_ASSERT_PTR_NON_NULL(config, NULL);
 
-  PXOPT_LOOKUP_S64(dummy, config->args, "-chip_id", true,  false);
+  // PXOPT_LOOKUP_S64(dummy, config->args, "-chip_id", true,  false);
   PXOPT_LOOKUP_STR(outfile, config->args, "-outfile", true,  false);
   PXOPT_LOOKUP_U64(limit,   config->args, "-limit",   false, false);
@@ -1937,5 +1937,5 @@
 
 //    PXOPT_LOOKUP_BOOL(all, config->args, "-all", false);
-    PXOPT_LOOKUP_BOOL(no_magic, config->args, "-no_magic", false);
+    // PXOPT_LOOKUP_BOOL(no_magic, config->args, "-no_magic", false);
 
     PXOPT_LOOKUP_U64(limit, config->args, "-limit", false, false);
Index: /branches/eam_branches/ipp-20120601/ippTools/src/difftool.c
===================================================================
--- /branches/eam_branches/ipp-20120601/ippTools/src/difftool.c	(revision 34033)
+++ /branches/eam_branches/ipp-20120601/ippTools/src/difftool.c	(revision 34034)
@@ -1075,5 +1075,5 @@
 
     // default
-    PXOPT_LOOKUP_BOOL(simple, config->args, "-simple", false);
+    // PXOPT_LOOKUP_BOOL(simple, config->args, "-simple", false);
     PXOPT_LOOKUP_TIME(registered, config->args, "-registered", false, false);
 
@@ -2059,5 +2059,5 @@
     PXOPT_LOOKUP_BOOL(newTemplates,config->args,"-new-templates", false);
 
-    PXOPT_LOOKUP_BOOL(available, config->args, "-available", false);
+    // PXOPT_LOOKUP_BOOL(available, config->args, "-available", false);
     PXOPT_LOOKUP_BOOL(pretend, config->args, "-pretend", false);
 
@@ -2849,5 +2849,5 @@
   PS_ASSERT_PTR_NON_NULL(config, NULL);
 
-  PXOPT_LOOKUP_S64(det_id, config->args, "-diff_id", true,  false);
+  // PXOPT_LOOKUP_S64(det_id, config->args, "-diff_id", true,  false);
   PXOPT_LOOKUP_STR(outfile, config->args, "-outfile", true,  false);
   PXOPT_LOOKUP_U64(limit,   config->args, "-limit",   false, false);
Index: /branches/eam_branches/ipp-20120601/ippTools/src/pxerrors.c
===================================================================
--- /branches/eam_branches/ipp-20120601/ippTools/src/pxerrors.c	(revision 34033)
+++ /branches/eam_branches/ipp-20120601/ippTools/src/pxerrors.c	(revision 34034)
@@ -26,5 +26,8 @@
 psExit pxerrorGetExitStatus(void) {
 
-    psErrorCode err = psErrorCodeLast ();
+    // psErrorCodeLast returns a psErrorCode, but we are being a bit sleezy and defining a set
+    // of enum values that have non-overlapping-ranges (not enforced by the compiler)
+
+    int err = psErrorCodeLast ();
     switch (err) {
       case PXTOOLS_ERR_SYS:
