delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/1999/11/25/04:53:38

Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie DOT com AT sourceware DOT cygnus DOT com>
List-Subscribe: <mailto:cygwin-subscribe AT sourceware DOT cygnus DOT com>
List-Archive: <http://sourceware.cygnus.com/ml/cygwin/>
List-Post: <mailto:cygwin AT sourceware DOT cygnus DOT com>
List-Help: <mailto:cygwin-help AT sourceware DOT cygnus DOT com>, <http://sourceware.cygnus.com/ml/#faqs>
Sender: cygwin-owner AT sourceware DOT cygnus DOT com
Delivered-To: mailing list cygwin AT sourceware DOT cygnus DOT com
X-Authentication-Warning: hp2.xraylith.wisc.edu: khan owned process doing -bs
Date: Thu, 25 Nov 1999 03:52:48 -0600 (CST)
From: Mumit Khan <khan AT NanoTech DOT Wisc DOT EDU>
To: cygwin AT sourceware DOT cygnus DOT com
Subject: Bind, sendmail etc -- some porting news
Message-ID: <Pine.HPP.3.96.991125033356.10034I-100000@hp2.xraylith.wisc.edu>
MIME-Version: 1.0

I've seen a few queries regarding ports of sendmail (and bind is 
related[1]), so it's probably a good time to dig out my bind and
sendmail changes. I took a shot a while back with bind-8.2.2 and
sendmail-8.9.3, and had it mostly working (don't take "working"
too literally ;-). 

Basic sendmail was easy, but I need to go through the code to get
the uid/gid etc fixed (haven't looked at Sergey's changes, so it's
probably already there); for bind, I started with Sergey's changes,
made quite a few changes, and the whole thing actually built. I 
used a Cygwin DLL without AF_UNIX support, but if you use a DLL
that supports AF_UNIX, you can always enable AF_UNIX by editing 
the port/cygwin/include/port_before.h file.

Sendmail port is reasonably clean -- it uses the BuildTools/OS/cygwin 
and you build it just like you would on a normal Unix box. There were
two #ifdef __CYGWIN__ -- one to include sysmacros.h to get major and
minor macros, and other one to work around a bug I never found (see
the first problem below).

What worked when I last tried:

- I could send mail using command line or a mail user agent. I used a 
  trivial mail client that passed the args onto sendmail. I don't
  remember if I tried to use Pine (I have a Cygwin port on my ftp
  site ftp://ftp.xraylith.wisc.edu/pub/khan/gnu-win32/cygwin/ports/),
  but should work in theory.
- I *think* I could get it accept mail as well, but not sure.

Problems I remember:
  
- Something gets corrupted and sendmail dies at the first putenv
  call (from main->setuserenv("AGENT","sendmail"). I have no idea
  why. I was using original B20.1 DLL, so should probably try a
  newer one. For now, I just disabled the putenv for CYGWIN, which
  means if sendmail forks, it may not work correctly.
- Had some problems with sendmail + bind, but I believe I know 
  what it was (I think I forgot to recompile parts of sendmail with
  -DNAMED_BIND=1 after I added the resolver support).

- resolver insisted on using 0.0.0.0 as the first server even if
  I had a /etc/resolv.conf that said otherwise.
- I never bothered to build named and named-xfer, and should be 
  reasonably simple after I #ifdef the support (or lack thereof)
  for AF_UNIX.

Let me know if anyone wants to play with this and I'll bundle up
the patches. It'll take a few days, so have patience.

Regards,
Mumit

[1] If you don't have a resolver library, and unless you want to add
winsock code, MX lookups won't work in sendmail.



--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe AT sourceware DOT cygnus DOT com

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019