Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!wuarchive!uunet!netxcom!elw From: elw@netxcom.netx.com (Edwin Wiles) Newsgroups: comp.mail.sendmail Subject: Re: Sample sendmail.cf Summary: Use Ease! Message-ID: <176@netxcom.netx.com> Date: 5 May 91 23:41:28 GMT References: Organization: NetExpress Inc., Vienna, VA, USA Lines: 48 In article dsurber@nasamail.nasa.gov writes: >In evan@plxsun.uucp (Evan Bigall) writes: >>I took their samples and massaged it into something that basically >>works (yes there are still problems). > >Karl Kleinpaste has developed a generic sendmail.cf file and made it >available for ftp from tut.cis.ohio-state.edu as pub/sendmail/Tut:sendmail.cf. Doug, Evan, And anyone else out there strugling with sendmail.cf files. If you've already got a sendmail.cf that mostly works, lay hands on the "ease" program and use it. It makes understanding and modifying sendmail.cf files MUCH easier. (Check your local comp.sources.unix archives, in volume 17, for a package named "ease2". DO NOT ask me for source or binaries!) Unfortunately, it is a bit of a bear to get running, mainly due to two problems: 1) The "cfc" program, which takes an existing sendmail.cf file and does *most* of the translation work into "ease", will dump garbage into the output (including nulls) if there are any syntactical errors in the sendmail.cf file. I was initial unaware of this, and presumed it was an error in the cfc code, having heard that EASE had several problems. I later discovered (after much headpounding) that the .cf file was missing "$" in front of ":", in several locations. After fixing that, the cfc output was fine. 2) The "et" (ease translator) program makes use of a YACC generated parser that uses "free()" to release memory apparently allocated durring translation. Unfortunately, on my machine (a 386 IBM PC clone, running SCO Xenix), an attempt to free a null pointer will get you a memory fault core dump. I fixed that by substituting "Xfree(...)" for all occurances of "free(...)" in the parser source, and defining: #define Xfree( a ) { if ( a != NULL ) free ( a ); } After fixing the above two problems, I discovered a number of errors in our sendmail.cf file, fixed those, did a lot more work getting the EASE file to compile without errors, and then went about figuring out how to twist it to make it do what we needed here. From my prior experience trying to do this with just sendmail.cf files to look at, I can honestly say that it's a lot easier with EASE. Enjoy! Edwin (elw@netx.com)