OSDN Git Service

Merge from no_bogosity
authorkorbb <korbb@138bc75d-0d04-0410-961f-82ee72b054a4>
Tue, 12 Oct 1999 14:44:18 +0000 (14:44 +0000)
committerkorbb <korbb@138bc75d-0d04-0410-961f-82ee72b054a4>
Tue, 12 Oct 1999 14:44:18 +0000 (14:44 +0000)
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@29918 138bc75d-0d04-0410-961f-82ee72b054a4

13 files changed:
gcc/ChangeLog
gcc/fixinc/Makefile.in
gcc/fixinc/fixfixes.c [new file with mode: 0644]
gcc/fixinc/fixincl.c
gcc/fixinc/fixincl.tpl
gcc/fixinc/fixincl.x
gcc/fixinc/fixlib.c [new file with mode: 0644]
gcc/fixinc/fixlib.h [new file with mode: 0644]
gcc/fixinc/fixtests.c [new file with mode: 0644]
gcc/fixinc/hackshell.tpl
gcc/fixinc/inclhack.def
gcc/fixinc/inclhack.sh
gcc/fixinc/inclhack.tpl

index 8a5acbc..93a6e4a 100644 (file)
@@ -1,3 +1,7 @@
+Tue Oct 12 07:38:41 1999  Bruce Korb  <autogen@linuxbox.com>
+
+       * fixincl/*: Merged "no_bogosity" branch
+
 Mon Oct 11 20:18:41 1999  Jim Wilson  <wilson@cygnus.com>
 
        * genoutput.c: Include toplev.h.
index 9821969..62df337 100644 (file)
@@ -22,7 +22,7 @@
 # Its purpose is to build the any-platforms fixinc.sh script.
 
 CFLAGS = -g
-FIXINC_DEFS = @fixinc_defs@
+FIXINC_DEFS = $(CFLAGS) $(CPPFLAGS) @fixinc_defs@ $(INCLUDES)
 
 CC = @CC@
 SHELL = /bin/sh
@@ -45,7 +45,7 @@ INCLUDES = -I. -I.. -I$(srcdir) -I$(srcdir)/.. -I$(srcdir)/../config -I$(srcdir)
 
 # Always use -I$(srcdir)/config when compiling.
 .c.o:
-       $(CC) -c $(CFLAGS) $(FIXINC_DEFS) $(CPPFLAGS) $(INCLUDES) $<
+       $(CC) -c $(FIXINC_DEFS) $<
 
 # The only suffixes we want for implicit rules are .c and .o.
 .SUFFIXES:
@@ -59,28 +59,37 @@ INCLUDES = -I. -I.. -I$(srcdir) -I$(srcdir)/.. -I$(srcdir)/../config -I$(srcdir)
 ##
 ## # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
 
-OBJ = fixincl.o server.o gnu-regex.o procopen.o
-HDR = server.h gnu-regex.h
 LIBERTY = ../../libiberty/libiberty.a
+LIBOBJ  = gnu-regex.o fixlib.o $(LIBERTY)
+FIOBJ   = fixincl.o server.o procopen.o $(LIBOBJ)
+
+HDR = server.h gnu-regex.h fixlib.h
 
 SH_TARGET  = inclhack.sh fixincl.sh
-BIN_TARGET = fixincl
-AG_TEXT    = $(SH_TARGET) fixincl.x \
-       inclhack.def inclhack.tpl hackshell.tpl fixincl.tpl
+BIN_TARGET = fixincl fixfixes fixtests
+
 TARGETS    = $(SH_TARGET) $(BIN_TARGET)
 
 all : $(TARGETS)
 sh  : $(SH_TARGET)
 gen : $(SH_TARGET) fixincl.x
 
-$(OBJ): $(HDR)
+$(FIOBJ): $(HDR)
 
-fixincl: $(OBJ)
-       @echo $(CC) -o $@ $(OBJ) $(LIBERTY) $(LIB) ; \
-       if $(CC) -o $@ $(OBJ) $(LIBERTY) $(LIB) ; then : ; else \
+fixincl: $(FIOBJ)
+       @echo $(CC) -o $@ $(FIOBJ) $(LIBERTY) $(LIB) ; \
+       if $(CC) -o $@ $(FIOBJ) $(LIBERTY) $(LIB) ; then : ; else \
        rm -f $@ ; (echo "#! /bin/sh" ; echo exit 1 ) > $@ ; \
        chmod 777 $@ ; fi
 
+fixfixes: fixfixes.c $(LIBOBJ)
+       $(CC) -o $@ $(FIXINC_DEFS) -DMAIN \
+               $(srcdir)/fixfixes.c $(LIBOBJ) $(LIB)
+
+fixtests: fixtests.c $(LIBOBJ)
+       $(CC) -o $@ $(FIXINC_DEFS) -DMAIN \
+               $(srcdir)/fixtests.c $(LIBOBJ) $(LIB)
+
 gnu-regex.o: gnu-regex.c
        -$(CC) $(CFLAGS) $(FIXINC_DEFS) $(INCLUDES) -DREGEX_MALLOC \
                -c $(srcdir)/gnu-regex.c
diff --git a/gcc/fixinc/fixfixes.c b/gcc/fixinc/fixfixes.c
new file mode 100644 (file)
index 0000000..805e1db
--- /dev/null
@@ -0,0 +1,243 @@
+
+/*
+
+   Test to see if a particular fix should be applied to a header file.
+
+   Copyright (C) 1997, 1998, 1999 Free Software Foundation, Inc.
+
+= = = = = = = = = = = = = = = = = = = = = = = = =
+
+NOTE TO DEVELOPERS
+
+The routines you write here must work closely with both the fixincl.c
+and the test_need.c program.
+
+Here are the rules:
+
+1.  Every test procedure name must be suffixed with "_fix".
+    These routines will be referenced from inclhack.def, sans the suffix.
+
+2.  Use the "FIX_PROC_HEAD()" macro _with_ the "_fix" suffix
+    (I cannot use the ## magic from ANSI C) for defining your entry point.
+
+3.  Put your test name into the FIXUP_TABLE
+
+4.  Do not read anything from stdin.  It is closed.
+
+5.  Write to stderr only in the event of a reportable error
+    In such an event, call "exit(1)".
+
+6.  If "MAIN" is _not_ defined, then you have access to the fixDescList
+    entry for the fix in question.  This may be useful, for example,
+    if there are pre-compiled selection expressions stored there.
+
+    For example, you may do this if you know that the first 
+    test contains a useful regex.  This is okay because, remember,
+    this code perforce works closely with the inclhack.def fixes!!
+
+
+    tFixDesc*  pMyDesc = fixDescList + MY_FIX_NAME_FIXIDX;
+    tTestDesc* pTestList = pMyDesc->p_test_desc;
+
+    regexec (pTestList->p_test_regex, ...)
+
+
+    If MAIN _is_ defined, then you will have to compile it on
+    your own.
+
+= = = = = = = = = = = = = = = = = = = = = = = = =
+
+This file is part of GNU CC.
+
+GNU CC is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU CC is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU CC; see the file COPYING.  If not, write to
+the Free Software Foundation, 59 Temple Place - Suite 330,
+Boston, MA 02111-1307, USA.  */
+
+#include "fixlib.h"
+
+typedef struct {
+    const char*  fix_name;
+    void (*fix_proc)();
+} fix_entry_t;
+
+#define FIXUP_TABLE \
+  _FT_( "no_double_slash", double_slash_fix )
+
+
+#define FIX_PROC_HEAD( fix ) \
+static void fix ( filname, text ) \
+    const char* filname; \
+    char* text;
+
+
+/*
+ *  Skip over a quoted string.  Single quote strings may
+ *  contain multiple characters if the first character is
+ *  a backslash.  Especially a backslash followed by octal digits.
+ *  We are not doing a correctness syntax check here.
+ */
+static char*
+print_quote( q, text )
+  char  q;
+  char* text;
+{
+  fputc( q, stdout );
+
+  for (;;)
+    {
+      char ch = *(text++);
+      fputc( ch, stdout );
+
+      switch (ch)
+        {
+        case '\\':
+          if (*text == NUL)
+            goto quote_done;
+
+          fputc( *(text++), stdout );
+          break;
+
+        case '"':
+        case '\'':
+          if (ch != q)
+            break;
+          /*FALLTHROUGH*/
+
+        case '\n':
+        case NUL:
+          goto quote_done;
+        }
+    } quote_done:;
+
+  return text;
+}
+
+
+FIX_PROC_HEAD( double_slash_fix )
+{
+  /*  Now look for the comment markers in the text */
+  for (;;)
+    {
+      char ch = *(text++);
+      switch (ch)
+        {
+        case '/':
+          switch (*text) /* do not advance `text' here */
+            {
+            case '/':
+              /*
+                We found a "//" pair in open text.
+                Delete text to New-Line
+              */
+              while ((*text != '\n') && (*text != '\0'))  text++;
+              break;
+
+            case '*':
+              {
+                /* We found a C-style comment.  Skip forward to the end */
+                char* pz = strstr( (--text)+2, "*/" );
+                if (pz == (char*)NULL)
+                  {
+                    fputs( text, stdout );
+                    goto fix_done;
+                  }
+                pz += 2;
+                fwrite (text, (pz - text), 1, stdout );
+                text = pz;
+              }
+              break;
+
+            default:
+              fputc (ch, stdout );
+            }
+          break;
+
+        case NUL:
+          goto fix_done;
+
+        case '"':
+        case '\'':
+          text = print_quote (ch, text );
+          break;
+
+        default:
+          fputc (ch, stdout );
+        }
+
+    } fix_done:;
+
+  fclose (stdout);;
+}
+
+/* = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
+
+     test for fix selector
+
+     THIS IS THE ONLY EXPORTED ROUTINE
+
+*/
+void
+apply_fix( fixname, filname )
+  const char* fixname;
+  const char* filname;
+{
+  #define _FT_(n,p) { n, p },
+  static fix_entry_t fix_table[] = { FIXUP_TABLE { NULL, NULL }};
+  #undef _FT_
+  #define FIX_TABLE_CT ((sizeof(fix_table)/sizeof(fix_table[0]))-1)
+
+  char* buf;
+  int ct = FIX_TABLE_CT;
+  fix_entry_t* pfe = fix_table;
+
+  for (;;)
+    {
+      if (strcmp (pfe->fix_name, fixname) == 0)
+        break;
+      if (--ct <= 0)
+       {
+         fprintf (stderr, "fixincludes error:  the `%s' fix is unknown\n",
+                  fixname );
+         exit (3);
+       }
+    }
+
+  buf = load_file_data (stdin);
+  (*pfe->fix_proc)( filname, buf );
+}
+
+#ifdef MAIN
+
+/* = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
+
+     MAIN ROUTINE
+
+     This file is both included in fixincl.c and compiled as a separate
+     program for use by the inclhack.sh script.
+
+*/
+
+int
+main( argc, argv )
+  int argc;
+  char** argv;
+{
+  if (argc != 3)
+    apply_fix ("No test name provided", NULL, NULL, 0 );
+
+  apply_fix (argv[2], argv[1]);
+  return 0;
+}
+
+#endif
index 1a570f2..1e7c126 100644 (file)
@@ -22,52 +22,28 @@ along with GNU CC; see the file COPYING.  If not, write to
 the Free Software Foundation, 59 Temple Place - Suite 330,
 Boston, MA 02111-1307, USA.  */
 
-#include "auto-host.h"
+#include "fixlib.h"
+
+   #include <fcntl.h>
+   #include <sys/mman.h>
+   #define  BAD_ADDR ((void*)-1)
 
-#include "gansidecl.h"
-#include "system.h"
 #include <signal.h>
 
-#include "gnu-regex.h"
 #include "server.h"
 
-static const char program_id[] = "fixincl version 1.0";
-
-#define MINIMUM_MAXIMUM_LINES   128
-
-/* If this particular system's header files define the macro `MAXPATHLEN',
-   we happily take advantage of it; otherwise we use a value which ought
-   to be large enough.  */
-#ifndef MAXPATHLEN
-# define MAXPATHLEN     4096
-#endif
-#define NAME_TABLE_SIZE (MINIMUM_MAXIMUM_LINES * MAXPATHLEN)
-
-#ifndef EXIT_SUCCESS
-# define EXIT_SUCCESS 0
-#endif
-#ifndef EXIT_FAILURE
-# define EXIT_FAILURE 1
-#endif
-
-char *file_name_buf;
+/*  Quality Assurance Marker  :-)
 
-#define tSCC static const char
-#define tCC  const char
-#define tSC  static char
+    Any file that contains this string is presumed to have
+    been carefully constructed and will not be fixed  */
 
-typedef int t_success;
-
-#define FAILURE         (-1)
-#define SUCCESS           0
-#define PROBLEM           1
+static const char gnu_lib_mark[] =
+    "This file is part of the GNU C Library";
 
-#define SUCCEEDED(p)    ((p) == SUCCESS)
-#define SUCCESSFUL(p)   SUCCEEDED (p)
-#define FAILED(p)       ((p) < SUCCESS)
-#define HADGLITCH(p)    ((p) > SUCCESS)
+/*  The contents of this string are not very important.  It is mostly
+    just used as part of the "I am alive and working" test.  */
 
-#define NUL             '\0'
+static const char program_id[] = "fixincl version 1.1";
 
 /*  Test Descriptor
 
@@ -81,7 +57,7 @@ typedef int t_success;
     */
 typedef enum
 {
-  TT_TEST, TT_EGREP, TT_NEGREP
+  TT_TEST, TT_EGREP, TT_NEGREP, TT_FUNCTION
 } te_test_type;
 
 typedef struct test_desc tTestDesc;
@@ -101,10 +77,14 @@ typedef struct patch_desc tPatchDesc;
     a particular fix (which files, how to qualify them,
     how to actually make the fix, etc...)
 
+    NB:  the FD_ defines are BIT FLAGS
+
     */
 #define FD_MACH_ONLY      0x0000
 #define FD_MACH_IFNOT     0x0001
 #define FD_SHELL_SCRIPT   0x0002
+#define FD_SUBROUTINE     0x0004
+#define FD_REPLACEMENT    0x0008
 #define FD_SKIP_TEST      0x8000
 
 typedef struct fix_desc tFixDesc;
@@ -124,21 +104,47 @@ struct fix_desc
 char *pz_dest_dir = NULL;
 char *pz_src_dir = NULL;
 char *pz_machine = NULL;
-char *pz_find_base = NULL;
 int find_base_len = 0;
 
 pid_t process_chain_head = (pid_t) -1;
 
+char*  pz_curr_file;  /*  name of the current file under test/fix  */
+char*  pz_curr_data;  /*  original contents of that file  */
+t_bool curr_data_mapped;
+int    data_map_fd;
+size_t data_map_size;
+size_t ttl_data_size = 0;
+#ifdef DO_STATS
+int process_ct = 0;
+int apply_ct = 0;
+int fixed_ct = 0;
+int altered_ct = 0;
+#endif /* DO_STATS */
+
+#ifdef HAVE_MMAP
+#define UNLOAD_DATA() do { if (curr_data_mapped) { \
+  munmap ((void*)pz_curr_data, data_map_size); close (data_map_fd); } \
+  else free ((void*)pz_curr_data); } while(0)
+#else
+#define UNLOAD_DATA() free ((void*)pz_curr_data)
+#endif
+
 const char incl_quote_pat[] = "^[ \t]*#[ \t]*include[ \t]*\"[^/]";
+tSCC z_fork_err[] = "Error %d (%s) starting filter process for %s\n";
 regex_t incl_quote_re;
 
+void do_version ();
 char *load_file  _P_((const char *));
 void process  _P_((char *, const char *));
 void run_compiles ();
-void wait_for_pid _P_(( pid_t ));
 void initialize ();
+void process ();
+
+/*  External Source Code */
 
 #include "fixincl.x"
+#include "fixtests.c"
+#include "fixfixes.c"
 
 /* * * * * * * * * * * * * * * * * * *
  *
@@ -149,25 +155,7 @@ main (argc, argv)
      int argc;
      char **argv;
 {
-  static const char gnu_lib_mark[] =
-    "This file is part of the GNU C Library";
-
-#ifndef NO_BOGOSITY_LIMITS
-# define BOGUS_LIMIT    MINIMUM_MAXIMUM_LINES
-  size_t loop_ct;
-#endif
-
-  char *apz_names[BOGUS_LIMIT];
-  size_t file_name_ct;
-
-  /* Before anything else, ensure we can allocate our file name buffer. */
-  file_name_buf = (char *) malloc (NAME_TABLE_SIZE);
-  if (file_name_buf == (char *) NULL)
-    {
-      fprintf (stderr, "fixincl cannot allocate 0x%08X bytes\n",
-               NAME_TABLE_SIZE);
-      exit (EXIT_FAILURE);
-    }
+  char *file_name_buf;
 
   switch (argc)
     {
@@ -176,20 +164,13 @@ main (argc, argv)
 
     case 2:
       if (strcmp (argv[1], "-v") == 0)
+        do_version ();
+      if (freopen (argv[1], "r", stdin) == (FILE*)NULL)
         {
-          static const char zFmt[] = "echo '%s'";
-
-          /* The 'version' option is really used to test that:
-               1.  The program loads correctly (no missing libraries)
-               2.  we can correctly run our server shell process
-               3.  that we can compile all the regular expressions.
-           */
-          run_compiles ();
-          sprintf (file_name_buf, zFmt, program_id);
-          fputs (file_name_buf + 5, stdout);
-          exit (strcmp (run_shell (file_name_buf), program_id));
+          fprintf (stderr, "Error %d (%s) reopening %s as stdin\n",
+                   errno, strerror (errno), argv[1] );
+          exit (EXIT_FAILURE);
         }
-      freopen (argv[1], "r", stdin);
       break;
 
     default:
@@ -199,52 +180,69 @@ main (argc, argv)
 
   initialize ();
 
-#ifndef NO_BOGOSITY_LIMITS
-  /*  Some systems only allow so many calls to fork(2).
-      This is inadequate for this program.  Consequently,
-      we must let a grandfather process spawn children
-      that then spawn all the processes that do the real work.
-      */
+  /* Before anything else, ensure we can allocate our file name buffer. */
+  file_name_buf = load_file_data (stdin);
+
+  /*  Because of the way server shells work, you have to keep stdin, out
+      and err open so that the proper input file does not get closed
+      by accident  */
+
+  freopen ("/dev/null", "r", stdin);
+
+  if (file_name_buf == (char *) NULL)
+    {
+      fputs ("No file names listed for fixing\n", stderr);
+      exit (EXIT_FAILURE);
+    }
+
   for (;;)
     {
-      file_name_ct = 0;
+      char* pz_end;
 
-      {
-        char *pz_buf = file_name_buf;
+      /*  skip to start of name, past any "./" prefixes */
 
-        /* Only the parent process can read from stdin without confusing
-           the world. (How does the child tell the parent to skip
-           forward?  Pipes and files behave differently.)  */
+      while (ISSPACE (*file_name_buf))  file_name_buf++;
+      while ((file_name_buf[0] == '.') && (file_name_buf[1] == '/'))
+        file_name_buf += 2;
 
-        while (  (file_name_ct < BOGUS_LIMIT)
-              && (pz_buf < (file_name_buf + NAME_TABLE_SIZE - MAXPATHLEN)))
-          {
-            if (fgets (pz_buf, MAXPATHLEN, stdin) == (char *) NULL)
-              break;
-            while (ISSPACE (*pz_buf))
-              pz_buf++;
-            if ((*pz_buf == '\0') || (*pz_buf == '#'))
-              continue;
-            apz_names[file_name_ct++] = pz_buf;
-            pz_buf += strlen (pz_buf);
-            while (ISSPACE (pz_buf[-1]))
-              pz_buf--;
-            *pz_buf++ = '\0';
-          }
-      }
+      /*  Check for end of list  */
+
+      if (*file_name_buf == NUL)
+        break;
+
+      /*  Set global file name pointer and find end of name */
+
+      pz_curr_file = file_name_buf;
+      pz_end = strchr( pz_curr_file, '\n' );
+      if (pz_end == (char*)NULL)
+        pz_end = file_name_buf = pz_curr_file + strlen (pz_curr_file);
+      else
+        file_name_buf = pz_end + 1;
+
+      while ((pz_end > pz_curr_file) && ISSPACE( pz_end[-1]))  pz_end--;
+
+      /*  IF no name is found (blank line) or comment marker, skip line  */
+
+      if ((pz_curr_file == pz_end) || (*pz_curr_file == '#'))
+        continue;
+      *pz_end = NUL;
 
-      /*  IF we did not get any files this time thru
-          THEN we must be done.  */
-      if (file_name_ct == 0)
-        return EXIT_SUCCESS;
+#ifdef NO_BOGOSITY
+      process ();
+#else
+      /*  Prevent duplicate output by child process  */
 
       fflush (stdout);
       fflush (stderr);
 
       {
+        void wait_for_pid _P_(( pid_t ));
         pid_t child = fork ();
         if (child == NULLPROCESS)
-          break;
+          {
+            process ();
+            return EXIT_SUCCESS;
+          }
 
         if (child == NOPROCESS)
           {
@@ -253,52 +251,52 @@ main (argc, argv)
             exit (EXIT_FAILURE);
           }
 
-#ifdef DEBUG
-        fprintf (stderr, "Waiting for %d to complete %d files\n",
-                 child, file_name_ct);
-#endif
-
-        wait_for_pid( child, file_name_ct );
+        wait_for_pid( child );
       }
-    }
-#else
- /*#*/ error "NON-BOGUS LIMITS NOT SUPPORTED?!?!"
 #endif
+    } /*  for (;;) */
 
-  /*  For every file specified in stdandard in
-      (except as throttled for bogus reasons)...
-      */
-  for (loop_ct = 0; loop_ct < file_name_ct; loop_ct++)
-    {
-      char *pz_data;
-      char *pz_file_name = apz_names[loop_ct];
-
-      if (access (pz_file_name, R_OK) != 0)
-        {
-          int erno = errno;
-          fprintf (stderr, "Cannot access %s from %s\n\terror %d (%s)\n",
-                   pz_file_name, getcwd ((char *) NULL, MAXPATHLEN),
-                   erno, strerror (erno));
-        }
-      else if (pz_data = load_file (pz_file_name), (pz_data != (char *) NULL))
-        {
-          if (strstr (pz_data, gnu_lib_mark) == (char *) NULL)
-            process (pz_data, pz_file_name);
-          free ((void *) pz_data);
-        }
-    }
-
+#ifdef DO_STATS
+  {
+    tSCC zFmt[] =
+      "\
+Processed %5d files containing %d bytes    \n\
+Applying  %5d fixes to %d files\n\
+Altering  %5d of them\n";
+
+    fprintf (stderr, zFmt, process_ct, ttl_data_size, apply_ct,
+             fixed_ct, altered_ct);
+  }
+#endif /* DO_STATS */
   return EXIT_SUCCESS;
 }
 
 
+void
+do_version ()
+{
+  static const char zFmt[] = "echo '%s'";
+  char zBuf[ 1024 ];
+
+  /* The 'version' option is really used to test that:
+     1.  The program loads correctly (no missing libraries)
+     2.  we can correctly run our server shell process
+     3.  that we can compile all the regular expressions.
+  */
+  run_compiles ();
+  sprintf (zBuf, zFmt, program_id);
+  fputs (zBuf + 5, stdout);
+  exit (strcmp (run_shell (zBuf), program_id));
+}
+
 /* * * * * * * * * * * * */
 
 void
-initialize()
+initialize ()
 {
   static const char var_not_found[] =
-    "fixincl ERROR:  %s environment variable not defined\n";
+    "fixincl ERROR:  %s environment variable not defined\n\
+\tTARGET_MACHINE, DESTDIR, SRCDIR and FIND_BASE are required\n";
 
   {
     static const char var[] = "TARGET_MACHINE";
@@ -332,13 +330,16 @@ initialize()
 
   {
     static const char var[] = "FIND_BASE";
-    pz_find_base = getenv (var);
-    if (pz_find_base == (char *) NULL)
+    char *pz = getenv (var);
+    if (pz == (char *) NULL)
       {
         fprintf (stderr, var_not_found, var);
         exit (EXIT_FAILURE);
       }
-    find_base_len = strlen( pz_find_base );
+    while ((pz[0] == '.') && (pz[1] == '/'))
+      pz += 2;
+    if ((pz[0] != '.') || (pz[1] != NUL))
+      find_base_len = strlen( pz );
   }
 
   /*  Compile all the regular expressions now.
@@ -351,7 +352,7 @@ initialize()
   signal (SIGPIPE, SIG_IGN);
   signal (SIGALRM, SIG_IGN);
   signal (SIGTERM, SIG_IGN);
-
+#ifndef NO_BOGOSITY
   /*
      Make sure that if we opened a server process, we close it now.
      This is the grandparent process.  We don't need the server anymore
@@ -359,18 +360,19 @@ initialize()
 
   close_server ();
   (void)wait ( (int*)NULL );
+#endif
 }
 
+#ifndef NO_BOGOSITY
 /* * * * * * * * * * * * *
+
    wait_for_pid  -  Keep calling `wait(2)' until it returns
    the process id we are looking for.  Not every system has
    `waitpid(2)'.  We also ensure that the children exit with success. */
 
 void
-wait_for_pid(child, file_name_ct)
+wait_for_pid(child)
      pid_t child;
-     int file_name_ct;
 {
   for (;;) {
     int status;
@@ -414,91 +416,61 @@ wait_for_pid(child, file_name_ct)
       }
   } done_waiting:;
 }
-
+#endif /* NO_BOGOSITY */
 
 /* * * * * * * * * * * * *
+
    load_file loads all the contents of a file into malloc-ed memory.
    Its argument is the name of the file to read in; the returned
    result is the NUL terminated contents of the file.  The file
    is presumed to be an ASCII text file containing no NULs.  */
 char *
-load_file (pz_file_name)
-     const char *pz_file_name;
+load_file ( fname )
+    const char* fname;
 {
-  char *pz_data;
-  size_t file_size;
-
-  {
-    struct stat stbf;
-    
-    if (stat (pz_file_name, &stbf) != 0)
-      {
-        fprintf (stderr, "error %d (%s) stat-ing %s\n",
-                 errno, strerror (errno), pz_file_name);
-        return (char *) NULL;
-      }
-    file_size = stbf.st_size;
-  }
-  if (file_size == 0)
-    return (char *) NULL;
+  struct stat stbf;
+  char* res;
 
-  pz_data = (char *) malloc ((file_size + 16) & ~0x00F);
-  if (pz_data == (char *) NULL)
+  if (stat (fname, &stbf) != 0)
     {
-      fprintf (stderr, "error:  could not malloc %d bytes\n",
-               file_size);
-      exit (EXIT_FAILURE);
+      fprintf (stderr, "error %d (%s) stat-ing %s\n",
+               errno, strerror (errno), fname );
+      return (char *) NULL;
     }
+  if (stbf.st_size == 0)
+    return (char*)NULL;
 
-  {
-    FILE *fp = fopen (pz_file_name, "r");
-    size_t size_left = file_size;
-    char *read_ptr = pz_data;
-
-    if (fp == (FILE *) NULL)
-      {
-        fprintf (stderr, "error %d (%s) opening %s\n", errno,
-                 strerror (errno), pz_file_name);
-        free ((void *) pz_data);
-        return (char *) NULL;
-      }
-
-    do
-      {
-        size_t sizeRead = fread ((void *) read_ptr, 1, size_left, fp);
-
-        if (sizeRead == 0)
-          {
-            if (feof (fp))
-              break;
+  data_map_size = stbf.st_size+1;
+  data_map_fd   = open (fname, O_RDONLY);
+  ttl_data_size += data_map_size-1;
 
-            if (ferror (fp))
-              {
-                int err = errno;
-                if (err != EISDIR)
-                  fprintf (stderr, "error %d (%s) reading %s\n", err,
-                           strerror (err), pz_file_name);
-                free ((void *) pz_data);
-                fclose (fp);
-                return (char *) NULL;
-              }
-          }
+  if (data_map_fd < 0)
+    {
+      fprintf (stderr, "error %d (%s) opening %s for read\n",
+               errno, strerror (errno), fname);
+      return (char*)NULL;
+    }
 
-        read_ptr += sizeRead;
-        size_left -= sizeRead;
-      }
-    while (size_left != 0);
+#ifdef HAVE_MMAP
+  curr_data_mapped = BOOL_TRUE;
+  res = (char*)mmap ((void*)NULL, data_map_size, PROT_READ, MAP_PRIVATE,
+                     data_map_fd, 0);
+  if (res == (char*)BAD_ADDR)
+    {
+      curr_data_mapped = BOOL_FALSE;
+      res = load_file_data ( fdopen (data_map_fd, "r"));
+    }
+#else
+  curr_data_mapped = BOOL_FALSE;
+  res = load_file_data ( fdopen (data_map_fd, "r"));
+#endif
 
-    *read_ptr = '\0';
-    fclose (fp);
-  }
-  return pz_data;
+  return res;
 }
 
 
 /* * * * * * * * * * * * *
+
    run_compiles   run all the regexp compiles for all the fixes once.
  */
 void
@@ -555,28 +527,28 @@ run_compiles ()
       if (  (pz_machine != NULL)
          && (p_fixd->papz_machs != (const char**) NULL) )
         {
+          tSCC case_fmt[] = "case %s in\n";     /*  9 bytes, plus string */
+          tSCC esac_fmt[] = " )\n"              /*  3 bytes */
+                           "    echo %s ;;\n"   /* 13 bytes */
+                           "* ) echo %s ;;\n"   /* 13 bytes */
+                           "esac";              /*  4 bytes */
+          tSCC skip[] = "skip";                 /*  4 bytes */
+          tSCC run[] = "run";                   /*  3 bytes */
+          /* total bytes to add to machine sum:    49 - see fixincl.tpl */
+
           const char **papz_machs = p_fixd->papz_machs;
-          char *pz = file_name_buf;
+          char *pz;
           char *pz_sep = "";
           tCC *pz_if_true;
           tCC *pz_if_false;
-          tSCC skip[] = "skip";
-          tSCC run[] = "run";
-
-          /*  Construct a shell script that looks like this:
+          char cmd_buf[ MACH_LIST_SIZE_LIMIT ]; /* size lim from fixincl.tpl */
 
-              case our-cpu-platform-os in
-              tests-cpu-platform-os-pattern )
-                  echo run ;;
-              * )
-                  echo skip ;;
-              esac
+          /* Start the case statement */
 
