/libcue

Zig build for CUE Sheet Parser Library

Primary LanguageCOtherNOASSERTION

libcue CI

This is libcue, packaged for Zig.

Getting parser and scanner

TODO: These actions could be automated

To generate cue_parser.c and cue_parser.h invoke this command from upstream repository:

bison -d -o cue_parser.c cue_parser.y

To generate cue_scanner.c invoke this command from upstream repository:

flex -o cue_scanner.c cue_scanner.l

Using library in Zig

Add library to your build.zig file:

const libcue_dep = b.dependency("libcue", .{
    .target = target,
    .optimize = optimize,
});
mod.linkLibrary(libcue_dep.artifact("cue"));

After that you will be able to import functions from libcue.h:

const cue = @cImport({
    @cInclude("libcue.h");
});

Glhf!