in Computer setup

How to install kcachegrind / qcachegrind on Mac OSX

Installing kcachegrind via macports takes a long time because it has to build KDE, as well. An alternative faster way is described below.
* download Qt binary and install it
* download and install graphviz; I used brew install graphviz
* fix default graphviz location by symlinking to a place where cachegrind will find it sudo ln -s /usr/local/bin/dot /usr/bin/dot
* qmake -spec 'macx-g++'; make
* copy generated to your Applications folder
* enjoy!

Join the discussion


  1. If you’re using brew, here are the steps I did:

    a. brew install qt5 qt valgrind graphviz
    b. brew reinstall qcachegrind –with-graphviz
    c. brew linkapps qt qcachegrind
    sudo ln -s /usr/local/bin/dot /usr/bin/dot
    download kcachegrind
    a. wget
    b. tar -xvf kcachegrind-0.7.4.tar.gz
    install kcachegrind
    a. cd kcachegrind-0.7.4/
    b. qmake -spec ‘macx-g++’; make
    c. open finder and copy qcachegrind/ to /Applications