mirror of
https://github.com/allyourcodebase/libffi.git
synced 2026-11-17 01:20:37 +00:00
libffi built with the zig build system
- Zig 100%
| Filename | Latest commit message | Latest commit date |
|---|---|---|
| .github/workflows | ||
| .gitattributes | ||
| .gitignore | ||
| build.zig | ||
| build.zig.zon | ||
| LICENSE | ||
| README.md | ||
libffi
This is libffi, packaged for Zig.
Installation
First, update your build.zig.zon:
# Initialize a `zig build` project if you haven't already
zig init
zig fetch --save git+https://github.com/allyourcodebase/libffi.git
You can then import libffi in your build.zig with:
const libffi = b.dependency("libffi", .{
.target = target,
.optimize = optimize,
});
exe.root_module.linkLibrary(libffi.artifact("ffi"));