imported 9.0.299 Beta 02
authorIan Beckwith <ianb@erislabs.net>
Thu, 23 Jun 2011 23:57:22 +0000 (00:57 +0100)
committerIan Beckwith <ianb@erislabs.net>
Thu, 23 Jun 2011 23:57:22 +0000 (00:57 +0100)
ckc299.txt
ckcmai.c
ckutio.c
ckuus4.c
ckuus5.c
ckuusx.c
makefile

index fc7c6a9..f7239f2 100644 (file)
@@ -7692,5 +7692,107 @@ Fedora 14  i386   32/64  linux+krb5+ssl    2539891 MIT Krb5 + OpenSSL 0.9.8r
 
 * KFLAGS=-UCK_DES
 
+--- C-Kermit 9.0.299 Beta.01 ---
+
+sizeof() can return a long or an int, so neither printf("%d",sizeof(blah));
+or printf("%ld",sizeof(blah)); can be used everywhere.  Changed the
+"sizeofs" section of SHOW FEATURES in the dumbest (and therefore most
+portable) way to squelch the warnings.  ckuus5.c, 17 Jun 2011.
+
+From John Dunlap: "Watching the server screen led me to offer a cosmetic
+patch for ckuusx.c.  I noticed that the server screen said it was
+"RESENDING" when it really wasn't.  The attached patch emits blanks to
+insure that old labels are completely erased."  ckuusx.c, 17 Jun 2011.
+
+Nelson Beebe found two places where I had SSLLIBS in the makefile instead of
+SSLLIB.  makefile, 18 Jun 2011.
+
+More important he knew how to force gcc to load the right header files for
+OpenSSL 1.0.0d (by using '-isystem' rather than '-I').  Previously it was
+using the 0.9.8r header files but linking with the 1.0.0d libraries.  This
+is not in the sources, it's done in the 'make' command, e.g.:
+
+  export PATH=/usr/bin:$PATH
+  export SSLINC=-isystem/usr/include
+  export "SSLLIB=-L/usr/lib -Wl,-rpath,/usr/lib"
+  make linux+ssl
+
+Folded the previous linux+openssl+zlib+shadow+pam and linux+openssl+shadow
+targets into linux+ssl.  Checked the linuxso (scripting only) target, builds
+OK, 600K.  Made new subroutinized linux+krb5+krb4 target but can't find
+anyplace to test it.   Made new subroutinized linux+shadow+pam target, works
+fine on RHEL4.  Revised comments and lists again.  makefile, 18 Jun 2011.
+
+For the pluggable-disk OS's that boot OK but lack a working network, I
+rigged up a serial connection using a DB9-FF null modem cable, and then a
+DB9-MF modem cable to make it reach.  I don't see any modem signals on
+either end, but the data goes through OK.  COM1 on the desktop PC,
+/dev/ttyS1 or whatever on Lab.  Since there are no modem signals, can't use
+RTS/CTS.  At 57600bps with Xon/Xoff, 500-byte packets and sliding windows,
+transfers work OK at about 5000cps using 5 window slots; takes 8 minutes to
+transfer the gzipped C-Kermit tarball.  Kermit to the rescue.  19 Jun 2011.
+
+Transferred the tarball over serial ports to SCO OSR5.0.5 at 38.4Kbps, the
+highest speed supported, 12 minutes, no errors, 3300cps.  Unpack, make
+sco32v505udk, OK.  Also built the TCP/IP version and it almost made an
+outbound connection, but only once.  19 Jun 2011.
+
+Ditto for Solaris 2.6/i386, except 57.6Kbps, 4K-byte packets, no problem.
+Solaris 8/i386, ditto.  19 Jun 2011.
+
+SCO OpenServer 5.0.5  i386   32   sco32v505udk     1940964  No TCP/IP
+SCO OpenServer 5.0.5  i386   32   sco32v505udknet  2314668  With TCP/IP
+Sun Solaris 2.6       i386   32   solaris26g       4661368
+Sun Solaris 8         i386   32   solaris8g        4675432
+
+When using compact substring notation, \s(xx[4]) returns the whole string
+xx starting at position 4, but \s(xx[4:]) returns an empty string.  Fixed
+the latter to be like the former.  ckuus5.c, 20 Jun 2010.
+
+Really it would have been nicer if \s(xx[4]) returned a single character,
+the 4th character of xx, but it's too late now.  Added another "separator"
+character '.' (period) for that: \s(xx[4.]) is the 4th character of xx.
+ckuus4.c, 20 Jun 2010.
+
+Back to SCO OSR5.0.7... This failed before because 'rdchk' came up unknown
+at link time, unlike all previous OSR5's, that used rdchk() in place of the
+FIONREAD ioctl.  Added #ifdefs to make a special case for 5.0.7.  I'm not
+sure this is the best way, but this is the minimal change to get it to work.
+If anybody cares, maybe the same can be done for previous OSR5 releases.
+ckutio.c, 20 Jun 2010 (search for SCO_OSR507).
+
+SCO OpenServer 5.0.7  i386   32   sco32v507        1895724  No TCP/IP
+SCO OpenServer 5.0.7  i386   32   sco32v507net     2246792  With TCP/IP
+
+Checked current code on RHEL4, found that my GSSAPI-lib finding makefile
+target didn't look in enough places; added some more.  makefile, 21 Jun 2011.
+
+Got reports back on HPUX from Peter Eichhorn, almost all good on HP-UX 8, 9,
+10, and 11.  21 Jun 2011.
+
+Got access to Debian 5.0 and 7-to-be ("Wheezy/Sid").  Regular 'make linux' is
+OK in Debian 5, but in 7 can't find crypt, res_search, or dn_expand; had
+to add more library search clauses to 'make linux'.  makefile, 21 Jun 2011.
+
+In Debian 7.0, libk5crypto could not be found without adding another clause
+to 'make linux+krb5'.  That done, the SSL build (1.0.0d) was OK, as well as
+the krb5+ssl one.  makefile, 21 Jun 2011.
+
+I found a Linux box that had both Kerberos 4 and 5 installed and tried 'make
+linux+krb5+krb4', which failed because of missing DES functions.  Tried
+'make linux+krb5+krb4 KFLAGS=-UCK_DES', but that fails too, even though it
+doesn't fail for Kerberos 5 alone, so probably some Krb4 code is making
+unguarded calls to the DES routines.  What is really needed is a way to
+completely strip all DES references from any given build.  21 Jun 2011.
+
+-----------------------------------
+To check:
+
+after logging out from "ssh jezebel":
+(/home/fdc/) C-Kermit>ssh jezebel
+ Closing connection
+Sorry, network type not supported
+(/home/fdc/) C-Kermit> # This happens in Linux but not Solaris
+
 ---------------------------------
 ***************************
index e29f51a..26b773a 100644 (file)
--- a/ckcmai.c
+++ b/ckcmai.c
@@ -1,6 +1,6 @@
-#define EDITDATE  "15 Jun 2011"                /* Last edit date dd mmm yyyy */
-#define EDITNDATE "20110615"           /* Keep them in sync */
-/* Wed Jun 15 07:12:45 2011 */
+#define EDITDATE  "21 Jun 2011"                /* Last edit date dd mmm yyyy */
+#define EDITNDATE "20110621"           /* Keep them in sync */
+/* Tue Jun 21 11:32:48 2011 */
 
 /* ckcmai.c - Main program for C-Kermit plus some miscellaneous functions */
 
@@ -41,7 +41,7 @@ char * ck_cryear = "2011";            /* C-Kermit copyright year */
 #ifndef BETATEST
 #ifndef OS2                             /* UNIX, VMS, etc... (i.e. C-Kermit) */
 char *ck_s_test = "Beta";              /* "Dev","Alpha","Beta","RC", or "" */
