top image
home  /  pages  /  tech tips  /  contact about

How to compile mutt on Mac OS X

Problem

MacPorts has mutt, but it lacks patches you want. Once you start compiling it yourself (including --with-hcache), configure fails on BerkeleyDB, saying "configure: error: You need Tokyo Cabinet, QDBM, GDBM or Berkeley DB4 for hcache".

Keywords

mutt, mac os x, macports, berkeleydb, bdb, db47, --with-hcache.

Solution

With many thanks to Joshua Herring's web page on this topic. However, whereas he choses to compile BerkeleyDB from scratch, I prefer to install db47 using MacPorts. The key to making the configure errors go away is including CPPFLAGS and LDFLAGS on the command line when configuring mutt.
$ CPPFLAGS=-I/opt/local/include/ LDFLAGS=-L/opt/local/lib/ ./configure ...
URL: http://thomer.com/howtos/mutt_on_mac.html
Copyright © 1994-2011 by Thomer M. Gil
Updated: 2010/12/14