-              where 'run' and 'skip' may be reversed, depending on
-              the sense of the test.  */
+          sprintf (cmd_buf, case_fmt, pz_machine);
+          pz = cmd_buf + strlen (cmd_buf);
 
-          sprintf (pz, "case %s in\n", pz_machine);
-          pz += strlen (pz);
+          /*  Determine if a match means to apply the fix or not apply it */
 
           if (p_fixd->fd_flags & FD_MACH_IFNOT)
             {
@@ -589,8 +561,8 @@ run_compiles ()
               pz_if_false = skip;
             }
 
-          /*  FOR any additional machine names to test for,
-              insert the " | \\\n" glue and the machine pattern.  */
+          /*  Emit all the machine names.  If there are more than one,
+              then we will insert " | \\\n" between the names  */
 
           for (;;)
             {
@@ -598,19 +570,21 @@ run_compiles ()
 
               if (pz_mach == (const char*) NULL)
                 break;
-              sprintf (pz, "%s  %s", pz_sep, pz_mach);
+              sprintf (pz, "%s%s", pz_sep, pz_mach);
               pz += strlen (pz);
               pz_sep = " | \\\n";
             }
-          sprintf (pz, " )\n    echo %s ;;\n  * )\n    echo %s ;;\nesac",
-                   pz_if_true, pz_if_false);
+
+          /* Now emit the match and not-match actions and the esac */
+
+          sprintf (pz, esac_fmt, pz_if_true, pz_if_false);
 
           /*  Run the script.
               The result will start either with 's' or 'r'.  */
 
           {
             int skip;
-            pz = run_shell (file_name_buf);
+            pz = run_shell (cmd_buf);
             skip = (*pz == 's');
             free ( (void*)pz );
             if (skip)
@@ -658,31 +632,21 @@ run_compiles ()
 
 
 /* * * * * * * * * * * * *
+
    create_file  Create the output modified file.
    Input:    the name of the file to create
    Returns:  a file pointer to the new, open file  */
 
-#define S_IRALL        (S_IRUSR | S_IWUSR | S_IRGRP | S_IROTH)
+#define S_IRALL (S_IRUSR | S_IWUSR | S_IRGRP | S_IROTH)
 
 FILE *
-create_file (pz_file_name)
-     const char *pz_file_name;
+create_file ()
 {
   int fd;
   FILE *pf;
   char fname[MAXPATHLEN];
 
-#ifdef DEBUG
-  if (strncmp( pz_file_name, pz_find_base, find_base_len ) != 0)
-    {
-      fprintf (stderr, "Error:  input file %s does not match %s/*\n",
-              pz_file_name, pz_find_base );
-      exit (1);
-    }
-#endif
-
-  sprintf (fname, "%s/%s", pz_dest_dir, pz_file_name + find_base_len);
+  sprintf (fname, "%s/%s", pz_dest_dir, pz_curr_file + find_base_len);
 
   fd = open (fname, O_WRONLY | O_CREAT | O_TRUNC, S_IRALL);
 
@@ -714,7 +678,7 @@ create_file (pz_file_name)
                errno, strerror (errno), fname);
       exit (EXIT_FAILURE);
     }
-  fprintf (stderr, "Fixed:  %s\n", pz_file_name);
+  fprintf (stderr, "Fixed:  %s\n", pz_curr_file);
   pf = fdopen (fd, "w");
 
 #ifdef LATER
@@ -725,7 +689,7 @@ create_file (pz_file_name)
     "    This had to be done to correct non-standard usages in the\n"
     "    original, manufacturer supplied header file.  */\n\n";
 
-    fprintf (pf, hdr, pz_file_name);
+    fprintf (pf, hdr, pz_curr_file);
   }
 #endif
   return pf;
@@ -737,13 +701,13 @@ create_file (pz_file_name)
   test_test   make sure a shell-style test expression passes.
   Input:  a pointer to the descriptor of the test to run and
           the name of the file that we might want to fix
-  Result: SUCCESS or FAILURE, depending on the result of the
+  Result: APPLY_FIX or SKIP_FIX, depending on the result of the
           shell script we run.  */
 
-t_success
-test_test (p_test, pz_file_name)
+int
+test_test (p_test, pz_test_file)
      tTestDesc *p_test;
-     char*      pz_file_name;
+     char*      pz_test_file;
 {
   tSCC cmd_fmt[] =
 "file=%s\n\
@@ -753,44 +717,44 @@ else echo FALSE\n\
 fi";
 
   char *pz_res;
-  t_success res = FAILURE;
+  int res = SKIP_FIX;
 
   static char cmd_buf[4096];
 
-  sprintf (cmd_buf, cmd_fmt, pz_file_name, p_test->pz_test_text);
+  sprintf (cmd_buf, cmd_fmt, pz_test_file, p_test->pz_test_text);
   pz_res = run_shell (cmd_buf);
   if (*pz_res == 'T')
-    res = SUCCESS;
+    res = APPLY_FIX;
   free ((void *) pz_res);
   return res;
 }
 
 
 /* * * * * * * * * * * * *
+
   egrep_test   make sure an egrep expression is found in the file text.
   Input:  a pointer to the descriptor of the test to run and
           the pointer to the contents of the file under suspicion
-  Result: SUCCESS if the pattern is found, FAILURE otherwise
+  Result: APPLY_FIX if the pattern is found, SKIP_FIX otherwise
 
-  The caller may choose 'FAILURE' as 'SUCCESS' if the sense of the test
+  The caller may choose to reverse meaning if the sense of the test
   is inverted.  */
 
-t_success
+int
 egrep_test (pz_data, p_test)
      char *pz_data;
      tTestDesc *p_test;
 {
   regmatch_t match;
 
-#ifndef NO_BOGOSITY
+#ifdef DEBUG
   if (p_test->p_test_regex == 0)
     fprintf (stderr, "fixincl ERROR RE not compiled:  `%s'\n",
              p_test->pz_test_text);
 #endif
   if (regexec (p_test->p_test_regex, pz_data, 1, &match, 0) == 0)
-    return SUCCESS;
-  return FAILURE;
+    return APPLY_FIX;
+  return SKIP_FIX;
 }
 
 
@@ -813,7 +777,7 @@ quoted_file_exists (pz_src_path, pz_file_path, pz_file)
 
   for (;;) {
     char ch = *pz_file++;
-    if (! ISGRAPH(ch))
+    if (! ISGRAPH( ch ))
       return 0;
     if (ch == '"')
       break;
@@ -832,7 +796,7 @@ quoted_file_exists (pz_src_path, pz_file_path, pz_file)
 /* * * * * * * * * * * * *
  *
    extract_quoted_files
-  
+
    The syntax, `#include "file.h"' specifies that the compiler is to
    search the local directory of the current file before the include
    list.  Consequently, if we have modified a header and stored it in
@@ -840,7 +804,7 @@ quoted_file_exists (pz_src_path, pz_file_path, pz_file)
    file in that fashion must also be copied into this new directory.
    This routine finds those flavors of #include and for each one found
    emits a triple of:
-  
+
     1.  source directory of the original file
     2.  the relative path file name of the #includ-ed file
     3.  the full destination path for this file
@@ -852,21 +816,21 @@ quoted_file_exists (pz_src_path, pz_file_path, pz_file)
 
 
 void
-extract_quoted_files (pz_data, pz_file_name, p_re_match)
+extract_quoted_files (pz_data, pz_fixed_file, p_re_match)
      char *pz_data;
-     const char *pz_file_name;
+     const char *pz_fixed_file;
      regmatch_t *p_re_match;
 {
-  char *pz_dir_end = strrchr (pz_file_name, '/');
+  char *pz_dir_end = strrchr (pz_fixed_file, '/');
   char *pz_incl_quot = pz_data;
 
-  fprintf (stderr, "Quoted includes in %s\n", pz_file_name);
+  fprintf (stderr, "Quoted includes in %s\n", pz_fixed_file);
 
-  /*  Set "pz_file_name" to point to the containing subdirectory of the source
+  /*  Set "pz_fixed_file" to point to the containing subdirectory of the source
       If there is none, then it is in our current directory, ".".   */
 
   if (pz_dir_end == (char *) NULL)
-    pz_file_name = ".";
+    pz_fixed_file = ".";
   else
     *pz_dir_end = '\0';
 
@@ -878,17 +842,17 @@ extract_quoted_files (pz_data, pz_file_name, p_re_match)
       while (ISSPACE (*pz_incl_quot))
         pz_incl_quot++;
       /* ISSPACE() may evaluate is argument more than once!  */
-      while ((++pz_incl_quot, ISSPACE (*pz_incl_quot)))
+      while (++pz_incl_quot, ISSPACE (*pz_incl_quot))
         ;
       pz_incl_quot += sizeof ("include") - 1;
       while (*pz_incl_quot++ != '"')
         ;
 
-      if (quoted_file_exists (pz_src_dir, pz_file_name, pz_incl_quot))
+      if (quoted_file_exists (pz_src_dir, pz_fixed_file, pz_incl_quot))
         {
           /* Print the source directory and the subdirectory
              of the file in question.  */
-          printf ("%s  %s/", pz_src_dir, pz_file_name);
+          printf ("%s  %s/", pz_src_dir, pz_fixed_file);
           pz_dir_end = pz_incl_quot;
 
           /* Append to the directory the relative path of the desired file */
@@ -897,7 +861,7 @@ extract_quoted_files (pz_data, pz_file_name, p_re_match)
 
           /* Now print the destination directory appended with the
              relative path of the desired file */
-          printf ("  %s/%s/", pz_dest_dir, pz_file_name);
+          printf ("  %s/%s/", pz_dest_dir, pz_fixed_file);
           while (*pz_dir_end != '"')
             putc (*pz_dir_end++, stdout);
 
@@ -912,6 +876,79 @@ extract_quoted_files (pz_data, pz_file_name, p_re_match)
 }
 
 
+/* * * * * * * * * * * * *
+
+    Somebody wrote a *_fix subroutine that we must call.
+    */
+
+int
+internal_fix (read_fd, p_fixd)
+  int read_fd;
+  tFixDesc* p_fixd;
+{
+  int fd[2];
+
+  if (pipe( fd ) != 0)
+    {
+      fprintf (stderr, "Error %d on pipe(2) call\n", errno );
+      exit (EXIT_FAILURE);
+    }
+
+  for (;;)
+    {
+      pid_t childid = fork();
+
+      switch (childid)
+        {
+        case -1:
+          break;
+
+        case 0:
+          close (fd[0]);
+          goto do_child_task;
+
+        default:
+          /*
+           *  Parent process
+           */
+          close (read_fd);
+          close (fd[1]);
+          return fd[0];
+        }
+
+      /*
+       *  Parent in error
+       */
+      fprintf (stderr, z_fork_err, errno, strerror (errno),
+               p_fixd->fix_name);
+      {
+        static int failCt = 0;
+        if ((errno != EAGAIN) || (++failCt > 10))
+          exit (EXIT_FAILURE);
+        sleep (1);
+      }
+    } do_child_task:;
+
+  /*
+   *  Close our current stdin and stdout
+   */
+  close (STDIN_FILENO);
+  close (STDOUT_FILENO);
+  UNLOAD_DATA();
+
+  /*
+   *  Make the fd passed in the stdin, and the write end of
+   *  the new pipe become the stdout.
+   */
+  fcntl (fd[1], F_DUPFD, STDOUT_FILENO);
+  fcntl (read_fd, F_DUPFD, STDIN_FILENO);
+  fdopen (STDIN_FILENO, "r");
+  fdopen (STDOUT_FILENO, "w");
+
+  apply_fix (p_fixd->patch_args[0], pz_curr_file);
+  exit (0);
+}
+
 
 /* * * * * * * * * * * * *
 
@@ -921,24 +958,31 @@ extract_quoted_files (pz_data, pz_file_name, p_re_match)
     for stdout.  */
 
 int
-start_fixer (read_fd, p_fixd, pz_file_name)
+start_fixer (read_fd, p_fixd, pz_fix_file)
   int read_fd;
   tFixDesc* p_fixd;
-  char* pz_file_name;
+  char* pz_fix_file;
 {
-  tSCC z_err[] = "Error %d (%s) starting filter process for %s\n";
   tCC* pz_cmd_save;
   char* pz_cmd;
 
+  if ((p_fixd->fd_flags & FD_SUBROUTINE) != 0)
+    return internal_fix (read_fd, p_fixd);
+
   if ((p_fixd->fd_flags & FD_SHELL_SCRIPT) == 0)
     pz_cmd = (char*)NULL;
   else
     {
       tSCC z_cmd_fmt[] = "file='%s'\n%s";
-      pz_cmd = (char*)xmalloc (strlen (p_fixd->patch_args[2])
+      pz_cmd = (char*)malloc (strlen (p_fixd->patch_args[2])
                                + sizeof( z_cmd_fmt )
-                               + strlen( pz_file_name ));
-      sprintf (pz_cmd, z_cmd_fmt, pz_file_name, p_fixd->patch_args[2]);
+                               + strlen( pz_fix_file ));
+      if (pz_cmd == (char*)NULL)
+        {
+          fputs ("allocation failure\n", stderr);
+          exit (EXIT_FAILURE);
+        }
+      sprintf (pz_cmd, z_cmd_fmt, pz_fix_file, p_fixd->patch_args[2]);
       pz_cmd_save = p_fixd->patch_args[2];
       p_fixd->patch_args[2] = pz_cmd;
     }
@@ -959,7 +1003,7 @@ start_fixer (read_fd, p_fixd, pz_file_name)
           break;
         }
 
-      fprintf (stderr, z_err, errno, strerror (errno),
+      fprintf (stderr, z_fork_err, errno, strerror (errno),
                p_fixd->fix_name);
 
       if ((errno != EAGAIN) || (++failCt > 10))
@@ -976,212 +1020,279 @@ start_fixer (read_fd, p_fixd, pz_file_name)
   return read_fd;
 }
 
+
 /* * * * * * * * * * * * *
 
    Process the potential fixes for a particular include file.
    Input:  the original text of the file and the file's name
    Result: none.  A new file may or may not be created.  */
 
-void
-process (pz_data, pz_file_name)
-     char *pz_data;
-     const char *pz_file_name;
+t_bool
+fix_applies (p_fixd)
+  tFixDesc *p_fixd;
 {
-  static char env_current_file[1024];
-  tFixDesc *p_fixd = fixDescList;
-  int todo_ct = FIX_COUNT;
-  int read_fd = -1;
-  int num_children = 0;
+  int test_ct;
+  tTestDesc *p_test;
 
-  process_chain_head = NOPROCESS;
-  fprintf (stderr, "%-50s   \r", pz_file_name );
-  /* For every fix in our fix list, ...  */
-  for (; todo_ct > 0; p_fixd++, todo_ct--)
-    {
-      tTestDesc *p_test;
-      int test_ct;
+  if (p_fixd->fd_flags & FD_SKIP_TEST)
+    return BOOL_FALSE;
 
-      if (p_fixd->fd_flags & FD_SKIP_TEST)
-        continue;
+  /*  IF there is a file name restriction,
+      THEN ensure the current file name matches one in the pattern  */
+
+  if (p_fixd->file_list != (char *) NULL)
+    {
+      const char *pz_fname = pz_curr_file;
+      const char *pz_scan = p_fixd->file_list;
+      size_t name_len;
 
-      /*  IF there is a file name restriction,
-          THEN ensure the current file name matches one in the pattern  */
+      while ((pz_fname[0] == '.') && (pz_fname[1] == '/'))
+        pz_fname += 2;
+      name_len = strlen (pz_fname);
 
-      if (p_fixd->file_list != (char *) NULL)
+      for (;;)
         {
-          const char *pz_fname = pz_file_name;
-          const char *pz_scan = p_fixd->file_list;
-          size_t name_len;
+          pz_scan = strstr (pz_scan + 1, pz_fname);
+          /*  IF we can't match the string at all,
+              THEN bail  */
+          if (pz_scan == (char *) NULL)
+            return BOOL_FALSE;
 
-          while ((pz_fname[0] == '.') && (pz_fname[1] == '/'))
-            pz_fname += 2;
-          name_len = strlen (pz_fname);
+          /*  IF the match is surrounded by the '|' markers,
+              THEN we found a full match -- time to run the tests  */
 
-          for (;;)
-            {
-              pz_scan = strstr (pz_scan + 1, pz_fname);
-              /*  IF we can't match the string at all,
-                  THEN bail  */
-              if (pz_scan == (char *) NULL)
-                goto next_fix;
+          if ((pz_scan[-1] == '|') && (pz_scan[name_len] == '|'))
+            break;
+        }
+    }
 
-              /*  IF the match is surrounded by the '|' markers,
-                  THEN we found a full match -- time to run the tests  */
+  /*  FOR each test, see if it fails.
+      IF it does fail, then we go on to the next test */
 
-              if ((pz_scan[-1] == '|') && (pz_scan[name_len] == '|'))
-                break;
-            }
+  for (p_test = p_fixd->p_test_desc, test_ct = p_fixd->test_ct;
+       test_ct-- > 0;
+       p_test++)
+    {
+      switch (p_test->type)
+        {
+        case TT_TEST:
+          if (test_test (p_test, pz_curr_file) != APPLY_FIX)
+            return BOOL_FALSE;
+          break;
+
+        case TT_EGREP:
+          if (egrep_test (pz_curr_data, p_test) != APPLY_FIX)
+            return BOOL_FALSE;
+          break;
+
+        case TT_NEGREP:
+          if (egrep_test (pz_curr_data, p_test) == APPLY_FIX)
+            /*  Negated sense  */
+            return BOOL_FALSE;
+          break;
+
+        case TT_FUNCTION:
+          if (run_test (p_test->pz_test_text, pz_curr_file, pz_curr_data)
+              != APPLY_FIX)
+            return BOOL_FALSE;
+          break;
         }
+    }
 
-      /*  FOR each test, see if it fails.
-          IF it does fail, then we go on to the next test */
+  return BOOL_TRUE;
+}
 
-      for (p_test = p_fixd->p_test_desc, test_ct = p_fixd->test_ct;
-           test_ct-- > 0;
-           p_test++)
-        {
-#ifdef DEBUG_TEST
-          static const char z_test_fail[] =
-            "%16s test %2d failed for %s\n";
-#endif
-          switch (p_test->type)
-            {
-            case TT_TEST:
-              if (!SUCCESSFUL (test_test (p_test, pz_file_name)))
-                {
-#ifdef DEBUG_TEST
-                  fprintf (stderr, z_test_fail, p_fixd->fix_name,
-                           p_fixd->test_ct - test_ct, pz_file_name);
-#endif
-                  goto next_fix;
-                }
-              break;
 
-            case TT_EGREP:
-              if (!SUCCESSFUL (egrep_test (pz_data, p_test)))
-                {
-#ifdef DEBUG_TEST
-                  fprintf (stderr, z_test_fail, p_fixd->fix_name,
-                           p_fixd->test_ct - test_ct, pz_file_name);
+/* * * * * * * * * * * * *
+
+   Write out a replacement file  */
+
+void
+write_replacement (p_fixd)
+  tFixDesc *p_fixd;
+{
+   const char* pz_text = p_fixd->patch_args[0];
+
+   if ((pz_text == (char*)NULL) || (*pz_text == NUL))
+     return;
+
+   {
+     FILE* out_fp = create_file (pz_curr_file);
+     fputs (pz_text, out_fp);
+     fclose (out_fp);
+   }
+}
+
+
+/* * * * * * * * * * * * *
+
+    We have work to do.  Read back in the output
+    of the filtering chain.  Compare each byte as we read it with
+    the contents of the original file.  As soon as we find any
+    difference, we will create the output file, write out all
+    the matched text and then copy any remaining data from the
+    output of the filter chain.
+    */
+void
+test_for_changes (read_fd)
+  int read_fd;
+{
+  FILE *in_fp = fdopen (read_fd, "r");
+  FILE *out_fp = (FILE *) NULL;
+  char *pz_cmp = pz_curr_data;
+
+#ifdef DO_STATS
+  fixed_ct++;
 #endif
-                  goto next_fix;
-                }
-              break;
+  for (;;)
+    {
+      int ch;
 
-            case TT_NEGREP:
-              if (SUCCESSFUL (egrep_test (pz_data, p_test)))
-                {
-#ifdef DEBUG_TEST
-                  fprintf (stderr, z_test_fail, p_fixd->fix_name,
-                           p_fixd->test_ct - test_ct, pz_file_name);
+      ch = getc (in_fp);
+      if (ch == EOF)
+        break;
+
+      /*  IF we are emitting the output
+          THEN emit this character, too.
+      */
+      if (out_fp != (FILE *) NULL)
+        putc (ch, out_fp);
+
+      /*  ELSE if this character does not match the original,
+          THEN now is the time to start the output.
+      */
+      else if (ch != *pz_cmp)
+        {
+          out_fp = create_file (pz_curr_file);
+
+#ifdef DO_STATS
+          altered_ct++;
 #endif
-                  goto next_fix;
-                }
-              break;
-            }
+          /*  IF there are matched data, write the matched part now. */
+          if (pz_cmp != pz_curr_data)
+            fwrite (pz_curr_data, (size_t)(pz_cmp - pz_curr_data), 1, out_fp);
+
+          /*  Emit the current unmatching character */
+          putc (ch, out_fp);
         }
+      else
+        /*  ELSE the character matches.  Advance the compare ptr */
+        pz_cmp++;
+    }
+
+  /*  IF we created the output file, ... */
+  if (out_fp != (FILE *) NULL)
+    {
+      regmatch_t match;
+
+      /* Close the file and see if we have to worry about
+         `#include "file.h"' constructs.  */
+      fclose (out_fp);
+      if (regexec (&incl_quote_re, pz_curr_data, 1, &match, 0) == 0)
+        extract_quoted_files (pz_curr_data, pz_curr_file, &match);
+    }
+
+  fclose (in_fp);
+  close (read_fd);  /* probably redundant, but I'm paranoid */
+}
+
+
+/* * * * * * * * * * * * *
+
+   Process the potential fixes for a particular include file.
+   Input:  the original text of the file and the file's name
+   Result: none.  A new file may or may not be created.  */
+
+void
+process ()
+{
+  static char env_current_file[1024];
+  tFixDesc *p_fixd = fixDescList;
+  int todo_ct = FIX_COUNT;
+  int read_fd = -1;
+  int num_children = 0;
+
+  if (access (pz_curr_file, R_OK) != 0)
+    {
+      int erno = errno;
+      fprintf (stderr, "Cannot access %s from %s\n\terror %d (%s)\n",
+               pz_curr_file, getcwd ((char *) NULL, MAXPATHLEN),
+               erno, strerror (erno));
+      return;
+    }
+
+  pz_curr_data = load_file (pz_curr_file);
+  if (pz_curr_data == (char *) NULL)
+    return;
+
+#ifdef DO_STATS
+  process_ct++;
+#endif
+  fprintf (stderr, "%6d %-50s   \r", data_map_size, pz_curr_file );
+  if (strstr (pz_curr_data, gnu_lib_mark) != (char *) NULL)
+    {
+      UNLOAD_DATA();
+      return;
+    }
+
+  process_chain_head = NOPROCESS;
+
+  /* For every fix in our fix list, ...  */
+  for (; todo_ct > 0; p_fixd++, todo_ct--)
+    {
+      if (! fix_applies (p_fixd))
+        continue;
 
       fprintf (stderr, "Applying %-24s to %s\n",
-               p_fixd->fix_name, pz_file_name);
+               p_fixd->fix_name, pz_curr_file);
+
+      if (p_fixd->fd_flags & FD_REPLACEMENT)
+        {
+          write_replacement (p_fixd);
+          UNLOAD_DATA();
+          return;
+        }
 
       /*  IF we do not have a read pointer,
           THEN this is the first fix for the current file.
           Open the source file.  That will be used as stdin for
           the first fix.  Any subsequent fixes will use the
-          stdout descriptor of the previous fix as its stdin.  */
+          stdout descriptor of the previous fix for its stdin.  */
 
       if (read_fd == -1)
         {
-          read_fd = open (pz_file_name, O_RDONLY);
+          read_fd = open (pz_curr_file, O_RDONLY);
           if (read_fd < 0)
             {
               fprintf (stderr, "Error %d (%s) opening %s\n", errno,
-                       strerror (errno), pz_file_name);
+                       strerror (errno), pz_curr_file);
               exit (EXIT_FAILURE);
             }
+
+          /*  Ensure we do not get duplicate output */
+
+          fflush (stdout);
         }
 
-      read_fd = start_fixer (read_fd, p_fixd, pz_file_name);
+      read_fd = start_fixer (read_fd, p_fixd, pz_curr_file);
       num_children++;
-
-    next_fix:
-      ;
     }
 
-  /*  IF after all the tests we did not start any patch programs,
-      THEN quit now.   */
-
-  if (read_fd < 0)
-    return;
-
-  /*  OK.  We have work to do.  Read back in the output
-      of the filtering chain.  Compare each byte as we read it with
-      the contents of the original file.  As soon as we find any
-      difference, we will create the output file, write out all
-      the matched text and then copy any remaining data from the
-      output of the filter chain.
-      */
-  {
-    FILE *in_fp = fdopen (read_fd, "r");
-    FILE *out_fp = (FILE *) NULL;
-    char *pz_cmp = pz_data;
-
-    for (;;)
-      {
-        int ch;
-
-        ch = getc (in_fp);
-        if (ch == EOF)
-          break;
-
-        /*  IF we are emitting the output
-            THEN emit this character, too.
-            */
-        if (out_fp != (FILE *) NULL)
-          putc (ch, out_fp);
-
-        /*  ELSE if this character does not match the original,
-            THEN now is the time to start the output.
-            */
-        else if (ch != *pz_cmp)
-          {
-            out_fp = create_file (pz_file_name);
+  /*  IF we have a read-back file descriptor,
+      THEN check for changes and write output if changed.   */
 
-            /*  IF there are matched data, write it all now. */
-            if (pz_cmp != pz_data)
-              {
-                char c = *pz_cmp;
-                
-                *pz_cmp = NUL;
-                fputs (pz_data, out_fp);
-                *pz_cmp = c;
-              }
-
-            /*  Emit the current unmatching character */
-            putc (ch, out_fp);
-          }
-        else
-          /*  ELSE the character matches.  Advance the compare ptr */
-          pz_cmp++;
-      }
-
-    /*  IF we created the output file, ... */
-    if (out_fp != (FILE *) NULL)
-      {
-        regmatch_t match;
-
-        /* Close the file and see if we have to worry about
-          `#include "file.h"' constructs.  */
-        fclose (out_fp);
-        if (regexec (&incl_quote_re, pz_data, 1, &match, 0) == 0)
-          extract_quoted_files (pz_data, pz_file_name, &match);
-      }
-    fclose (in_fp);
-  }
-  close (read_fd);  /* probably redundant, but I'm paranoid */
+  if (read_fd >= 0)
+    {
+      test_for_changes (read_fd);
+#ifdef DO_STATS
+      apply_ct += num_children;
+#endif
+      /* Wait for child processes created by chain_open()
+         to avoid leaving zombies.  */
+      do  {
+        wait ((int *) NULL);
+      } while (--num_children > 0);
+    }
 
-  /* Wait for child processes created by chain_open()
-     to avoid creating zombies.  */
-  while (--num_children >= 0)
-    wait ((int *) NULL);
+  UNLOAD_DATA();
 }
index afdd131..58a9865 100644 (file)
@@ -15,12 +15,13 @@ x =]
                                 =] The Free Software Foundation, Inc.
  *
 [=_eval inclhack "# *  " _gpl=]