-char *ck_s_tver = "01";                        /* Test version number or "" */
+char *ck_s_tver = "02";                        /* Test version number or "" */
 #else  /* OS2 */
 char *ck_s_test = "";                  /* (i.e. K95) */
 char *ck_s_tver = "";
index d3354be..6551e77 100644 (file)
--- a/ckutio.c
+++ b/ckutio.c
@@ -1,12 +1,12 @@
 #define CKUTIO_C
 
 #ifdef aegis
-char *ckxv = "Aegis Communications support, 9.0.323, 10 June 2011";
+char *ckxv = "Aegis Communications support, 9.0.324, 20 June 2011";
 #else
 #ifdef Plan9
-char *ckxv = "Plan 9 Communications support, 9.0.323, 10 June 2011";
+char *ckxv = "Plan 9 Communications support, 9.0.324, 20 June 2011";
 #else
-char *ckxv = "UNIX Communications support, 9.0.323, 10 June 2011";
+char *ckxv = "UNIX Communications support, 9.0.324, 20 June 2011";
 #endif /* Plan9 */
 #endif /* aegis */
 
@@ -828,10 +828,18 @@ Time functions
 #endif /* XENIX */
 
 #ifdef CK_SCOV5                                /* Ditto for SCO OpenServer 5.0 */
+#ifndef SCO_OSR507                     /* 299 */
 #ifdef FIONREAD
 #undef FIONREAD
 #endif /* FIONREAD */
-#endif /* XENIX */
+#endif /* SCO_OSR507 */
+#endif /* CK_SCOV5 */
+
+#ifdef SCO_OSR507                      /* 299 */
+#ifdef RDCHK
+#undef RDCHK
+#endif /* RDCHK */
+#endif /* SCO_OSR507 */
 
 /* Whether to include <fcntl.h> */
 
@@ -14397,9 +14405,11 @@ pty_chk(fd) int fd; {
             ckitoa(n));
     debug(F100,msgbuf,"",0);
 #else
+#ifdef RDCHK
     n = rdchk(fd);
     debug(F101,"pty_chk rdchk","",n);
-#ifdef RDCHK
+#else
+    n = 1;
 #endif /* RDCHK */
 #endif /* FIONREAD */
     return((n > -1) ? n : 0);
