Tracy ported to the zig build system
  • C++ 91.9%
  • C 3.4%
  • TeX 2.5%
  • Python 1.2%
  • Fortran 0.4%
  • Other 0.4%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
2026-10-14 23:34:45 +02:00
.github move to the Zig build System 2026-10-14 22:47:15 +02:00
.omp/skills/tracy-gui-verify Refine GUI verify skill name and description. 2026-08-22 13:07:05 +02:00
capture/src move to the Zig build System 2026-10-14 22:47:15 +02:00
cmake move to the Zig build System 2026-10-14 22:47:15 +02:00
csvexport/src move to the Zig build System 2026-10-14 22:47:15 +02:00
doc Cleanup. 2024-05-25 00:16:29 +02:00
examples Use section categories in dyna example. 2026-07-14 19:12:59 +02:00
extra feat(mcp): migrate to MCP Python SDK v2 2026-08-21 20:42:28 -07:00
icon Minimize SVG files. 2022-04-16 00:13:10 +02:00
import/src move to the Zig build System 2026-10-14 22:47:15 +02:00
include/glad move to the Zig build System 2026-10-14 22:47:15 +02:00
manual Mention that statistics range limit also affects source view. 2026-08-22 12:41:29 +02:00
merge/src move to the Zig build System 2026-10-14 22:47:15 +02:00
monitor/src move to the Zig build System 2026-10-14 22:47:15 +02:00
profiler move to the Zig build System 2026-10-14 22:47:15 +02:00
public move to the Zig build System 2026-10-14 22:47:15 +02:00
python Derive meson and python package versions from TracyVersion.hpp. 2026-08-21 23:05:58 +02:00
server move to the Zig build System 2026-10-14 22:47:15 +02:00
tests move to the Zig build System 2026-10-14 22:47:15 +02:00
update/src move to the Zig build System 2026-10-14 22:47:15 +02:00
.clang-format Refine .clang-format 2025-07-27 21:18:57 +02:00
.clang-tidy Shut up about anonymous namespaces. 2026-03-31 01:18:50 +02:00
.gitignore move to the Zig build System 2026-10-14 22:47:15 +02:00
.mailmap Setup mailmap. 2024-09-27 16:56:55 +02:00
build.zig update to Zig 0.17.0 2026-10-14 23:34:45 +02:00
build.zig.zon update to Zig 0.17.0 2026-10-14 23:34:45 +02:00
build.zig.zon.nix move to the Zig build System 2026-10-14 22:47:15 +02:00
diff.sh move to the Zig build System 2026-10-14 22:47:15 +02:00
flake.lock move to the Zig build System 2026-10-14 22:47:15 +02:00
flake.nix update to Zig 0.17.0 2026-10-14 23:34:45 +02:00
LICENSE Bump copyright year. 2026-01-01 02:12:05 +01:00
NEWS Release 0.14.1. 2026-08-22 19:06:43 +02:00
README.md update to Zig 0.17.0 2026-10-14 23:34:45 +02:00
shell.nix move to the Zig build System 2026-10-14 22:47:15 +02:00

CI

Tracy Profiler

This is Tracy, packaged for Zig.

Installation

Install Zig 0.17.0 and then run the following command:

zig build install-profiler
./zig-out/bin/tracy-profiler

You can also directly run the Tracy Profiler with the "run" step:

zig build run

System Dependencies

When building for Windows or macOS, no system dependencies are required.

The graphical profiler has the following dependencies on Linux and BSD:

  • libGL, libGLX: runtime dependency
  • libEGL: runtime dependency, not required when using -Dlegacy
  • libwayland-* runtime dependencies to run a native wayland session
  • libX* runtime dependencies to run a X11 session, only required when using -Dlegacy
  • libxkbcommon: not required when using -Dlegacy
  • libdbus-1: can be disabled with -Dno-fileselector or -Dportal=false
  • libgtk+-3.0: only required when using -Dportal=false

System Integrations

Tracy has been ported with support for Zig's System Integration Options. By default, all system dependencies will be avoided except libxkbcommon.

Cross Compilation

Windows

Cross compiling to windows works out of the box. It can even connect to a client that is running a different host (Linux).

zig build -Dtarget=x86_64-windows
zig build run -Dtarget=x86_64-windows -fwine # run the tracy profiler with Wine

Linux

This will produce a dynamically linked executable that will try to dlopen various runtime libraries. This is not guaranteed to work as all distros like NixOS.

# Wayland
zig build -Dtarget=x86_64-linux-gnu -Dlinkage=dynamic -Dno-fileselector -fno-sys=libxkbcommon -Dxkb-config-root=/usr/share/X11/xkb -Dx-locale-root=/usr/share/X11/locale
# X11
zig build -Dtarget=x86_64-linux-gnu -Dlinkage=dynamic -Dno-fileselector -Dlegacy

FreeBSD

# Wayland
zig build -Dtarget=x86_64-freebsd -Dno-fileselector -fno-sys=libxkbcommon -Dxkb-config-root=/usr/local/share/X11/xkb -Dx-locale-root=/usr/local/lib/X11/locale
# X11
zig build -Dtarget=x86_64-freebsd -Dno-fileselector -Dlegacy

NetBSD

# X11
zig build -Dtarget=x86_64-freebsd -Dno-fileselector

OpenBSD

# X11
zig build -Dtarget=x86_64-freebsd -Dno-fileselector