- *[=_EVAL "re_ct=0" _shell=][=
+ *[=_EVAL "re_ct=0\nmax_mach=0" _shell=][=
 
 _FOR fix =]
  *
- *  Description [=_eval _index 1 + "#%3d -" _printf=] [=hackname _Cap=] fix
+ *  Description of [=hackname _Cap=] fix
  */
+#define [=hackname _up #_FIXIDX + #%-32s _printf=] [=_eval _index=]
 tSCC z[=hackname _cap=]Name[] =
      [=hackname _cap _krstr=];
 /*
@@ -40,11 +41,18 @@ tSCC z[=hackname _cap=]List[] =
 
   _IF mach _exist=]
 tSCC* apz[=hackname _cap=]Machs[] = {[=
+    _EVAL "this_mach=0" _shell =][=
+
     _FOR mach =]
         [=mach _krstr=],[=
+      _EVAL mach _len "this_mach=`expr $this_mach + %d + 5`"
+            _printf _shell =][=
     /mach=]
         (const char*)NULL };[=
 
+    _EVAL "if [ $this_mach -gt $max_mach ] ; then max_mach=$this_mach ; fi"
+          _shell =][=
+
   _ELSE =]
 #define apz[=hackname _cap=]Machs (const char**)NULL[=
   _ENDIF "files _exist" =][=
@@ -94,24 +102,37 @@ tSCC z[=hackname _cap=]Test[=_eval _index=][] =
     /test =][=
   _ENDIF =][=
 
+  _IF c_test _exist=]
+
+/*
+ *  perform the C function call test
+ */[=
+    _FOR c_test =]
+tSCC z[=hackname _cap=]FTst[=_eval _index=][] = "[=c_test=]";[=
+    /c_test =][=
+  _ENDIF =][=
+
 
 #  Build the array of test descriptions for this fix: =][=
 
-  _IF exesel       _exist
-      select       _exist |
-      bypass       _exist |
-      test         _exist |
+  _IF exesel  _exist
+      select  _exist |
+      bypass  _exist |
+      test    _exist |
+      c_test  _exist |
 =]
 
 #define    [=hackname _up =]_TEST_CT  [=
     _IF exesel _exist =][=
        _eval exesel       _count
             bypass       _count +
-            test         _count + =][=
+            test         _count + 
+            c_test       _count + =][=
     _ELSE =][=
        _eval select       _count
             bypass       _count +
-            test         _count + =][=
+            test         _count + 
+            c_test       _count + =][=
     _ENDIF =]
 #define    [=hackname _up =]_RE_CT    [=
     _IF exesel _exist =][=
@@ -126,11 +147,15 @@ tSCC z[=hackname _cap=]Test[=_eval _index=][] =
 tTestDesc a[=hackname _cap=]Tests[] = {[=
 
     _FOR test =]
-  { TT_TEST,   z[=hackname _cap=]Test[=_eval _index=],     0 /* unused */ },[=
+  { TT_TEST,     z[=hackname _cap=]Test[=_eval _index=],   0 /* unused */ },[=
     /test =][=
 
+    _FOR c_test =]
+  { TT_FUNCTION, z[=hackname _cap=]FTst[=_eval _index=],   0 /* unused */ },[=
+    /c_test =][=
+
     _FOR bypass =]
-  { TT_NEGREP, z[=hackname _cap=]Bypass[=_eval _index=],   (regex_t*)NULL },[=
+  { TT_NEGREP,   z[=hackname _cap=]Bypass[=_eval _index=], (regex_t*)NULL },[=
     /bypass =][=
 
     #  IF there is an exesel, then use that (those) selection
@@ -138,12 +163,12 @@ tTestDesc a[=hackname _cap=]Tests[] = {[=
     =][=
     _IF exesel _exist =][=
       _FOR exesel =]
-  { TT_EGREP,  z[=hackname _cap=]Select[=_eval _index=],   (regex_t*)NULL },[=
+  { TT_EGREP,    z[=hackname _cap=]Select[=_eval _index=], (regex_t*)NULL },[=
       /exesel =][=
 
     _ELSE =][=
       _FOR select =]
-  { TT_EGREP,  z[=hackname _cap=]Select[=_eval _index=],   (regex_t*)NULL },[=
+  { TT_EGREP,    z[=hackname _cap=]Select[=_eval _index=], (regex_t*)NULL },[=
       /select =][=
     _ENDIF =] };[=
   _ELSE =]
@@ -156,11 +181,20 @@ tTestDesc a[=hackname _cap=]Tests[] = {[=
  *  Fix Command Arguments for [=hackname _cap=]
  */
 const char* apz[=hackname _cap=]Patch[] = {[=
-    _IF   sed         _exist =] "sed"[=_FOR sed=],
-    "-e", [=sed _krstr=][=/sed=][=
+    _IF   sed         _exist =] "sed"[=
+      _FOR sed=],
+    "-e", [=sed _krstr=][=
+      /sed=],[=
+
     _ELIF shell       _exist =] "sh", "-c",
-    [=shell _krstr=][=
-    _ENDIF=],
+    [=shell _krstr=],[=
+
+    _ELIF c_fix _exist =]"[=c_fix=]",[=
+
+    _ELIF replace _len =]
+[=replace _krstr=],[=
+
+    _ENDIF=]
     (char*)NULL };
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *[=
@@ -168,8 +202,16 @@ const char* apz[=hackname _cap=]Patch[] = {[=
  *
  *  List of all fixes
  */
-#define  REGEX_COUNT  [=_eval "echo $re_ct" _shell =]
-#define  FIX_COUNT    [=_eval fix _count =]
+[=_EVAL '
+echo "#define REGEX_COUNT          $re_ct"
+echo "#define MACH_LIST_SIZE_LIMIT `expr $max_mach + 128`" ' _shell =][=
+
+#  as of this writing, 49 bytes are needed by the case statement format.
+   We also must allow for the size of the target machine machine name.
+   This allows for a 79 byte machine name.  Better be enough.
+=]
+#define FIX_COUNT            [=_eval fix _count =]
+
 tFixDesc fixDescList[ FIX_COUNT ] = {[=
 
 
@@ -180,7 +222,9 @@ _FOR fix ",\n" =]
        _IF not_machine _exist =]FD_MACH_IFNOT[=
        _ELSE                  =]FD_MACH_ONLY[=
        _ENDIF =][=
-       _IF shell       _exist =] | FD_SHELL_SCRIPT[=
+       _IF    shell    _exist =] | FD_SHELL_SCRIPT[=
+       _ELIF  c_fix    _exist =] | FD_SUBROUTINE[=
+       _ELIF  replace  _exist =] | FD_REPLACEMENT[=
        _ENDIF =],
      a[=hackname _cap=]Tests,   apz[=hackname _cap=]Patch }[=
 
index d17614b..51afb75 100644 (file)
  *             Boston,  MA  02111-1307, USA.
  *
  *
- *  Description   1 - Aix_Syswait fix
+ *  Description of Aaa_Ki_Iface fix
  */
+#define AAA_KI_IFACE_FIXIDX              0
+tSCC zAaa_Ki_IfaceName[] =
+     "Aaa_Ki_Iface";
+/*
+ *  File name selection pattern
+ */
+tSCC zAaa_Ki_IfaceList[] =
+  "|sys/ki_iface.h|";
+/*
+ *  Machine/OS name selection pattern
+ */
+#define apzAaa_Ki_IfaceMachs (const char**)NULL
+
+/*
+ *  content selection pattern - do fix if pattern found
+ */
+tSCC zAaa_Ki_IfaceSelect0[] =
+       "These definitions are for HP Internal developers";
+
+#define    AAA_KI_IFACE_TEST_CT  1
+#define    AAA_KI_IFACE_RE_CT    1
+tTestDesc aAaa_Ki_IfaceTests[] = {
+  { TT_EGREP,    zAaa_Ki_IfaceSelect0, (regex_t*)NULL }, };
+
+/*
+ *  Fix Command Arguments for Aaa_Ki_Iface
+ */
+const char* apzAaa_Ki_IfacePatch[] = {
+    (char*)NULL };
+
+/* * * * * * * * * * * * * * * * * * * * * * * * * *
+ *
+ *  Description of Aaa_Ki fix
+ */
+#define AAA_KI_FIXIDX                    1
+tSCC zAaa_KiName[] =
+     "Aaa_Ki";
+/*
+ *  File name selection pattern
+ */
+tSCC zAaa_KiList[] =
+  "|sys/ki.h|";
+/*
+ *  Machine/OS name selection pattern
+ */
+#define apzAaa_KiMachs (const char**)NULL
+
+/*
+ *  content selection pattern - do fix if pattern found
+ */
+tSCC zAaa_KiSelect0[] =
+       "11.00 HP-UX LP64";
+
+#define    AAA_KI_TEST_CT  1
+#define    AAA_KI_RE_CT    1
+tTestDesc aAaa_KiTests[] = {
+  { TT_EGREP,    zAaa_KiSelect0, (regex_t*)NULL }, };
+
+/*
+ *  Fix Command Arguments for Aaa_Ki
+ */
+const char* apzAaa_KiPatch[] = {
+    (char*)NULL };
+
+/* * * * * * * * * * * * * * * * * * * * * * * * * *
+ *
+ *  Description of Aaa_Ki_Calls fix
+ */
+#define AAA_KI_CALLS_FIXIDX              2
+tSCC zAaa_Ki_CallsName[] =
+     "Aaa_Ki_Calls";
+/*
+ *  File name selection pattern
+ */
+tSCC zAaa_Ki_CallsList[] =
+  "|sys/ki_calls.h|";
+/*
+ *  Machine/OS name selection pattern
+ */
+#define apzAaa_Ki_CallsMachs (const char**)NULL
+
+/*
+ *  content selection pattern - do fix if pattern found
+ */
+tSCC zAaa_Ki_CallsSelect0[] =
+       "kthread_create_caller_t";
+
+#define    AAA_KI_CALLS_TEST_CT  1
+#define    AAA_KI_CALLS_RE_CT    1
+tTestDesc aAaa_Ki_CallsTests[] = {
+  { TT_EGREP,    zAaa_Ki_CallsSelect0, (regex_t*)NULL }, };
+
+/*
+ *  Fix Command Arguments for Aaa_Ki_Calls
+ */
+const char* apzAaa_Ki_CallsPatch[] = {
+    (char*)NULL };
+
+/* * * * * * * * * * * * * * * * * * * * * * * * * *
+ *
+ *  Description of Aaa_Ki_Defs fix
+ */
+#define AAA_KI_DEFS_FIXIDX               3
+tSCC zAaa_Ki_DefsName[] =
+     "Aaa_Ki_Defs";
+/*
+ *  File name selection pattern
+ */
+tSCC zAaa_Ki_DefsList[] =
+  "|sys/ki_defs.h|";
+/*
+ *  Machine/OS name selection pattern
+ */
+#define apzAaa_Ki_DefsMachs (const char**)NULL
+
+/*
+ *  content selection pattern - do fix if pattern found
+ */
+tSCC zAaa_Ki_DefsSelect0[] =
+       "Kernel Instrumentation Definitions";
+
+#define    AAA_KI_DEFS_TEST_CT  1
+#define    AAA_KI_DEFS_RE_CT    1
+tTestDesc aAaa_Ki_DefsTests[] = {
+  { TT_EGREP,    zAaa_Ki_DefsSelect0, (regex_t*)NULL }, };
+
+/*
+ *  Fix Command Arguments for Aaa_Ki_Defs
+ */
+const char* apzAaa_Ki_DefsPatch[] = {
+    (char*)NULL };
+
+/* * * * * * * * * * * * * * * * * * * * * * * * * *
+ *
+ *  Description of Aaa_Bad_Fixes fix
+ */
+#define AAA_BAD_FIXES_FIXIDX             4
+tSCC zAaa_Bad_FixesName[] =
+     "Aaa_Bad_Fixes";
+/*
+ *  File name selection pattern
+ */
+tSCC zAaa_Bad_FixesList[] =
+  "|sundev/ipi_error.h|";
+/*
+ *  Machine/OS name selection pattern
+ */
+#define apzAaa_Bad_FixesMachs (const char**)NULL
+#define AAA_BAD_FIXES_TEST_CT  0
+#define AAA_BAD_FIXES_RE_CT    0
+#define aAaa_Bad_FixesTests   (tTestDesc*)NULL
+
+/*
+ *  Fix Command Arguments for Aaa_Bad_Fixes
+ */
+const char* apzAaa_Bad_FixesPatch[] = {
+    (char*)NULL };
+
+/* * * * * * * * * * * * * * * * * * * * * * * * * *
+ *
+ *  Description of Aaa_Time fix
+ */
+#define AAA_TIME_FIXIDX                  5
+tSCC zAaa_TimeName[] =
+     "Aaa_Time";
+/*
+ *  File name selection pattern
+ */
+tSCC zAaa_TimeList[] =
+  "|sys/time.h|";
+/*
+ *  Machine/OS name selection pattern
+ */
+#define apzAaa_TimeMachs (const char**)NULL
+
+/*
+ *  content selection pattern - do fix if pattern found
+ */
+tSCC zAaa_TimeSelect0[] =
+       "11.0 and later representation of ki time";
+
+#define    AAA_TIME_TEST_CT  1
+#define    AAA_TIME_RE_CT    1
+tTestDesc aAaa_TimeTests[] = {
+  { TT_EGREP,    zAaa_TimeSelect0, (regex_t*)NULL }, };
+
+/*
+ *  Fix Command Arguments for Aaa_Time
+ */
+const char* apzAaa_TimePatch[] = {
+    (char*)NULL };
+
+/* * * * * * * * * * * * * * * * * * * * * * * * * *
+ *
+ *  Description of Aab_Dgux_Int_Varargs fix
+ */
+#define AAB_DGUX_INT_VARARGS_FIXIDX      6
+tSCC zAab_Dgux_Int_VarargsName[] =
+     "Aab_Dgux_Int_Varargs";
+/*
+ *  File name selection pattern
+ */
+tSCC zAab_Dgux_Int_VarargsList[] =
+  "|_int_varargs.h|";
+/*
+ *  Machine/OS name selection pattern
+ */
+#define apzAab_Dgux_Int_VarargsMachs (const char**)NULL
+#define AAB_DGUX_INT_VARARGS_TEST_CT  0
+#define AAB_DGUX_INT_VARARGS_RE_CT    0
+#define aAab_Dgux_Int_VarargsTests   (tTestDesc*)NULL
+
+/*
+ *  Fix Command Arguments for Aab_Dgux_Int_Varargs
+ */
+const char* apzAab_Dgux_Int_VarargsPatch[] = {
+"#ifndef __INT_VARARGS_H\n\
+#define __INT_VARARGS_H\n\
+\n\
+/************************************************************************/\n\
+/* _INT_VARARGS.H - Define the common stuff for varargs/stdarg/stdio.   */\n\
+/************************************************************************/\n\
+\n\
+/*\n\
+** This file is a DG internal header.  Never include this\n\
+** file directly.\n\
+*/\n\
+\n\
+#ifndef ___int_features_h\n\
+#include &lt;sys/_int_features.h&gt;\n\
+#endif\n\
+\n\
+#if !(defined(_VA_LIST) || defined(_VA_LIST_))\n\
+#define _VA_LIST\n\
+#define _VA_LIST_\n\
+\n\
+#ifdef __LINT__\n\
+\n\
+#ifdef __STDC__\n\
+typedef void * va_list;\n\
+#else\n\
+typedef char * va_list;\n\
+#endif\n\
+\n\
+#else\n\
+#if _M88K_ANY\n\
+\n\
+#if defined(__DCC__)\n\
+\n\
+typedef struct {\n\
+      int     next_arg;\n\
+      int     *mem_ptr;\n\
+      int     *reg_ptr;\n\
+} va_list;\n\
+\n\
+#else  /* ! defined(__DCC__) */\n\
+\n\
+typedef struct {\n\
+      int  __va_arg;       /* argument number */\n\
+      int *__va_stk;       /* start of args passed on stack */\n\
+      int *__va_reg;       /* start of args passed in regs */\n\
+} va_list;\n\
+\n\
+#endif  /* ! defined(__DCC__) */\n\
+\n\
+#elif _IX86_ANY\n\
+\n\
+#if defined(__GNUC__) || defined(__STDC__)\n\
+typedef void * va_list;\n\
+#else\n\
+typedef char * va_list;\n\
+#endif\n\
+\n\
+#endif  /*  _IX86_ANY */\n\
+\n\
+#endif /* __LINT__ */\n\
+#endif /*  !(defined(_VA_LIST) || defined(_VA_LIST_)) */\n\
+#endif /*  #ifndef __INT_VARARGS_H  */\n",
+    (char*)NULL };
+
+/* * * * * * * * * * * * * * * * * * * * * * * * * *
+ *
+ *  Description of Aix_Syswait fix
+ */
+#define AIX_SYSWAIT_FIXIDX               7
 tSCC zAix_SyswaitName[] =
      "Aix_Syswait";
 /*
@@ -52,7 +337,7 @@ tSCC zAix_SyswaitSelect0[] =
 #define    AIX_SYSWAIT_TEST_CT  1
 #define    AIX_SYSWAIT_RE_CT    1
 tTestDesc aAix_SyswaitTests[] = {
-  { TT_EGREP,  zAix_SyswaitSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zAix_SyswaitSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Aix_Syswait
@@ -64,8 +349,9 @@ struct rusage;\n",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description   2 - Aix_Volatile fix
+ *  Description of Aix_Volatile fix
  */
+#define AIX_VOLATILE_FIXIDX              8
 tSCC zAix_VolatileName[] =
      "Aix_Volatile";
 /*
@@ -87,7 +373,7 @@ tSCC zAix_VolatileSelect0[] =
 #define    AIX_VOLATILE_TEST_CT  1
 #define    AIX_VOLATILE_RE_CT    1
 tTestDesc aAix_VolatileTests[] = {
-  { TT_EGREP,  zAix_VolatileSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zAix_VolatileSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Aix_Volatile
@@ -98,8 +384,9 @@ const char* apzAix_VolatilePatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description   3 - Alpha_Getopt fix
+ *  Description of Alpha_Getopt fix
  */
+#define ALPHA_GETOPT_FIXIDX              9
 tSCC zAlpha_GetoptName[] =
      "Alpha_Getopt";
 /*
@@ -121,7 +408,7 @@ tSCC zAlpha_GetoptSelect0[] =
 #define    ALPHA_GETOPT_TEST_CT  1
 #define    ALPHA_GETOPT_RE_CT    1
 tTestDesc aAlpha_GetoptTests[] = {
-  { TT_EGREP,  zAlpha_GetoptSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zAlpha_GetoptSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Alpha_Getopt
@@ -132,8 +419,9 @@ const char* apzAlpha_GetoptPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description   4 - Alpha_Parens fix
+ *  Description of Alpha_Parens fix
  */
+#define ALPHA_PARENS_FIXIDX              10
 tSCC zAlpha_ParensName[] =
      "Alpha_Parens";
 /*
@@ -155,7 +443,7 @@ tSCC zAlpha_ParensSelect0[] =
 #define    ALPHA_PARENS_TEST_CT  1
 #define    ALPHA_PARENS_RE_CT    1
 tTestDesc aAlpha_ParensTests[] = {
-  { TT_EGREP,  zAlpha_ParensSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zAlpha_ParensSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Alpha_Parens
@@ -166,8 +454,9 @@ const char* apzAlpha_ParensPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description   5 - Alpha_Sbrk fix
+ *  Description of Alpha_Sbrk fix
  */
+#define ALPHA_SBRK_FIXIDX                11
 tSCC zAlpha_SbrkName[] =
      "Alpha_Sbrk";
 /*
@@ -189,7 +478,7 @@ tSCC zAlpha_SbrkSelect0[] =
 #define    ALPHA_SBRK_TEST_CT  1
 #define    ALPHA_SBRK_RE_CT    1
 tTestDesc aAlpha_SbrkTests[] = {
-  { TT_EGREP,  zAlpha_SbrkSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zAlpha_SbrkSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Alpha_Sbrk
@@ -200,8 +489,9 @@ const char* apzAlpha_SbrkPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description   6 - Arm_Norcroft_Hint fix
+ *  Description of Arm_Norcroft_Hint fix
  */
+#define ARM_NORCROFT_HINT_FIXIDX         12
 tSCC zArm_Norcroft_HintName[] =
      "Arm_Norcroft_Hint";
 /*
@@ -223,7 +513,7 @@ tSCC zArm_Norcroft_HintSelect0[] =
 #define    ARM_NORCROFT_HINT_TEST_CT  1
 #define    ARM_NORCROFT_HINT_RE_CT    1
 tTestDesc aArm_Norcroft_HintTests[] = {
-  { TT_EGREP,  zArm_Norcroft_HintSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zArm_Norcroft_HintSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Arm_Norcroft_Hint
@@ -234,8 +524,9 @@ const char* apzArm_Norcroft_HintPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description   7 - Arm_Wchar fix
+ *  Description of Arm_Wchar fix
  */
+#define ARM_WCHAR_FIXIDX                 13
 tSCC zArm_WcharName[] =
      "Arm_Wchar";
 /*
@@ -257,7 +548,7 @@ tSCC zArm_WcharSelect0[] =
 #define    ARM_WCHAR_TEST_CT  1
 #define    ARM_WCHAR_RE_CT    1
 tTestDesc aArm_WcharTests[] = {
-  { TT_EGREP,  zArm_WcharSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zArm_WcharSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Arm_Wchar
@@ -269,8 +560,9 @@ const char* apzArm_WcharPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description   8 - Aux_Asm fix
+ *  Description of Aux_Asm fix
  */
+#define AUX_ASM_FIXIDX                   14
 tSCC zAux_AsmName[] =
      "Aux_Asm";
 /*
@@ -292,7 +584,7 @@ tSCC zAux_AsmSelect0[] =
 #define    AUX_ASM_TEST_CT  1
 #define    AUX_ASM_RE_CT    1
 tTestDesc aAux_AsmTests[] = {
-  { TT_EGREP,  zAux_AsmSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zAux_AsmSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Aux_Asm
@@ -303,8 +595,9 @@ const char* apzAux_AsmPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description   9 - Avoid_Bool fix
+ *  Description of Avoid_Bool fix
  */
+#define AVOID_BOOL_FIXIDX                15
 tSCC zAvoid_BoolName[] =
      "Avoid_Bool";
 /*
@@ -348,8 +641,9 @@ const char* apzAvoid_BoolPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  10 - Bad_Struct_Term fix
+ *  Description of Bad_Struct_Term fix
  */
+#define BAD_STRUCT_TERM_FIXIDX           16
 tSCC zBad_Struct_TermName[] =
      "Bad_Struct_Term";
 /*
@@ -371,7 +665,7 @@ tSCC zBad_Struct_TermSelect0[] =
 #define    BAD_STRUCT_TERM_TEST_CT  1
 #define    BAD_STRUCT_TERM_RE_CT    1
 tTestDesc aBad_Struct_TermTests[] = {
-  { TT_EGREP,  zBad_Struct_TermSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zBad_Struct_TermSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Bad_Struct_Term
@@ -382,8 +676,9 @@ const char* apzBad_Struct_TermPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  11 - Badquote fix
+ *  Description of Badquote fix
  */
+#define BADQUOTE_FIXIDX                  17
 tSCC zBadquoteName[] =
      "Badquote";
 /*
@@ -408,8 +703,9 @@ const char* apzBadquotePatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  12 - Bad_Lval fix
+ *  Description of Bad_Lval fix
  */
+#define BAD_LVAL_FIXIDX                  18
 tSCC zBad_LvalName[] =
      "Bad_Lval";
 /*
@@ -434,8 +730,9 @@ const char* apzBad_LvalPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  13 - Broken_Assert_Stdio fix
+ *  Description of Broken_Assert_Stdio fix
  */
+#define BROKEN_ASSERT_STDIO_FIXIDX       19
 tSCC zBroken_Assert_StdioName[] =
      "Broken_Assert_Stdio";
 /*
@@ -463,8 +760,8 @@ tSCC zBroken_Assert_StdioBypass0[] =
 #define    BROKEN_ASSERT_STDIO_TEST_CT  2
 #define    BROKEN_ASSERT_STDIO_RE_CT    2
 tTestDesc aBroken_Assert_StdioTests[] = {
-  { TT_NEGREP, zBroken_Assert_StdioBypass0,   (regex_t*)NULL },
-  { TT_EGREP,  zBroken_Assert_StdioSelect0,   (regex_t*)NULL }, };
+  { TT_NEGREP,   zBroken_Assert_StdioBypass0, (regex_t*)NULL },
+  { TT_EGREP,    zBroken_Assert_StdioSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Broken_Assert_Stdio
@@ -476,8 +773,9 @@ const char* apzBroken_Assert_StdioPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  14 - Broken_Assert_Stdlib fix
+ *  Description of Broken_Assert_Stdlib fix
  */
+#define BROKEN_ASSERT_STDLIB_FIXIDX      20
 tSCC zBroken_Assert_StdlibName[] =
      "Broken_Assert_Stdlib";
 /*
@@ -505,8 +803,8 @@ tSCC zBroken_Assert_StdlibBypass0[] =
 #define    BROKEN_ASSERT_STDLIB_TEST_CT  2
 #define    BROKEN_ASSERT_STDLIB_RE_CT    2
 tTestDesc aBroken_Assert_StdlibTests[] = {
-  { TT_NEGREP, zBroken_Assert_StdlibBypass0,   (regex_t*)NULL },
-  { TT_EGREP,  zBroken_Assert_StdlibSelect0,   (regex_t*)NULL }, };
+  { TT_NEGREP,   zBroken_Assert_StdlibBypass0, (regex_t*)NULL },
+  { TT_EGREP,    zBroken_Assert_StdlibSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Broken_Assert_Stdlib
@@ -520,8 +818,9 @@ const char* apzBroken_Assert_StdlibPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  15 - Bsd43_Io_Macros fix
+ *  Description of Bsd43_Io_Macros fix
  */
+#define BSD43_IO_MACROS_FIXIDX           21
 tSCC zBsd43_Io_MacrosName[] =
      "Bsd43_Io_Macros";
 /*
@@ -542,7 +841,7 @@ tSCC zBsd43_Io_MacrosSelect0[] =
 #define    BSD43_IO_MACROS_TEST_CT  1
 #define    BSD43_IO_MACROS_RE_CT    1
 tTestDesc aBsd43_Io_MacrosTests[] = {
-  { TT_EGREP,  zBsd43_Io_MacrosSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zBsd43_Io_MacrosSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Bsd43_Io_Macros
@@ -554,8 +853,9 @@ const char* apzBsd43_Io_MacrosPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  16 - Dec_Intern_Asm fix
+ *  Description of Dec_Intern_Asm fix
  */
+#define DEC_INTERN_ASM_FIXIDX            22
 tSCC zDec_Intern_AsmName[] =
      "Dec_Intern_Asm";
 /*
@@ -583,98 +883,9 @@ const char* apzDec_Intern_AsmPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  17 - Dgux_Int_Varargs fix
- */
-tSCC zDgux_Int_VarargsName[] =
-     "Dgux_Int_Varargs";
-/*
- *  File name selection pattern
- */
-tSCC zDgux_Int_VarargsList[] =
-  "|_int_varargs.h|";
-/*
- *  Machine/OS name selection pattern
- */
-#define apzDgux_Int_VarargsMachs (const char**)NULL
-#define DGUX_INT_VARARGS_TEST_CT  0
-#define DGUX_INT_VARARGS_RE_CT    0
-#define aDgux_Int_VarargsTests   (tTestDesc*)NULL
-
-/*
- *  Fix Command Arguments for Dgux_Int_Varargs
- */
-const char* apzDgux_Int_VarargsPatch[] = { "sh", "-c",
-    "cat > /dev/null\n\
-cat << '_EOF_'\n\
-#ifndef __INT_VARARGS_H\n\
-#define __INT_VARARGS_H\n\
-\n\
-/************************************************************************/\n\
-/* _INT_VARARGS.H - Define the common stuff for varargs/stdarg/stdio.   */\n\
-/************************************************************************/\n\
-\n\
-/*\n\
-** This file is a DG internal header.  Never include this\n\
-** file directly.\n\
-*/\n\
-\n\
-#ifndef ___int_features_h\n\
-#include &lt;sys/_int_features.h&gt;\n\
-#endif\n\
-\n\
-#if !(defined(_VA_LIST) || defined(_VA_LIST_))\n\
-#define _VA_LIST\n\
-#define _VA_LIST_\n\
-\n\
-#ifdef __LINT__\n\
-\n\
-#ifdef __STDC__\n\
-typedef void * va_list;\n\
-#else\n\
-typedef char * va_list;\n\
-#endif\n\
-\n\
-#else\n\
-#if _M88K_ANY\n\
-\n\
-#if defined(__DCC__)\n\
-\n\
-typedef struct {\n\
-      int     next_arg;\n\
-      int     *mem_ptr;\n\
-      int     *reg_ptr;\n\
-} va_list;\n\
-\n\
-#else  /* ! defined(__DCC__) */\n\
-\n\
-typedef struct {\n\
-      int  __va_arg;       /* argument number */\n\
-      int *__va_stk;       /* start of args passed on stack */\n\
-      int *__va_reg;       /* start of args passed in regs */\n\
-} va_list;\n\
-\n\
-#endif  /* ! defined(__DCC__) */\n\
-\n\
-#elif _IX86_ANY\n\
-\n\
-#if defined(__GNUC__) || defined(__STDC__)\n\
-typedef void * va_list;\n\
-#else\n\
-typedef char * va_list;\n\
-#endif\n\
-\n\
-#endif  /*  _IX86_ANY */\n\
-\n\
-#endif /* __LINT__ */\n\
-#endif /*  !(defined(_VA_LIST) || defined(_VA_LIST_)) */\n\
-#endif /*  #ifndef __INT_VARARGS_H  */\n\
-_EOF_\n",
-    (char*)NULL };
-
-/* * * * * * * * * * * * * * * * * * * * * * * * * *
- *
- *  Description  18 - No_Double_Slash fix
+ *  Description of No_Double_Slash fix
  */
+#define NO_DOUBLE_SLASH_FIXIDX           23
 tSCC zNo_Double_SlashName[] =
      "No_Double_Slash";
 /*
@@ -687,36 +898,26 @@ tSCC zNo_Double_SlashName[] =
 #define apzNo_Double_SlashMachs (const char**)NULL
 
 /*
- *  content selection pattern - do fix if pattern found
- */
-tSCC zNo_Double_SlashSelect0[] =
-       "(^|[^:])//[^\"*]";
-
-/*
- *  perform the 'test' shell command - do fix on success
+ *  perform the C function call test
  */
-tSCC zNo_Double_SlashTest0[] =
-       " -z \"`echo ${file} | egrep '(CC|cxx|\\+\\+)/'`\"";
+tSCC zNo_Double_SlashFTst0[] = "double_slash";
 
-#define    NO_DOUBLE_SLASH_TEST_CT  2
-#define    NO_DOUBLE_SLASH_RE_CT    1
+#define    NO_DOUBLE_SLASH_TEST_CT  1
+#define    NO_DOUBLE_SLASH_RE_CT    0
 tTestDesc aNo_Double_SlashTests[] = {
-  { TT_TEST,   zNo_Double_SlashTest0,     0 /* unused */ },
-  { TT_EGREP,  zNo_Double_SlashSelect0,   (regex_t*)NULL }, };
+  { TT_FUNCTION, zNo_Double_SlashFTst0,   0 /* unused */ }, };
 
 /*
  *  Fix Command Arguments for No_Double_Slash
  */
-const char* apzNo_Double_SlashPatch[] = { "sed",
-    "-e", "s,^//.*$,,",
-    "-e", "s,\\(/\\*.*\\)//\\(.*\\*/\\),\\1/ /\\2,g",
-    "-e", "s,\\([^:]\\)//[^\"].*$,\\1,",
+const char* apzNo_Double_SlashPatch[] = {"no_double_slash",
     (char*)NULL };
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  19 - Ecd_Cursor fix
+ *  Description of Ecd_Cursor fix
  */
+#define ECD_CURSOR_FIXIDX                24
 tSCC zEcd_CursorName[] =
      "Ecd_Cursor";
 /*
@@ -741,8 +942,9 @@ const char* apzEcd_CursorPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  20 - Sco5_Stat_Wrappers fix
+ *  Description of Sco5_Stat_Wrappers fix
  */
+#define SCO5_STAT_WRAPPERS_FIXIDX        25
 tSCC zSco5_Stat_WrappersName[] =
      "Sco5_Stat_Wrappers";
 /*
@@ -777,8 +979,9 @@ extern \"C\"\\\n\
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  21 - End_Else_Label fix
+ *  Description of End_Else_Label fix
  */
+#define END_ELSE_LABEL_FIXIDX            26
 tSCC zEnd_Else_LabelName[] =
      "End_Else_Label";
 /*
@@ -799,7 +1002,7 @@ tSCC zEnd_Else_LabelSelect0[] =
 #define    END_ELSE_LABEL_TEST_CT  1
 #define    END_ELSE_LABEL_RE_CT    1
 tTestDesc aEnd_Else_LabelTests[] = {
-  { TT_EGREP,  zEnd_Else_LabelSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zEnd_Else_LabelSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for End_Else_Label
@@ -819,8 +1022,9 @@ s%^\\([ \t]*#[ \t]*endif\\)[ \t][ \t]*[^/* \t].*%\\1%",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  22 - Hp_Inline fix
+ *  Description of Hp_Inline fix
  */
+#define HP_INLINE_FIXIDX                 27
 tSCC zHp_InlineName[] =
      "Hp_Inline";
 /*
@@ -842,7 +1046,7 @@ tSCC zHp_InlineSelect0[] =
 #define    HP_INLINE_TEST_CT  1
 #define    HP_INLINE_RE_CT    1
 tTestDesc aHp_InlineTests[] = {
-  { TT_EGREP,  zHp_InlineSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zHp_InlineSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Hp_Inline
@@ -854,8 +1058,9 @@ const char* apzHp_InlinePatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  23 - Hp_Sysfile fix
+ *  Description of Hp_Sysfile fix
  */
+#define HP_SYSFILE_FIXIDX                28
 tSCC zHp_SysfileName[] =
      "Hp_Sysfile";
 /*
@@ -877,7 +1082,7 @@ tSCC zHp_SysfileSelect0[] =
 #define    HP_SYSFILE_TEST_CT  1
 #define    HP_SYSFILE_RE_CT    1
 tTestDesc aHp_SysfileTests[] = {
-  { TT_EGREP,  zHp_SysfileSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zHp_SysfileSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Hp_Sysfile
@@ -888,8 +1093,9 @@ const char* apzHp_SysfilePatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  24 - Cxx_Unready fix
+ *  Description of Cxx_Unready fix
  */
+#define CXX_UNREADY_FIXIDX               29
 tSCC zCxx_UnreadyName[] =
      "Cxx_Unready";
 /*
@@ -911,7 +1117,7 @@ tSCC zCxx_UnreadyBypass0[] =
 #define    CXX_UNREADY_TEST_CT  1
 #define    CXX_UNREADY_RE_CT    1
 tTestDesc aCxx_UnreadyTests[] = {
-  { TT_NEGREP, zCxx_UnreadyBypass0,   (regex_t*)NULL }, };
+  { TT_NEGREP,   zCxx_UnreadyBypass0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Cxx_Unready
@@ -930,8 +1136,9 @@ extern \"C\" {\\\n\
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  25 - Hpux_Maxint fix
+ *  Description of Hpux_Maxint fix
  */
+#define HPUX_MAXINT_FIXIDX               30
 tSCC zHpux_MaxintName[] =
      "Hpux_Maxint";
 /*
@@ -959,8 +1166,9 @@ const char* apzHpux_MaxintPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  26 - Hpux_Systime fix
+ *  Description of Hpux_Systime fix
  */
+#define HPUX_SYSTIME_FIXIDX              31
 tSCC zHpux_SystimeName[] =
      "Hpux_Systime";
 /*
@@ -982,7 +1190,7 @@ tSCC zHpux_SystimeSelect0[] =
 #define    HPUX_SYSTIME_TEST_CT  1
 #define    HPUX_SYSTIME_RE_CT    1
 tTestDesc aHpux_SystimeTests[] = {
-  { TT_EGREP,  zHpux_SystimeSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zHpux_SystimeSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Hpux_Systime
@@ -993,8 +1201,9 @@ const char* apzHpux_SystimePatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  27 - Interactv_Add1 fix
+ *  Description of Interactv_Add1 fix
  */
+#define INTERACTV_ADD1_FIXIDX            32
 tSCC zInteractv_Add1Name[] =
      "Interactv_Add1";
 /*
@@ -1018,8 +1227,8 @@ tSCC zInteractv_Add1Test1[] =
 #define    INTERACTV_ADD1_TEST_CT  2
 #define    INTERACTV_ADD1_RE_CT    0
 tTestDesc aInteractv_Add1Tests[] = {
-  { TT_TEST,   zInteractv_Add1Test0,     0 /* unused */ },
-  { TT_TEST,   zInteractv_Add1Test1,     0 /* unused */ }, };
+  { TT_TEST,     zInteractv_Add1Test0,   0 /* unused */ },
+  { TT_TEST,     zInteractv_Add1Test1,   0 /* unused */ }, };
 
 /*
  *  Fix Command Arguments for Interactv_Add1
@@ -1030,8 +1239,9 @@ const char* apzInteractv_Add1Patch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  28 - Interactv_Add2 fix
+ *  Description of Interactv_Add2 fix
  */
+#define INTERACTV_ADD2_FIXIDX            33
 tSCC zInteractv_Add2Name[] =
      "Interactv_Add2";
 /*
@@ -1055,8 +1265,8 @@ tSCC zInteractv_Add2Test1[] =
 #define    INTERACTV_ADD2_TEST_CT  2
 #define    INTERACTV_ADD2_RE_CT    0
 tTestDesc aInteractv_Add2Tests[] = {
-  { TT_TEST,   zInteractv_Add2Test0,     0 /* unused */ },
-  { TT_TEST,   zInteractv_Add2Test1,     0 /* unused */ }, };
+  { TT_TEST,     zInteractv_Add2Test0,   0 /* unused */ },
+  { TT_TEST,     zInteractv_Add2Test1,   0 /* unused */ }, };
 
 /*
  *  Fix Command Arguments for Interactv_Add2
@@ -1067,8 +1277,9 @@ const char* apzInteractv_Add2Patch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  29 - Interactv_Add3 fix
+ *  Description of Interactv_Add3 fix
  */
+#define INTERACTV_ADD3_FIXIDX            34
 tSCC zInteractv_Add3Name[] =
      "Interactv_Add3";
 /*
@@ -1092,8 +1303,8 @@ tSCC zInteractv_Add3Test1[] =
 #define    INTERACTV_ADD3_TEST_CT  2
 #define    INTERACTV_ADD3_RE_CT    0
 tTestDesc aInteractv_Add3Tests[] = {
-  { TT_TEST,   zInteractv_Add3Test0,     0 /* unused */ },
-  { TT_TEST,   zInteractv_Add3Test1,     0 /* unused */ }, };
+  { TT_TEST,     zInteractv_Add3Test0,   0 /* unused */ },
+  { TT_TEST,     zInteractv_Add3Test1,   0 /* unused */ }, };
 
 /*
  *  Fix Command Arguments for Interactv_Add3
@@ -1105,8 +1316,9 @@ const char* apzInteractv_Add3Patch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  30 - Io_Def_Quotes fix
+ *  Description of Io_Def_Quotes fix
  */
+#define IO_DEF_QUOTES_FIXIDX             35
 tSCC zIo_Def_QuotesName[] =
      "Io_Def_Quotes";
 /*
@@ -1127,7 +1339,7 @@ tSCC zIo_Def_QuotesSelect0[] =
 #define    IO_DEF_QUOTES_TEST_CT  1
 #define    IO_DEF_QUOTES_RE_CT    1
 tTestDesc aIo_Def_QuotesTests[] = {
-  { TT_EGREP,  zIo_Def_QuotesSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zIo_Def_QuotesSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Io_Def_Quotes
@@ -1141,8 +1353,9 @@ const char* apzIo_Def_QuotesPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  31 - Ioctl_Fix_Ctrl fix
+ *  Description of Ioctl_Fix_Ctrl fix
  */
+#define IOCTL_FIX_CTRL_FIXIDX            36
 tSCC zIoctl_Fix_CtrlName[] =
      "Ioctl_Fix_Ctrl";
 /*
@@ -1163,7 +1376,7 @@ tSCC zIoctl_Fix_CtrlSelect0[] =
 #define    IOCTL_FIX_CTRL_TEST_CT  1
 #define    IOCTL_FIX_CTRL_RE_CT    1
 tTestDesc aIoctl_Fix_CtrlTests[] = {
-  { TT_EGREP,  zIoctl_Fix_CtrlSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zIoctl_Fix_CtrlSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Ioctl_Fix_Ctrl
@@ -1179,8 +1392,9 @@ const char* apzIoctl_Fix_CtrlPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  32 - Ip_Missing_Semi fix
+ *  Description of Ip_Missing_Semi fix
  */
+#define IP_MISSING_SEMI_FIXIDX           37
 tSCC zIp_Missing_SemiName[] =
      "Ip_Missing_Semi";
 /*
@@ -1205,8 +1419,9 @@ const char* apzIp_Missing_SemiPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  33 - Irix_Multiline_Cmnt fix
+ *  Description of Irix_Multiline_Cmnt fix
  */
+#define IRIX_MULTILINE_CMNT_FIXIDX       38
 tSCC zIrix_Multiline_CmntName[] =
      "Irix_Multiline_Cmnt";
 /*
@@ -1232,8 +1447,9 @@ const char* apzIrix_Multiline_CmntPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  34 - Irix_Sockaddr fix
+ *  Description of Irix_Sockaddr fix
  */
+#define IRIX_SOCKADDR_FIXIDX             39
 tSCC zIrix_SockaddrName[] =
      "Irix_Sockaddr";
 /*
@@ -1255,7 +1471,7 @@ tSCC zIrix_SockaddrSelect0[] =
 #define    IRIX_SOCKADDR_TEST_CT  1
 #define    IRIX_SOCKADDR_RE_CT    1
 tTestDesc aIrix_SockaddrTests[] = {
-  { TT_EGREP,  zIrix_SockaddrSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zIrix_SockaddrSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Irix_Sockaddr
@@ -1267,8 +1483,9 @@ struct sockaddr;\n",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  35 - Irix_Struct__File fix
+ *  Description of Irix_Struct__File fix
  */
+#define IRIX_STRUCT__FILE_FIXIDX         40
 tSCC zIrix_Struct__FileName[] =
      "Irix_Struct__File";
 /*
@@ -1294,8 +1511,9 @@ struct __file_s;\n",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  36 - Irix_Asm_Apostrophe fix
+ *  Description of Irix_Asm_Apostrophe fix
  */
+#define IRIX_ASM_APOSTROPHE_FIXIDX       41
 tSCC zIrix_Asm_ApostropheName[] =
      "Irix_Asm_Apostrophe";
 /*
@@ -1317,7 +1535,7 @@ tSCC zIrix_Asm_ApostropheSelect0[] =
 #define    IRIX_ASM_APOSTROPHE_TEST_CT  1
 #define    IRIX_ASM_APOSTROPHE_RE_CT    1
 tTestDesc aIrix_Asm_ApostropheTests[] = {
-  { TT_EGREP,  zIrix_Asm_ApostropheSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zIrix_Asm_ApostropheSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Irix_Asm_Apostrophe
@@ -1328,8 +1546,9 @@ const char* apzIrix_Asm_ApostrophePatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  37 - Isc_Fmod fix
+ *  Description of Isc_Fmod fix
  */
+#define ISC_FMOD_FIXIDX                  42
 tSCC zIsc_FmodName[] =
      "Isc_Fmod";
 /*
@@ -1351,7 +1570,7 @@ tSCC zIsc_FmodSelect0[] =
 #define    ISC_FMOD_TEST_CT  1
 #define    ISC_FMOD_RE_CT    1
 tTestDesc aIsc_FmodTests[] = {
-  { TT_EGREP,  zIsc_FmodSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zIsc_FmodSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Isc_Fmod
@@ -1362,8 +1581,9 @@ const char* apzIsc_FmodPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  38 - Motorola_Nested fix
+ *  Description of Motorola_Nested fix
  */
+#define MOTOROLA_NESTED_FIXIDX           43
 tSCC zMotorola_NestedName[] =
      "Motorola_Nested";
 /*
@@ -1391,8 +1611,9 @@ const char* apzMotorola_NestedPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  39 - Isc_Sys_Limits fix
+ *  Description of Isc_Sys_Limits fix
  */
+#define ISC_SYS_LIMITS_FIXIDX            44
 tSCC zIsc_Sys_LimitsName[] =
      "Isc_Sys_Limits";
 /*
@@ -1414,7 +1635,7 @@ tSCC zIsc_Sys_LimitsSelect0[] =
 #define    ISC_SYS_LIMITS_TEST_CT  1
 #define    ISC_SYS_LIMITS_RE_CT    1
 tTestDesc aIsc_Sys_LimitsTests[] = {
-  { TT_EGREP,  zIsc_Sys_LimitsSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zIsc_Sys_LimitsSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Isc_Sys_Limits
@@ -1426,8 +1647,9 @@ const char* apzIsc_Sys_LimitsPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  40 - Kandr_Concat fix
+ *  Description of Kandr_Concat fix
  */
+#define KANDR_CONCAT_FIXIDX              45
 tSCC zKandr_ConcatName[] =
      "Kandr_Concat";
 /*
@@ -1449,7 +1671,7 @@ tSCC zKandr_ConcatSelect0[] =
 #define    KANDR_CONCAT_TEST_CT  1
 #define    KANDR_CONCAT_RE_CT    1
 tTestDesc aKandr_ConcatTests[] = {
-  { TT_EGREP,  zKandr_ConcatSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zKandr_ConcatSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Kandr_Concat
@@ -1460,8 +1682,9 @@ const char* apzKandr_ConcatPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  41 - Limits_Ifndefs fix
+ *  Description of Limits_Ifndefs fix
  */
+#define LIMITS_IFNDEFS_FIXIDX            46
 tSCC zLimits_IfndefsName[] =
      "Limits_Ifndefs";
 /*
@@ -1483,7 +1706,7 @@ tSCC zLimits_IfndefsBypass0[] =
 #define    LIMITS_IFNDEFS_TEST_CT  1
 #define    LIMITS_IFNDEFS_RE_CT    1
 tTestDesc aLimits_IfndefsTests[] = {
-  { TT_NEGREP, zLimits_IfndefsBypass0,   (regex_t*)NULL }, };
+  { TT_NEGREP,   zLimits_IfndefsBypass0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Limits_Ifndefs
@@ -1518,8 +1741,9 @@ const char* apzLimits_IfndefsPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  42 - Lynx_Void_Int fix
+ *  Description of Lynx_Void_Int fix
  */
+#define LYNX_VOID_INT_FIXIDX             47
 tSCC zLynx_Void_IntName[] =
      "Lynx_Void_Int";
 /*
@@ -1541,7 +1765,7 @@ tSCC zLynx_Void_IntSelect0[] =
 #define    LYNX_VOID_INT_TEST_CT  1
 #define    LYNX_VOID_INT_RE_CT    1
 tTestDesc aLynx_Void_IntTests[] = {
-  { TT_EGREP,  zLynx_Void_IntSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zLynx_Void_IntSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Lynx_Void_Int
@@ -1552,8 +1776,9 @@ const char* apzLynx_Void_IntPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  43 - Lynxos_Fcntl_Proto fix
+ *  Description of Lynxos_Fcntl_Proto fix
  */
+#define LYNXOS_FCNTL_PROTO_FIXIDX        48
 tSCC zLynxos_Fcntl_ProtoName[] =
      "Lynxos_Fcntl_Proto";
 /*
@@ -1575,7 +1800,7 @@ tSCC zLynxos_Fcntl_ProtoSelect0[] =
 #define    LYNXOS_FCNTL_PROTO_TEST_CT  1
 #define    LYNXOS_FCNTL_PROTO_RE_CT    1
 tTestDesc aLynxos_Fcntl_ProtoTests[] = {
-  { TT_EGREP,  zLynxos_Fcntl_ProtoSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zLynxos_Fcntl_ProtoSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Lynxos_Fcntl_Proto
@@ -1586,8 +1811,9 @@ const char* apzLynxos_Fcntl_ProtoPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  44 - M88k_Bad_Hypot_Opt fix
+ *  Description of M88k_Bad_Hypot_Opt fix
  */
+#define M88K_BAD_HYPOT_OPT_FIXIDX        49
 tSCC zM88k_Bad_Hypot_OptName[] =
      "M88k_Bad_Hypot_Opt";
 /*
@@ -1627,8 +1853,9 @@ static __inline__ double fake_hypot (x, y)\\\n\
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  45 - M88k_Bad_S_If fix
+ *  Description of M88k_Bad_S_If fix
  */
+#define M88K_BAD_S_IF_FIXIDX             50
 tSCC zM88k_Bad_S_IfName[] =
      "M88k_Bad_S_If";
 /*
@@ -1652,7 +1879,7 @@ tSCC zM88k_Bad_S_IfSelect0[] =
 #define    M88K_BAD_S_IF_TEST_CT  1
 #define    M88K_BAD_S_IF_RE_CT    1
 tTestDesc aM88k_Bad_S_IfTests[] = {
-  { TT_EGREP,  zM88k_Bad_S_IfSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zM88k_Bad_S_IfSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for M88k_Bad_S_If
@@ -1664,8 +1891,9 @@ const char* apzM88k_Bad_S_IfPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  46 - M88k_Multi_Incl fix
+ *  Description of M88k_Multi_Incl fix
  */
+#define M88K_MULTI_INCL_FIXIDX           51
 tSCC zM88k_Multi_InclName[] =
      "M88k_Multi_Incl";
 /*
@@ -1689,7 +1917,7 @@ tSCC zM88k_Multi_InclBypass0[] =
 #define    M88K_MULTI_INCL_TEST_CT  1
 #define    M88K_MULTI_INCL_RE_CT    1
 tTestDesc aM88k_Multi_InclTests[] = {
-  { TT_NEGREP, zM88k_Multi_InclBypass0,   (regex_t*)NULL }, };
+  { TT_NEGREP,   zM88k_Multi_InclBypass0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for M88k_Multi_Incl
@@ -1705,8 +1933,9 @@ const char* apzM88k_Multi_InclPatch[] = { "sh", "-c",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  47 - Machine_Name fix
+ *  Description of Machine_Name fix
  */
+#define MACHINE_NAME_FIXIDX              52
 tSCC zMachine_NameName[] =
      "Machine_Name";
 /*
@@ -1729,7 +1958,7 @@ tSCC zMachine_NameSelect0[] =
 #define    MACHINE_NAME_TEST_CT  1
 #define    MACHINE_NAME_RE_CT    1
 tTestDesc aMachine_NameTests[] = {
-  { TT_EGREP,  zMachine_NameSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zMachine_NameSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Machine_Name
@@ -1774,8 +2003,9 @@ s/\\\\+++fixinc_eol+++/\\\\/g\n\
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  48 - Math_Exception fix
+ *  Description of Math_Exception fix
  */
+#define MATH_EXCEPTION_FIXIDX            53
 tSCC zMath_ExceptionName[] =
      "Math_Exception";
 /*
@@ -1797,7 +2027,7 @@ tSCC zMath_ExceptionSelect0[] =
 #define    MATH_EXCEPTION_TEST_CT  1
 #define    MATH_EXCEPTION_RE_CT    1
 tTestDesc aMath_ExceptionTests[] = {
-  { TT_EGREP,  zMath_ExceptionSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zMath_ExceptionSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Math_Exception
@@ -1823,8 +2053,9 @@ const char* apzMath_ExceptionPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  49 - Math_Gcc_Ifndefs fix
+ *  Description of Math_Gcc_Ifndefs fix
  */
+#define MATH_GCC_IFNDEFS_FIXIDX          54
 tSCC zMath_Gcc_IfndefsName[] =
      "Math_Gcc_Ifndefs";
 /*
@@ -1861,8 +2092,9 @@ const char* apzMath_Gcc_IfndefsPatch[] = { "sh", "-c",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  50 - Nested_Comment fix
+ *  Description of Nested_Comment fix
  */
+#define NESTED_COMMENT_FIXIDX            55
 tSCC zNested_CommentName[] =
      "Nested_Comment";
 /*
@@ -1887,8 +2119,9 @@ const char* apzNested_CommentPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  51 - News_Os_Recursion fix
+ *  Description of News_Os_Recursion fix
  */
+#define NEWS_OS_RECURSION_FIXIDX         56
 tSCC zNews_Os_RecursionName[] =
      "News_Os_Recursion";
 /*
@@ -1910,7 +2143,7 @@ tSCC zNews_Os_RecursionSelect0[] =
 #define    NEWS_OS_RECURSION_TEST_CT  1
 #define    NEWS_OS_RECURSION_RE_CT    1
 tTestDesc aNews_Os_RecursionTests[] = {
-  { TT_EGREP,  zNews_Os_RecursionSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zNews_Os_RecursionSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for News_Os_Recursion
@@ -1924,8 +2157,9 @@ const char* apzNews_Os_RecursionPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  52 - Next_Math_Prefix fix
+ *  Description of Next_Math_Prefix fix
  */
+#define NEXT_MATH_PREFIX_FIXIDX          57
 tSCC zNext_Math_PrefixName[] =
      "Next_Math_Prefix";
 /*
@@ -1947,7 +2181,7 @@ tSCC zNext_Math_PrefixSelect0[] =
 #define    NEXT_MATH_PREFIX_TEST_CT  1
 #define    NEXT_MATH_PREFIX_RE_CT    1
 tTestDesc aNext_Math_PrefixTests[] = {
-  { TT_EGREP,  zNext_Math_PrefixSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zNext_Math_PrefixSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Next_Math_Prefix
@@ -1962,8 +2196,9 @@ const char* apzNext_Math_PrefixPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  53 - Next_Template fix
+ *  Description of Next_Template fix
  */
+#define NEXT_TEMPLATE_FIXIDX             58
 tSCC zNext_TemplateName[] =
      "Next_Template";
 /*
@@ -1985,7 +2220,7 @@ tSCC zNext_TemplateSelect0[] =
 #define    NEXT_TEMPLATE_TEST_CT  1
 #define    NEXT_TEMPLATE_RE_CT    1
 tTestDesc aNext_TemplateTests[] = {
-  { TT_EGREP,  zNext_TemplateSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zNext_TemplateSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Next_Template
@@ -1997,8 +2232,9 @@ const char* apzNext_TemplatePatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  54 - Next_Volitile fix
+ *  Description of Next_Volitile fix
  */
+#define NEXT_VOLITILE_FIXIDX             59
 tSCC zNext_VolitileName[] =
      "Next_Volitile";
 /*
@@ -2020,7 +2256,7 @@ tSCC zNext_VolitileSelect0[] =
 #define    NEXT_VOLITILE_TEST_CT  1
 #define    NEXT_VOLITILE_RE_CT    1
 tTestDesc aNext_VolitileTests[] = {
-  { TT_EGREP,  zNext_VolitileSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zNext_VolitileSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Next_Volitile
@@ -2032,8 +2268,9 @@ const char* apzNext_VolitilePatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  55 - Next_Wait_Union fix
+ *  Description of Next_Wait_Union fix
  */
+#define NEXT_WAIT_UNION_FIXIDX           60
 tSCC zNext_Wait_UnionName[] =
      "Next_Wait_Union";
 /*
@@ -2055,7 +2292,7 @@ tSCC zNext_Wait_UnionSelect0[] =
 #define    NEXT_WAIT_UNION_TEST_CT  1
 #define    NEXT_WAIT_UNION_RE_CT    1
 tTestDesc aNext_Wait_UnionTests[] = {
-  { TT_EGREP,  zNext_Wait_UnionSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zNext_Wait_UnionSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Next_Wait_Union
@@ -2066,8 +2303,9 @@ const char* apzNext_Wait_UnionPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  56 - Nodeent_Syntax fix
+ *  Description of Nodeent_Syntax fix
  */
+#define NODEENT_SYNTAX_FIXIDX            61
 tSCC zNodeent_SyntaxName[] =
      "Nodeent_Syntax";
 /*
@@ -2092,8 +2330,9 @@ const char* apzNodeent_SyntaxPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  57 - Osf_Namespace_A fix
+ *  Description of Osf_Namespace_A fix
  */
+#define OSF_NAMESPACE_A_FIXIDX           62
 tSCC zOsf_Namespace_AName[] =
      "Osf_Namespace_A";
 /*
@@ -2121,10 +2360,10 @@ tSCC zOsf_Namespace_ATest3[] =
 #define    OSF_NAMESPACE_A_TEST_CT  4
 #define    OSF_NAMESPACE_A_RE_CT    0
 tTestDesc aOsf_Namespace_ATests[] = {
-  { TT_TEST,   zOsf_Namespace_ATest0,     0 /* unused */ },
-  { TT_TEST,   zOsf_Namespace_ATest1,     0 /* unused */ },
-  { TT_TEST,   zOsf_Namespace_ATest2,     0 /* unused */ },
-  { TT_TEST,   zOsf_Namespace_ATest3,     0 /* unused */ }, };
+  { TT_TEST,     zOsf_Namespace_ATest0,   0 /* unused */ },
+  { TT_TEST,     zOsf_Namespace_ATest1,   0 /* unused */ },
+  { TT_TEST,     zOsf_Namespace_ATest2,   0 /* unused */ },
+  { TT_TEST,     zOsf_Namespace_ATest3,   0 /* unused */ }, };
 
 /*
  *  Fix Command Arguments for Osf_Namespace_A
@@ -2137,8 +2376,9 @@ const char* apzOsf_Namespace_APatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  58 - Osf_Namespace_B fix
+ *  Description of Osf_Namespace_B fix
  */
