From: dla@se05.wg2.waii.com (Doug Acker)
Newsgroups: comp.mail.mh
Subject: Re: MH 6.7.2 for AIX 3.2
Date: 14 Oct 92 18:24:03 GMT
Reply-To: acker@se01.wg2.waii.com
Organization: Western Geophysical Exploration Products

In article <1992Oct13.022009.195554@jrh.uucp>, jrh@jrh.uucp (James R. Hamilton) writes:
|> 
|>     I run MH 6.7.2 at home under AIX 1.2.1 but haven't yet got it compiled 
|>     at work under AIX 3.2.  However, I'm growing tired of some of the MH
|>     6.6 bugs in the standard AIX distribution.  Before I waste anymore time
|>     I thought I'd check to see who has beaten me to it.  If you have succes-
|>     sfully compiled MH 6.7.2 on a RS/6k, please let me know what incantations 
|>     you used.  Thanks very much.  
|> 

Bascialy you need to convert the NULLS to \0 .... I think I used this patch.

*** ./conf/MH	Sat Apr 13 15:13:16 1991
--- ./conf/MH-	Sat Apr 13 15:02:55 1991
***************
*** 1,5 ****
  # @(#)$Id: MH,v 1.7 90/04/06 09:44:31 sources Exp $
! # a RISC System/6000 running AIX 3.1.x
  bin	/usr/local
  etc	/usr/local/lib/mh
  mail	/usr/spool/mail
--- 1,5 ----
  # @(#)$Id: MH,v 1.7 90/04/06 09:44:31 sources Exp $
! # a 4.2BSD VAX system running SendMail
  bin	/usr/local
  etc	/usr/local/lib/mh
  mail	/usr/spool/mail
***************
*** 6,14 ****
  manuals	local
  chown	/bin/chown
  mts	sendmail
! options	ATHENA ATZ BIND DBM ISI MHRC
! options MORE='"/usr/bin/more"'
! options RPATHS SOCKETS SYS5 SYS5DIR
! options TYPESIG='void' TZNAME
! options curses="-lcurses"
! options ldoptlibs="-ldbm"
--- 6,11 ----
  manuals	local
  chown	/bin/chown
  mts	sendmail
! options	ATHENA ATZ BERK BIND BSD42 DBM 
! options ISI MHRC MORE="/usr/bin/more" 
! options RPATHS SOCKETS
There are no differences between the files.
*** ./conf/config/mtstailor	Sat Apr 13 15:17:02 1991
--- ./conf/config/mtstailor-	Sat Apr 13 11:47:41 1991
***************
*** 1,12 ****
  mmdfldir:	@(MHDROPATH)
  mmdflfil:	@(MHDROPFIL)
- uucpldir:	/usr/spool/mail
- uucplfil:	
- mmdelim1:	\001\001\001\001\n
- mmdelim2:	\001\001\001\001\n
- mmailid:	0
- umincproc:
- lockldir:
- 
  hostable:	@(MHETCPATH)/hosts
! sendmail:	/usr/lib/sendmail
--- 1,4 ----
  mmdfldir:	@(MHDROPATH)
  mmdflfil:	@(MHDROPFIL)
  hostable:	@(MHETCPATH)/hosts
! servers:	localhost \01localnet
*** ./conf/mhconfig.c	Sat Apr 13 15:12:02 1991
--- ./conf/mhconfig.c-	Sat Apr 13 15:10:56 1991
***************
*** 560,566 ****
  	}
  	break;
      }
!     if ((config = *vec++) == NULL && *vec != NULL)
  	adios (NULLCP, "usage: %s file", myname);
  
      if ((fp = fopen (config, "r")) == NULL)
--- 560,566 ----
  	}
  	break;
      }
!     if ((config = *vec++) == NULL || *vec != NULL)
  	adios (NULLCP, "usage: %s file", myname);
  
      if ((fp = fopen (config, "r")) == NULL)
*** ./config/version.sh	Sat Apr 13 15:18:44 1991
--- ./config/version.sh-	Sat Apr 13 12:46:51 1991
***************
*** 39,43 ****
  rm -f version.c
  
  cat version ${Patch} |\
! awk -F. -f version.awk && mv _version version
  echo '('$LOCAL') of '`date`'";' >> version.c
--- 39,63 ----
  rm -f version.c
  
  cat version ${Patch} |\
