Zig build of libmaxminddb library.
- Add
libmaxminddb
dependency tobuild.zig.zon
.
zig fetch --save https://github.com/allyourcodebase/libmaxminddb/archive/<git_tag_or_commit_hash>.tar.gz
- Use
libmaxminddb
dependency inbuild.zig
.
const libmaxminddb_dep = b.dependency("libmaxminddb", .{
.target = target,
.optimize = optimize,
});
const maxminddb_mod = libmaxminddb_dep.module("maxminddb");
<compile>.root_module.addImport("maxminddb", maxminddb_mod);