fastdep

Changelog

User manual

Latest release : 0.16 (29 Oct 2003)

fastdep is (will be) a fast dependency generator for C/C++ files. Latest version is in fastdep.tar.gz (http download; 68k), or if you wish the same file with version information in the filename is fastdep-0.16.tar.gz. This version does not (yet) evaluate sizeof() in #if. Unoptimized fastdep is 10 times faster than gcc.

Sadly I can no longer provide RPMs of fastdep anymore because I don't have an RPM based distribution. The spec file to generate them is still included in the regular tar.gz, so it should be easy to make one for yourself.

The most recent release in RPM format is fastdep-0.15-1.src.rpm (http download; 60k). It's my first self-made RPM so let me know if you had any problems with it. To celebrate this fact here is a binary rpm for Mandrake 8.2/i586 as fastdep-0.15-1.i586.rpm (http download; 65k). As is usual with free software, there is no guarantee these files will work, it is not even guaranteed they will not harm your system, although I've tried to double check everything (and they work for me).

Zenaan Harkness contributes a Debian package. You can find it here.

Note : I don't have access to a debian system but am looking for someone who can make a .deb package of fastdep. It shouldn't be too hard. If you feel like it, please contact me at bvh-cplusplus@irule.be.

More information on using fastdep.

Why?

I like my Makefiles to regenerate dependency information automatically. The suggestion in the GNU make info file however uses gcc -MM on each (possibly) changed file even before compilation starts. Unfortunatly gcc is really slow when generating dependencies (it is slow when compiling too, but at least then it is doing real work). Since I develop on an old computer this is unacceptable. For some of my projects just generating the dependencies takes over 1 minute with gcc. Thus I wrote a fast dependency generator, fastdep. Now, generating dependencies is a matter of a few seconds.

How?

Written in C++ with a handoptimized parser for just the preproccesor tokens, it's no surprise fastdep is fast. Besides that it processes multiple source files at once. When doing so fastdep parses every header file exactly one time and keeps an in memory structure of it. Those structures are then used to generate dependency information for all files at once. This is a real improvement for C++ projects which generally have one include file for every class. A more traditional generator needs to parse these files multiple times.

Other free software by me.

Author Bart Vanhauwaert (bvh-cplusplus@irule.be)