+#define OSF_NAMESPACE_B_FIXIDX           63
 tSCC zOsf_Namespace_BName[] =
      "Osf_Namespace_B";
 /*
@@ -2166,10 +2406,10 @@ tSCC zOsf_Namespace_BTest3[] =
 #define    OSF_NAMESPACE_B_TEST_CT  4
 #define    OSF_NAMESPACE_B_RE_CT    0
 tTestDesc aOsf_Namespace_BTests[] = {
-  { TT_TEST,   zOsf_Namespace_BTest0,     0 /* unused */ },
-  { TT_TEST,   zOsf_Namespace_BTest1,     0 /* unused */ },
-  { TT_TEST,   zOsf_Namespace_BTest2,     0 /* unused */ },
-  { TT_TEST,   zOsf_Namespace_BTest3,     0 /* unused */ }, };
+  { TT_TEST,     zOsf_Namespace_BTest0,   0 /* unused */ },
+  { TT_TEST,     zOsf_Namespace_BTest1,   0 /* unused */ },
+  { TT_TEST,     zOsf_Namespace_BTest2,   0 /* unused */ },
+  { TT_TEST,     zOsf_Namespace_BTest3,   0 /* unused */ }, };
 
 /*
  *  Fix Command Arguments for Osf_Namespace_B
@@ -2183,8 +2423,9 @@ typedef __regmatch_t\tregmatch_t;\n",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  59 - Pthread_Page_Size fix
+ *  Description of Pthread_Page_Size fix
  */
+#define PTHREAD_PAGE_SIZE_FIXIDX         64
 tSCC zPthread_Page_SizeName[] =
      "Pthread_Page_Size";
 /*
@@ -2206,7 +2447,7 @@ tSCC zPthread_Page_SizeSelect0[] =
 #define    PTHREAD_PAGE_SIZE_TEST_CT  1
 #define    PTHREAD_PAGE_SIZE_RE_CT    1
 tTestDesc aPthread_Page_SizeTests[] = {
-  { TT_EGREP,  zPthread_Page_SizeSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zPthread_Page_SizeSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Pthread_Page_Size
@@ -2217,8 +2458,9 @@ const char* apzPthread_Page_SizePatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  60 - Read_Ret_Type fix
+ *  Description of Read_Ret_Type fix
  */