! awk -F. '
! BEGIN	{ split ("'"${1}"'", ver, ".");\
! 	  major = ver[1]; minor = ver[2]; patch = ver[3]}\
! NR == 1 { local = $(NF) }\
! NR == 2 { patch = $(NF) }\
! END	{ local++;\
! 	  if (patch > 0) {\
! 	  printf "char *version = \"MH %s.%s.%s #%d[UCI] ", \
! 		major, minor, patch, local > "version.c"; \
! 	  printf ".ds MH %s.%s.%s #%d[UCI]\n", \
! 		major, minor, patch, local > "../doc/version.rf"; \
! 	  printf "MH %s.%s.%s #%d[UCI]\n", major, minor, patch, local ;\
! 	} else {\
! 	  printf "char *version = \"MH %s.%s #%d[UCI] ", \
! 		major, minor, local > "version.c"; \
! 	  printf ".ds MH %s.%s #%d[UCI]\n", \
! 		major, minor, local > "../doc/version.rf"; \
! 	  printf "MH %s.%s #%d[UCI]\n", major, minor, local ;\
! 	}\
! 	  printf "%s.%s.%s.%d\n", major, minor, patch, local > "_version";\
! }' && mv _version version
  echo '('$LOCAL') of '`date`'";' >> version.c
*** ./h/local.h	Sat Apr 13 15:19:27 1991
--- ./h/local.h-	Sat Apr 13 14:41:12 1991
***************
*** 6,19 ****
  #include <sys/param.h>
  #endif	BSD42
  
! #if !defined(BSD42) && !defined(_AIX)
  #ifndef NDIR
  #include <dir.h>
  #else	NDIR
  #include <ndir.h>
  #endif  NDIR
! #else	BSD42 || _AIX
  #include <sys/dir.h>
! #endif	BSD42 || _AIX
  
  #include <sys/stat.h>
--- 6,19 ----
  #include <sys/param.h>
  #endif	BSD42
  
! #ifndef	BSD42
  #ifndef NDIR
  #include <dir.h>
  #else	NDIR
  #include <ndir.h>
  #endif  NDIR
! #else	BSD42
  #include <sys/dir.h>
! #endif	BSD42
  
  #include <sys/stat.h>
*** ./h/mh.h	Sat Apr 13 15:49:56 1991
--- ./h/mh.h-	Sat Apr 13 12:21:14 1991
***************
*** 340,346 ****
  
  /* miscellaneous */
  
! #if !defined(BSD42) && !defined(hpux) && !defined(_AIX)
  #define	rename(f1,f2)	(link (f1, f2) != NOTOK ? unlink (f1) : NOTOK)
  #endif	not BSD42
  
--- 340,346 ----
  
  /* miscellaneous */
  
! #if !defined(BSD42) && !defined(hpux)
  #define	rename(f1,f2)	(link (f1, f2) != NOTOK ? unlink (f1) : NOTOK)
  #endif	not BSD42
  
*** ./h/strings.h	Sat Apr 13 15:19:37 1991
--- ./h/strings.h-	Sat Apr 13 12:19:32 1991
***************
*** 12,18 ****
  char   *index ();
  char   *mktemp ();
  char   *rindex ();
- #ifndef _AIX
  #ifndef	SPRINTFTYPE
  char   *sprintf ();		/* I guess this is the new standard */
  #else
--- 12,17 ----
***************
*** 28,34 ****
  
  char   *getenv ();
  char   *calloc (), *malloc (), *realloc ();
- #endif !_AIX
  
  #ifdef	SYS5
  #include <memory.h>
--- 27,32 ----
*** ./sbr/formatsbr.c	Sat Apr 13 15:21:23 1991
--- ./sbr/formatsbr.c-	Sat Apr 13 14:25:10 1991
***************
*** 93,103 ****
  		case '\n':
  		    break;
  
- #ifdef _AIX
- 		case '\0':
- #else
  		case NULL: 
- #endif
  		    cp--;	/* fall */
  		default: 
  		    *dp++ = *cp;