index 35cfa5f..3e52fee 100644 (file)
--- a/ckuus4.c
+++ b/ckuus4.c
@@ -14866,7 +14866,7 @@ zzstring(s,s2,n) char *s; char **s2; int *n; {
                         int i;
                         for (i = 0; i < k-1; i++) {
                             if (vnambuf[i] == '[') {
-                               bprc = boundspair(vnambuf,":_",&x1,&x2,&c);
+                               bprc = boundspair(vnambuf,":_.",&x1,&x2,&c);
                                debug(F111,"zzstring boundspair",vnambuf,bprc);
                                debug(F000,"zzstring boundspair c","",c);
                                if (bprc > -1) {
@@ -14915,18 +14915,22 @@ zzstring(s,s2,n) char *s; char **s2; int *n; {
                                debug(F000,">>> c","",c);
                                 if ((q = malloc(k+1))) {
                                     strcpy(q,vp); /* safe */
+                                   if (c == '.') {
+                                       q[x1+1] = NUL;
+                                       debug(F000,"XXX. q",q,c);
+                                   }
                                    if (c == ':') { /* start:length */
                                        if ((x2 > -1) && ((x1 + x2) <= k)) {
                                            q[x1+x2] = NUL;
                                        }
-                                       debug(F000,"XXX q",q,c);
+                                       debug(F000,"XXX: q",q,c);
                                    } else if (c == '_') { /* start_endpos */
                                        if (x1 >= x2) {
                                            q[x1 = 0] = NUL;
                                        } else if (x2 < k && x2 > -1) {
                                            q[x2] = NUL;
                                        }
-                                       debug(F000,"XXX q",q,c);
+                                       debug(F000,"XXX_ q",q,c);
                                    }
                                    vp = q+x1;
                                 } else vp = NULL;
index c93036f..744d75e 100644 (file)
--- a/ckuus5.c
+++ b/ckuus5.c
@@ -8723,13 +8723,13 @@ boundspair(s,sep,lo,hi,zz) char *s, *sep, *zz; int *lo, *hi;
     r = NULL;
     for (p = s; *p; p++) {             /* Get the two elements */
        if (*p == '[') {
-           bc++;
+           bc++;                       /* Bracket counter */
            if (bc == 1 && !q) q = p+1;
        } else if (*p == ']') {
            bc--;
            if (bc == 0 && q) *p = NUL;
-       } else if (bc == 1) {           /* Check for separator */
-           s2 = ckstrchr(sep,*p);
+       } else if (bc == 1) {           /* If within brackers */
+           s2 = ckstrchr(sep,*p);      /* Check for separator */
            if (s2) {
                debug(F000,"boundspair *s2","",*s2);
                if (c) {        
@@ -8737,7 +8737,7 @@ boundspair(s,sep,lo,hi,zz) char *s, *sep, *zz; int *lo, *hi;
                    makestr(&tmp,NULL);
                    return(-1);
                }
-               c = *s2;
+               c = *s2;                /* Separator character */
                *p = NUL;
                r = p+1;
            }
@@ -8754,8 +8754,10 @@ boundspair(s,sep,lo,hi,zz) char *s, *sep, *zz; int *lo, *hi;
        makestr(&tmp,NULL);
        return(-1);
     }
+    if (!q) q = "";
     if (!*q) q = "-1";
-    if (!r) r = "-1";
+    if (!r) r = "";
+    if (!*r) r = "-1";
 
     e[0] = q;
     e[1] = r;
@@ -12332,44 +12334,59 @@ shofea() {
              " endian",
              NULL
              );
-    if (!prtopt(&lines,line)) return(0);
-    if (!prtopt(&lines,"")) return(0);  /* Start a new section */
-    sprintf(line,"sizeofs: int=%d",sizeof(int)); /* SAFE */
-    if (!prtopt(&lines,line)) return(0);
-    sprintf(line,"long=%d",sizeof(long)); /* SAFE */
-    if (!prtopt(&lines,line)) return(0);
+    {
+/* Whether to use %d or %ld with sizeof is a portability issue, so... */
+       int size = 0;
 
-#ifdef COMMENT
-#ifdef CK_LONGLONG
-    sprintf(line,"long long=%d",sizeof(long long)); /* SAFE */
-    if (!prtopt(&lines,line)) return(0);
-#endif /* CK_LONGLONG */
-#endif /* COMMENT */
+       if (!prtopt(&lines,line)) return(0);
+       if (!prtopt(&lines,"")) return(0);  /* Start a new section */
+
+       size = (int)sizeof(int);
+       sprintf(line,"sizeofs: int=%d",size); /* SAFE */
+       if (!prtopt(&lines,line)) return(0);
+
+       size = (int)sizeof(long);
+       sprintf(line,"long=%d",size); /* SAFE */
+       if (!prtopt(&lines,line)) return(0);
 
 #ifndef OS2
-    /* Windows doesn't have off_t */
-    sprintf(line,"off_t=%d",sizeof(off_t)); /* SAFE */
-    if (!prtopt(&lines,line)) return(0);
+       /* Windows doesn't have off_t */
+       size = (int)sizeof(off_t);
+       sprintf(line,"off_t=%d",size); /* SAFE */
+       if (!prtopt(&lines,line)) return(0);
 #endif /* OS2 */
 
-    sprintf(line,"CK_OFF_T=%d",sizeof(CK_OFF_T)); /* SAFE */
-    if (!prtopt(&lines,line)) return(0);
+       size = (int)sizeof(CK_OFF_T);
+       sprintf(line,"CK_OFF_T=%d",size); /* SAFE */
+       if (!prtopt(&lines,line)) return(0);
 
 #ifdef BIGBUFOK
-    sprintf(line,"size_t=%d",sizeof(size_t)); /* SAFE */
-    if (!prtopt(&lines,line)) return(0);
+       size = (int)sizeof(size_t);
+       sprintf(line,"size_t=%d",size); /* SAFE */
+       if (!prtopt(&lines,line)) return(0);
 #endif /* BIGBUFOK */
 
-    sprintf(line,"short=%d",sizeof(short)); /* SAFE */
-    if (!prtopt(&lines,line)) return(0);
-    sprintf(line,"char=%d",sizeof(char)); /* SAFE */
-    if (!prtopt(&lines,line)) return(0);
-    sprintf(line,"char*=%d",sizeof(char *)); /* SAFE */
-    if (!prtopt(&lines,line)) return(0);
-    sprintf(line,"float=%d",sizeof(float)); /* SAFE */
-    if (!prtopt(&lines,line)) return(0);
-    sprintf(line,"double=%d",sizeof(double)); /* SAFE */
-    if (!prtopt(&lines,line)) return(0);
+       size = (int)sizeof(short);
+       sprintf(line,"short=%d",size); /* SAFE */
+       if (!prtopt(&lines,line)) return(0);
+
+       size = (int)sizeof(char);
+       sprintf(line,"char=%d",size); /* SAFE */
+       if (!prtopt(&lines,line)) return(0);
+
+       size = (int)sizeof(char *);
+       sprintf(line,"char*=%d",size); /* SAFE */
+       if (!prtopt(&lines,line)) return(0);
+
+       size = (int)sizeof(float);
+       sprintf(line,"float=%d",size); /* SAFE */
+       if (!prtopt(&lines,line)) return(0);
+
+       size = (int)sizeof(double);
+       sprintf(line,"double=%d",size); /* SAFE */
+       if (!prtopt(&lines,line)) return(0);
+    }
+
 #ifdef FNFLOAT
     if (!prtopt(&lines,"")) return(0);  /* Start a new section */
     if (!prtopt(&lines,"floating-point:")) return(0);
index 14f19cc..d332bed 100644 (file)
--- a/ckuusx.c
+++ b/ckuusx.c
@@ -9,7 +9,7 @@
     Jeffrey E Altman <jaltman@secure-endpoints.com>
       Secure Endpoints Inc., New York City
 
-  Copyright (C) 1985, 2010,
+  Copyright (C) 1985, 2011,
     Trustees of Columbia University in the City of New York.
     All rights reserved.  See the C-Kermit COPYING.TXT file or the
     copyright text in the ckcmai.c module for disclaimer and permissions.
@@ -7616,35 +7616,35 @@ char *s;        /* a string */
         if (what & W_SEND) {           /* If we're sending... */
 #ifdef NEWFTP
            if (what & W_FTP) {         /* FTP */
-                move(CW_NAM,13);
-                printw("FTP PUT:");
+                move(CW_NAM,10);
+                printw("   FTP PUT:");
            } else
 #endif /* NEWFTP */
 #ifdef CK_RESEND
             switch (sendmode) {                /* Kermit */
               case SM_RESEND:
-                move(CW_NAM,11);
-                printw("RESENDING:");
+                move(CW_NAM,10);
+                printw(" RESENDING:");
                 break;
               default:
-                move(CW_NAM,13);
-                printw("SENDING:");
+                move(CW_NAM,10);
+                printw("   SENDING:");
                 break;
             }
 #else
-            move(CW_NAM,13);
-            printw("SENDING:");
+            move(CW_NAM,10);
+            printw("   SENDING:");
 #endif /* CK_RESEND */
 
         } else if (what & W_RECV) {    /* If we're receiving... */
 #ifdef NEWFTP
            if (what & W_FTP) {         /* FTP */
-                move(CW_NAM,13);
-                printw("FTP GET:");
+                move(CW_NAM,10);
+                printw("   FTP GET:");
            } else {
 #endif /* NEWFTP */
-               move(CW_NAM,11);
-               printw("RECEIVING:");
+               move(CW_NAM,10);
+               printw(" RECEIVING:");
 #ifdef NEWFTP
            }
         } else if (what == (W_FTP|W_FT_DELE)) {
@@ -7652,8 +7652,8 @@ char *s;        /* a string */
                printw("FTP DELETE:");
 #endif /* NEWFTP */
         } else {                        /* If we don't know... */
-            move(CW_NAM,11);            /* (should never see this) */
-            printw("File Name:");
+            move(CW_NAM,10);            /* (should never see this) */
+            printw(" File Name:");
         }
         move(CW_NAM,22);                /* Display the filename */
         if (len > 57) {
index b89778d..454d3e4 100644 (file)
--- a/makefile
+++ b/makefile
@@ -1,10 +1,9 @@
 # makefile / Makefile / ckuker.mak / CKUKER.MAK
 #
-# Thu Jun 16 17:36:23 2011
-# Note: sources haven't changed since 20110615, only this file.
-BUILDID=20110615
+# Tue Jun 21 13:04:45 2011
+BUILDID=20110621
 CKVER= "9.0.299"
-TESTID= "Beta.01"
+TESTID= "Beta.02"
 #
 # -- Makefile to build C-Kermit for UNIX and UNIX-like platforms --
 #
@@ -17,13 +16,13 @@ TESTID= "Beta.01"
 #
 # Author: Frank da Cruz, Columbia University
 # 612 West 115th Street, New York NY 10025-7799, USA
-# E-mail: fdc@columbia.edu
-# Web:    http://www.columbia.edu/kermit/
-# FTP:    ftp://kermit.columbia.edu/kermit/
+# Email: fdc@columbia.edu
+# Web:   http://kermit.columbia.edu/
+# FTP:   ftp://kermit.columbia.edu/kermit/
 #
 # Note: Author is no longer at Columbia University or at the 115th Street
 # address effective 1 July 2011.  The email address should still work,
-# and the website and FTP addresses, for the foreseeable future.
+# as well as the website and FTP addresses, for the foreseeable future.
 #
 # Contributions from many others.  Special thanks to Jeff Altman for the
 # secure-build targets, Peter Eichhorn, assyst GmbH, for the consolidated
@@ -55,13 +54,18 @@ TESTID= "Beta.01"
 # separated by whitespace.  Some versions of "make" understand these as
 # directives.  Uppercase letters remove the danger, e.g. "# If you have..."
 # 
-# WARNING: This is a huge makefile and it contains nested makes.  Although
+# WARNING: This is a huge makefile.  Although
 # this is less likely since the turn of the century, some "make" programs
 # might run out of memory.  If this happens to you, edit away the parts that
 # do not apply to your platform and try again.
 #
+# WARNING 2: In many cases this file invokes itself recursively, sometimes
+# several levels deep (as in the Linux targets); i.e. some targets are used
+# as 'subroutines' of other targets, with parameters passed by setting
+# environment variables.  For that reason, don't use 'make -e'.
+#
 # Certain UNIX variations have their own separate makefiles:
-#  . For 2.10 or 2.11 BSD on DEC PDP-11s, use ckubs2.mak.
+#  . For 2.10 or 2.11 BSD on the DEC PDP-11, use ckubs2.mak.
 #  . For Plan 9, use ckpker.mk.
 #
 # Separate build procedures are provided non-UNIX platforms: VMS, VOS,
@@ -79,7 +83,9 @@ TESTID= "Beta.01"
 #
 # Other targets:
 #  'make install' is an installation script (read accompanying comments!).
+#  'make uninstall' undoes 'make install' (read accompanying comments!).
 #  'make clean' removes intermediate and object files.
+#  'make show' tells the default include and lib paths for secure builds.
 #
 # IMPORTANT:
 #   For more detailed installation instructions, read the files ckuins.txt
@@ -113,7 +119,7 @@ TESTID= "Beta.01"
 #
 # TARGETS FOR DIFFERENT UNIX PLATFORMS AND VERSIONS:
 #
-# + Marks those that have been built successfully for C-Kermit 8.0 or later.
+# + Marks those that have been built successfully for C-Kermit 9.0 or later.
 # - Those that once built OK but no longer do (e.g. too big).
 # ? Those that worked in a previous version but have not been tested recently.
 # --------------------------
@@ -296,7 +302,7 @@ TESTID= "Beta.01"
 # ? for Data General MV systems with DG/UX, ???
 # ? for Data General MV systems with MV/UX, use AOS/VS C-Kermit (CKDKER.MAK)
 # ? for Data General MV systems with AOS/VS, use CKDKER.MAK (last = C-K 7.0)
-#   for DEC PDP-11 with Berkeley UNIX 2.x, see Berkeley UNIX 2.x.
+# ? for DEC PDP-11 with Berkeley UNIX 2.x, see Berkeley UNIX 2.x.
 # ? for DEC PDP-11 with Mini-UNIX (Bell 6th Edition for PDP-11 with no MMU),
 #     probably no way to fit C-Kermit without I&D space.
 # ? for DEC PDP-11 with Ultrix-11 3.x, ??? (probably needs overlays)
@@ -319,6 +325,7 @@ TESTID= "Beta.01"
 # ? for DEC Alpha with Digital UNIX 3.2, "make du32"
 # ? for DEC Alpha with Digital UNIX 4.0-4.0D, "make du40" or "make du40gcc"
 # ? for DEC Alpha with Digital UNIX 4.0E or higher, see Tru64.
+# + for DEC Alpha with any version of DU or OSF/1, "make dec-osf1"
 # - for DEC Pro-350 with Pro/Venix V1.x, "make provx1" (version 5A is too big)
 # ? for DEC Pro-380 with Pro/Venix V2.0 (Sys V), "make sys3" or "make sys3nid"
 # ? for DEC Pro-380 with 2.9, 2.10, or 2.11 BSD, "make bsd29" or "make bsd210"
@@ -356,12 +363,17 @@ TESTID= "Beta.01"
 # ? for FreeBSD 3.x, "make freebsd3" (ncurses) or "make freebsd3c" (curses)
 # ? for FreeBSD 4.0, "make freebsd40"
 # ? for FreeBSD 4.1 or later, "make freebsd"
+# + NOTE: Just use "make freebsd" for any reasonably recent FreeBSD version.
 # ? for Harris HCX-2900, "make sys5r3"
 # ? for Harris Night Hawk 88K or 68K with CX/UX pre-6.1, "make sys5r3"
 # ? for Harris Night Hawk 88K or 68K with CX/UX 6.1 or later, "make cx_ux"
 # ? for Heurikon, "make sys3"
 # ? for HP-3000, MPE/ix, "make posix"?
 # ? for HP-9000 Series 300 with 4.4BSD, "make bsd44"
+
+# NOTE: Most of the HP-UX targets were tested successfully in 2010.
+# Verification needed for C-Kermit 9.0 Beta.01...
+
 # ? for HP-9000 Series 500, HP-UX 5.21 and no networking "make hpux0500"
 # ? for HP-9000 Series 500, HP-UX 5.21 with WIN/TCP 1.2 "make hpux0500wintcp"
 # ? for HP-9000 Series, HP-UX 6.5, without long filenames,
@@ -420,6 +432,7 @@ TESTID= "Beta.01"
 #     or if you have GNU CC, "make minix386gcc"
 # ? for IBM PC family, 386-based, with MINIX 2.0, "make minix20"
 # ? for IBM PC family, 386-based, with MINIX 3.0, "make minix3"
+# + for IBM PC family, 386-based, with MINIX 3.0, "make minix315"
 # ? for IBM PS/2 with PS/2 AIX 1.0, 1.1, or 1.2, "make ps2aix" or ps2aixnetc.
 # ? for IBM PS/2 with PS/2 AIX 1.3, "make ps2aix3"
 # ? for IBM RISC System/6000 with AIX 3.0, "make aix30"
@@ -526,8 +539,8 @@ TESTID= "Beta.01"
 #       ln /usr/include/sys/termiox.h /usr/include/termiox.h
 # ? for NCR System 3000, NCR UNIX 02.02.01, same as above.
 # ? for NCR MP-RAS System V R4 V2.03 or 3.02, "make mpras" or "make mprastcpc"
-# ? for NetBSD any version on any architecture, "make netbsd"
-# ? for NetBSD with SSL/TLS, SRP, and ZLIB, "make netbsd+ssl+srp+zlib"
+# + for NetBSD any version on any architecture, "make netbsd"
+# + for NetBSD with OpenSSL, "make netbsd+ssl"
 # ? for NetBSD with ncurses specified instead of curses, "make netbsdn"
 # ? for NetBSD with all curses support omitted, "make netbsdnc"
 # ? for NeXT with NeXTSTEP 1.0 through 3.2, "make next" (on a NeXT)
@@ -644,7 +657,7 @@ TESTID= "Beta.01"
 # ? for Sequent Symmetry S81 with DYNIX 3.0.xx, "make dynix3"
 # ? for Sequent DYNIX 3.1.xx, "make dynix31" or "make dynix31c"
 # ? for Siemens/Nixdorf SINIX-L Intel V5.41, "make sinix541i"
-# ? for Siemens/Nixdorf SINIX-N MIPS V5.42, "make sinix542"
+# + for Siemens/Nixdorf SINIX-N MIPS V5.42, "make sinix542"
 # ? for Siemens/Nixdorf SINIX-P MIPS V5.42 with gcc, "make sinix542g"
 # ? for Siemens/Nixdorf SINIX-Z Intel V5.42, "make sinix542i"
 # ? for Siemens/Nixdorf Reliant UNIX V5.43, "make sni543"
@@ -727,12 +740,13 @@ TESTID= "Beta.01"
 #     or (for models without hardware flow control), "make uteknohwfc"
 # ? for Tektronix XD88 series with UTekV OS, "make utekvr3"
 # ? for Tri Star Flash Cache with Esix SVR3.2, "make sys5r3"
-# + for Tru64 UNIX 4.0E, "make tru64-40e"
-# + for Tru64 UNIX 4.0F, "make tru64-40f"
-# + for Tru64 UNIX 4.0G, "make tru64-40g"
-# + for Tru64 UNIX 5.0A, "make tru64-50a"
-# + for Tru64 UNIX 5.1A, "make tru64-51a"
-# + for Tru64 UNIX 5.1B, "make tru64-51b"
+# NOTE: The Tru64 builds have been failing since 2010, but "make dec-osf" is OK
+# ? for Tru64 UNIX 4.0E, "make tru64-40e"
+# ? for Tru64 UNIX 4.0F, "make tru64-40f"
+# ? for Tru64 UNIX 4.0G, "make tru64-40g"
+# ? for Tru64 UNIX 5.0A, "make tru64-50a"
+# ? for Tru64 UNIX 5.1A, "make tru64-51a"
+# ? for Tru64 UNIX 5.1B, "make tru64-51b"
 # ? for Unistar, "make sys5"
 # ? for Unisys S/4040 68040 CTIX SVR3.2 6.4.1, "make ctix" or "make sys5r3"
 # ? for Unisys U5000 UNIX SVR3 6.x, "make sys5r3" or "make sys5r3c"
@@ -990,7 +1004,8 @@ show:
        @echo SRPINC=$(SRPINC)
        @echo SSLLIB=$(SSLLIB)
        @echo SSLINC=$(SSLINC)
-       
+       @exit
+
 # Install C-Kermit after building -- IMPORTANT: Read the instructions above
 # (SAMPLE INSTALLATION SCRIPT).  For SSL/TLS versions, ca_certs.pem file
 # should be installed in the appropriate place for your OpenSSL library, e.g.:
@@ -1721,7 +1736,7 @@ freebsd40:
 
 #FreeBSD 4.1 and above
 #Like FreeBSD 4.0 but without the NONOSETBUF hack and with CK_NEWTERM.
-#OK 2009/11/17 FreeBSD 7.2-RELEASE
+#OK 2011/06/15 FreeBSD 3.3, 4,4, 4.7, and 8.2
 freebsd freebsd41 freebsd72:
        @echo 'Making C-Kermit $(CKVER) for FreeBSD 4.1 or later...'
        $(MAKE) CC=$(CC) CC2=$(CC2) xermit KTARGET=$${KTARGET:-$(@)} \
@@ -1732,7 +1747,7 @@ freebsd freebsd41 freebsd72:
        "LIBS= -lncurses -lcrypt -lutil -lm $(LIBS)"
 
 #FreeBSD 5.0 or later with OpenSSL 0.9.7 or later.
-#OK 2009/11/17 FreeBSD 7.2-RELEASE
+#OK 2011/06/15 FreeBSD 4.7 and 8.2
 freebsd+ssl freebsd+openssl freebsd50+openssl:
        @echo 'Making C-Kermit $(CKVER) for FreeBSD 5.0, ncurses, openssl'
        $(MAKE) CC=$(CC) CC2=$(CC2) xermit KTARGET=$${KTARGET:-$(@)} \
@@ -1847,6 +1862,7 @@ netbsd+krb5+ssl netbsd+krb5+openssl+zlib:
 #then go to work/srp-x.y.z/libsrp and "bmake install".  As of 2005Q3, the
 #pkgsrc install only installed the statically linked client applications.  You
 #need to manually install the libraries to build your own applications.
+#NOT TESTED RECENTLY - probably needs work.
 netbsd+ssl+srp+zlib:
        @echo Making C-Kermit $(CKVER) for NetBSD with curses...
        $(MAKE) CC=$(CC) CC2=$(CC2) xermit KTARGET=$${KTARGET:-$(@)} \
@@ -1875,7 +1891,7 @@ netbsdn:
        -DCK_DTRCD -DCK_DTRCTS -DTPUTSARGTYPE=int -DFNFLOAT $(KFLAGS) -O" \
        "LIBS= -L/usr/pkg/lib -lncurses -lcrypt -lm -lutil $(LIBS)"
 
-#OpenBSD - All versions.
+#OpenBSD before 2.3.
 #Uses ncurses as its curses so use -ltermlib, not -ltermcap
 #But it doesn't use uu_lock() which was introduced in OpenBSD 2.3.
 #For that use the next entry.
@@ -2020,7 +2036,7 @@ oldmacosx103+secure:
 # Note: Mac OS X 10.5 and earlier are 32-bit; 10.6 and later 64-bit.
 # Note 2: As of C-Kermit 9.0 -NOUUCP is included by default because
 # Mac OS X doesn't support UUCP.  To undo this, use KFLAGS=-UNOUUCP.
-#OK: 2009/11/16 (for 10.3.9, 10.4.11, 10.5.8, 10.6.1)
+#OK: 2011/06/14 (for 10.4.11, 10.5.8, 10.6.7)
 macosx macosx10 macosx10.3.9 macosx10.4 macosx10.5 macosx10.6:
        @MACOSNAME=`/usr/bin/sw_vers -productName`; \
        MACOSV=`/usr/bin/sw_vers -productVersion`; \
@@ -2045,6 +2061,7 @@ macosx macosx10 macosx10.3.9 macosx10.4 macosx10.5 macosx10.6:
 #   automatically based on the Mac OS X version number.
 # See note about UUCP in previous target.
 #OK: 2009/11/16 (for 10.3.9, 10.4.11, 10.5.8, 10.6.1)
+#OK: 2011/06/14 (for 10.4.11, 10.5.8, 10.6.7)
 macosx+krb5+ssl macosx10.5+krb5+ssl macosx10.6+krb5+ssl \
 macosx+krb5+openssl macosx10.5+krb5+openssl macosx10.6+krb5+openssl:
        @MACOSNAME=`/usr/bin/sw_vers -productName`; \
@@ -2870,7 +2887,7 @@ rtacis:
 
 # This one should work for any AIX 4.2 or later: "make aix".
 # Other tags are for compatibility with old makefile targets.
-#OK: 2009/11/16
+#OK: 2011/06/11
 aix aix42 aix43 aix44 aix45 aix50 aix51 aix52 aix53 aix54 aix61:
        @echo Making C-Kermit $(CKVER) for IBM AIX...
        $(MAKE) xermit KTARGET=$${KTARGET:-$(@)} \
@@ -2899,7 +2916,7 @@ aixg:
 #
 # To build with gcc use "make aix CC=gcc CC2=gcc", or "make aixg"
 #
-#OK: 2009/11/16
+#OK: 2011/06/15
 aix+ssl aix51+openssl aix52+openssl aix53+openssl:
        @echo "Making C-Kermit $(CKVER) for IBM AIX with OpenSSL..."
        @echo "SSLINC=$(SSLINC) SSLLIB=$(SSLLIB)"
@@ -3895,6 +3912,7 @@ solaris9g64 solaris10g64 solaris11g64:
 #Solaris 9, 10, or 11 with SunPro CC
 #Uses streams PTYs rather than BSD ptys as in C-Kermit 8.0 and earlier.
 #This target is chained to by the secure targets below.
+#OK: 2011/06/15
 solaris9 solaris10 solaris11:
        @echo 'Making C-Kermit $(CKVER) for Solaris 9 or later with Sun CC'
        @case `uname -r` in \
@@ -3950,7 +3968,7 @@ solaris9+openssl solaris10+openssl solaris11+openssl:
 # chains to the solaris{9,10,11}g target but for some reason it doesn't work if
 # you add the -DFORWARD_X option, thus the solaris9g+openssl+forward_x target.
 #
-#OK: 2009/09/25 (but not tested on Solaris 11)
+#OK: 2020/06/15
 solaris9g+ssl solaris10g+ssl solaris11g+ssl \
 solaris9g+openssl solaris10g+openssl solaris11g+openssl:
        @echo 'Making C-Kermit $(CKVER) for Solaris 9/10/11 with OpenSSL: gcc'
@@ -5463,7 +5481,7 @@ hpux0700osf:
 #other files) increase the '...' value in '-Wc,-Ns...'! The default maximum
 #symbol table size (-Ns) is 2000 table entries. ckuus4.c from Mar 12 2010
 #needs 2031 table entries (C-Kermit Version "9.0.299").
-#OK: 2020/03/24
+#OK: 2010/03/24
 hpux0700sftcpc:
        @$(MAKE) hpux-header
        @echo 'supporting: NO long filenames, \c'
@@ -6049,9 +6067,9 @@ linuxp:
 #On 64-bit platforms, it does no harm.
 #As of 3 March 2009 we detect automatically if we have curses, ncurses,
 #or no curses at all.
-#OK: 2009/11/16
 #Added HAVE_LOCKDEV as openSuSE >= 11.3 uses ttylock directly instead of
 #baudboy 2010/08/23
+#OK: 2011/06/18
 linux:
        @if test \
        `grep grantpt /usr/include/*.h /usr/include/sys/*.h | wc -l` -gt 0; \
@@ -6092,10 +6110,12 @@ linux:
        "LIBS=$(LIBS) $$HAVE_LIBCURSES \
        `if test -n '$$HAVE_OPENPTY'; then echo -lutil; fi` \
        `if test -f /usr/lib64/libresolv.a || test -f /usr/lib64/libresolv.so \
-       || test -f /usr/lib/libresolv.a || test -f /usr/lib/libresolv.so; \
+       || test -f /usr/lib/libresolv.a || test -f /usr/lib/libresolv.so \
+       || ls /lib/x86_64-linux-gnu/libresolv.* > /dev/null 2> /dev/null; \
        then echo -lresolv; fi` \
        `if test -f /usr/lib64/libcrypt.a || test -f /usr/lib64/libcrypt.so \
-       || test -f /usr/lib/libcrypt.a || test -f /usr/lib/libcrypt.so; \
+       || test -f /usr/lib/libcrypt.a || test -f /usr/lib/libcrypt.so \
+       || ls /lib/x86_64-linux-gnu/libcrypt.* > /dev/null 2> /dev/null; \
        then echo -lcrypt; fi` \
        `if test -f /usr/lib64/liblockdev.a || \
        test -f /usr/lib64/liblockdev.so || \
@@ -6104,21 +6124,39 @@ linux:
        then echo -llockdev; fi`" \
        linuxa
 
+# Linux + Shadow passwords + PAM
+# OK 2011/06/18
+linux+shadow+pam:
+       @echo 'Making C-Kermit $(CKVER) for Linux+Shadow+PAM...'
+       $(MAKE) linux KTARGET=$${KTARGET:-$(@)} \
+       KFLAGS="-DCK_SHADOW -DCK_PAM $(KFLAGS)" \
+       "LNKFLAGS = $(LNKFLAGS)" \
+       "LIBS = -lpam"
+
+# Linux systems that have no <sys/select.h>.
+# (not tested in recent years, perhaps no longer needed)
+linuxns:
+       $(MAKE) linux KTARGET=$${KTARGET:-$(@)} KFLAGS=-DNO_SYS_SELECT_H
+
+# Linux-script-only:
+# A minimum-size version for Linux that does only scripting and
+# serial communication -- no networks, no file transfer, no security.
+# OK 2011/06/18
+linuxso:
+       $(MAKE) xermit KTARGET=$${KTARGET:-$(@)} "CC = gcc" "CC2 = gcc" \
+       "CFLAGS = -O -DLINUX -pipe -funsigned-char -DPOSIX -DCK_POSIX_SIG \
+       -DLINUXFSSTND -DNOCOTFMC -DNOXFER -DNODEBUG -DNOCSETS -DNOHELP \
+       -DNONET -DMINIDIAL -DNOSCRIPT -DNOIKSD -DNOPUSH $(KFLAGS)" \
+       "LNKFLAGS = $(LNKFLAGS)" "LIBS = "
+
 # Secure targets for Linux.  These work on RHAS4, RHEL4, and RHEL5,
 # unlike some of the older targets that follow.  They hook into the main Linux
 # target so we pick up all the other new stuff - large files, baudboy.h, the
 # appropriate pty interface, etc.
 
-# Linux with Kerberos 5 (but not 4) and OpenSSL.
-# Note: -DOPENSSL_097 is necessary.  Without it we use the wrong names
-# for the DES routines and the link step fails.
-# Note 2: In recent Red Hat releases libpam might be in /lib instead of in
-# /usr/lib.  There should be symlinks in place but if not add them yourself.
-#OK: 2010/04/01
-
 # Linux with Kerberos 5.
 # Use "make linux+krb5 KFLAGS=-DNO_KRB5_INIT_ETS" if necessary.
-#OK 2011/06/14 on Fedora 14:
+#OK 2011/06/16 on Fedora 14 with:
 # make linux+krb5 "LIBS=$LIBS /lib/libk5crypto.so.3 /lib/libcom_err.so.2"
 # On RHEL5: make linux+krb5 -UCK_DES
 linux+krb5:
@@ -6139,24 +6177,46 @@ linux+krb5:
            else echo "NO DES"; \
        fi; \
        K5CRYPTO=''; \
-       if ls /lib/libk5crypto* > /dev/null 2> /dev/null; then \
-               K5CRYPTO='-lk5crypto'; \
-       fi; \
+        if ls /lib/libk5crypto* > /dev/null 2> /dev/null; then \
+                K5CRYPTO='-lk5crypto'; \
+        else if ls /usr/lib64/libk5crypto* > /dev/null 2> /dev/null; then \
+                K5CRYPTO='-lk5crypto'; \
+        fi; fi; \
        COM_ERR=''; \
        if ls /lib/libcom_err* > /dev/null 2> /dev/null; then \
                COM_ERR='-lcom_err'; \
        fi; \
        GSSAPILIB='-lgssapi'; \
-       K5DIR=`echo $(K5LIB) | sed 's|-L||'`; \
-       if ls $$K5DIR/libgssapi_krb5* > /dev/null 2> /dev/null; then \
+       if ls /lib/libgssapi_krb5* > /dev/null 2> /dev/null; then \
                GSSAPILIB='-lgssapi_krb5'; \
-       fi; \
+       else if ls /usr/lib/libgssapi_krb5* > /dev/null 2> /dev/null; then \
+               GSSAPILIB='-lgssapi_krb5'; \
+       else K5DIR=`echo $(K5LIB) | sed 's|-L||'`; \
+               if ls $$K5DIR/libgssapi_krb5* > /dev/null 2> /dev/null; then \
+                       GSSAPILIB='-lgssapi_krb5'; \
+       fi; fi; fi; \
        $(MAKE) linux KTARGET=$${KTARGET:-$(@)} "CC = gcc" "CC2 = gcc" \
        "KFLAGS= -DCK_AUTHENTICATION -DCK_KERBEROS -DKRB5 $$OPENSSLOPTION \
        -DCK_ENCRYPTION $$HAVE_DES $(K5INC) $(K5INC)/krb5 \
        -I/usr/include/et $(KFLAGS)" "LNKFLAGS = $(LNKFLAGS)" \
        "LIBS = $(K5LIB) $$DES_LIB -lcrypto $$GSSAPILIB -lkrb5 \
-       $$K5CRYPTO $$COM_ERR $(LIBS)"
+       $$K5CRYPTO $$COM_ERR $(LIBS)" ; \
+       if [ ! -f ./wermit ] || [ ./ckcmai.o -nt ./wermit ] ; then \
+               echo ""; \
+               echo "If build failed try:"; \
+               echo ""; \
+               echo "  make clean ; make $${KTARGET:-$(@)} KFLAGS=-UCK_DES"; \
+               echo ""; \
+       fi
+
+# Linux with Kerberos 5 and Kerberos 4.
+# Use "make linux+krb5 KFLAGS=-DNO_KRB5_INIT_ETS" if necessary.
+# Add "KFLAGS=-UCK_DES" if failure messages look DES-related.
+# UNTESTED (because I can't find a box with Krb4 and Krb5 installed)
+linux+krb5+krb4:
+       @echo 'Making C-Kermit for Linux with Kerberos 4 and Kerberos 5'
+       $(MAKE) linux+krb5 KTARGET=$${KTARGET:-$(@)} \
+       "KFLAGS=-DKRB4 -DKRB524 $(KFLAGS)" "LIBS=$(LIBS) -lkrb4"
 
 # Linux with OpenSSL 
 # In Linux, SSL libs are often in /lib or /usr/lib and so found by default.
@@ -6170,7 +6230,7 @@ linux+krb5:
 # There's a new warning at the end that should come out if this happens,
 # and that should not come out if it didn't.
 #
-linux+ssl linux+openssl:
+linux+ssl linux+openssl linux+openssl+zlib+shadow+pam linux+openssl+shadow:
        @echo 'Making C-Kermit $(CKVER) for Linux+OpenSSL SSLLIB=$(SSLLIB)'
        @case `openssl version` in \
          *0.9.7*) OPENSSLOPTION="-DOPENSSL_097" ;; \
@@ -6184,20 +6244,21 @@ linux+ssl linux+openssl:
           ls $(SSLLIB)/libdes* > /dev/null 2> /dev/null; then \
              DES_LIB='-ldes425'; \
              HAVE_DES='-DCK_DES -DLIBDES'; \
-              echo "HAVE DES"; \
-           else echo "NO DES"; \
+             echo "HAVE DES"; \
+          else echo "NO DES"; \
        fi; \
        $(MAKE) linux KTARGET=$${KTARGET:-$(@)} "CC = gcc" "CC2 = gcc" \
        "KFLAGS= -DCK_AUTHENTICATION -DCK_ENCRYPTION -DCK_CAST $$HAVE_DES \
        -DCK_SSL -DCK_PAM -DZLIB -DCK_SHADOW $$OPENSSLOPTION $(SSLINC) \
        $(KFLAGS)" "LNKFLAGS = $(LNKFLAGS)" \
-       "LIBS = $(SSLLIBS) -lssl $$DES_LIB -lcrypto -lpam -ldl -lz $(LIBS)"; \
-       if [ ! -f ./wermit ] || [ ckcmai.o -nt ./wermit ]; then \
-       echo ""; \
-       echo "If build failed try:"; \
-       echo ""; \
-       echo "  make clean ; make linux+ssl KFLAGS=-UCK_DES"; \
-       echo ""; fi
+       "LIBS = $(SSLLIB) -lssl $$DES_LIB -lcrypto -lpam -ldl -lz $(LIBS)" ; \
+       if [ ! -f ./wermit ] || [ ./ckcmai.o -nt ./wermit ] ; then \
+               echo ""; \
+               echo "If build failed try:"; \
+               echo ""; \
+               echo "  make clean ; make $${KTARGET:-$(@)} KFLAGS=-UCK_DES"; \
+               echo ""; \
+       fi
 
 # Linux with Kerberos 5 and OpenSSL
 # OK 2011/05/16
@@ -6221,61 +6282,49 @@ linux+krb5+ssl linux+krb5+openssl:
           else echo "NO DES"; \
        fi; \
        K5CRYPTO=''; \
-       if ls /lib/libk5crypto* > /dev/null 2> /dev/null; then \
-               K5CRYPTO='-lk5crypto'; \
-       fi; \
+        if ls /lib/libk5crypto* > /dev/null 2> /dev/null; then \
+                K5CRYPTO='-lk5crypto'; \
+        else if ls /usr/lib64/libk5crypto* > /dev/null 2> /dev/null; then \
+                K5CRYPTO='-lk5crypto'; \
+        fi; fi; \
        COM_ERR=''; \
        if ls /lib/libcom_err* > /dev/null 2> /dev/null; then \
                COM_ERR='-lcom_err'; \
        fi; \
        GSSAPILIB='-lgssapi'; \
-       K5DIR=`echo $(K5LIB) | sed 's|-L||'`; \
-       echo K5DIR=$$K5DIR; \
-       if ls $$K5DIR/libgssapi_krb5* > /dev/null 2> /dev/null; then \
+       if ls /lib/libgssapi_krb5* > /dev/null 2> /dev/null; then \
                GSSAPILIB='-lgssapi_krb5'; \
-       fi; \
+       else if ls /usr/lib/libgssapi_krb5* > /dev/null 2> /dev/null; then \
+               GSSAPILIB='-lgssapi_krb5'; \
+       else K5DIR=`echo $(K5LIB) | sed 's|-L||'`; \
+               if ls $$K5DIR/libgssapi_krb5* > /dev/null 2> /dev/null; then \
+                       GSSAPILIB='-lgssapi_krb5'; \
+       fi; fi; fi; \
        $(MAKE) linux KTARGET=$${KTARGET:-$(@)} "CC = gcc" "CC2 = gcc" \
        "KFLAGS= -DCK_AUTHENTICATION -DCK_KERBEROS -DKRB5 \
        -DCK_SSL -DCK_PAM -DZLIB -DCK_SHADOW $$OPENSSLOPTION $(SSLINC) \
        -DCK_ENCRYPTION $$HAVE_DES $(K5INC) $(K5INC)/krb5 \
        -I/usr/include/et $(KFLAGS)" "LNKFLAGS = $(LNKFLAGS)" \
-       "LIBS = $(K5LIB) $(SSLLIBS) -lssl $$DES_LIB -lpam -lz \
-       -lcrypto $$GSSAPILIB_krb5 -lkrb5 $$K5CRYPTO $$COM_ERR $(LIBS)" \
-       if [ ! -f ./wermit ] || [ ckcmai.o -nt ./wermit ]; then \
-       echo ""; \
-       echo "If build failed try:"; \
-       echo ""; \
-       echo "  make clean ; make linux+ssl KFLAGS=-UCK_DES"; \
-       echo ""; fi
-
-#Linux configured for SSL/TLS, ZLIB, PAM and Shadow Passwords
-#OK: 2009/11/17
-linux+openssl+zlib+shadow+pam:
-       @echo 'Making C-Kermit $(CKVER) for Linux on i386 with SSL/TLS...'
-       $(MAKE) linux KTARGET=$${KTARGET:-$(@)} "CC = gcc" "CC2 = gcc" \
-       "KFLAGS = -DCK_AUTHENTICATION -DCK_SSL -DCK_PAM -DZLIB -DOPENSSL_097 \
-       -DCK_SHADOW $(SSLINC) $(KFLAGS)" "LNKFLAGS = $(LNKFLAGS)" \
-       "LIBS= $(SSLLIB) -lssl -lcrypto -lz -lpam -ldl $(LIBS)"
-
-# As above but for Linux systems that have no <sys/select.h>.
-linuxns:
-       $(MAKE) linux KTARGET=$${KTARGET:-$(@)} KFLAGS=-DNO_SYS_SELECT_H
+       "LIBS = $(K5LIB) $(SSLLIB) -lssl $$DES_LIB -lpam -lz \
+       -lcrypto $$GSSAPILIB -lkrb5 $$K5CRYPTO $$COM_ERR $(LIBS)" ; \
+       if [ ! -f ./wermit ] || [ ./ckcmai.o -nt ./wermit ] ; then \
+               echo ""; \
+               echo "If build failed try:"; \
+               echo ""; \
+               echo "  make clean ; make $${KTARGET:-$(@)} KFLAGS=-UCK_DES"; \
+               echo ""; \
+       fi
 
-# A minimum-size version for Linux that does only scripting and
-# serial communication -- no networks, no file transfer.
-linuxso:
-       $(MAKE) xermit KTARGET=$${KTARGET:-$(@)} "CC = gcc" "CC2 = gcc" \
-       "CFLAGS = -O -DLINUX -pipe -funsigned-char -DPOSIX -DCK_POSIX_SIG \
-       -DLINUXFSSTND -DNOCOTFMC -DNOXFER -DNODEBUG -DNOCSETS -DNOHELP \
-       -DNONET -DMINIDIAL -DNOSCRIPT -DNOIKSD -DNOPUSH $(KFLAGS)" \
-       "LNKFLAGS = $(LNKFLAGS)" "LIBS = "
+# ::BEGIN_OLD_LINUX_TARGETS::
 
-# The remaining Linux entries are for special or customized builds.  They
-# have not been generalized like the ones above.  Ideally, we should allow
-# for every combination of libc vs glibc, gcc vs egcs, curses vs ncurses,
-# Kerberos IV vs Kerberos V vs SRP (in any combination), and so on.  The
-# best way to do this is simply to set KFLAGS and LIBS values and then
-# chain to the main "linux" target, as in the examples just above.
+# The remaining Linux entries are for special or customized builds.  They have
+# not been generalized ("subroutinized") like the ones above.  Ideally, we
+# should allow for every combination of libc vs glibc, gcc vs egcs, curses vs
+# ncurses, Kerberos IV vs Kerberos V vs SRP (in any combination), and so on.
+# The best way to do this is to set KFLAGS and LIBS values and then chain to
+# the main "linux" target, as in the examples just above.  To skip past all of
+# these old targets (and there are many) search for ::END_OLD_LINUX_TARGETS::
+# (after this line).
 
 #Sharp Zaurus SL-5500 - Linux based
 zsl5500:
@@ -6343,20 +6392,6 @@ linux+krb5-old:
        "LIBS = $(K5LIB) -lncurses -ltermcap -ldes425 -lkrb5 \
        -lcom_err -lk5crypto -lgssapi_krb5 -lcrypt -lresolv"
 
-#Linux on Intel PC with Cygnus or MIT Kerberos 5 1.2.1 with K4 compatibility.
-#
-# Requires the Kerberos 1.2.1 be compiled with KRB4 compatibility.
-linux+krb5+krb4:
-       @echo 'Making C-Kermit $(CKVER) for Linux on Intel with Kerberos...'
-       $(MAKE) xermit KTARGET=$${KTARGET:-$(@)} "CC = gcc" "CC2 = gcc" \
-       "CFLAGS = -O -funsigned-char -pipe -DPOSIX -DLINUX -DNOCOTFMC \
-       -DCK_AUTHENTICATION -DCK_KERBEROS -DKRB5 -DKRB4 -DKRB524 \
-       -DCK_ENCRYPTION -DCK_DES -DCK_CURSES -DCK_POSIX_SIG \
-       -DTCPSOCKET -DLINUXFSSTND -DHAVE_CRYPT_H $(K5INC) $(K5INC)/krb5 \
-       $(KFLAGS)" "LNKFLAGS = $(LNKFLAGS)" \
-       "LIBS = $(K5LIB) -lncurses -ltermcap -lkrb4 -ldes425 -lkrb5 \
-       -lcom_err -lk5crypto -lcrypt -lgssapi_krb5 -lresolv"
-
 # Linux on Intel PC with SRP 1.7.4 using GNU MP, Krypto, and Eric Young's
 # DES library.  Remove the -DCK_DES, -DLIBDES and -ldes if you do not have
 # Eric Young's# libdes.a installed.
@@ -6431,41 +6466,6 @@ linux+srp+pam:
        "LIBS = $(SRPLIB) $(SSLLIB) -lncurses -ltermcap -lsrp -lkrypto \
        -lcrypto -lcrypt -lpam -ldl -lm -lresolv"
 
-linux+shadow+pam:
-       @echo 'Making C-Kermit $(CKVER) for Linux on i386 with Shadow+PAM...'
-       $(MAKE) xermit KTARGET=$${KTARGET:-$(@)} "CC = gcc" "CC2 = gcc" \
-       "CFLAGS = -O -funsigned-char -pipe -DPOSIX -DLINUX -DNOCOTFMC \
-       -DCK_CURSES -DCK_POSIX_SIG -DTCPSOCKET -DLINUXFSSTND -DHAVE_CRYPT_H \
-       -DCK_SHADOW -DCK_PAM -DFNFLOAT \
-       $(KFLAGS)" "LNKFLAGS = $(LNKFLAGS)" \
-       "LIBS = -lncurses -ltermcap -lcrypt -lpam -ldl -lm -lresolv"
-
-#Linux configured for SSL/TLS.
-#Remove -ltermcap if it causes trouble e.g. in Debian 2.2.
-#If you have OpenSSL 0.9.7 or later, add -DOPENSSL_097 to KFLAGS.
-oldlinux+openssl:
-       @echo 'Making C-Kermit $(CKVER) for Linux on i386 with SSL/TLS...'
-       $(MAKE) xermit KTARGET=$${KTARGET:-$(@)} "CC = gcc" "CC2 = gcc" \
-       "CFLAGS = -O -funsigned-char -pipe -DPOSIX -DLINUX -DNOCOTFMC \
-       -DCK_AUTHENTICATION -DCK_SSL \
-       -DCK_CURSES -DCK_POSIX_SIG -DTCPSOCKET -DLINUXFSSTND -DHAVE_CRYPT_H \
-       -DFNFLOAT $(SSLINC) $(KFLAGS)" "LNKFLAGS = $(LNKFLAGS)" \
-       "LIBS= $(SSLLIB) \
-       -lncurses -ltermcap -lssl -lcrypto -lm -lresolv -lcrypt"
-
-#Linux configured for SSL/TLS and Shadow Passwords
-#Remove -ltermcap if it causes trouble e.g. in Debian 2.2.
-#If you have OpenSSL 0.9.7 or later, add -DOPENSSL_097 to KFLAGS.
-linux+openssl+shadow:
-       @echo 'Making C-Kermit $(CKVER) for Linux on i386 with SSL/TLS...'
-       $(MAKE) xermit KTARGET=$${KTARGET:-$(@)} "CC = gcc" "CC2 = gcc" \
-       "CFLAGS = -O -funsigned-char -pipe -DPOSIX -DLINUX -DNOCOTFMC \
-       -DCK_AUTHENTICATION -DCK_SSL \
-       -DCK_CURSES -DCK_POSIX_SIG -DTCPSOCKET -DLINUXFSSTND -DHAVE_CRYPT_H \
-       -DFNFLOAT -DCK_SHADOW $(SSLINC) $(KFLAGS)" "LNKFLAGS = $(LNKFLAGS)" \
-       "LIBS= $(SSLLIB) \
-       -lncurses -ltermcap -lssl -lcrypto -lm -lresolv -lcrypt"
-
 #Linux on Intel PC with SRP and SSL/TLS.
 #
 # libsrp.a should be build with OpenSSL
@@ -6883,6 +6883,8 @@ linuxold:
        "CFLAGS = -O -DLINUX -DPOSIX -DCK_CURSES -DCK_POSIX_SIG -DNOLEARN \
        $(KFLAGS)" "LNKFLAGS = $(LNKFLAGS)" "LIBS = -lcurses -ltermcap"
 
+# ::END_OLD_LINUX_TARGETS::
+
 # LynxOS 2.2 with GCC compiler, TCP/IP and fullscreen display.
 # Probably also works with Lynx 2.1, and maybe even Lynx 2.0.
 # -X means use termios serial drivers rather than BSD4.3-style sgtty drivers.
@@ -7137,6 +7139,7 @@ sco3r22netc:
 #Use -M3 to generate 32-bit i386 code instead of 16-bit segmented i286 code.
 #Use -Me to enable MS nonstandard keywords in system headers.
 #Use -W2 or W3 to increase the warning level.
+#OK: 2011/06/15
 sco234:
        @echo 'Making C-Kermit $(CKVER) for SCO XENIX 2.3.4...'
        $(MAKE) wermit KTARGET=$${KTARGET:-$(@)} \
@@ -7568,7 +7571,7 @@ sco32v507net:
        -b elf -DPOSIX $(KFLAGS)"
 
 #SCO OpenServer 6 (new target 30 Jan 2006)
-sco_osr600:
+sco_osr600 sco600:
        @echo Making C-Kermit $(CKVER) for SCO OpenServer 6.0.0...
        $(MAKE) xermit KTARGET=$${KTARGET:-$(@)} \
        "CFLAGS= -O -DDIRENT -DHDBUUCP -DSVR4 -DCK_SCOV5 -DCK_RTSCTS \
@@ -7619,6 +7622,7 @@ trs16:
 #      @rm use.qnx
 #
 # If you get warnings about HEADER or C_IN add -DNO_DNS_SRV.
+# OK 2011/06/14
 qnx32:
        @echo 'Making C-Kermit $(CKVER) for QNX 4.2x, 32-bit...'
        $(MAKE) xermit \