+#define READ_RET_TYPE_FIXIDX             65
 tSCC zRead_Ret_TypeName[] =
      "Read_Ret_Type";
 /*
@@ -2240,7 +2482,7 @@ tSCC zRead_Ret_TypeSelect0[] =
 #define    READ_RET_TYPE_TEST_CT  1
 #define    READ_RET_TYPE_RE_CT    1
 tTestDesc aRead_Ret_TypeTests[] = {
-  { TT_EGREP,  zRead_Ret_TypeSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zRead_Ret_TypeSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Read_Ret_Type
@@ -2252,8 +2494,9 @@ const char* apzRead_Ret_TypePatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  61 - Rs6000_Double fix
+ *  Description of Rs6000_Double fix
  */
+#define RS6000_DOUBLE_FIXIDX             66
 tSCC zRs6000_DoubleName[] =
      "Rs6000_Double";
 /*
@@ -2275,7 +2518,7 @@ tSCC zRs6000_DoubleSelect0[] =
 #define    RS6000_DOUBLE_TEST_CT  1
 #define    RS6000_DOUBLE_RE_CT    1
 tTestDesc aRs6000_DoubleTests[] = {
-  { TT_EGREP,  zRs6000_DoubleSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zRs6000_DoubleSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Rs6000_Double
@@ -2289,8 +2532,9 @@ const char* apzRs6000_DoublePatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  62 - Rs6000_Fchmod fix
+ *  Description of Rs6000_Fchmod fix
  */
+#define RS6000_FCHMOD_FIXIDX             67
 tSCC zRs6000_FchmodName[] =
      "Rs6000_Fchmod";
 /*
@@ -2312,7 +2556,7 @@ tSCC zRs6000_FchmodSelect0[] =
 #define    RS6000_FCHMOD_TEST_CT  1
 #define    RS6000_FCHMOD_RE_CT    1
 tTestDesc aRs6000_FchmodTests[] = {
-  { TT_EGREP,  zRs6000_FchmodSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zRs6000_FchmodSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Rs6000_Fchmod
@@ -2323,8 +2567,9 @@ const char* apzRs6000_FchmodPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  63 - Rs6000_Param fix
+ *  Description of Rs6000_Param fix
  */
+#define RS6000_PARAM_FIXIDX              68
 tSCC zRs6000_ParamName[] =
      "Rs6000_Param";
 /*
@@ -2349,8 +2594,9 @@ const char* apzRs6000_ParamPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  64 - Sony_Include fix
+ *  Description of Sony_Include fix
  */
+#define SONY_INCLUDE_FIXIDX              69
 tSCC zSony_IncludeName[] =
      "Sony_Include";
 /*
@@ -2372,7 +2618,7 @@ tSCC zSony_IncludeSelect0[] =
 #define    SONY_INCLUDE_TEST_CT  1
 #define    SONY_INCLUDE_RE_CT    1
 tTestDesc aSony_IncludeTests[] = {
-  { TT_EGREP,  zSony_IncludeSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zSony_IncludeSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Sony_Include
@@ -2383,8 +2629,9 @@ const char* apzSony_IncludePatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  65 - Statsswtch fix
+ *  Description of Statsswtch fix
  */
+#define STATSSWTCH_FIXIDX                70
 tSCC zStatsswtchName[] =
      "Statsswtch";
 /*
@@ -2406,7 +2653,7 @@ tSCC zStatsswtchSelect0[] =
 #define    STATSSWTCH_TEST_CT  1
 #define    STATSSWTCH_RE_CT    1
 tTestDesc aStatsswtchTests[] = {
-  { TT_EGREP,  zStatsswtchSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zStatsswtchSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Statsswtch
@@ -2417,8 +2664,9 @@ const char* apzStatsswtchPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  66 - Stdio_Va_List fix
+ *  Description of Stdio_Va_List fix
  */
+#define STDIO_VA_LIST_FIXIDX             71
 tSCC zStdio_Va_ListName[] =
      "Stdio_Va_List";
 /*
@@ -2447,7 +2695,7 @@ const char* apzStdio_Va_ListPatch[] = { "sh", "-c",
 \n\
   sed -e 's@ va_list @ __gnuc_va_list @' \\\n\
       -e 's@ va_list)@ __gnuc_va_list)@' \\\n\
-      -e 's@ _BSD_VA_LIST_))@ __gnuc_va_list))@' \\\n\
+      -e 's@ _BSD_VA_LIST_));@ __gnuc_va_list));@' \\\n\
       -e 's@ _VA_LIST_));@ __gnuc_va_list));@' \\\n\
       -e 's@ va_list@ __va_list__@' \\\n\
       -e 's@\\*va_list@*__va_list__@' \\\n\
@@ -2460,8 +2708,9 @@ const char* apzStdio_Va_ListPatch[] = { "sh", "-c",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  67 - Sun_Bogus_Ifdef fix
+ *  Description of Sun_Bogus_Ifdef fix
  */
+#define SUN_BOGUS_IFDEF_FIXIDX           72
 tSCC zSun_Bogus_IfdefName[] =
      "Sun_Bogus_Ifdef";
 /*
@@ -2483,7 +2732,7 @@ tSCC zSun_Bogus_IfdefSelect0[] =
 #define    SUN_BOGUS_IFDEF_TEST_CT  1
 #define    SUN_BOGUS_IFDEF_RE_CT    1
 tTestDesc aSun_Bogus_IfdefTests[] = {
-  { TT_EGREP,  zSun_Bogus_IfdefSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zSun_Bogus_IfdefSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Sun_Bogus_Ifdef
@@ -2494,8 +2743,9 @@ const char* apzSun_Bogus_IfdefPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  68 - Sun_Bogus_Ifdef_Sun4c fix
+ *  Description of Sun_Bogus_Ifdef_Sun4c fix
  */
+#define SUN_BOGUS_IFDEF_SUN4C_FIXIDX     73
 tSCC zSun_Bogus_Ifdef_Sun4cName[] =
      "Sun_Bogus_Ifdef_Sun4c";
 /*
@@ -2517,7 +2767,7 @@ tSCC zSun_Bogus_Ifdef_Sun4cSelect0[] =
 #define    SUN_BOGUS_IFDEF_SUN4C_TEST_CT  1
 #define    SUN_BOGUS_IFDEF_SUN4C_RE_CT    1
 tTestDesc aSun_Bogus_Ifdef_Sun4cTests[] = {
-  { TT_EGREP,  zSun_Bogus_Ifdef_Sun4cSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zSun_Bogus_Ifdef_Sun4cSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Sun_Bogus_Ifdef_Sun4c
@@ -2528,8 +2778,9 @@ const char* apzSun_Bogus_Ifdef_Sun4cPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  69 - Sun_Catmacro fix
+ *  Description of Sun_Catmacro fix
  */
+#define SUN_CATMACRO_FIXIDX              74
 tSCC zSun_CatmacroName[] =
      "Sun_Catmacro";
 /*
@@ -2551,7 +2802,7 @@ tSCC zSun_CatmacroSelect0[] =
 #define    SUN_CATMACRO_TEST_CT  1
 #define    SUN_CATMACRO_RE_CT    1
 tTestDesc aSun_CatmacroTests[] = {
-  { TT_EGREP,  zSun_CatmacroSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zSun_CatmacroSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Sun_Catmacro
@@ -2567,8 +2818,9 @@ const char* apzSun_CatmacroPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  70 - Sun_Malloc fix
+ *  Description of Sun_Malloc fix
  */
+#define SUN_MALLOC_FIXIDX                75
 tSCC zSun_MallocName[] =
      "Sun_Malloc";
 /*
@@ -2596,8 +2848,9 @@ const char* apzSun_MallocPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  71 - Sun_Memcpy fix
+ *  Description of Sun_Memcpy fix
  */
+#define SUN_MEMCPY_FIXIDX                76
 tSCC zSun_MemcpyName[] =
      "Sun_Memcpy";
 /*
@@ -2619,7 +2872,7 @@ tSCC zSun_MemcpySelect0[] =
 #define    SUN_MEMCPY_TEST_CT  1
 #define    SUN_MEMCPY_RE_CT    1
 tTestDesc aSun_MemcpyTests[] = {
-  { TT_EGREP,  zSun_MemcpySelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zSun_MemcpySelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Sun_Memcpy
@@ -2650,8 +2903,9 @@ extern int memcmp();\\\n\
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  72 - Sun_Rusers_Semi fix
+ *  Description of Sun_Rusers_Semi fix
  */
+#define SUN_RUSERS_SEMI_FIXIDX           77
 tSCC zSun_Rusers_SemiName[] =
      "Sun_Rusers_Semi";
 /*
@@ -2673,7 +2927,7 @@ tSCC zSun_Rusers_SemiSelect0[] =
 #define    SUN_RUSERS_SEMI_TEST_CT  1
 #define    SUN_RUSERS_SEMI_RE_CT    1
 tTestDesc aSun_Rusers_SemiTests[] = {
-  { TT_EGREP,  zSun_Rusers_SemiSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zSun_Rusers_SemiSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Sun_Rusers_Semi
@@ -2684,8 +2938,9 @@ const char* apzSun_Rusers_SemiPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  73 - Sun_Signal fix
+ *  Description of Sun_Signal fix
  */
+#define SUN_SIGNAL_FIXIDX                78
 tSCC zSun_SignalName[] =
      "Sun_Signal";
 /*
@@ -2707,7 +2962,7 @@ tSCC zSun_SignalSelect0[] =
 #define    SUN_SIGNAL_TEST_CT  1
 #define    SUN_SIGNAL_RE_CT    1
 tTestDesc aSun_SignalTests[] = {
-  { TT_EGREP,  zSun_SignalSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zSun_SignalSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Sun_Signal
@@ -2723,8 +2978,9 @@ void\t(*signal(...))(...);\\\n\
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  74 - Sun_Auth_Proto fix
+ *  Description of Sun_Auth_Proto fix
  */
+#define SUN_AUTH_PROTO_FIXIDX            79
 tSCC zSun_Auth_ProtoName[] =
      "Sun_Auth_Proto";
 /*
@@ -2746,7 +3002,7 @@ tSCC zSun_Auth_ProtoSelect0[] =
 #define    SUN_AUTH_PROTO_TEST_CT  1
 #define    SUN_AUTH_PROTO_RE_CT    1
 tTestDesc aSun_Auth_ProtoTests[] = {
-  { TT_EGREP,  zSun_Auth_ProtoSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zSun_Auth_ProtoSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Sun_Auth_Proto
@@ -2762,8 +3018,9 @@ const char* apzSun_Auth_ProtoPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  75 - Sunos_Matherr_Decl fix
+ *  Description of Sunos_Matherr_Decl fix
  */
+#define SUNOS_MATHERR_DECL_FIXIDX        80
 tSCC zSunos_Matherr_DeclName[] =
      "Sunos_Matherr_Decl";
 /*
@@ -2790,8 +3047,9 @@ struct exception;\n",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  76 - Sunos_Strlen fix
+ *  Description of Sunos_Strlen fix
  */
+#define SUNOS_STRLEN_FIXIDX              81
 tSCC zSunos_StrlenName[] =
      "Sunos_Strlen";
 /*
@@ -2816,8 +3074,9 @@ const char* apzSunos_StrlenPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  77 - Systypes fix
+ *  Description of Systypes fix
  */
+#define SYSTYPES_FIXIDX                  82
 tSCC zSystypesName[] =
      "Systypes";
 /*
@@ -2839,7 +3098,7 @@ tSCC zSystypesSelect0[] =
 #define    SYSTYPES_TEST_CT  1
 #define    SYSTYPES_RE_CT    1
 tTestDesc aSystypesTests[] = {
-  { TT_EGREP,  zSystypesSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zSystypesSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Systypes
@@ -2874,8 +3133,9 @@ typedef __SIZE_TYPE__ size_t;\\\n\
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  78 - Systypes_For_Aix fix
+ *  Description of Systypes_For_Aix fix
  */
+#define SYSTYPES_FOR_AIX_FIXIDX          83
 tSCC zSystypes_For_AixName[] =
      "Systypes_For_Aix";
 /*
@@ -2903,8 +3163,8 @@ tSCC zSystypes_For_AixBypass0[] =
 #define    SYSTYPES_FOR_AIX_TEST_CT  2
 #define    SYSTYPES_FOR_AIX_RE_CT    2
 tTestDesc aSystypes_For_AixTests[] = {
-  { TT_NEGREP, zSystypes_For_AixBypass0,   (regex_t*)NULL },
-  { TT_EGREP,  zSystypes_For_AixSelect0,   (regex_t*)NULL }, };
+  { TT_NEGREP,   zSystypes_For_AixBypass0, (regex_t*)NULL },
+  { TT_EGREP,    zSystypes_For_AixSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Systypes_For_Aix
@@ -2919,8 +3179,9 @@ const char* apzSystypes_For_AixPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  79 - Sysv68_String fix
+ *  Description of Sysv68_String fix
  */
+#define SYSV68_STRING_FIXIDX             84
 tSCC zSysv68_StringName[] =
      "Sysv68_String";
 /*
@@ -2955,8 +3216,9 @@ extern unsigned int\\\n\
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  80 - Sysz_Stdlib_For_Sun fix
+ *  Description of Sysz_Stdlib_For_Sun fix
  */
+#define SYSZ_STDLIB_FOR_SUN_FIXIDX       85
 tSCC zSysz_Stdlib_For_SunName[] =
      "Sysz_Stdlib_For_Sun";
 /*
@@ -2992,8 +3254,9 @@ const char* apzSysz_Stdlib_For_SunPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  81 - Sysz_Stdtypes_For_Sun fix
+ *  Description of Sysz_Stdtypes_For_Sun fix
  */
+#define SYSZ_STDTYPES_FOR_SUN_FIXIDX     86
 tSCC zSysz_Stdtypes_For_SunName[] =
      "Sysz_Stdtypes_For_Sun";
 /*
@@ -3032,8 +3295,9 @@ const char* apzSysz_Stdtypes_For_SunPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  82 - Tinfo_Cplusplus fix
+ *  Description of Tinfo_Cplusplus fix
  */
+#define TINFO_CPLUSPLUS_FIXIDX           87
 tSCC zTinfo_CplusplusName[] =
      "Tinfo_Cplusplus";
 /*
@@ -3058,8 +3322,9 @@ const char* apzTinfo_CplusplusPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  83 - Ultrix_Ansi_Compat fix
+ *  Description of Ultrix_Ansi_Compat fix
  */
+#define ULTRIX_ANSI_COMPAT_FIXIDX        88
 tSCC zUltrix_Ansi_CompatName[] =
      "Ultrix_Ansi_Compat";
 /*
@@ -3081,7 +3346,7 @@ tSCC zUltrix_Ansi_CompatSelect0[] =
 #define    ULTRIX_ANSI_COMPAT_TEST_CT  1
 #define    ULTRIX_ANSI_COMPAT_RE_CT    1
 tTestDesc aUltrix_Ansi_CompatTests[] = {
-  { TT_EGREP,  zUltrix_Ansi_CompatSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zUltrix_Ansi_CompatSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Ultrix_Ansi_Compat
@@ -3094,8 +3359,9 @@ const char* apzUltrix_Ansi_CompatPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  84 - Ultrix_Fix_Fixproto fix
+ *  Description of Ultrix_Fix_Fixproto fix
  */
+#define ULTRIX_FIX_FIXPROTO_FIXIDX       89
 tSCC zUltrix_Fix_FixprotoName[] =
      "Ultrix_Fix_Fixproto";
 /*
@@ -3117,7 +3383,7 @@ tSCC zUltrix_Fix_FixprotoSelect0[] =
 #define    ULTRIX_FIX_FIXPROTO_TEST_CT  1
 #define    ULTRIX_FIX_FIXPROTO_RE_CT    1
 tTestDesc aUltrix_Fix_FixprotoTests[] = {
-  { TT_EGREP,  zUltrix_Fix_FixprotoSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zUltrix_Fix_FixprotoSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Ultrix_Fix_Fixproto
@@ -3129,8 +3395,9 @@ struct utsname;\n",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  85 - Ultrix_Atof_Param fix
+ *  Description of Ultrix_Atof_Param fix
  */
+#define ULTRIX_ATOF_PARAM_FIXIDX         90
 tSCC zUltrix_Atof_ParamName[] =
      "Ultrix_Atof_Param";
 /*
@@ -3159,8 +3426,9 @@ const char* apzUltrix_Atof_ParamPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  86 - Ultrix_Const fix
+ *  Description of Ultrix_Const fix
  */
+#define ULTRIX_CONST_FIXIDX              91
 tSCC zUltrix_ConstName[] =
      "Ultrix_Const";
 /*
@@ -3193,8 +3461,9 @@ const char* apzUltrix_ConstPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  87 - Ultrix_Ifdef fix
+ *  Description of Ultrix_Ifdef fix
  */
+#define ULTRIX_IFDEF_FIXIDX              92
 tSCC zUltrix_IfdefName[] =
      "Ultrix_Ifdef";
 /*
@@ -3216,7 +3485,7 @@ tSCC zUltrix_IfdefSelect0[] =
 #define    ULTRIX_IFDEF_TEST_CT  1
 #define    ULTRIX_IFDEF_RE_CT    1
 tTestDesc aUltrix_IfdefTests[] = {
-  { TT_EGREP,  zUltrix_IfdefSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zUltrix_IfdefSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Ultrix_Ifdef
@@ -3227,8 +3496,9 @@ const char* apzUltrix_IfdefPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  88 - Ultrix_Nested_Cmnt fix
+ *  Description of Ultrix_Nested_Cmnt fix
  */
+#define ULTRIX_NESTED_CMNT_FIXIDX        93
 tSCC zUltrix_Nested_CmntName[] =
      "Ultrix_Nested_Cmnt";
 /*
@@ -3253,8 +3523,9 @@ const char* apzUltrix_Nested_CmntPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  89 - Ultrix_Static fix
+ *  Description of Ultrix_Static fix
  */
+#define ULTRIX_STATIC_FIXIDX             94
 tSCC zUltrix_StaticName[] =
      "Ultrix_Static";
 /*
@@ -3276,7 +3547,7 @@ tSCC zUltrix_StaticSelect0[] =
 #define    ULTRIX_STATIC_TEST_CT  1
 #define    ULTRIX_STATIC_RE_CT    1
 tTestDesc aUltrix_StaticTests[] = {
-  { TT_EGREP,  zUltrix_StaticSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zUltrix_StaticSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Ultrix_Static
@@ -3289,8 +3560,9 @@ const char* apzUltrix_StaticPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  90 - Undefine_Null fix
+ *  Description of Undefine_Null fix
  */
+#define UNDEFINE_NULL_FIXIDX             95
 tSCC zUndefine_NullName[] =
      "Undefine_Null";
 /*
@@ -3317,8 +3589,8 @@ tSCC zUndefine_NullBypass0[] =
 #define    UNDEFINE_NULL_TEST_CT  2
 #define    UNDEFINE_NULL_RE_CT    2
 tTestDesc aUndefine_NullTests[] = {
-  { TT_NEGREP, zUndefine_NullBypass0,   (regex_t*)NULL },
-  { TT_EGREP,  zUndefine_NullSelect0,   (regex_t*)NULL }, };
+  { TT_NEGREP,   zUndefine_NullBypass0, (regex_t*)NULL },
+  { TT_EGREP,    zUndefine_NullSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Undefine_Null
@@ -3330,8 +3602,9 @@ const char* apzUndefine_NullPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  91 - Va_I960_Macro fix
+ *  Description of Va_I960_Macro fix
  */
+#define VA_I960_MACRO_FIXIDX             96
 tSCC zVa_I960_MacroName[] =
      "Va_I960_Macro";
 /*
@@ -3353,7 +3626,7 @@ tSCC zVa_I960_MacroSelect0[] =
 #define    VA_I960_MACRO_TEST_CT  1
 #define    VA_I960_MACRO_RE_CT    1
 tTestDesc aVa_I960_MacroTests[] = {
-  { TT_EGREP,  zVa_I960_MacroSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zVa_I960_MacroSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Va_I960_Macro
@@ -3367,8 +3640,9 @@ const char* apzVa_I960_MacroPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  92 - Void_Null fix
+ *  Description of Void_Null fix
  */
+#define VOID_NULL_FIXIDX                 97
 tSCC zVoid_NullName[] =
      "Void_Null";
 /*
@@ -3390,7 +3664,7 @@ tSCC zVoid_NullSelect0[] =
 #define    VOID_NULL_TEST_CT  1
 #define    VOID_NULL_RE_CT    1
 tTestDesc aVoid_NullTests[] = {
-  { TT_EGREP,  zVoid_NullSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zVoid_NullSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Void_Null
@@ -3401,8 +3675,9 @@ const char* apzVoid_NullPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  93 - Vxworks_Gcc_Problem fix
+ *  Description of Vxworks_Gcc_Problem fix
  */
+#define VXWORKS_GCC_PROBLEM_FIXIDX       98
 tSCC zVxworks_Gcc_ProblemName[] =
      "Vxworks_Gcc_Problem";
 /*
@@ -3424,7 +3699,7 @@ tSCC zVxworks_Gcc_ProblemSelect0[] =
 #define    VXWORKS_GCC_PROBLEM_TEST_CT  1
 #define    VXWORKS_GCC_PROBLEM_RE_CT    1
 tTestDesc aVxworks_Gcc_ProblemTests[] = {
-  { TT_EGREP,  zVxworks_Gcc_ProblemSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zVxworks_Gcc_ProblemSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Vxworks_Gcc_Problem
@@ -3450,8 +3725,9 @@ const char* apzVxworks_Gcc_ProblemPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  94 - Vxworks_Needs_Vxtypes fix
+ *  Description of Vxworks_Needs_Vxtypes fix
  */
+#define VXWORKS_NEEDS_VXTYPES_FIXIDX     99
 tSCC zVxworks_Needs_VxtypesName[] =
      "Vxworks_Needs_Vxtypes";
 /*
@@ -3473,7 +3749,7 @@ tSCC zVxworks_Needs_VxtypesSelect0[] =
 #define    VXWORKS_NEEDS_VXTYPES_TEST_CT  1
 #define    VXWORKS_NEEDS_VXTYPES_RE_CT    1
 tTestDesc aVxworks_Needs_VxtypesTests[] = {
-  { TT_EGREP,  zVxworks_Needs_VxtypesSelect0,   (regex_t*)NULL }, };
+  { TT_EGREP,    zVxworks_Needs_VxtypesSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Vxworks_Needs_Vxtypes
@@ -3484,8 +3760,9 @@ const char* apzVxworks_Needs_VxtypesPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  95 - Vxworks_Needs_Vxworks fix
+ *  Description of Vxworks_Needs_Vxworks fix
  */