--- 93,99 ----
*** ./sbr/path.c	Sat Apr 13 15:30:02 1991
--- ./sbr/path.c-	Sat Apr 13 15:29:35 1991
***************
*** 107,117 ****
      for (cp = f; *cp;)
  	if (*cp == '/') {
  	    switch (*++cp) {
- #ifdef _AIX
- 		case '\0': 
- #else
  		case NULL: 
- #endif _AIX
  		    if (--cp > f)
  			*cp = NULL;
  		    break;
--- 107,113 ----
*** ./sbr/makedir.c	Sat Apr 13 15:28:24 1991
--- ./sbr/makedir.c-	Sat Apr 13 15:24:01 1991
***************
*** 11,17 ****
  #include "../h/mh.h"
  #include <stdio.h>
  
! #if defined (BSD42)  || defined (hpux) || defined (_AIX)
  #include <errno.h>
  #include <sys/param.h>
  #include <sys/file.h>
--- 11,17 ----
  #include "../h/mh.h"
  #include <stdio.h>
  
! #if defined (BSD42)  || defined (hpux)
  #include <errno.h>
  #include <sys/param.h>
  #include <sys/file.h>
***************
*** 28,34 ****
  {
      int     pid;
      register char  *cp;
! #if defined (BSD42)  || defined (hpux) || defined (SYS5DIR)
      register char  *c;
      char path[MAXPATHLEN];
  #endif BSD42
--- 28,34 ----
  {
      int     pid;
      register char  *cp;
! #if defined (BSD42)  || defined (hpux)
      register char  *c;
      char path[MAXPATHLEN];
  #endif BSD42
*** ./uip/aliasbr.c	Sat Apr 13 15:42:07 1991
--- ./uip/aliasbr.c-	Sat Apr 13 15:41:20 1991
***************
*** 152,162 ****
  	    case ':': 		/* comment */
  	    case ';': 
  	    case '#':
- #ifdef _AIX
- 	    case '\0': 
- #else
  	    case NULL: 
- #endif
  		continue;
  	}
  
--- 152,158 ----
***************
*** 184,194 ****
  	}
  
  	switch (*(pp = scanp (ap))) {
- #ifdef _AIX
- 	    case '\0': 		/* EOL */
- #else
  	    case NULL: 		/* EOL */
- #endif
  		(void) fclose (fp);
  		return AK_ERROR;
  
--- 180,186 ----
*** ./uip/msh.c	Sat Apr 13 15:46:34 1991
--- ./uip/msh.c-	Sat Apr 13 15:46:08 1991
***************
*** 1562,1572 ****
  	    case '"': 
  		for (;;) {
  		    switch (c = *cp++) {
- #ifdef _AIX
- 			case '\0': 
- #else
  			case NULL: 
- #endif
  			    padvise (NULLCP, "unmatched \"");
  			    return NOTOK;
  			case '"': 
--- 1562,1568 ----
*** ./zotnet/bboards/getbbent.c	Sat Apr 13 15:35:39 1991
--- ./zotnet/bboards/getbbent.c-	Sat Apr 13 15:34:52 1991
***************
*** 646,656 ****
  		    hp = item;
  		    break;
  
- #ifdef _AIX
- 		case '\0': 
- #else
  		case NULL: 
- #endif
  		    if ((cp = rindex (bb -> bb_file, '/')) == NULL || *++cp == NULL)
  			(void) strcpy (prf, ""), cp = bb -> bb_file;
  		    else
--- 646,652 ----
*** ./zotnet/mf/mf.c	Sat Apr 13 15:39:46 1991
--- ./zotnet/mf/mf.c-	Sat Apr 13 15:37:29 1991
***************
*** 865,875 ****
      if (c == '(')
  	for (*bp++ = c, i = 0;;)
  	    switch (c = *cp++) {
- #ifdef _AIX
- 		case '\0': 
- #else
  		case NULL: 
- #endif
  		    cp = NULL;
  		    return (last_lex = LX_ERR);
  		case QUOTE: 
--- 865,871 ----
***************
*** 900,910 ****
      if (c == '"')
  	for (*bp++ = c;;)
  	    switch (c = *cp++) {
- #ifdef _AIX
- 		case '\0': 
- #else
  		case NULL: 
- #endif
  		    cp = NULL;
  		    return (last_lex = LX_ERR);
  		case QUOTE: 
--- 896,902 ----
***************
*** 925,935 ****
      if (c == '[')
  	for (*bp++ = c;;)
  	    switch (c = *cp++) {
- #ifdef _AIX
- 		case '\0': 
- #else
  		case NULL: 
- #endif
  		    cp = NULL;
  		    return (last_lex = LX_ERR);
  		case QUOTE: 
--- 917,923 ----
***************
*** 1032,1042 ****
  		pp = NULL;
  		return DONE;
  
- #ifdef _AIX
- 	    case '\0': 
- #else
  	    case NULL: 
- #endif
  		continue;
  
  	    case '\n': 
--- 1020,1026 ----
*** ./zotnet/mts/mts.c	Sat Apr 13 15:33:30 1991
--- ./zotnet/mts/mts.c-	Sat Apr 13 15:32:54 1991
***************
*** 43,51 ****
  #define	rindex	strrchr
  #endif	SYS5
  
- #ifndef _AIX
  char   *index (), *malloc (), *mktemp (), *rindex (), *strcpy ();
- #endif
  
  struct passwd  *getpwuid ();
  
--- 43,49 ----
***************
*** 294,304 ****
  		grot ('t', '\t');
  #undef	grot
  
- #ifdef _AIX
- 		case '\0': s--;
- #else
  		case NULL: s--;
- #endif
  		case QUOTE: 
  		    *bp = QUOTE;
  		    break;
--- 292,298 ----


-- 
Douglas L. Acker

Western Geophysical Exploration Products
Systems Engineer

Email (internal):  acker                Phone:  713-964-6128
      (Internet):  acker@wg2.waii.com