Skip to content

Latest commit

 

History

History
47 lines (32 loc) · 1.09 KB

File metadata and controls

47 lines (32 loc) · 1.09 KB

libgfxd

CI

libgfxd ported to the Zig build system

Consuming

Since this repo doesn't currently have tags or releases, it makes the most sense to pull the latest commit from main.

zig fetch --save git+https://github.com/k64ret/libgfxd?ref=main

Then, you can consume libgfxd as a static library in your build.zig.

const gfxd_dep = b.dependency("gfxd", .{
    .target = target,
    .optimize = optimize,
    // This is the default if not provided...
    .mt = false,
});

const gfxd_artifact = gfxd_dep.artifact("gfxd");

some_lib_or_exe.addIncludePath(gfxd_artifact.getEmittedIncludeTree());
some_lib_or_exe.linkLibrary(gfxd_artifact);

Building

zig build [OPTIONS] [--summary all]

Options

-Dmt

Warning

This option currently does not compile here, nor in the upstream project.

Enable multi-threaded build. In practice, this adds -DCONFIG_MT to the compiler flags.