Home | History | Documents | Software | Feedback | Disclaimer

Building qmail on FreeBSD

Described here is the procedure I used for building qmail from the FreeBSD port tree. This is how I would install qmail on a FreeBSD machine before I started using netqmail.

The ports tree includes a number of qmail variants in the ports/mail directory. I started with the vanilla ports/mail/qmail port for my installs and then added the particular patches that I wanted.

  1. First I ran 'make' in the /usr/ports/mail/qmail directory to download and unpack the qmail source tree. This step also builds qmail.
  2. I then copied the patch files into /usr/ports/mail/qmail/work/qmail-1.03 and from that directory ran 'patch -F 3 < starttls-2way-auth-20040725.patch' to apply the first patch. The -F switch increases patch’s fuzz factor and is necessary when applying the latest starttls-2way-auth patch to qmail 1.03.
  3. I used 'patch < qregex-20040725.patch' to apply the second patch. This patch didn’t apply cleanly because it collided with some changes made by the first one. I used the *.rej files generated by patch to find the parts that failed and applied them manually.
  4. From /usr/ports/mail/qmail/work/qmail-1.03 I ran 'make' again to rebuild qmail.
  5. From the /usr/ports/mail/qmail directory, I ran 'make install' then 'make disable-sendmail' to install qmail and make it the default MTA.

Copyright © 2004 Andrew St. Jean Last update Oct. 08, 2005
Apache Webserver FreeBSD