Category Archives: build systems

Upgrading kdevelop’s valgrind plugin to KF5

I’ve started to upgrade KDevelop’s valgrind plugin ( kdev-valgrind ) to KF5 so that the KF5 version of KDevelop can use it.
In short ‘Valgrind’ is a dynamic analysis tool that allows you to check your programs for memory errors, threading errors in runtime. It also allows you to cache and call profile. So it’s very useful. Without such tools it would be almost impossible to detect and debug these kinds of errors. ( other than reading all the code and spotting it of course )

Kdev-valgrind is a plugin for KDevelop, that integrates some of this functionality into KDevelop. I did not create the plugin I am just merely updating it, because it is very very important to have!

It took me some time, but finally I can compile and load it as the screenshots below will show. All I had to do was basically update it’s cmake project file with the KF5 libraries instead of the KDE4 ones, change some class/call references ( ok, lots of them ), and move away from the deprecated KDE widgets, in favor of the Qt ones. Very soon I will test it througly and then submit my changes for review to the KDevelop guys.




Checkinstall is awesome

Developers on Unix or Unix-like Operating Systems, like Linux, typically build and install software packages with the make system. First you issue the command ‘make’ to build the package, then issue ‘make install’. Sadly this often means you end up polluting your system with the parts of that package, as often the maintainers don’t provide an uninstall target.

Fortunately for us, there’s a solution to this problem, and that is a little tool called ‘checkinstall’:

Basically it builds the install target in the Makefile ( which copies the files to the system ), packages the files, and install the package, so if you no longer want the files on your system, instead of having to look around for it’s parts and manually cleaning up, you can just remove the package. It also support the Debian, Red Hat and Slackware types of packages.
Isn’t it wonderful?

A word of warning:
Checkinstall strips the binaries by default, so when packaging debug binaries, the user should explicitly specify that they DON’T want them stripped! Keep that in mind!