Building the Tracy Profiler GUI on Linux

03/02/2024

How to build the Tracy Profiler GUI (data analyzer/server) under Linux (Ubuntu 20.04) from source.

Tested on Ubuntu 20.04 (on Ubuntu 22.04 every dependency can be installed through apt)

Clone the project:

git clone https://github.com/wolfpld/tracy.git
cd tracy

Switch to the commit tagged with the latest released version (in my case v0.10):

git checkout v0.10

If you don’t alreay have make installed, you should install it by running:

sudo apt install build-essential

Then install the required dependencies:

sudo apt install libdbus-1-dev libfreetype-dev libtbb-dev

For Wayland:

sudo apt install libxkbcommon-dev libwayland-dev libglvnd-dev

For X11:

Afterwards always run make LEGACY=1 instead of just make

sudo apt install libglfw3-dev

Building capstone from source

Building and installing capstone (a required dependency of Tracy):

git clone https://github.com/capstone-engine/capstone.git

Switch to the latest tagged release, in my case 5.0.1:

git checkout 5.0.1

To build:

./make.sh

And then install:

sudo ./make.sh install

Then, add the directory where you downloaded capstone to the $PKG_CONFIG_PATH environment variable:

export PKG_CONFIG_PATH="/home/path/to/capstone"

In the same terminal, go to the directory profiler/build/unix, inside the tracy repository, and run:

make

If you are building with wayland support, or:

make LEGACY=1

If you are building with X11 support.

If everything goes well, there sould be an executable called Tracy-release inside the same directory where make got ran.

All posts
davespace.xyz – 2024