Sunday, July 09, 2006

CMake -> Jam

Today, I switched the build systems of peixes/acharya and the IMLI libraries to Jam. Previously, I used autotools for the IMLI libs and CMake for peixes. CMake is pretty nice and it has recently been adopted by the KDE and Scribus projects. From a CMake project, project files can be created for KDevelop and Visual Studio. However, I use neither of them. I use Emacs + CEDET + ECB for my coding tasks at home. I use the Mingw toolset on Windoze though I want to be able to build peixes using other toolsets like OpenWatcom and DigitalMars C++ .

Using Jam makes this quite easy. The version I'm using is Freetype's Jam which is a slightly enhanced version of the Perforce one. Then there is Boost's version of Jam which is based on Freetype's Jam but heavily modified to suit large projects.

Some of the advantages of Jam is listed here.

The other nice feature of Jam is the default collection of rules and actions are compiled into the executable itself which makes it very compact without the need for having a dozen files in /usr/share .

I've also switched the IMLI lib to Jam from autotools. Although the autotools does a lot more than just build, it is too heavy for such a simple library. The code is plain ANSI C and does not use any platform specific extensions so there is no need for "configuring" the build. In fact, the size of the configure script is twice as that of all the library code put together.

Next step is to try building with all the available toolsets.

1 comments:

sqz said...

nice...I was just looking for some comparision between jam and cmake...looks like I'm gonna try jam first :)