How to build Thunderbird (Win32) with Visual C++ 2005 Express

After having a bunch of trouble (missing ml.exe, missing manifests, missing dlls, broken spellcheck) building Thunderbird 2.0b2 (to add in a trivial fix for bcc hname parsing in mailto URIs), I found a simple way to build Thunderbird. Grab the latest and greatest off the trunk instead.

Set up the build enviroment

Get the source:

  • Double-left-click on "c:\mozilla-build\start-msvc8.bat".
  • Enter "cd c:"
  • Enter "cvs -d :pserver:anonymous@cvs-mirror.mozilla.org:/cvsroot co mozilla/client.mk"
  • Enter "cd mozilla"
  • Check the Thunderbird trunk status before continuing.
  • Enter "make -f client.mk checkout MOZ_CO_PROJECT=mail" to download the source.

Generate the Makefiles

  • Enter "./configure –enable-application=mail –enable-static –disable-shared –enable-optimize=-Zc:wchar_t-"

Build Thunderbird

  • Enter "make" and sit back while it builds.

If you get lucky, it will build successfully and all the Thunderbird executables will be in the "c:\mozilla\dist\bin". You can then copy the content of the folder somewhere and run thunderbird.exe.

There are some extra steps involved in setting up the version information, branding, the installer and adding the redistributable runtime dlls and manifest, but haven't went there. (I disabled updates in Thunderbird though just in case the update checker thinks the build is old.)

Building process
Having access to the Thunderbird source so I can fix things (the fix worked btw) is really cool. However, building it is still a pain (much easier than building gaim and all its dependencies in Debian woody though). It's not automated enough and build instructions are even more vague than the above. Of course, Thunderbird is a beast.

I'm also not too happy about the dependency on Microsoft's compiler for Win32 builds. I'd really like to be able to *just as easily* use Mingw (plus MSYS for ./configure) to build Thunderbird, but oh well.

I also got a broken pipe cvs error. I didn't realize that I could ignore it at first, so I kept redownloading the source. Turns out, the error happens after everything is downloaded and it can be ignored.

2 Replies to “How to build Thunderbird (Win32) with Visual C++ 2005 Express”

  1. Anonymous writes:This is very useful and worked until the final step. Did any body see any problems by following the above steps?

  2. Try refetching the src from scratch and try again.I’m still not very good at building Thundebird though. Just get lucky sometimes. 🙂

Leave a Reply

Your email address will not be published. Required fields are marked *