+#define VXWORKS_NEEDS_VXWORKS_FIXIDX     100
 tSCC zVxworks_Needs_VxworksName[] =
      "Vxworks_Needs_Vxworks";
 /*
@@ -3517,10 +3794,10 @@ tSCC zVxworks_Needs_VxworksTest2[] =
 #define    VXWORKS_NEEDS_VXWORKS_TEST_CT  4
 #define    VXWORKS_NEEDS_VXWORKS_RE_CT    1
 tTestDesc aVxworks_Needs_VxworksTests[] = {
-  { TT_TEST,   zVxworks_Needs_VxworksTest0,     0 /* unused */ },
-  { TT_TEST,   zVxworks_Needs_VxworksTest1,     0 /* unused */ },
-  { TT_TEST,   zVxworks_Needs_VxworksTest2,     0 /* unused */ },
-  { TT_EGREP,  zVxworks_Needs_VxworksSelect0,   (regex_t*)NULL }, };
+  { TT_TEST,     zVxworks_Needs_VxworksTest0,   0 /* unused */ },
+  { TT_TEST,     zVxworks_Needs_VxworksTest1,   0 /* unused */ },
+  { TT_TEST,     zVxworks_Needs_VxworksTest2,   0 /* unused */ },
+  { TT_EGREP,    zVxworks_Needs_VxworksSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Vxworks_Needs_Vxworks
@@ -3532,8 +3809,9 @@ const char* apzVxworks_Needs_VxworksPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  96 - Vxworks_Time fix
+ *  Description of Vxworks_Time fix
  */
+#define VXWORKS_TIME_FIXIDX              101
 tSCC zVxworks_TimeName[] =
      "Vxworks_Time";
 /*
@@ -3561,8 +3839,8 @@ tSCC zVxworks_TimeTest0[] =
 #define    VXWORKS_TIME_TEST_CT  2
 #define    VXWORKS_TIME_RE_CT    1
 tTestDesc aVxworks_TimeTests[] = {
-  { TT_TEST,   zVxworks_TimeTest0,     0 /* unused */ },
-  { TT_EGREP,  zVxworks_TimeSelect0,   (regex_t*)NULL }, };
+  { TT_TEST,     zVxworks_TimeTest0,   0 /* unused */ },
+  { TT_EGREP,    zVxworks_TimeSelect0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for Vxworks_Time
@@ -3582,8 +3860,9 @@ typedef void (*__gcc_VOIDFUNCPTR) ();\\\n\
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  97 - X11_Class fix
+ *  Description of X11_Class fix
  */
+#define X11_CLASS_FIXIDX                 102
 tSCC zX11_ClassName[] =
      "X11_Class";
 /*
@@ -3605,7 +3884,7 @@ tSCC zX11_ClassBypass0[] =
 #define    X11_CLASS_TEST_CT  1
 #define    X11_CLASS_RE_CT    1
 tTestDesc aX11_ClassTests[] = {
-  { TT_NEGREP, zX11_ClassBypass0,   (regex_t*)NULL }, };
+  { TT_NEGREP,   zX11_ClassBypass0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for X11_Class
@@ -3621,8 +3900,9 @@ const char* apzX11_ClassPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  98 - X11_Class_Usage fix
+ *  Description of X11_Class_Usage fix
  */
+#define X11_CLASS_USAGE_FIXIDX           103
 tSCC zX11_Class_UsageName[] =
      "X11_Class_Usage";
 /*
@@ -3644,7 +3924,7 @@ tSCC zX11_Class_UsageBypass0[] =
 #define    X11_CLASS_USAGE_TEST_CT  1
 #define    X11_CLASS_USAGE_RE_CT    1
 tTestDesc aX11_Class_UsageTests[] = {
-  { TT_NEGREP, zX11_Class_UsageBypass0,   (regex_t*)NULL }, };
+  { TT_NEGREP,   zX11_Class_UsageBypass0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for X11_Class_Usage
@@ -3655,8 +3935,9 @@ const char* apzX11_Class_UsagePatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description  99 - X11_New fix
+ *  Description of X11_New fix
  */
+#define X11_NEW_FIXIDX                   104
 tSCC zX11_NewName[] =
      "X11_New";
 /*
@@ -3678,7 +3959,7 @@ tSCC zX11_NewBypass0[] =
 #define    X11_NEW_TEST_CT  1
 #define    X11_NEW_RE_CT    1
 tTestDesc aX11_NewTests[] = {
-  { TT_NEGREP, zX11_NewBypass0,   (regex_t*)NULL }, };
+  { TT_NEGREP,   zX11_NewBypass0, (regex_t*)NULL }, };
 
 /*
  *  Fix Command Arguments for X11_New
@@ -3695,8 +3976,9 @@ const char* apzX11_NewPatch[] = { "sed",
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description 100 - X11_Sprintf fix
+ *  Description of X11_Sprintf fix
  */
+#define X11_SPRINTF_FIXIDX               105
 tSCC zX11_SprintfName[] =
      "X11_Sprintf";
 /*
@@ -3723,219 +4005,48 @@ extern char *\tsprintf();\\\n\
 
 /* * * * * * * * * * * * * * * * * * * * * * * * * *
  *
- *  Description 101 - Zzz_Ki_Iface fix
- */
-tSCC zZzz_Ki_IfaceName[] =
-     "Zzz_Ki_Iface";
-/*
- *  File name selection pattern
- */
-tSCC zZzz_Ki_IfaceList[] =
-  "|sys/ki_iface.h|";
-/*
- *  Machine/OS name selection pattern
- */
-#define apzZzz_Ki_IfaceMachs (const char**)NULL
-
-/*
- *  content selection pattern - do fix if pattern found
- */
-tSCC zZzz_Ki_IfaceSelect0[] =
-       "These definitions are for HP Internal developers";
-
-#define    ZZZ_KI_IFACE_TEST_CT  1
-#define    ZZZ_KI_IFACE_RE_CT    1
-tTestDesc aZzz_Ki_IfaceTests[] = {
-  { TT_EGREP,  zZzz_Ki_IfaceSelect0,   (regex_t*)NULL }, };
-
-/*
- *  Fix Command Arguments for Zzz_Ki_Iface
- */
-const char* apzZzz_Ki_IfacePatch[] = { "sh", "-c",
-    "echo \"Removing incorrect fix to <$file>\" >&2\n\
-rm -f ${DESTFILE} ${DESTDIR}/fixinc.tmp\n\
-cat > /dev/null",
-    (char*)NULL };
-
-/* * * * * * * * * * * * * * * * * * * * * * * * * *
- *
- *  Description 102 - Zzz_Ki fix
- */
-tSCC zZzz_KiName[] =
-     "Zzz_Ki";
-/*
- *  File name selection pattern
- */
-tSCC zZzz_KiList[] =
-  "|sys/ki.h|";
-/*
- *  Machine/OS name selection pattern
- */
-#define apzZzz_KiMachs (const char**)NULL
-
-/*
- *  content selection pattern - do fix if pattern found
- */
-tSCC zZzz_KiSelect0[] =
-       "11.00 HP-UX LP64";
-
-#define    ZZZ_KI_TEST_CT  1
-#define    ZZZ_KI_RE_CT    1
-tTestDesc aZzz_KiTests[] = {
-  { TT_EGREP,  zZzz_KiSelect0,   (regex_t*)NULL }, };
-
-/*
- *  Fix Command Arguments for Zzz_Ki
- */
-const char* apzZzz_KiPatch[] = { "sh", "-c",
-    "echo \"Removing incorrect fix to <$file>\" >&2\n\
-rm -f ${DESTFILE} ${DESTDIR}/fixinc.tmp\n\
-cat > /dev/null",
-    (char*)NULL };
-
-/* * * * * * * * * * * * * * * * * * * * * * * * * *
- *
- *  Description 103 - Zzz_Ki_Calls fix
- */
-tSCC zZzz_Ki_CallsName[] =
-     "Zzz_Ki_Calls";
-/*
- *  File name selection pattern
- */
-tSCC zZzz_Ki_CallsList[] =
-  "|sys/ki_calls.h|";
-/*
- *  Machine/OS name selection pattern
- */
-#define apzZzz_Ki_CallsMachs (const char**)NULL
-
-/*
- *  content selection pattern - do fix if pattern found
- */
-tSCC zZzz_Ki_CallsSelect0[] =
-       "kthread_create_caller_t";
-
-#define    ZZZ_KI_CALLS_TEST_CT  1
-#define    ZZZ_KI_CALLS_RE_CT    1
-tTestDesc aZzz_Ki_CallsTests[] = {
-  { TT_EGREP,  zZzz_Ki_CallsSelect0,   (regex_t*)NULL }, };
-
-/*
- *  Fix Command Arguments for Zzz_Ki_Calls
- */
-const char* apzZzz_Ki_CallsPatch[] = { "sh", "-c",
-    "echo \"Removing incorrect fix to <$file>\" >&2\n\
-rm -f ${DESTFILE} ${DESTDIR}/fixinc.tmp\n\
-cat > /dev/null",
-    (char*)NULL };
-
-/* * * * * * * * * * * * * * * * * * * * * * * * * *
- *
- *  Description 104 - Zzz_Ki_Defs fix
- */
-tSCC zZzz_Ki_DefsName[] =
-     "Zzz_Ki_Defs";
-/*
- *  File name selection pattern
- */
-tSCC zZzz_Ki_DefsList[] =
-  "|sys/ki_defs.h|";
-/*
- *  Machine/OS name selection pattern
- */
-#define apzZzz_Ki_DefsMachs (const char**)NULL
-
-/*
- *  content selection pattern - do fix if pattern found
- */
-tSCC zZzz_Ki_DefsSelect0[] =
-       "Kernel Instrumentation Definitions";
-
-#define    ZZZ_KI_DEFS_TEST_CT  1
-#define    ZZZ_KI_DEFS_RE_CT    1
-tTestDesc aZzz_Ki_DefsTests[] = {
-  { TT_EGREP,  zZzz_Ki_DefsSelect0,   (regex_t*)NULL }, };
-
-/*
- *  Fix Command Arguments for Zzz_Ki_Defs
- */
-const char* apzZzz_Ki_DefsPatch[] = { "sh", "-c",
-    "echo \"Removing incorrect fix to <$file>\" >&2\n\
-rm -f ${DESTFILE} ${DESTDIR}/fixinc.tmp\n\
-cat > /dev/null",
-    (char*)NULL };
-
-/* * * * * * * * * * * * * * * * * * * * * * * * * *
- *
- *  Description 105 - Zzz_Bad_Fixes fix
- */
-tSCC zZzz_Bad_FixesName[] =
-     "Zzz_Bad_Fixes";
-/*
- *  File name selection pattern
- */
-tSCC zZzz_Bad_FixesList[] =
-  "|sundev/ipi_error.h|";
-/*
- *  Machine/OS name selection pattern
- */
-#define apzZzz_Bad_FixesMachs (const char**)NULL
-#define ZZZ_BAD_FIXES_TEST_CT  0
-#define ZZZ_BAD_FIXES_RE_CT    0
-#define aZzz_Bad_FixesTests   (tTestDesc*)NULL
-
-/*
- *  Fix Command Arguments for Zzz_Bad_Fixes
- */
-const char* apzZzz_Bad_FixesPatch[] = { "sh", "-c",
-    "echo \"Removing incorrect fix to <$file>\" >&2\n\
-rm -f ${DESTFILE} ${DESTDIR}/fixinc.tmp\n\
-cat > /dev/null",
-    (char*)NULL };
-
-/* * * * * * * * * * * * * * * * * * * * * * * * * *
- *
- *  Description 106 - Zzz_Time fix
- */
-tSCC zZzz_TimeName[] =
-     "Zzz_Time";
-/*
- *  File name selection pattern
- */
-tSCC zZzz_TimeList[] =
-  "|sys/time.h|";
-/*
- *  Machine/OS name selection pattern
- */
-#define apzZzz_TimeMachs (const char**)NULL
-
-/*
- *  content selection pattern - do fix if pattern found
- */
-tSCC zZzz_TimeSelect0[] =
-       "11.0 and later representation of ki time";
-
-#define    ZZZ_TIME_TEST_CT  1
-#define    ZZZ_TIME_RE_CT    1
-tTestDesc aZzz_TimeTests[] = {
-  { TT_EGREP,  zZzz_TimeSelect0,   (regex_t*)NULL }, };
-
-/*
- *  Fix Command Arguments for Zzz_Time
- */
-const char* apzZzz_TimePatch[] = { "sh", "-c",
-    "echo \"Removing incorrect fix to <$file>\" >&2\n\
-rm -f ${DESTFILE} ${DESTDIR}/fixinc.tmp\n\
-cat > /dev/null",
-    (char*)NULL };
-
-/* * * * * * * * * * * * * * * * * * * * * * * * * *
- *
  *  List of all fixes
  */
-#define  REGEX_COUNT  75
-#define  FIX_COUNT    106
+#define REGEX_COUNT          74
+#define MACH_LIST_SIZE_LIMIT 154
+#define FIX_COUNT            106
+
 tFixDesc fixDescList[ FIX_COUNT ] = {
+  {  zAaa_Ki_IfaceName,    zAaa_Ki_IfaceList,
+     apzAaa_Ki_IfaceMachs, (regex_t*)NULL,
+     AAA_KI_IFACE_TEST_CT, FD_MACH_ONLY | FD_REPLACEMENT,
+     aAaa_Ki_IfaceTests,   apzAaa_Ki_IfacePatch },
+
+  {  zAaa_KiName,    zAaa_KiList,
+     apzAaa_KiMachs, (regex_t*)NULL,
+     AAA_KI_TEST_CT, FD_MACH_ONLY | FD_REPLACEMENT,
+     aAaa_KiTests,   apzAaa_KiPatch },
+
+  {  zAaa_Ki_CallsName,    zAaa_Ki_CallsList,
+     apzAaa_Ki_CallsMachs, (regex_t*)NULL,
+     AAA_KI_CALLS_TEST_CT, FD_MACH_ONLY | FD_REPLACEMENT,
+     aAaa_Ki_CallsTests,   apzAaa_Ki_CallsPatch },
+
+  {  zAaa_Ki_DefsName,    zAaa_Ki_DefsList,
+     apzAaa_Ki_DefsMachs, (regex_t*)NULL,
+     AAA_KI_DEFS_TEST_CT, FD_MACH_ONLY | FD_REPLACEMENT,
+     aAaa_Ki_DefsTests,   apzAaa_Ki_DefsPatch },
+
+  {  zAaa_Bad_FixesName,    zAaa_Bad_FixesList,
+     apzAaa_Bad_FixesMachs, (regex_t*)NULL,
+     AAA_BAD_FIXES_TEST_CT, FD_MACH_ONLY | FD_REPLACEMENT,
+     aAaa_Bad_FixesTests,   apzAaa_Bad_FixesPatch },
+
+  {  zAaa_TimeName,    zAaa_TimeList,
+     apzAaa_TimeMachs, (regex_t*)NULL,
+     AAA_TIME_TEST_CT, FD_MACH_ONLY | FD_REPLACEMENT,
+     aAaa_TimeTests,   apzAaa_TimePatch },
+
+  {  zAab_Dgux_Int_VarargsName,    zAab_Dgux_Int_VarargsList,
+     apzAab_Dgux_Int_VarargsMachs, (regex_t*)NULL,
+     AAB_DGUX_INT_VARARGS_TEST_CT, FD_MACH_ONLY | FD_REPLACEMENT,
+     aAab_Dgux_Int_VarargsTests,   apzAab_Dgux_Int_VarargsPatch },
+
   {  zAix_SyswaitName,    zAix_SyswaitList,
      apzAix_SyswaitMachs, (regex_t*)NULL,
      AIX_SYSWAIT_TEST_CT, FD_MACH_ONLY,
@@ -4016,14 +4127,9 @@ tFixDesc fixDescList[ FIX_COUNT ] = {
      DEC_INTERN_ASM_TEST_CT, FD_MACH_ONLY,
      aDec_Intern_AsmTests,   apzDec_Intern_AsmPatch },
 
-  {  zDgux_Int_VarargsName,    zDgux_Int_VarargsList,
-     apzDgux_Int_VarargsMachs, (regex_t*)NULL,
-     DGUX_INT_VARARGS_TEST_CT, FD_MACH_ONLY | FD_SHELL_SCRIPT,
-     aDgux_Int_VarargsTests,   apzDgux_Int_VarargsPatch },
-
   {  zNo_Double_SlashName,    zNo_Double_SlashList,
      apzNo_Double_SlashMachs, (regex_t*)NULL,
-     NO_DOUBLE_SLASH_TEST_CT, FD_MACH_ONLY,
+     NO_DOUBLE_SLASH_TEST_CT, FD_MACH_ONLY | FD_SUBROUTINE,
      aNo_Double_SlashTests,   apzNo_Double_SlashPatch },
 
   {  zEcd_CursorName,    zEcd_CursorList,
@@ -4434,35 +4540,5 @@ tFixDesc fixDescList[ FIX_COUNT ] = {
   {  zX11_SprintfName,    zX11_SprintfList,
      apzX11_SprintfMachs, (regex_t*)NULL,
      X11_SPRINTF_TEST_CT, FD_MACH_ONLY,
-     aX11_SprintfTests,   apzX11_SprintfPatch },
-
-  {  zZzz_Ki_IfaceName,    zZzz_Ki_IfaceList,
-     apzZzz_Ki_IfaceMachs, (regex_t*)NULL,
-     ZZZ_KI_IFACE_TEST_CT, FD_MACH_ONLY | FD_SHELL_SCRIPT,
-     aZzz_Ki_IfaceTests,   apzZzz_Ki_IfacePatch },
-
-  {  zZzz_KiName,    zZzz_KiList,
-     apzZzz_KiMachs, (regex_t*)NULL,
-     ZZZ_KI_TEST_CT, FD_MACH_ONLY | FD_SHELL_SCRIPT,
-     aZzz_KiTests,   apzZzz_KiPatch },
-
-  {  zZzz_Ki_CallsName,    zZzz_Ki_CallsList,
-     apzZzz_Ki_CallsMachs, (regex_t*)NULL,
-     ZZZ_KI_CALLS_TEST_CT, FD_MACH_ONLY | FD_SHELL_SCRIPT,
-     aZzz_Ki_CallsTests,   apzZzz_Ki_CallsPatch },
-
-  {  zZzz_Ki_DefsName,    zZzz_Ki_DefsList,
-     apzZzz_Ki_DefsMachs, (regex_t*)NULL,
-     ZZZ_KI_DEFS_TEST_CT, FD_MACH_ONLY | FD_SHELL_SCRIPT,
-     aZzz_Ki_DefsTests,   apzZzz_Ki_DefsPatch },
-
-  {  zZzz_Bad_FixesName,    zZzz_Bad_FixesList,
-     apzZzz_Bad_FixesMachs, (regex_t*)NULL,
-     ZZZ_BAD_FIXES_TEST_CT, FD_MACH_ONLY | FD_SHELL_SCRIPT,
-     aZzz_Bad_FixesTests,   apzZzz_Bad_FixesPatch },
-
-  {  zZzz_TimeName,    zZzz_TimeList,
-     apzZzz_TimeMachs, (regex_t*)NULL,
-     ZZZ_TIME_TEST_CT, FD_MACH_ONLY | FD_SHELL_SCRIPT,
-     aZzz_TimeTests,   apzZzz_TimePatch }
+     aX11_SprintfTests,   apzX11_SprintfPatch }
 };
diff --git a/gcc/fixinc/fixlib.c b/gcc/fixinc/fixlib.c
new file mode 100644 (file)
index 0000000..25a672e
--- /dev/null
@@ -0,0 +1,56 @@
+
+#include "fixlib.h"
+
+/* * * * * * * * * * * * *
+   load_file_data loads all the contents of a file into malloc-ed memory.
+   Its argument is the file pointer of the file to read in; the returned
+   result is the NUL terminated contents of the file.  The file
+   is presumed to be an ASCII text file containing no NULs.  */
+
+char *
+load_file_data (fp)
+     FILE* fp;
+{
+  char *pz_data = (char*)NULL;
+  int    space_left = -1;  /* allow for terminating NUL */
+  size_t space_used = 0;
+
+  do
+    {
+      size_t  size_read;
+
+      if (space_left < 1024)
+        {
+          space_left += 4096;
+          pz_data = realloc ((void*)pz_data, space_left + space_used + 1 );
+        }
+      size_read = fread (pz_data + space_used, 1, space_left, fp);
+
+      if (size_read == 0)
+        {
+          if (feof (fp))
+            break;
+
+          if (ferror (fp))
+            {
+              int err = errno;
+              if (err != EISDIR)
+                fprintf (stderr, "error %d (%s) reading input\n", err,
+                         strerror (err));
+              free ((void *) pz_data);
+              fclose (fp);
+              return (char *) NULL;
+            }
+        }
+
+      space_left -= size_read;
+      space_used += size_read;
+    } while (! feof (fp));
+
+  pz_data = realloc ((void*)pz_data, space_used+1 );
+  pz_data[ space_used ] = NUL;
+  fclose (fp);
+
+  return pz_data;
+}
diff --git a/gcc/fixinc/fixlib.h b/gcc/fixinc/fixlib.h
new file mode 100644 (file)
index 0000000..3821905
--- /dev/null
@@ -0,0 +1,92 @@
+
+/* Install modified versions of certain ANSI-incompatible system header
+   files which are fixed to work correctly with ANSI C and placed in a
+   directory that GNU C will search.
+
+   Copyright (C) 1997, 1998, 1999 Free Software Foundation, Inc.
+
+This file is part of GNU CC.
+
+GNU CC is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU CC is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU CC; see the file COPYING.  If not, write to
+the Free Software Foundation, 59 Temple Place - Suite 330,
+Boston, MA 02111-1307, USA.  */
+
+#ifndef FIXINCLUDES_FIXLIB_H
+#define FIXINCLUDES_FIXLIB_H
+
+#include "auto-host.h"
+#include "gansidecl.h"
+#include "system.h"
+
+#include "gnu-regex.h"
+
+#ifndef STDIN_FILENO
+# define STDIN_FILENO   0
+#endif
+#ifndef STDOUT_FILENO
+# define STDOUT_FILENO  1
+#endif
+
+typedef int t_success;
+
+#define FAILURE         (-1)
+#define SUCCESS           0
+#define PROBLEM           1
+
+#define SUCCEEDED(p)    ((p) == SUCCESS)
+#define SUCCESSFUL(p)   SUCCEEDED (p)
+#define FAILED(p)       ((p) < SUCCESS)
+#define HADGLITCH(p)    ((p) > SUCCESS)
+
+
+#define tSCC static const char
+#define tCC  const char
+#define tSC  static char
+
+/* If this particular system's header files define the macro `MAXPATHLEN',
+   we happily take advantage of it; otherwise we use a value which ought
+   to be large enough.  */
+#ifndef MAXPATHLEN
+# define MAXPATHLEN     4096
+#endif
+
+#ifndef EXIT_SUCCESS
+# define EXIT_SUCCESS 0
+#endif
+#ifndef EXIT_FAILURE
+# define EXIT_FAILURE 1
+#endif
+
+#define NUL             '\0'
+
+#ifndef NOPROCESS
+#define NOPROCESS      ((pid_t) -1)
+#define NULLPROCESS    ((pid_t)0)
+
+#define EXIT_PANIC     99
+
+typedef enum
+{
+  BOOL_FALSE, BOOL_TRUE
+} t_bool;
+
+#define _P_(p) ()
+#endif
+
+/*
+ *  Exported procedures
+ */
+char * load_file_data _P_(( FILE* fp ));
+
+#endif /* FIXINCLUDES_FIXLIB_H */
diff --git a/gcc/fixinc/fixtests.c b/gcc/fixinc/fixtests.c
new file mode 100644 (file)
index 0000000..07161ce
--- /dev/null
@@ -0,0 +1,220 @@
+
+/*
+
+   Test to see if a particular fix should be applied to a header file.
+
+   Copyright (C) 1997, 1998, 1999 Free Software Foundation, Inc.
+
+= = = = = = = = = = = = = = = = = = = = = = = = =
+
+NOTE TO DEVELOPERS
+
+The routines you write here must work closely with both the fixincl.c
+and the test_need.c program.
+
+Here are the rules:
+
+1.  Every test procedure name must be suffixed with "_test".
+    These routines will be referenced from inclhack.def, sans the suffix.
+
+2.  Use the "TEST_FOR_FIX_PROC_HEAD()" macro _with_ the "_test" suffix
+    (I cannot use the ## magic from ANSI C) for defining your entry point.
+
+3.  Put your test name into the FIX_TEST_TABLE
+
+4.  Do not write anything to stdout.  It may be closed.
+
+5.  Write to stderr only in the event of a reportable error
+    In such an event, call "exit(1)".
+
+= = = = = = = = = = = = = = = = = = = = = = = = =
+
+This file is part of GNU CC.
+
+GNU CC is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU CC is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU CC; see the file COPYING.  If not, write to
+the Free Software Foundation, 59 Temple Place - Suite 330,
+Boston, MA 02111-1307, USA.  */
+
+#include "fixlib.h"
+
+typedef int apply_fix_p_t;  /* Apply Fix Predicate Type */
+
+#define APPLY_FIX 0
+#define SKIP_FIX  1
+
+#define SHOULD_APPLY(afp) ((afp) == APPLY_FIX)
+apply_fix_p_t run_test();
+
+typedef struct {
+    const char*  test_name;
+    apply_fix_p_t (*test_proc)();
+} test_entry_t;
+
+#define FIX_TEST_TABLE \
+  _FT_( "double_slash", double_slash_test )
+
+
+#define TEST_FOR_FIX_PROC_HEAD( test ) \
+static apply_fix_p_t test ( fname, text ) \
+    const char* fname; \
+    const char* text;
+
+/*
+ *  Skip over a quoted string.  Single quote strings may
+ *  contain multiple characters if the first character is
+ *  a backslash.  Especially a backslash followed by octal digits.
+ *  We are not doing a correctness syntax check here.
+ */
+static const char*
+skip_quote( q, text )
+  char  q;
+  char* text;
+{
+  for (;;)
+    {
+      char ch = *(text++);
+      switch (ch)
+        {
+        case '\\':
+          text++; /* skip over whatever character follows */
+          break;
+
+        case '"':
+        case '\'':
+          if (ch != q)
+            break;
+          /*FALLTHROUGH*/
+
+        case '\n':
+        case NUL:
+          goto skip_done;
+        }
+    } skip_done:;
+
+  return text;
+}
+
+
+TEST_FOR_FIX_PROC_HEAD( double_slash_test )
+{
+  /*  First, check to see if the file is in a C++ directory */
+  if (strstr( fname, "CC/" ) != NULL)
+    return SKIP_FIX;
+  if (strstr( fname, "xx/" ) != NULL)
+    return SKIP_FIX;
+  if (strstr( fname, "++/" ) != NULL)
+    return SKIP_FIX;
+
+  /*  Now look for the comment markers in the text */
+  for (;;)
+    {
+      char ch = *(text++);
+      switch (ch)
+        {
+        case '/':
+          switch (*text) /* do not advance `text' here */
+            {
+            case '/':
+              /*
+                We found a "//" pair in open text.
+                The fix must be applied
+              */
+              return APPLY_FIX;
+
+            case '*':
+              /* We found a C-style comment.  Skip forward to the end */
+              text = strstr( text+1, "*/" );
+              if (text == (char*)NULL)
+                goto test_done;
+              text += 2;
+            }
+          break;
+
+        case NUL:
+          goto test_done;
+
+        case '"':
+        case '\'':
+          text = skip_quote( ch, text );
+        }
+
+    } test_done:;
+
+  return SKIP_FIX;
+}
+
+/* = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
+
+     test for fix selector
+
+     THIS IS THE ONLY EXPORTED ROUTINE
+
+*/
+apply_fix_p_t
+run_test( tname, fname, text )
+  const char* tname;
+  const char* fname;
+  const char* text;
+{
+  #define _FT_(n,p) { n, p },
+  static test_entry_t test_table[] = { FIX_TEST_TABLE { NULL, NULL }};
+  #undef _FT_
+  #define TEST_TABLE_CT ((sizeof(test_table)/sizeof(test_table[0]))-1)
+
+  int ct = TEST_TABLE_CT;
+  test_entry_t* pte = test_table;
+
+  do
+    {
+      if (strcmp( pte->test_name, tname ) == 0)
+        return (*pte->test_proc)( fname, text );
+    } while (--ct > 0);
+  fprintf( stderr, "fixincludes error:  the `%s' fix test is unknown\n",
+           tname );
+  exit( 3 );
+}
+
+/* = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
+
+     MAIN ROUTINE
+
+     This file is both included in fixincl.c and compiled as a separate
+     program for use by the inclhack.sh script.
+
+*/
+
+#ifdef MAIN
+
+int
+main( argc, argv )
+  int argc;
+  char** argv;
+{
+  char* fname = *++argv;
+  char* tname = *++argv;
+  char* buf;
+  size_t buf_size = 0;
+
+  if (argc != 3)
+    return run_test( "No test name provided", NULL, NULL, 0 );
+
+  fclose( stdin );
+  fclose( stdout );
+
+  buf = load_file_data (fopen (fname, "r"));
+
+  return run_test( tname, fname, buf );
+}
+
+#endif
index 8461527..36cc390 100644 (file)
@@ -43,70 +43,54 @@ _FOR fix "\n\n" =]
 
     _ENDIF=][=
 
-    #  There are three conditional tests:  select, bypass and test.
+    #  There are four conditional tests:  select, bypass and test c_test.
        They may appear as often as desired.  They must all pass for
        the fix to be applied.  "select" and "bypass" are egrep expressions
        that must each appear (or not appear) in the target file.
        "test" is an arbitrary test program expression that must yield
-       true or false.  It is enclosed in parenthesis to avoid
-       precedence problems.  The output looks like this:
-
-       if ( test -n "`egrep 'find-expr' ${file}`" -a
-                 -z "`egrep 'not-find'  ${file}`" -a
-                 '(' <some-test-expression> ')'
-          ) > /dev/null 2>&1 ; then
-
-    #  =][=
+       true or false.  =][=
 
     _IF select _exist =]
     if ( test [=
         _FOR select " -a \\\n              "
               =]-n [=select _shrstr "#`egrep %s ${file}`"
                             _printf _shstr =][=
-        /select=][=
+        /select=]
+       ) > /dev/null 2>&1 ; then[=
+    _ENDIF =][=
 
-        _IF bypass _exist =][=
+    _IF bypass _exist =]
+    if ( test [=
             _FOR bypass=] -a \
               -z [=bypass _shrstr "#`egrep %s ${file}`"
                             _printf _shstr =][=
-            /bypass=][=
-        _ENDIF=][=
-
-        _IF test _exist=][=
-            _FOR test=] -a \
-              '(' [=test=] ')'[=
-            /test=][=
-        _ENDIF=]
+            /bypass=]
        ) > /dev/null 2>&1 ; then[=
+    _ENDIF =][=
 
-
-    _ELIF test _exist =]
+    _IF test _exist =]
     if ( test [=
         _FOR test " -a \\\n              "
               =]'(' [=test=] ')'[=
-        /test=][=
-
-        _IF bypass _exist=][=
-            _FOR bypass=] -a \
-              -z [=bypass _shrstr "#`egrep %s ${file}`"
-                            _printf _shstr=][=
-            /bypass=][=
-        _ENDIF=]
+        /test=]
        ) > /dev/null 2>&1 ; then[=
+    _ENDIF=][=
 
+    _IF c_test _exist =]
+    if [=
+        _FOR c_test " && \\\n              "
+              =]${FIXTESTS} ${file} [=c_test=][=
+        /c_test=]
+    then[=
 
-    _ELIF bypass _exist =]
-    if ( test [=_FOR bypass " -a \\\n              "
-              =]-z [=bypass _shrstr "#`egrep %s ${file}`"
-                            _printf _shstr=][=/bypass=]
-       ) > /dev/null 2>&1 ; then[=
-
-      _ENDIF=]
+    _ENDIF=][=
+    _IF replace _exist ! =]
     fixlist="${fixlist}
       [=hackname=]"
     if [ ! -r ${DESTFILE} ]
     then infile=${file}
     else infile=${DESTFILE} ; fi [=
+    _ENDIF =][=
 
     _IF sed _exist=][=
         _IF shell _exist =][=
@@ -129,20 +113,50 @@ _FOR fix "\n\n" =]
     if test ! -f ${DESTDIR}/fixinc.tmp
     then continue ; fi [=
 
+    _ELIF c_fix _exist =]
+    ${FIXFIXES} ${file} [=c_fix=] < $infile > ${DESTDIR}/fixinc.tmp[=
+
+    _ELIF replace _exist =][=
+
+      _IF replace _len 0 > =]
+    echo "[=hackname _down=] replacing file ${file}" >&2
+    cat > ${DESTFILE} << '_EOF_'
+[=replace=]
+_EOF_[=
+      _ELSE =]
+    echo "[=hackname _down=] bypassing file ${file}"[=
+      _ENDIF =]
+    continue
+[=
 
     _ELSE=][=
         _ERROR hackname _get "ERROR:  %s has no fixup" _printf=][=
 
-    _ENDIF=]
+    _ENDIF=][=
+
+    _IF replace _exist ! =]
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}[=
+    _ENDIF =][=
 
     #  Close off any opened "if" or "case" statements in reverse order
 
     # =][=
 
-    _IF select _exist test _exist | bypass _exist | =]
-    fi # end of selection 'if'[=
+    _IF c_test _exist =]
+    fi # end of c_test 'if'[=
+    _ENDIF =][=
+
+    _IF test _exist =]
+    fi # end of test expression 'if'[=
+    _ENDIF =][=
+
+    _IF bypass _exist =]
+    fi # end of bypass 'if'[=
+    _ENDIF =][=
+
+    _IF select _exist =]
+    fi # end of select 'if'[=
     _ENDIF =][=
 
     _IF mach _exist=]
index fbdc737..a02efb5 100644 (file)
@@ -45,7 +45,7 @@ The rules for making fixes:
         that the backslash is processed before '\\', '\'' and '#'
         characters (using C character syntax).
 
-4.  There are currently two methods of fixing a file:
+4.  There are currently four methods of fixing a file:
 
     1.  a series of sed expressions.  Each will be an individual
         "-e" argument to a single invocation of sed.
@@ -54,16 +54,182 @@ The rules for making fixes:
         of stdin in order to avoid pipe stalls.  They may choose to
         discard the input.
 
-    A C language subroutine method is planned for both tests and fixes
-    in the near term.  Awk ought to be possible too, but there may
-    be portability issues that I am not familiar with.
+    3.  A C language subroutine method for both tests and fixes.
 
