*BSD News Article 23064


Return to BSD News archive

Path: sserve!newshost.anu.edu.au!munnari.oz.au!news.Hawaii.Edu!ames!agate!spool.mu.edu!caen!destroyer!news.itd.umich.edu!altitude
From: altitude@css.itd.umich.edu (Alex Tang)
Newsgroups: comp.os.386bsd.apps
Subject: PINE3.87 ported...revisited
Date: 31 Oct 1993 00:19:20 GMT
Organization: University of Michigan ITD/User Services
Lines: 168
Message-ID: <2av0a8$ier@terminator.rs.itd.umich.edu>
NNTP-Posting-Host: stimpy.css.itd.umich.edu
X-Newsreader: TIN [version 1.2 PL1]

Hi.  I posted a little while back that I got pine3.87 ported.  Well, I found
out that there were a couple bugs...like the sent mail would get vaporized
before it got sent.  

I've got it recompiled and all works well now.  Thanx to Jin Mazumdar for the
patch to get the sending mail thing working.  

Here's a patch.  It patches all the necessary files for it to compile without
a hitch.  run the patch out of the pine3.87 directory.

oh yeah, do "build bsi" too.

Have fun...alex...

--
Alex Tang  ---  ALTITUDE@UMICH.EDU...USERW00Y@UMICHUM.BITNET
-----------+    U of M, SNRE: Student and Computer Consultant II,
PGP on req.|    ITD/CSS Consultant, Short asian with long hair :)

---start patch here....

*** ./imap/ANSI/c-client/makefile.bsi.old	Fri Oct 29 21:01:57 1993
--- ./imap/ANSI/c-client/makefile.bsi	Fri Oct 29 21:02:33 1993
***************
*** 31,37 ****
  RSH = rsh
  RSHPATH = /usr/ucb/rsh
  OSDEFS = -DRSH=\"$(RSH)\" -DRSHPATH=\"$(RSHPATH)\"
! CFLAGS = -g -O -pipe
  LDFLAGS =
  
  mtest: mtest.o c-client.a
--- 31,37 ----
  RSH = rsh
  RSHPATH = /usr/ucb/rsh
  OSDEFS = -DRSH=\"$(RSH)\" -DRSHPATH=\"$(RSHPATH)\"
! CFLAGS = -g -O -pipe -traditional
  LDFLAGS =
  
  mtest: mtest.o c-client.a
*** ./pico/os_unix.h.old	Mon Oct 25 16:58:20 1993
--- ./pico/os_unix.h 	Mon Oct 25 16:58:37 1993
***************
*** 102,108 ****
  #define QcompType const void
  #else
  #define	QSType	  int
! #define QcompType void
  #endif
  
  /*
--- 102,108 ----
  #define QcompType const void
  #else
  #define	QSType	  int
! #define QcompType const void
  #endif
  
  /*
*** ./pico/makefile.bsi.old	Fri Oct 29 16:26:18 1993
--- ./pico/makefile.bsi	Fri Oct 29 16:26:45 1993
***************
*** 44,50 ****
  #for normal build
  #DASHO=		-O
  
! CFLAGS=		-DBSDI -DJOB_CONTROL -DANSI
  
  # switches for library building
  LIBCMD=		ar
--- 44,50 ----
  #for normal build
  #DASHO=		-O
  
! CFLAGS=		-DBSDI -DJOB_CONTROL -DANSI -traditional
  
  # switches for library building
  LIBCMD=		ar
*** ./pine/makefile.bsi.old	Sat Oct 30 15:14:44 1993
--- ./pine/makefile.bsi	Sat Oct 30 15:15:24 1993
***************
*** 57,63 ****
  RM=          rm -f
  LN=          ln -s
  MAKE=        make
! OPTIMIZE=    -O
  PROFILE=     # -pg
  DEBUG=       -g -DDEBUG
  
--- 57,63 ----
  RM=          rm -f
  LN=          ln -s
  MAKE=        make
! OPTIMIZE=    -O -traditional
  PROFILE=     # -pg
  DEBUG=       -g -DDEBUG
  
***************
*** 135,141 ****
  	$(RM) os.c
  	$(LN) osdep/os-bsi.c os.c
  
! osdep/os-nxt.c:	osdep/bld_path osdep/canacces osdep/canonicl \
  		osdep/chnge_pw osdep/coredump osdep/creatdir \
  		osdep/diskquot.non osdep/domnames osdep/err_desc \
  		osdep/expnfldr osdep/fgetpos osdep/filesize osdep/fltrname \
--- 135,141 ----
  	$(RM) os.c
  	$(LN) osdep/os-bsi.c os.c
  
! osdep/os-bsi.c:	osdep/bld_path osdep/canacces osdep/canonicl \
  		osdep/chnge_pw osdep/coredump osdep/creatdir \
  		osdep/diskquot.non osdep/domnames osdep/err_desc \
  		osdep/expnfldr osdep/fgetpos osdep/filesize osdep/fltrname \


*** ./pine/osdep/os-bsi.h.old	Sat Oct 30 17:30:17 1993
--- ./pine/osdep/os-bsi.h	Sat Oct 30 17:31:17 1993
***************
*** 206,214 ****
  
  
  /*----------------- time.h ---------------------------------------------*/
! #include <time.h>
  /* plain time.h isn't enough on some systems */
! /* #include <sys/time.h>  /* For struct timeval usually in time.h */ 
  
  
  
--- 206,214 ----
  
  
  /*----------------- time.h ---------------------------------------------*/
! /*#include <time.h>*/
  /* plain time.h isn't enough on some systems */
! #include <sys/time.h>  /* For struct timeval usually in time.h */ 
  
  
  
*** ./pine/send.c	Thu Oct  7 20:55:45 1993
--- ./pine/send.c.orig	Fri Oct 29 15:56:48 1993
***************
*** 1463,1469 ****
--- 1463,1486 ----
      if(rv < 0)
        goto io_error;
  
+ /*
      sprintf(mail_cmd, "(( %s %s ; /bin/rm -f %s) & )< %s",
+             SENDMAIL, SENDMAILFLAGS, tmpfile, tmpfile);
+ 
+     sprintf(mail_cmd, "(( %s %s ; rm -rf %s) & )< %s",
+             SENDMAIL, SENDMAILFLAGS, tmpfile, tmpfile);
+     -- 930817
+     -- Jin Mazumdar
+     -- Dept. of Math. and C. S.
+     -- SUNY College at Fredonia
+     -- mazumdar@mary.cs.fredonia.edu
+ 
+     386BSD does not like the above.  It probably deletes the file before 
+     giving it to sendmail therefore all sent mail is lost.  A minor fix
+     follows :-
+ */
+ 
+     sprintf(mail_cmd, "(( %s %s ; rm -rf %s) < %s ) &",
              SENDMAIL, SENDMAILFLAGS, tmpfile, tmpfile);
  
      dprint(6, (debugfile, "Send command \"%s\"\n", mail_cmd));