Dovecot is an open source IMAP and POP3 server for Linux/UNIX-like systems, written with security primarily in mind. Dovecot is an excellent choice for both small and large installations. It’s fast, simple to set up, requires no special administration and it uses very little memory.
First you need to download the latest version, which you can find on the download page of the Dovecot site. Unpack the Dovecot source into a directory, use the Terminal and ‘cd’ into the directory where you unpacked it. Issue the following commands as a normal user:
./configure --with-mysql --with-ssl=openssl
This will create the appropriate Makefile for compiling dovecot with support for MySQL and SSL. If that all went without problems then follow with:
If that also went without problems you are ready for installing:
sudo make install