-5.  If the fix is to remove the file (i.e. the fixing process broke
-    the file), then you must use a shell script that deletes all
-    copies of the output file and does not write _anything_ to stdout.
-    See the "zzz_*" fixes at the end of this file.
+    4.  Replacement text.  If the replacement is empty, then
+        no fix is applied.  Otherwise, the replacement text is written
+        to the output file and no further fixes are applied.
+
+        Replacement text "fixes" must be first in this file!!
+
+
+    Now, first:  DO NOT DO BROKEN FIXES (empty replacement fixes) */
+
+
+/*
+ *  Purge some HP-UX 11 files that are only borken after they are "fixed".
+ */
+fix = {
+    hackname = AAA_ki_iface;
+    files    = sys/ki_iface.h;
+    select   = 'These definitions are for HP Internal developers';
+    replace; /* empty replacement -> no fixing the file */
+};
+
+
+/*
+ *  Purge some HP-UX 11 files that are only borken after they are "fixed".
+ */
+fix = {
+    hackname = AAA_ki;
+    files    = sys/ki.h;
+    select   = '11.00 HP-UX LP64';
+    replace; /* empty replacement -> no fixing the file */
+};
+
+
+/*
+ *  Purge some HP-UX 11 files that are only borken after they are "fixed".
+ */
+fix = {
+    hackname = AAA_ki_calls;
+    files    = sys/ki_calls.h;
+    select   = 'kthread_create_caller_t';
+    replace; /* empty replacement -> no fixing the file */
+};
+
+
+/*
+ *  Purge some HP-UX 11 files that are only borken after they are "fixed".
+ */
+fix = {
+    hackname = AAA_ki_defs;
+    files    = sys/ki_defs.h;
+    select   = 'Kernel Instrumentation Definitions';
+    replace; /* empty replacement -> no fixing the file */
+};
+
+
+/*
+ *  This file on SunOS 4 has a very large macro.  When the sed loop
+ *  tries pull it in, it overflows the pattern space size of the SunOS
+ *  sed (GNU sed does not have this problem).  Since the file does not
+ *  require fixing, we remove it from the fixed directory.
+ */
+fix = {
+    hackname = AAA_bad_fixes;
+    files    = sundev/ipi_error.h;
+    /* shouldn't there be a select expression here??? */
+    replace; /* empty replacement -> no fixing the file */
+};
+
+
+/*
+ *  Purge some HP-UX 11 files that are only borken after they are "fixed".
+ */
+fix = {
+    hackname = AAA_time;
+    files    = sys/time.h;
+    select   = '11.0 and later representation of ki time';
+    replace; /* empty replacement -> no fixing the file */
+};
+
+/* And now, the real fixes, replacement text fixes first: */
+
+/*
+ *  Completely replace &lt;_int_varargs.h&gt; with a file that includes gcc's
+ *  stdarg.h or varargs.h files as appropriate on DG/UX
+ */
+fix = {
+    hackname = AAB_dgux_int_varargs;
+    files    = _int_varargs.h;
+    replace  = "#ifndef __INT_VARARGS_H
+\#define __INT_VARARGS_H
+
+/************************************************************************/
+/* _INT_VARARGS.H - Define the common stuff for varargs/stdarg/stdio.   */
+/************************************************************************/
+
+/*
+** This file is a DG internal header.  Never include this
+** file directly.
+*/
+
+\#ifndef ___int_features_h
+\#include &lt;sys/_int_features.h&gt;
+\#endif
+
+\#if !(defined(_VA_LIST) || defined(_VA_LIST_))
+\#define _VA_LIST
+\#define _VA_LIST_
+
+\#ifdef __LINT__
+
+\#ifdef __STDC__
+typedef void * va_list;
+\#else
+typedef char * va_list;
+\#endif
+
+\#else
+\#if _M88K_ANY
+
+\#if defined(__DCC__)
+
+typedef struct {
+      int     next_arg;
+      int     *mem_ptr;
+      int     *reg_ptr;
+} va_list;
+
+\#else  /* ! defined(__DCC__) */
+
+typedef struct {
+      int  __va_arg;       /* argument number */
+      int *__va_stk;       /* start of args passed on stack */
+      int *__va_reg;       /* start of args passed in regs */
+} va_list;
+
+\#endif  /* ! defined(__DCC__) */
+
+\#elif _IX86_ANY
+
+\#if defined(__GNUC__) || defined(__STDC__)
+typedef void * va_list;
+\#else
+typedef char * va_list;
+\#endif
+
+\#endif  /*  _IX86_ANY */
+
+\#endif /* __LINT__ */
+\#endif /*  !(defined(_VA_LIST) || defined(_VA_LIST_)) */
+\#endif /*  #ifndef __INT_VARARGS_H  */\n";
+};
+
+
+/*
+ *  Completely replace <sys/varargs.h> with a file that includes gcc's
+ *  stdarg.h or varargs.h files as appropriate.
+ */
+#ifdef SVR4
+fix = {
+    hackname = AAB_svr4_no_varargs;
+    files    = sys/varargs.h;
+    replace  = "/* This file was generated by fixincludes.  */\n"
+               "#ifndef _SYS_VARARGS_H\n"
+               "#define _SYS_VARARGS_H\n\n"
+
+               "#ifdef __STDC__\n"
+               "#include <stdarg.h>\n"
+               "#else\n"
+               "#include <varargs.h>\n"
+               "#endif\n\n"
+
+               "#endif  /* _SYS_VARARGS_H */\n";
+};
+#endif
 
-Let the fixes begin: */
 
 /*
  *  sys/wait.h on AIX 3.2.5 puts the declaration of wait3 before the definition
@@ -322,80 +488,6 @@ fix = {
 
 
 /*
- *  Completely replace &lt;_int_varargs.h&gt; with a file that includes gcc's
- *  stdarg.h or varargs.h files as appropriate on DG/UX
- */
-fix = {
-    hackname = dgux_int_varargs;
-    files    = _int_varargs.h;
-    shell    = "cat > /dev/null\ncat << '_EOF_'
-\#ifndef __INT_VARARGS_H
-\#define __INT_VARARGS_H
-
-/************************************************************************/
-/* _INT_VARARGS.H - Define the common stuff for varargs/stdarg/stdio.   */
-/************************************************************************/
-
-/*
-** This file is a DG internal header.  Never include this
-** file directly.
-*/
-
-\#ifndef ___int_features_h
-\#include &lt;sys/_int_features.h&gt;
-\#endif
-
-\#if !(defined(_VA_LIST) || defined(_VA_LIST_))
-\#define _VA_LIST
-\#define _VA_LIST_
-
-\#ifdef __LINT__
-
-\#ifdef __STDC__
-typedef void * va_list;
-\#else
-typedef char * va_list;
-\#endif
-
-\#else
-\#if _M88K_ANY
-
-\#if defined(__DCC__)
-
-typedef struct {
-      int     next_arg;
-      int     *mem_ptr;
-      int     *reg_ptr;
-} va_list;
-
-\#else  /* ! defined(__DCC__) */
-
-typedef struct {
-      int  __va_arg;       /* argument number */
-      int *__va_stk;       /* start of args passed on stack */
-      int *__va_reg;       /* start of args passed in regs */
-} va_list;
-
-\#endif  /* ! defined(__DCC__) */
-
-\#elif _IX86_ANY
-
-\#if defined(__GNUC__) || defined(__STDC__)
-typedef void * va_list;
-\#else
-typedef char * va_list;
-\#endif
-
-\#endif  /*  _IX86_ANY */
-
-\#endif /* __LINT__ */
-\#endif /*  !(defined(_VA_LIST) || defined(_VA_LIST_)) */
-\#endif /*  #ifndef __INT_VARARGS_H  */
-_EOF_\n";
-};
-
-
-/*
  *  Remove the double-slash comments
  *  They *must* be removed so it will not create nested comments!!
  *  However, they will *not* be removed if the file name ends with
@@ -435,11 +527,17 @@ fix = {
      *  and do not appear to be within a single-line C-style comment
      *  and are not the end of a quoted string.
      */
+#ifdef NO_C_TESTS
     test   = ' -z "`echo ${file} | egrep \'(CC|cxx|\+\+)/\'`"';
     select = '(^|[^:])//[^"*]';
     sed    = 's,^//.*$,,';
     sed    = 's,\(/\*.*\)//\(.*\*/\),\1/ /\2,g';
     sed    = 's,\([^:]\)//[^"].*$,\1,';
+    sed    = 's,[^:]//[^"].*$,,';
+#else
+    c_test = "double_slash";
+    c_fix  = "no_double_slash";
+#endif
 };
 
 
@@ -1451,7 +1549,7 @@ fix = {
 
   sed -e 's@ va_list @ __gnuc_va_list @' \\
       -e 's@ va_list)@ __gnuc_va_list)@' \\
-      -e 's@ _BSD_VA_LIST_))@ __gnuc_va_list))@' \\
+      -e 's@ _BSD_VA_LIST_));@ __gnuc_va_list));@' \\
       -e 's@ _VA_LIST_));@ __gnuc_va_list));@' \\
       -e 's@ va_list@ __va_list__@' \\
       -e 's@\\*va_list@*__va_list__@' \\
@@ -1868,31 +1966,6 @@ fix = {
 #endif
 
 /*
- *  Completely replace <sys/varargs.h> with a file that includes gcc's
- *  stdarg.h or varargs.h files as appropriate.
- */
-#ifdef SVR4
-fix = {
-    hackname = svr4_no_varargs;
-    files    = sys/varargs.h;
-    shell    = "cat > /dev/null\n"
-               "cat << _EOF_\n"
-               "/* This file was generated by fixincludes.  */\n"
-               "#ifndef _SYS_VARARGS_H\n"
-               "#define _SYS_VARARGS_H\n\n"
-
-               "#ifdef __STDC__\n"
-               "#include <stdarg.h>\n"
-               "#else\n"
-               "#include <varargs.h>\n"
-               "#endif\n\n"
-
-               "#endif  /* _SYS_VARARGS_H */\n"
-               "_EOF_";
-};
-#endif
-
-/*
  *   Fix broken decl of profil present on some svr4 systems.
  */
 #ifdef SVR4
@@ -2443,99 +2516,4 @@ fix = {
                "#endif /* !defined __STDC__ */,";
 };
 
-
-/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
- *
- *  UNDO BROKEN FIXES
- *
- *  We sure do hope that broken fixes and needed fixes are never
- *  applied to the same file!!  :-}
- */
-
-/*
- *  Purge some HP-UX 11 files that are only borken after they are "fixed".
- */
-fix = {
-    hackname = zzz_ki_iface;
-    files    = sys/ki_iface.h;
-    select   = 'These definitions are for HP Internal developers';
-    shell    =
-         "echo \"Removing incorrect fix to <$file>\" >&2\n"
-         "rm -f ${DESTFILE} ${DESTDIR}/fixinc.tmp\n"
-         "cat > /dev/null";
-};
-
-
-/*
- *  Purge some HP-UX 11 files that are only borken after they are "fixed".
- */
-fix = {
-    hackname = zzz_ki;
-    files    = sys/ki.h;
-    select   = '11.00 HP-UX LP64';
-    shell    =
-         "echo \"Removing incorrect fix to <$file>\" >&2\n"
-         "rm -f ${DESTFILE} ${DESTDIR}/fixinc.tmp\n"
-         "cat > /dev/null";
-};
-
-
-/*
- *  Purge some HP-UX 11 files that are only borken after they are "fixed".
- */
-fix = {
-    hackname = zzz_ki_calls;
-    files    = sys/ki_calls.h;
-    select   = 'kthread_create_caller_t';
-    shell    =
-         "echo \"Removing incorrect fix to <$file>\" >&2\n"
-         "rm -f ${DESTFILE} ${DESTDIR}/fixinc.tmp\n"
-         "cat > /dev/null";
-};
-
-
-/*
- *  Purge some HP-UX 11 files that are only borken after they are "fixed".
- */
-fix = {
-    hackname = zzz_ki_defs;
-    files    = sys/ki_defs.h;
-    select   = 'Kernel Instrumentation Definitions';
-    shell    =
-         "echo \"Removing incorrect fix to <$file>\" >&2\n"
-         "rm -f ${DESTFILE} ${DESTDIR}/fixinc.tmp\n"
-         "cat > /dev/null";
-};
-
-
-/*
- *  This file on SunOS 4 has a very large macro.  When the sed loop
- *  tries pull it in, it overflows the pattern space size of the SunOS
- *  sed (GNU sed does not have this problem).  Since the file does not
- *  require fixing, we remove it from the fixed directory.
- */
-fix = {
-    hackname = zzz_bad_fixes;
-    files    = sundev/ipi_error.h;
-    /* shouldn't there be a select expression here??? */
-    shell    =
-         "echo \"Removing incorrect fix to <$file>\" >&2\n"
-         "rm -f ${DESTFILE} ${DESTDIR}/fixinc.tmp\n"
-         "cat > /dev/null";
-};
-
-
-/*
- *  Purge some HP-UX 11 files that are only borken after they are "fixed".
- */
-fix = {
-    hackname = zzz_time;
-    files    = sys/time.h;
-    select   = '11.0 and later representation of ki time';
-    shell    =
-         "echo \"Removing incorrect fix to <$file>\" >&2\n"
-         "rm -f ${DESTFILE} ${DESTDIR}/fixinc.tmp\n"
-         "cat > /dev/null";
-};
-
 /*EOF*/
index 457fc97..2d5ba12 100755 (executable)
@@ -361,7 +361,164 @@ while [ $# != 0 ]; do
     DESTFILE=${DESTDIR}/`echo ${file} | sed "s;${FIND_BASE}/;;" `
 
     #
-    # Fix   1:  Aix_Syswait
+    # Fix   1:  Aaa_Ki_Iface
+    #
+    case "${file}" in ./sys/ki_iface.h )
+    if ( test -n "`egrep 'These definitions are for HP Internal developers' ${file}`"
+       ) > /dev/null 2>&1 ; then
+    echo "aaa_ki_iface bypassing file ${file}"
+    continue
+
+    fi # end of select 'if'
+    ;; # case end for file name test
+    esac
+
+
+    #
+    # Fix   2:  Aaa_Ki
+    #
+    case "${file}" in ./sys/ki.h )
+    if ( test -n "`egrep '11.00 HP-UX LP64' ${file}`"
+       ) > /dev/null 2>&1 ; then
+    echo "aaa_ki bypassing file ${file}"
+    continue
+
+    fi # end of select 'if'
+    ;; # case end for file name test
+    esac
+
+
+    #
+    # Fix   3:  Aaa_Ki_Calls
+    #
+    case "${file}" in ./sys/ki_calls.h )
+    if ( test -n "`egrep 'kthread_create_caller_t' ${file}`"
+       ) > /dev/null 2>&1 ; then
+    echo "aaa_ki_calls bypassing file ${file}"
+    continue
+
+    fi # end of select 'if'
+    ;; # case end for file name test
+    esac
+
+
+    #
+    # Fix   4:  Aaa_Ki_Defs
+    #
+    case "${file}" in ./sys/ki_defs.h )
+    if ( test -n "`egrep 'Kernel Instrumentation Definitions' ${file}`"
+       ) > /dev/null 2>&1 ; then
+    echo "aaa_ki_defs bypassing file ${file}"
+    continue
+
+    fi # end of select 'if'
+    ;; # case end for file name test
+    esac
+
+
+    #
+    # Fix   5:  Aaa_Bad_Fixes
+    #
+    case "${file}" in ./sundev/ipi_error.h )
+    echo "aaa_bad_fixes bypassing file ${file}"
+    continue
+
+    ;; # case end for file name test
+    esac
+
+
+    #
+    # Fix   6:  Aaa_Time
+    #
+    case "${file}" in ./sys/time.h )
+    if ( test -n "`egrep '11.0 and later representation of ki time' ${file}`"
+       ) > /dev/null 2>&1 ; then
+    echo "aaa_time bypassing file ${file}"
+    continue
+
+    fi # end of select 'if'
+    ;; # case end for file name test
+    esac
+
+
+    #
+    # Fix   7:  Aab_Dgux_Int_Varargs
+    #
+    case "${file}" in ./_int_varargs.h )
+    echo "aab_dgux_int_varargs replacing file ${file}" >&2
+    cat > ${DESTFILE} << '_EOF_'
+#ifndef __INT_VARARGS_H
+#define __INT_VARARGS_H
+
+/************************************************************************/
+/* _INT_VARARGS.H - Define the common stuff for varargs/stdarg/stdio.   */
+/************************************************************************/
+
+/*
+** This file is a DG internal header.  Never include this
+** file directly.
+*/
+
+#ifndef ___int_features_h
+#include &lt;sys/_int_features.h&gt;
+#endif
+
+#if !(defined(_VA_LIST) || defined(_VA_LIST_))
+#define _VA_LIST
+#define _VA_LIST_
+
+#ifdef __LINT__
+
+#ifdef __STDC__
+typedef void * va_list;
+#else
+typedef char * va_list;
+#endif
+
+#else
+#if _M88K_ANY
+
+#if defined(__DCC__)
+
+typedef struct {
+      int     next_arg;
+      int     *mem_ptr;
+      int     *reg_ptr;
+} va_list;
+
+#else  /* ! defined(__DCC__) */
+
+typedef struct {
+      int  __va_arg;       /* argument number */
+      int *__va_stk;       /* start of args passed on stack */
+      int *__va_reg;       /* start of args passed in regs */
+} va_list;
+
+#endif  /* ! defined(__DCC__) */
+
+#elif _IX86_ANY
+
+#if defined(__GNUC__) || defined(__STDC__)
+typedef void * va_list;
+#else
+typedef char * va_list;
+#endif
+
+#endif  /*  _IX86_ANY */
+
+#endif /* __LINT__ */
+#endif /*  !(defined(_VA_LIST) || defined(_VA_LIST_)) */
+#endif /*  #ifndef __INT_VARARGS_H  */
+
+_EOF_
+    continue
+
+    ;; # case end for file name test
+    esac
+
+
+    #
+    # Fix   8:  Aix_Syswait
     #
     case "${file}" in ./sys/wait.h )
     if ( test -n "`egrep 'bos325,' ${file}`"
@@ -378,13 +535,13 @@ struct rusage;
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix   2:  Aix_Volatile
+    # Fix   9:  Aix_Volatile
     #
     case "${file}" in ./sys/signal.h )
     if ( test -n "`egrep 'typedef volatile int sig_atomic_t' ${file}`"
@@ -399,13 +556,13 @@ struct rusage;
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix   3:  Alpha_Getopt
+    # Fix  10:  Alpha_Getopt
     #
     case "${file}" in ./stdio.h | \
        ./stdlib.h )
@@ -421,13 +578,13 @@ struct rusage;
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix   4:  Alpha_Parens
+    # Fix  11:  Alpha_Parens
     #
     case "${file}" in ./sym.h )
     if ( test -n "`egrep '#ifndef\\(__mips64\\)' ${file}`"
@@ -442,13 +599,13 @@ struct rusage;
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix   5:  Alpha_Sbrk
+    # Fix  12:  Alpha_Sbrk
     #
     case "${file}" in ./unistd.h )
     if ( test -n "`egrep 'char[        ]*\\*[   ]*sbrk[        ]*\\(' ${file}`"
@@ -463,13 +620,13 @@ struct rusage;
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix   6:  Arm_Norcroft_Hint
+    # Fix  13:  Arm_Norcroft_Hint
     #
     case "${file}" in ./X11/Intrinsic.h )
     if ( test -n "`egrep '___type p_type' ${file}`"
@@ -484,13 +641,13 @@ struct rusage;
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix   7:  Arm_Wchar
+    # Fix  14:  Arm_Wchar
     #
     case "${file}" in ./stdlib.h )
     if ( test -n "`egrep '#[   ]*define[       ]*__wchar_t' ${file}`"
@@ -506,13 +663,13 @@ struct rusage;
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix   8:  Aux_Asm
+    # Fix  15:  Aux_Asm
     #
     case "${file}" in ./sys/param.h )
     if ( test -n "`egrep '#ifndef NOINLINE' ${file}`"
@@ -527,13 +684,13 @@ struct rusage;
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix   9:  Avoid_Bool
+    # Fix  16:  Avoid_Bool
     #
     case "${file}" in ./curses.h | \
        ./curses_colr/curses.h | \
@@ -583,7 +740,7 @@ struct rusage;
 
 
     #
-    # Fix  10:  Bad_Struct_Term
+    # Fix  17:  Bad_Struct_Term
     #
     case "${file}" in ./curses.h )
     if ( test -n "`egrep '^[   ]*typedef[      ]+struct[       ]+term[         ]*;' ${file}`"
@@ -598,13 +755,13 @@ struct rusage;
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  11:  Badquote
+    # Fix  18:  Badquote
     #
     case "${file}" in ./sundev/vuid_event.h )
     fixlist="${fixlist}
@@ -622,7 +779,7 @@ struct rusage;
 
 
     #
-    # Fix  12:  Bad_Lval
+    # Fix  19:  Bad_Lval
     #
     case "${file}" in ./libgen.h | \
        ./dirent.h | \
@@ -653,10 +810,12 @@ struct rusage;
 
 
     #
-    # Fix  13:  Broken_Assert_Stdio
+    # Fix  20:  Broken_Assert_Stdio
     #
     case "${file}" in ./assert.h )
-    if ( test -n "`egrep 'stderr' ${file}`" -a \
+    if ( test -n "`egrep 'stderr' ${file}`"
+       ) > /dev/null 2>&1 ; then
+    if ( test  -a \
               -z "`egrep 'include.*stdio.h' ${file}`"
        ) > /dev/null 2>&1 ; then
     fixlist="${fixlist}
@@ -671,16 +830,19 @@ struct rusage;
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of bypass 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  14:  Broken_Assert_Stdlib
+    # Fix  21:  Broken_Assert_Stdlib
     #
     case "${file}" in ./assert.h )
-    if ( test -n "`egrep 'exit *\\(|abort *\\(' ${file}`" -a \
+    if ( test -n "`egrep 'exit *\\(|abort *\\(' ${file}`"
+       ) > /dev/null 2>&1 ; then
+    if ( test  -a \
               -z "`egrep 'include.*stdlib.h' ${file}`"
        ) > /dev/null 2>&1 ; then
     fixlist="${fixlist}
@@ -697,13 +859,14 @@ struct rusage;
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of bypass 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  15:  Bsd43_Io_Macros
+    # Fix  22:  Bsd43_Io_Macros
     #
     if ( test -n "`egrep 'BSD43__IO' ${file}`"
        ) > /dev/null 2>&1 ; then
@@ -718,11 +881,11 @@ struct rusage;
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
 
 
     #
-    # Fix  16:  Dec_Intern_Asm
+    # Fix  23:  Dec_Intern_Asm
     #
     case "${file}" in ./c_asm.h )
     fixlist="${fixlist}
@@ -745,115 +908,23 @@ struct rusage;
 
 
     #
-    # Fix  17:  Dgux_Int_Varargs
-    #
-    case "${file}" in ./_int_varargs.h )
-    fixlist="${fixlist}
-      dgux_int_varargs"
-    if [ ! -r ${DESTFILE} ]
-    then infile=${file}
-    else infile=${DESTFILE} ; fi 
-    ( cat > /dev/null
-cat << '_EOF_'
-#ifndef __INT_VARARGS_H
-#define __INT_VARARGS_H
-
-/************************************************************************/
-/* _INT_VARARGS.H - Define the common stuff for varargs/stdarg/stdio.   */
-/************************************************************************/
-
-/*
-** This file is a DG internal header.  Never include this
-** file directly.
-*/
-
-#ifndef ___int_features_h
-#include &lt;sys/_int_features.h&gt;
-#endif
-
-#if !(defined(_VA_LIST) || defined(_VA_LIST_))
-#define _VA_LIST
-#define _VA_LIST_
-
-#ifdef __LINT__
-
-#ifdef __STDC__
-typedef void * va_list;
-#else
-typedef char * va_list;
-#endif
-
-#else
-#if _M88K_ANY
-
-#if defined(__DCC__)
-
-typedef struct {
-      int     next_arg;
-      int     *mem_ptr;
-      int     *reg_ptr;
-} va_list;
-
-#else  /* ! defined(__DCC__) */
-
-typedef struct {
-      int  __va_arg;       /* argument number */
-      int *__va_stk;       /* start of args passed on stack */
-      int *__va_reg;       /* start of args passed in regs */
-} va_list;
-
-#endif  /* ! defined(__DCC__) */
-
-#elif _IX86_ANY
-
-#if defined(__GNUC__) || defined(__STDC__)
-typedef void * va_list;
-#else
-typedef char * va_list;
-#endif
-
-#endif  /*  _IX86_ANY */
-
-#endif /* __LINT__ */
-#endif /*  !(defined(_VA_LIST) || defined(_VA_LIST_)) */
-#endif /*  #ifndef __INT_VARARGS_H  */
-_EOF_
- ) < $infile > ${DESTDIR}/fixinc.tmp
-
-    #  Shell scripts have the potential of removing the output
-    #  We interpret that to mean the file is not to be altered
-    #
-    if test ! -f ${DESTDIR}/fixinc.tmp
-    then continue ; fi 
-    rm -f ${DESTFILE}
-    mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    ;; # case end for file name test
-    esac
-
-
-    #
-    # Fix  18:  No_Double_Slash
+    # Fix  24:  No_Double_Slash
     #
-    if ( test -n "`egrep '(^|[^:])//[^\"*]' ${file}`" -a \
-              '('  -z "`echo ${file} | egrep '(CC|cxx|\+\+)/'`" ')'
-       ) > /dev/null 2>&1 ; then
+    if ${FIXTESTS} ${file} double_slash
+    then
     fixlist="${fixlist}
       no_double_slash"
     if [ ! -r ${DESTFILE} ]
     then infile=${file}
     else infile=${DESTFILE} ; fi 
-
-    sed -e 's,^//.*$,,' \
-        -e 's,\(/\*.*\)//\(.*\*/\),\1/ /\2,g' \
-        -e 's,\([^:]\)//[^"].*$,\1,' \
-          < $infile > ${DESTDIR}/fixinc.tmp
+    ${FIXFIXES} ${file} no_double_slash < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of c_test 'if'
 
 
     #
-    # Fix  19:  Ecd_Cursor
+    # Fix  25:  Ecd_Cursor
     #
     case "${file}" in ./sunwindow/win_lock.h | \
        ./sunwindow/win_cursor.h )
@@ -872,7 +943,7 @@ _EOF_
 
 
     #
-    # Fix  20:  Sco5_Stat_Wrappers
+    # Fix  26:  Sco5_Stat_Wrappers
     #
     case "${file}" in ./sys/stat.h )
     case "$target_canonical" in i*86-*-sco3.2v5* )
@@ -903,7 +974,7 @@ extern "C"\
 
 
     #
-    # Fix  21:  End_Else_Label
+    # Fix  27:  End_Else_Label
     #
     if ( test -n "`egrep '^[   ]*#[    ]*(else|endif)[         ]+([!-.0-z\\{\\|\\}\\~]|/[^\\*])' ${file}`"
        ) > /dev/null 2>&1 ; then
