Compile Claws Mail on Mac OS X

I use the wonderful Claws Mail on my linux boxes at work and home. However, I run Mac OS X on my old ibook G4 laptop. I’v used Mail.App, which was not bad, then switched to Gnu Mail, better.

But I really miss Claws on my ibook. That’s why I have decided to try to compile it. I don’t tweak with source compilation often, as I’m a script languages oriented guy. But let’s try.

Part 1 : compile against Xorg

First of all, Claws Mail needs gtk-2.6, and a working POSIX building environment. I decided to go for Fink, as I used it a bit in the past.

  • install fink
  • download and untar Claws Mail sources from there.
  • the way to go is to run the ./configure script, then using fink, install missing packages needed for the compilation. Some needed software are available only in unstable, so you need to enable unstable packages in the fink pref. This gave me :
    • make (binary)
    • pkgconfig (binary)
    • xorg (binary)
    • glib2-dev (compiled from source)
    • glib (not the version 2, needed for glib-config)
    • gtk2-dev : you’ll need version > 2.6,
  • Claws Mail needs etpan, but there is no fink package. Darwin Ports provides one, but let’s compile it from the sources directly. Get the tarball at etpan homepage
  • compile libetpan with : ./configure –prefix=/sw && make && sudo make install
  • If you need the SSL support (fot IMAPS for instance), install openssl-dev, via Fink, but before that, make sure you enable “Use unstable cryptography packages” in the Fink preferences
  • you may want to install/compile other library if you need them in claws. Use ./configure –help to get the list of available options.

The configure script doesn’t look for the gtk2, glib and other includes in the right location. one solution is to make symlinks, but wwp proposed adding the include dires in the CFLAGS env var. The configure script doesn’t have the options to add includedirs). You might have to add more include dirs depending on your options and lib versions. Check config.log if configure fails

Now run the configure :
CFLAGS="$CFLAGS -I/sw/include/glib-2.0 -I/sw/lib/glib-2.0 -I/sw/include/gtk+-2.0 -I/sw/lib/gtk+-2.0" ./configure --prefix=/sw --disable-spamassassin-plugin --disable-dillo-viewer-plugin --disable-trayicon-plugin --disable-bogofilter-plugin

If the ./configure runs well, it’ll output this


claws-mail 2.9.1
JPilot : no
LDAP : yes
OpenSSL : no
iconv : yes
compface : no
IPv6 : yes
GNU/aspell : no
IMAP4 : yes
Crash dialog : no
Libgnomeprint : no
LibSM : no
Manual : yes
Plugins :
Maemo build : no
Config dir : .claws-mail
The binary will be installed in /sw/bin

Now let’s buid Claws :

make

And install it :

sudo make install

Well that was the first part. Now if everything compiled correctly, you should be able to run claws-mail. How? You first need to start X, and from within, start claws-mail. As we installed the fink X server, you have to run startx, and within an xterm, run claws-mail. Success! Claws Mail will appear.

In the next post we’ll see how to compile against the Apple X11 server.


claws on mac OS X

2 thoughts on “Compile Claws Mail on Mac OS X”

  1. Cool banana Damien but whats wrong with using Emacs+Gnus on MaxOSX ? Wat’s better inside Claws-Mail

    And the last question is, where is “madame girard” ?

  2. The question could be, what’s better inside Emacs+Gnus? W/ Claws Mail, you feel better like after having stopped smoking ;-).

Comments are closed.