Comparisons with other build tools
This page provides more detailed comparisons with other existing tools to better explain the motivation behind creating Yet Another Build Tool.
As stated on the home page,
- Bakefile is cross-platform, cross-compiler native makefiles generator. It takes compiler-independent description of build tasks as input and generates native makefile (autoconf's Makefile.in, Visual C++ project, bcc makefile etc.).
- Bakefile's task is to generate native makefiles, so that people can keep using their favorite tools. There are other cross-platform make solutions, but they either aren't native and require the user to use unfamiliar tools (Boost.Build) or they are too limited (qmake).
Boost.Build / bjam
The synopsis on the Boost.Build homepage does a good job of describing it. It says the key features are:
- A simple target description language
- Build with your choice (or multiple) toolsets from a single command invocation
- Build your choice of basic variants (e.g. debug, release, profile...) and subvariant modifications (e.g. inlining off) from a single command invocation
- "Feature Normalization" allows target configurations to be described independently from the toolset used
- Modular toolset description files allow build instructions for different toolsets to be described independently
- Multiple subproject support
- Automatic building of subproject dependencies
CMake
Of this list, CMake most resembles Bakefile due to CMake's generation of pseduo-native project files.
In fact, CMake is a hybrid system, the native projects give the developer a certain level of comfort; however, the native project calls CMake--thus CMake must be installed on the build machine--to evaluate dependency state and build the targets. Additionally, CMake generates projects with absolute paths. Bakefile differs here being unnecessary after generating the project and paths are relative: these features allows Bakefile generated project files to be distributed to developers that do not have or use Bakefile.
Another difference: CMake can only generate projects valid on the current platform. Bakefile generates projects regardless of platform. (CMake can not generate an Xcode project on an MSWin platform; however, Bakefile can.)
CMake comes with some additional, useful tools that help to automate testing (CTest) and installs (CPack).
CMake also does (auto-)configuration (like Autoconf), which Bakefile doesn't.
As of this writing, CMake seems to support more project types; however, Bakefile seems easier to extend to new project types.
CMake (v2.4) and Bakefile (v0.2.3) seem very similar in maturity and functionality. While CMake may have more active developers, Bakefile seems easier to debug and extend.
CMake uses a shell or macro like language to describe how to build a project. Bakefile uses XML and some python. Neither necessarily provides an advantage over the other.
CMake's hybrid system adds a level of obscurity to the build process that is off putting to some developers. Bakefile's generation of pure native project files adds no such obscurity. (Example: a developer unfamiliar with CMake might have problems determining why a compilation failed when using a toolchain he was otherwise intimately familiar with.)
Scons
SCons is more a replacement for the venerable 'make' than a full build system. It allows you to define targets and dependencies and has some basic ability to invoke various compilers and other tools in a platform-independent way. The main advantage is that it is written in Python, so you have the full power of a modern programming language at your fingertips to solve build problems.
It is sometimes referred to as more of a "BuildMaster?'s Tool" than a build system. That is, if you're job is to create a build system, SCons can be a good platform to build your system on top of. But if you just want something that takes care of the details right out of the box, you may be disappointed.
qmake
Trolltech's intro to qmake:
- qmake is a tool created by Trolltech to write makefiles for different compilers and platforms.
- Writing makefiles by hand can be difficult and error prone, especially if several makefiles are required for different compiler and platform combinations. With qmake, developers create a simple single 'project' file and run qmake to generate the appropriate makefiles. qmake takes care of all the compiler and platform dependencies, freeing developers to focus on their code. Trolltech uses qmake as the primary build tool for the Qt library, and for the tools supplied with Qt.
- qmake also takes care of Qt's special requirements, automatically including build rules for moc and uic.
So qmake generates native makefiles, like bakefile. It is, however, primarily targeted at Qt and is not that usable for non-Qt use. It has very limited expressive power, too, it's not usable for generating complicated makefiles.
Apache Ant
Uses XML like bakefile... (VS: that's a real similarity indeed...)