This is jemalloc packaged for Zig
Use zig fetch
:
zig fetch --save git+https://github.com/allyourcodebase/jemalloc#main
You can then import jemalloc
in your build.zig
:
const jemalloc = b.dependency("jemalloc", .{
.target = target,
.optimize = optimize,
});
your_exe.addIncludePath(jemalloc.path("."));
your_exe.linkLibrary(jemalloc.artifact("jemalloc"));