@@ -926,11 +997,11 @@ s%^\([    ]*#[    ]*endif\)[      ][      ]*[^/*  ].*%\1%' \
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
 
 
     #
-    # Fix  22:  Hp_Inline
+    # Fix  28:  Hp_Inline
     #
     case "${file}" in ./sys/spinlock.h )
     if ( test -n "`egrep 'include.*\"\\.\\./machine/' ${file}`"
@@ -946,13 +1017,13 @@ s%^\([   ]*#[    ]*endif\)[      ][      ]*[^/*  ].*%\1%' \
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  23:  Hp_Sysfile
+    # Fix  29:  Hp_Sysfile
     #
     case "${file}" in ./sys/file.h )
     if ( test -n "`egrep 'HPUX_SOURCE' ${file}`"
@@ -967,17 +1038,18 @@ s%^\([   ]*#[    ]*endif\)[      ][      ]*[^/*  ].*%\1%' \
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  24:  Cxx_Unready
+    # Fix  30:  Cxx_Unready
     #
     case "${file}" in ./sys/mman.h | \
        ./rpc/types.h )
-    if ( test -z "`egrep '\"C\"|__BEGIN_DECLS' ${file}`"
+    if ( test  -a \
+              -z "`egrep '\"C\"|__BEGIN_DECLS' ${file}`"
        ) > /dev/null 2>&1 ; then
     fixlist="${fixlist}
       cxx_unready"
@@ -999,13 +1071,13 @@ extern "C" {\
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of bypass 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  25:  Hpux_Maxint
+    # Fix  31:  Hpux_Maxint
     #
     case "${file}" in ./sys/param.h )
     fixlist="${fixlist}
@@ -1028,7 +1100,7 @@ extern "C" {\
 
 
     #
-    # Fix  26:  Hpux_Systime
+    # Fix  32:  Hpux_Systime
     #
     case "${file}" in ./sys/time.h )
     if ( test -n "`egrep '^extern struct sigevent;' ${file}`"
@@ -1043,13 +1115,13 @@ extern "C" {\
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  27:  Interactv_Add1
+    # Fix  33:  Interactv_Add1
     #
     case "${file}" in ./stdio.h | \
        ./math.h | \
@@ -1070,13 +1142,13 @@ extern "C" {\
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of test expression 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  28:  Interactv_Add2
+    # Fix  34:  Interactv_Add2
     #
     case "${file}" in ./math.h )
     if ( test '('  -d /etc/conf/kconfig.d ')' -a \
@@ -1092,13 +1164,13 @@ extern "C" {\
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of test expression 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  29:  Interactv_Add3
+    # Fix  35:  Interactv_Add3
     #
     case "${file}" in ./sys/limits.h )
     if ( test '('  -d /etc/conf/kconfig.d ')' -a \
@@ -1115,13 +1187,13 @@ extern "C" {\
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of test expression 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  30:  Io_Def_Quotes
+    # Fix  36:  Io_Def_Quotes
     #
     if ( test -n "`egrep '[    ]*[     ](_|DES)IO[A-Z]*[       ]*\\( *[^,'\\'']' ${file}`"
        ) > /dev/null 2>&1 ; then
@@ -1138,11 +1210,11 @@ extern "C" {\
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
 
 
     #
-    # Fix  31:  Ioctl_Fix_Ctrl
+    # Fix  37:  Ioctl_Fix_Ctrl
     #
     if ( test -n "`egrep 'CTRL[        ]*\\(' ${file}`"
        ) > /dev/null 2>&1 ; then
@@ -1161,11 +1233,11 @@ extern "C" {\
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
 
 
     #
-    # Fix  32:  Ip_Missing_Semi
+    # Fix  38:  Ip_Missing_Semi
     #
     case "${file}" in ./netinet/ip.h )
     fixlist="${fixlist}
@@ -1183,7 +1255,7 @@ extern "C" {\
 
 
     #
-    # Fix  33:  Irix_Multiline_Cmnt
+    # Fix  39:  Irix_Multiline_Cmnt
     #
     case "${file}" in ./sys/types.h )
     fixlist="${fixlist}
@@ -1202,7 +1274,7 @@ extern "C" {\
 
 
     #
-    # Fix  34:  Irix_Sockaddr
+    # Fix  40:  Irix_Sockaddr
     #
     case "${file}" in ./rpc/auth.h )
     if ( test -n "`egrep 'authdes_create.*struct sockaddr' ${file}`"
@@ -1219,13 +1291,13 @@ struct sockaddr;
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  35:  Irix_Struct__File
+    # Fix  41:  Irix_Struct__File
     #
     case "${file}" in ./rpc/xdr.h )
     fixlist="${fixlist}
@@ -1245,7 +1317,7 @@ struct __file_s;
 
 
     #
-    # Fix  36:  Irix_Asm_Apostrophe
+    # Fix  42:  Irix_Asm_Apostrophe
     #
     case "${file}" in ./sys/asm.h )
     if ( test -n "`egrep '^[   ]*#.*[Ww]e'\\''re' ${file}`"
@@ -1260,13 +1332,13 @@ struct __file_s;
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  37:  Isc_Fmod
+    # Fix  43:  Isc_Fmod
     #
     case "${file}" in ./math.h )
     if ( test -n "`egrep 'fmod\\(double\\)' ${file}`"
@@ -1281,13 +1353,13 @@ struct __file_s;
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  38:  Motorola_Nested
+    # Fix  44:  Motorola_Nested
     #
     case "${file}" in ./limits.h | \
        ./sys/limits.h )
@@ -1310,7 +1382,7 @@ struct __file_s;
 
 
     #
-    # Fix  39:  Isc_Sys_Limits
+    # Fix  45:  Isc_Sys_Limits
     #
     case "${file}" in ./sys/limits.h )
     if ( test -n "`egrep 'CHILD_MAX' ${file}`"
@@ -1326,13 +1398,13 @@ struct __file_s;
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  40:  Kandr_Concat
+    # Fix  46:  Kandr_Concat
     #
     case "${file}" in ./sparc/asm_linkage.h | \
        ./sun3/asm_linkage.h | \
@@ -1364,17 +1436,18 @@ struct __file_s;
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  41:  Limits_Ifndefs
+    # Fix  47:  Limits_Ifndefs
     #
     case "${file}" in ./limits.h | \
        ./sys/limits.h )
-    if ( test -z "`egrep 'ifndef[      ]+FLT_MIN' ${file}`"
+    if ( test  -a \
+              -z "`egrep 'ifndef[      ]+FLT_MIN' ${file}`"
        ) > /dev/null 2>&1 ; then
     fixlist="${fixlist}
       limits_ifndefs"
@@ -1422,13 +1495,13 @@ struct __file_s;
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of bypass 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  42:  Lynx_Void_Int
+    # Fix  48:  Lynx_Void_Int
     #
     case "${file}" in ./curses.h )
     if ( test -n "`egrep '#[   ]*define[       ]+void[         ]+int' ${file}`"
@@ -1443,13 +1516,13 @@ struct __file_s;
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  43:  Lynxos_Fcntl_Proto
+    # Fix  49:  Lynxos_Fcntl_Proto
     #
     case "${file}" in ./fcntl.h )
     if ( test -n "`egrep 'fcntl.*\\(int, int, int\\)' ${file}`"
@@ -1464,13 +1537,13 @@ struct __file_s;
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  44:  M88k_Bad_Hypot_Opt
+    # Fix  50:  M88k_Bad_Hypot_Opt
     #
     case "${file}" in ./math.h )
     case "$target_canonical" in m88k-motorola-sysv3* )
@@ -1505,7 +1578,7 @@ static __inline__ double fake_hypot (x, y)\
 
 
     #
-    # Fix  45:  M88k_Bad_S_If
+    # Fix  51:  M88k_Bad_S_If
     #
     case "${file}" in ./sys/stat.h )
     case "$target_canonical" in m88k-*-sysv3* )
@@ -1522,7 +1595,7 @@ static __inline__ double fake_hypot (x, y)\
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for machine type test
     esac
     ;; # case end for file name test
@@ -1530,11 +1603,12 @@ static __inline__ double fake_hypot (x, y)\
 
 
     #
-    # Fix  46:  M88k_Multi_Incl
+    # Fix  52:  M88k_Multi_Incl
     #
     case "${file}" in ./time.h )
     case "$target_canonical" in m88k-tektronix-sysv3* )
-    if ( test -z "`egrep '#ifndef' ${file}`"
+    if ( test  -a \
+              -z "`egrep '#ifndef' ${file}`"
        ) > /dev/null 2>&1 ; then
     fixlist="${fixlist}
       m88k_multi_incl"
@@ -1555,7 +1629,7 @@ static __inline__ double fake_hypot (x, y)\
     then continue ; fi 
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of bypass 'if'
     ;; # case end for machine type test
     esac
     ;; # case end for file name test
@@ -1563,7 +1637,7 @@ static __inline__ double fake_hypot (x, y)\
 
 
     #
-    # Fix  47:  Machine_Name
+    # Fix  53:  Machine_Name
     #
     if ( test -n "`egrep '^#[  ]*(if|elif).*[^a-zA-Z0-9_](_*[MSRrhim]|[Mbimnpstuv])[a-zA-Z0-9_]' ${file}`"
        ) > /dev/null 2>&1 ; then
@@ -1611,11 +1685,11 @@ s/\\+++fixinc_eol+++/\\/g
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
 
 
     #
-    # Fix  48:  Math_Exception
+    # Fix  54:  Math_Exception
     #
     case "${file}" in ./math.h )
     if ( test -n "`egrep 'struct exception' ${file}`"
@@ -1649,13 +1723,13 @@ s/\\+++fixinc_eol+++/\\/g
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  49:  Math_Gcc_Ifndefs
+    # Fix  55:  Math_Gcc_Ifndefs
     #
     case "${file}" in ./math.h )
     fixlist="${fixlist}
@@ -1689,7 +1763,7 @@ s/\\+++fixinc_eol+++/\\/g
 
 
     #
-    # Fix  50:  Nested_Comment
+    # Fix  56:  Nested_Comment
     #
     case "${file}" in ./rpc/rpc.h )
     fixlist="${fixlist}
@@ -1707,7 +1781,7 @@ s/\\+++fixinc_eol+++/\\/g
 
 
     #
-    # Fix  51:  News_Os_Recursion
+    # Fix  57:  News_Os_Recursion
     #
     case "${file}" in ./stdlib.h )
     if ( test -n "`egrep '#include <stdlib.h>' ${file}`"
@@ -1727,13 +1801,13 @@ s/\\+++fixinc_eol+++/\\/g
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  52:  Next_Math_Prefix
+    # Fix  58:  Next_Math_Prefix
     #
     case "${file}" in ./ansi/math.h )
     if ( test -n "`egrep '^extern.*double.*__const__.*' ${file}`"
@@ -1752,13 +1826,13 @@ s/\\+++fixinc_eol+++/\\/g
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  53:  Next_Template
+    # Fix  59:  Next_Template
     #
     case "${file}" in ./bsd/libc.h )
     if ( test -n "`egrep 'template' ${file}`"
@@ -1774,13 +1848,13 @@ s/\\+++fixinc_eol+++/\\/g
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  54:  Next_Volitile
+    # Fix  60:  Next_Volitile
     #
     case "${file}" in ./ansi/stdlib.h )
     if ( test -n "`egrep 'volatile' ${file}`"
@@ -1796,13 +1870,13 @@ s/\\+++fixinc_eol+++/\\/g
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  55:  Next_Wait_Union
+    # Fix  61:  Next_Wait_Union
     #
     case "${file}" in ./sys/wait.h )
     if ( test -n "`egrep 'wait\\(union wait' ${file}`"
@@ -1817,13 +1891,13 @@ s/\\+++fixinc_eol+++/\\/g
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  56:  Nodeent_Syntax
+    # Fix  62:  Nodeent_Syntax
     #
     case "${file}" in ./netdnet/dnetdb.h )
     fixlist="${fixlist}
@@ -1841,7 +1915,7 @@ s/\\+++fixinc_eol+++/\\/g
 
 
     #
-    # Fix  57:  Osf_Namespace_A
+    # Fix  63:  Osf_Namespace_A
     #
     case "${file}" in ./reg_types.h | \
        ./sys/lc_core.h )
@@ -1862,13 +1936,13 @@ s/\\+++fixinc_eol+++/\\/g
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of test expression 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  58:  Osf_Namespace_B
+    # Fix  64:  Osf_Namespace_B
     #
     case "${file}" in ./regex.h )
     if ( test '('  -r reg_types.h ')' -a \
@@ -1890,13 +1964,13 @@ typedef __regmatch_t    regmatch_t;
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of test expression 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  59:  Pthread_Page_Size
+    # Fix  65:  Pthread_Page_Size
     #
     case "${file}" in ./pthread.h )
     if ( test -n "`egrep '^int __page_size' ${file}`"
@@ -1911,13 +1985,13 @@ typedef __regmatch_t    regmatch_t;
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  60:  Read_Ret_Type
+    # Fix  66:  Read_Ret_Type
     #
     case "${file}" in ./stdio.h )
     if ( test -n "`egrep 'extern int   .*, fread\\(\\), fwrite\\(\\)' ${file}`"
@@ -1933,13 +2007,13 @@ typedef __regmatch_t    regmatch_t;
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  61:  Rs6000_Double
+    # Fix  67:  Rs6000_Double
     #
     case "${file}" in ./math.h )
     if ( test -n "`egrep '[^a-zA-Z_]class\\(' ${file}`"
@@ -1959,13 +2033,13 @@ typedef __regmatch_t    regmatch_t;
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  62:  Rs6000_Fchmod
+    # Fix  68:  Rs6000_Fchmod
     #
     case "${file}" in ./sys/stat.h )
     if ( test -n "`egrep 'fchmod\\(char' ${file}`"
@@ -1980,13 +2054,13 @@ typedef __regmatch_t    regmatch_t;
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  63:  Rs6000_Param
+    # Fix  69:  Rs6000_Param
     #
     case "${file}" in ./stdio.h | \
        ./unistd.h )
@@ -2005,7 +2079,7 @@ typedef __regmatch_t      regmatch_t;
 
 
     #
-    # Fix  64:  Sony_Include
+    # Fix  70:  Sony_Include
     #
     case "${file}" in ./machine/machparam.h )
     if ( test -n "`egrep '\"\\.\\./machine/endian.h\"' ${file}`"
@@ -2020,13 +2094,13 @@ typedef __regmatch_t    regmatch_t;
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  65:  Statsswtch
+    # Fix  71:  Statsswtch
     #
     case "${file}" in ./rpcsvc/rstat.h )
     if ( test -n "`egrep 'boottime$' ${file}`"
@@ -2041,13 +2115,13 @@ typedef __regmatch_t    regmatch_t;
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  66:  Stdio_Va_List
+    # Fix  72:  Stdio_Va_List
     #
     case "${file}" in ./stdio.h )
     fixlist="${fixlist}
@@ -2064,7 +2138,7 @@ typedef __regmatch_t      regmatch_t;
 
   sed -e 's@ va_list @ __gnuc_va_list @' \
       -e 's@ va_list)@ __gnuc_va_list)@' \
-      -e 's@ _BSD_VA_LIST_))@ __gnuc_va_list))@' \
+      -e 's@ _BSD_VA_LIST_));@ __gnuc_va_list));@' \
       -e 's@ _VA_LIST_));@ __gnuc_va_list));@' \
       -e 's@ va_list@ __va_list__@' \
       -e 's@\*va_list@*__va_list__@' \
@@ -2086,7 +2160,7 @@ typedef __regmatch_t      regmatch_t;
 
 
     #
-    # Fix  67:  Sun_Bogus_Ifdef
+    # Fix  73:  Sun_Bogus_Ifdef
     #
     case "${file}" in ./hsfs/hsfs_spec.h | \
        ./hsfs/iso_spec.h )
@@ -2102,13 +2176,13 @@ typedef __regmatch_t    regmatch_t;
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  68:  Sun_Bogus_Ifdef_Sun4c
+    # Fix  74:  Sun_Bogus_Ifdef_Sun4c
     #
     case "${file}" in ./hsfs/hsnode.h )
     if ( test -n "`egrep '#ifdef __i386__ || __sun4c__' ${file}`"
@@ -2123,13 +2197,13 @@ typedef __regmatch_t    regmatch_t;
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  69:  Sun_Catmacro
+    # Fix  75:  Sun_Catmacro
     #
     case "${file}" in ./pixrect/memvar.h )
     if ( test -n "`egrep '^#define[    ]+CAT\\(a,b\\)' ${file}`"
@@ -2151,13 +2225,13 @@ typedef __regmatch_t    regmatch_t;
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  70:  Sun_Malloc
+    # Fix  76:  Sun_Malloc
     #
     case "${file}" in ./malloc.h )
     fixlist="${fixlist}
@@ -2178,7 +2252,7 @@ typedef __regmatch_t      regmatch_t;
 
 
     #
-    # Fix  71:  Sun_Memcpy
+    # Fix  77:  Sun_Memcpy
     #
     case "${file}" in ./memory.h )
     if ( test -n "`egrep '/\\* @\\(#\\)(head/memory.h  50.1     |memory\\.h 1\\.[2-4] 8./../.. SMI; from S5R2 1\\.2    )\\*/' ${file}`"
@@ -2214,13 +2288,13 @@ extern int memcmp();\
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  72:  Sun_Rusers_Semi
+    # Fix  78:  Sun_Rusers_Semi
     #
     case "${file}" in ./rpcsvc/rusers.h )
     if ( test -n "`egrep '_cnt$' ${file}`"
@@ -2235,13 +2309,13 @@ extern int memcmp();\
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  73:  Sun_Signal
+    # Fix  79:  Sun_Signal
     #
     case "${file}" in ./sys/signal.h | \
        ./signal.h )
@@ -2264,13 +2338,13 @@ void    (*signal(...))(...);\
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  74:  Sun_Auth_Proto
+    # Fix  80:  Sun_Auth_Proto
     #
     case "${file}" in ./rpc/auth.h | \
        ./rpc/clnt.h | \
@@ -2293,13 +2367,13 @@ void    (*signal(...))(...);\
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  75:  Sunos_Matherr_Decl
+    # Fix  81:  Sunos_Matherr_Decl
     #
     case "${file}" in ./math.h )
     fixlist="${fixlist}
@@ -2320,7 +2394,7 @@ struct exception;
 
 
     #
-    # Fix  76:  Sunos_Strlen
+    # Fix  82:  Sunos_Strlen
     #
     case "${file}" in ./strings.h )
     fixlist="${fixlist}
@@ -2338,7 +2412,7 @@ struct exception;
 
 
     #
-    # Fix  77:  Systypes
+    # Fix  83:  Systypes
     #
     case "${file}" in ./sys/types.h | \
        ./stdlib.h | \
@@ -2386,16 +2460,18 @@ typedef __SIZE_TYPE__ size_t;\
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  78:  Systypes_For_Aix
+    # Fix  84:  Systypes_For_Aix
     #
     case "${file}" in ./sys/types.h )
-    if ( test -n "`egrep 'typedef[     ][      ]*[A-Za-z_][    A-Za-z_]*[      ]size_t' ${file}`" -a \
+    if ( test -n "`egrep 'typedef[     ][      ]*[A-Za-z_][    A-Za-z_]*[      ]size_t' ${file}`"
+       ) > /dev/null 2>&1 ; then
+    if ( test  -a \
               -z "`egrep '_GCC_SIZE_T' ${file}`"
        ) > /dev/null 2>&1 ; then
     fixlist="${fixlist}
@@ -2414,13 +2490,14 @@ typedef __SIZE_TYPE__ size_t;\
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of bypass 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  79:  Sysv68_String
+    # Fix  85:  Sysv68_String
     #
     case "${file}" in ./string.h )
     fixlist="${fixlist}
@@ -2448,7 +2525,7 @@ extern unsigned int\
 
 
     #
-    # Fix  80:  Sysz_Stdlib_For_Sun
+    # Fix  86:  Sysz_Stdlib_For_Sun
     #
     case "${file}" in ./stdlib.h )
     fixlist="${fixlist}
@@ -2479,7 +2556,7 @@ extern unsigned int\
 
 
     #
-    # Fix  81:  Sysz_Stdtypes_For_Sun
+    # Fix  87:  Sysz_Stdtypes_For_Sun
     #
     case "${file}" in ./sys/stdtypes.h )
     fixlist="${fixlist}
@@ -2517,7 +2594,7 @@ extern unsigned int\
 
 
     #
-    # Fix  82:  Tinfo_Cplusplus
+    # Fix  88:  Tinfo_Cplusplus
     #
     case "${file}" in ./tinfo.h )
     fixlist="${fixlist}
@@ -2535,7 +2612,7 @@ extern unsigned int\
 
 
     #
-    # Fix  83:  Ultrix_Ansi_Compat
+    # Fix  89:  Ultrix_Ansi_Compat
     #
     case "${file}" in ./ansi_compat.h )
     if ( test -n "`egrep 'ULTRIX' ${file}`"
@@ -2553,13 +2630,13 @@ extern unsigned int\
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  84:  Ultrix_Fix_Fixproto
+    # Fix  90:  Ultrix_Fix_Fixproto
     #
     case "${file}" in ./sys/utsname.h )
     if ( test -n "`egrep 'ULTRIX' ${file}`"
@@ -2576,13 +2653,13 @@ struct utsname;
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  85:  Ultrix_Atof_Param
+    # Fix  91:  Ultrix_Atof_Param
     #
     case "${file}" in ./math.h )
     fixlist="${fixlist}
@@ -2604,7 +2681,7 @@ struct utsname;
 
 
     #
-    # Fix  86:  Ultrix_Const
+    # Fix  92:  Ultrix_Const
     #
     case "${file}" in ./stdio.h )
     fixlist="${fixlist}
@@ -2630,7 +2707,7 @@ struct utsname;
 
 
     #
-    # Fix  87:  Ultrix_Ifdef
+    # Fix  93:  Ultrix_Ifdef
     #
     case "${file}" in ./sys/file.h )
     if ( test -n "`egrep '#ifdef KERNEL' ${file}`"
@@ -2645,13 +2722,13 @@ struct utsname;
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  88:  Ultrix_Nested_Cmnt
+    # Fix  94:  Ultrix_Nested_Cmnt
     #
     case "${file}" in ./rpc/svc.h )
     fixlist="${fixlist}
@@ -2669,7 +2746,7 @@ struct utsname;
 
 
     #
-    # Fix  89:  Ultrix_Static
+    # Fix  95:  Ultrix_Static
     #
     case "${file}" in ./machine/cpu.h )
     if ( test -n "`egrep '#include \"r[34]_cpu' ${file}`"
@@ -2686,15 +2763,17 @@ struct utsname;
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  90:  Undefine_Null
+    # Fix  96:  Undefine_Null
     #
-    if ( test -n "`egrep '^#[  ]*define[       ]*[     ]NULL[  ]' ${file}`" -a \
+    if ( test -n "`egrep '^#[  ]*define[       ]*[     ]NULL[  ]' ${file}`"
+       ) > /dev/null 2>&1 ; then
+    if ( test  -a \
               -z "`egrep '#[   ]*(ifn|un)def[  ]*[     ]NULL($|[       ])' ${file}`"
        ) > /dev/null 2>&1 ; then
     fixlist="${fixlist}
@@ -2709,11 +2788,12 @@ struct utsname;
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of bypass 'if'
+    fi # end of select 'if'
 
 
     #
-    # Fix  91:  Va_I960_Macro
+    # Fix  97:  Va_I960_Macro
     #
     case "${file}" in ./arch/i960/archI960.h )
     if ( test -n "`egrep '__(vsiz|vali|vpad|alignof__)' ${file}`"
@@ -2731,13 +2811,13 @@ struct utsname;
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  92:  Void_Null
+    # Fix  98:  Void_Null
     #
     case "${file}" in ./curses.h | \
        ./dbm.h | \
@@ -2762,13 +2842,13 @@ struct utsname;
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  93:  Vxworks_Gcc_Problem
+    # Fix  99:  Vxworks_Gcc_Problem
     #
     case "${file}" in ./types/vxTypesBase.h )
     if ( test -n "`egrep '__GNUC_TYPEOF_FEATURE_BROKEN_USE_DEFAULT_UNTIL_FIXED__' ${file}`"
@@ -2804,13 +2884,13 @@ struct utsname;
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  94:  Vxworks_Needs_Vxtypes
+    # Fix 100:  Vxworks_Needs_Vxtypes
     #
     case "${file}" in ./time.h )
     if ( test -n "`egrep 'uint_t[      ][      ]*_clocks_per_sec' ${file}`"
@@ -2825,17 +2905,18 @@ struct utsname;
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  95:  Vxworks_Needs_Vxworks
+    # Fix 101:  Vxworks_Needs_Vxworks
     #
     case "${file}" in ./sys/stat.h )
-    if ( test -n "`egrep '#[   ]define[        ][      ]*__INCstath' ${file}`" -a \
-              '('  -r types/vxTypesOld.h ')' -a \
+    if ( test -n "`egrep '#[   ]define[        ][      ]*__INCstath' ${file}`"
+       ) > /dev/null 2>&1 ; then
+    if ( test '('  -r types/vxTypesOld.h ')' -a \
               '('  -n "`egrep '#include' $file`" ')' -a \
               '('  -n "`egrep ULONG $file`" ')'
        ) > /dev/null 2>&1 ; then
@@ -2851,17 +2932,19 @@ struct utsname;
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of test expression 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  96:  Vxworks_Time
+    # Fix 102:  Vxworks_Time
     #
     case "${file}" in ./time.h )
-    if ( test -n "`egrep 'VOIDFUNCPTR' ${file}`" -a \
-              '('  -r vxWorks.h ')'
+    if ( test -n "`egrep 'VOIDFUNCPTR' ${file}`"
+       ) > /dev/null 2>&1 ; then
+    if ( test '('  -r vxWorks.h ')'
        ) > /dev/null 2>&1 ; then
     fixlist="${fixlist}
       vxworks_time"
@@ -2883,16 +2966,18 @@ typedef void (*__gcc_VOIDFUNCPTR) ();\
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of test expression 'if'
+    fi # end of select 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  97:  X11_Class
+    # Fix 103:  X11_Class
     #
     case "${file}" in ./X11/ShellP.h )
-    if ( test -z "`egrep '__cplusplus' ${file}`"
+    if ( test  -a \
+              -z "`egrep '__cplusplus' ${file}`"
        ) > /dev/null 2>&1 ; then
     fixlist="${fixlist}
       x11_class"
@@ -2911,16 +2996,17 @@ typedef void (*__gcc_VOIDFUNCPTR) ();\
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of bypass 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  98:  X11_Class_Usage
+    # Fix 104:  X11_Class_Usage
     #
     case "${file}" in ./Xm/BaseClassI.h )
-    if ( test -z "`egrep '__cplusplus' ${file}`"
+    if ( test  -a \
+              -z "`egrep '__cplusplus' ${file}`"
        ) > /dev/null 2>&1 ; then
     fixlist="${fixlist}
       x11_class_usage"
@@ -2932,16 +3018,17 @@ typedef void (*__gcc_VOIDFUNCPTR) ();\
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of bypass 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix  99:  X11_New
+    # Fix 105:  X11_New
     #
     case "${file}" in ./Xm/Traversal.h )
-    if ( test -z "`egrep '__cplusplus' ${file}`"
+    if ( test  -a \
+              -z "`egrep '__cplusplus' ${file}`"
        ) > /dev/null 2>&1 ; then
     fixlist="${fixlist}
       x11_new"
@@ -2961,13 +3048,13 @@ typedef void (*__gcc_VOIDFUNCPTR) ();\
           < $infile > ${DESTDIR}/fixinc.tmp
     rm -f ${DESTFILE}
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
+    fi # end of bypass 'if'
     ;; # case end for file name test
     esac
 
 
     #
-    # Fix 100:  X11_Sprintf
+    # Fix 106:  X11_Sprintf
     #
     case "${file}" in ./X11*/Xmu.h )
     fixlist="${fixlist}
@@ -2984,165 +3071,6 @@ extern char *   sprintf();\
     mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
     ;; # case end for file name test
     esac
-
-
-    #
-    # Fix 101:  Zzz_Ki_Iface
-    #
-    case "${file}" in ./sys/ki_iface.h )
-    if ( test -n "`egrep 'These definitions are for HP Internal developers' ${file}`"
-       ) > /dev/null 2>&1 ; then
-    fixlist="${fixlist}
-      zzz_ki_iface"
-    if [ ! -r ${DESTFILE} ]
-    then infile=${file}
-    else infile=${DESTFILE} ; fi 
-    ( echo "Removing incorrect fix to <$file>" >&2
-rm -f ${DESTFILE} ${DESTDIR}/fixinc.tmp
-cat > /dev/null ) < $infile > ${DESTDIR}/fixinc.tmp
-
-    #  Shell scripts have the potential of removing the output
-    #  We interpret that to mean the file is not to be altered
-    #
-    if test ! -f ${DESTDIR}/fixinc.tmp
-    then continue ; fi 
-    rm -f ${DESTFILE}
-    mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
-    ;; # case end for file name test
-    esac
-
-
-    #
-    # Fix 102:  Zzz_Ki
-    #
-    case "${file}" in ./sys/ki.h )
-    if ( test -n "`egrep '11.00 HP-UX LP64' ${file}`"
-       ) > /dev/null 2>&1 ; then
-    fixlist="${fixlist}
-      zzz_ki"
-    if [ ! -r ${DESTFILE} ]
-    then infile=${file}
-    else infile=${DESTFILE} ; fi 
-    ( echo "Removing incorrect fix to <$file>" >&2
-rm -f ${DESTFILE} ${DESTDIR}/fixinc.tmp
-cat > /dev/null ) < $infile > ${DESTDIR}/fixinc.tmp
-
-    #  Shell scripts have the potential of removing the output
-    #  We interpret that to mean the file is not to be altered
-    #
-    if test ! -f ${DESTDIR}/fixinc.tmp
-    then continue ; fi 
-    rm -f ${DESTFILE}
-    mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
-    ;; # case end for file name test
-    esac
-
-
-    #
-    # Fix 103:  Zzz_Ki_Calls
-    #
-    case "${file}" in ./sys/ki_calls.h )
-    if ( test -n "`egrep 'kthread_create_caller_t' ${file}`"
-       ) > /dev/null 2>&1 ; then
-    fixlist="${fixlist}
-      zzz_ki_calls"
-    if [ ! -r ${DESTFILE} ]
-    then infile=${file}
-    else infile=${DESTFILE} ; fi 
-    ( echo "Removing incorrect fix to <$file>" >&2
-rm -f ${DESTFILE} ${DESTDIR}/fixinc.tmp
-cat > /dev/null ) < $infile > ${DESTDIR}/fixinc.tmp
-
-    #  Shell scripts have the potential of removing the output
-    #  We interpret that to mean the file is not to be altered
-    #
-    if test ! -f ${DESTDIR}/fixinc.tmp
-    then continue ; fi 
-    rm -f ${DESTFILE}
-    mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
-    ;; # case end for file name test
-    esac
-
-
-    #
-    # Fix 104:  Zzz_Ki_Defs
-    #
-    case "${file}" in ./sys/ki_defs.h )
-    if ( test -n "`egrep 'Kernel Instrumentation Definitions' ${file}`"
-       ) > /dev/null 2>&1 ; then
-    fixlist="${fixlist}
-      zzz_ki_defs"
-    if [ ! -r ${DESTFILE} ]
-    then infile=${file}
-    else infile=${DESTFILE} ; fi 
-    ( echo "Removing incorrect fix to <$file>" >&2
-rm -f ${DESTFILE} ${DESTDIR}/fixinc.tmp
-cat > /dev/null ) < $infile > ${DESTDIR}/fixinc.tmp
-
-    #  Shell scripts have the potential of removing the output
-    #  We interpret that to mean the file is not to be altered
-    #
-    if test ! -f ${DESTDIR}/fixinc.tmp
-    then continue ; fi 
-    rm -f ${DESTFILE}
-    mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
-    ;; # case end for file name test
-    esac
-
-
-    #
-    # Fix 105:  Zzz_Bad_Fixes
-    #
-    case "${file}" in ./sundev/ipi_error.h )
-    fixlist="${fixlist}
-      zzz_bad_fixes"
-    if [ ! -r ${DESTFILE} ]
-    then infile=${file}
-    else infile=${DESTFILE} ; fi 
-    ( echo "Removing incorrect fix to <$file>" >&2
-rm -f ${DESTFILE} ${DESTDIR}/fixinc.tmp
-cat > /dev/null ) < $infile > ${DESTDIR}/fixinc.tmp
-
-    #  Shell scripts have the potential of removing the output
-    #  We interpret that to mean the file is not to be altered
-    #
-    if test ! -f ${DESTDIR}/fixinc.tmp
-    then continue ; fi 
-    rm -f ${DESTFILE}
-    mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    ;; # case end for file name test
-    esac
-
-
-    #
-    # Fix 106:  Zzz_Time
-    #
-    case "${file}" in ./sys/time.h )
-    if ( test -n "`egrep '11.0 and later representation of ki time' ${file}`"
-       ) > /dev/null 2>&1 ; then
-    fixlist="${fixlist}
-      zzz_time"
-    if [ ! -r ${DESTFILE} ]
-    then infile=${file}
-    else infile=${DESTFILE} ; fi 
-    ( echo "Removing incorrect fix to <$file>" >&2
-rm -f ${DESTFILE} ${DESTDIR}/fixinc.tmp
-cat > /dev/null ) < $infile > ${DESTDIR}/fixinc.tmp
-
-    #  Shell scripts have the potential of removing the output
-    #  We interpret that to mean the file is not to be altered
-    #
-    if test ! -f ${DESTDIR}/fixinc.tmp
-    then continue ; fi 
-    rm -f ${DESTFILE}
-    mv -f ${DESTDIR}/fixinc.tmp ${DESTFILE}
-    fi # end of selection 'if'
-    ;; # case end for file name test
-    esac
     #  IF the output has been removed OR it is unchanged,
     #  THEN ensure the output is gone
     #  ELSE look for local directory include syntax
index 587a8e5..393f802 100644 (file)
@@ -44,7 +44,10 @@ else
     exit 1
   }
 fi
-
+[=_IF PROGRAM _env ! =]
+FIXTESTS=$PWD/fixinc/fixtests
+FIXFIXES=$PWD/fixinc/fixfixes
+[=_ENDIF=]
 # Define what target system we're fixing.
 #
 if test -r ./Makefile; then