This is a fork of SDL, packaged for Zig.
Unnecessary files have been deleted, and the build system has been replaced with build.zig
.
The package provides version 2 of SDL. For version 3, consider https://github.com/castholm/SDL.
Fetch SDL and add to your build.zig.zon
:
zig fetch --save=SDL git+https://github.com/allyourcodebase/SDL
Add this to your build.zig
:
const sdl_dep = b.dependency("SDL", .{
.optimize = .ReleaseFast,
.target = target,
});
exe.linkLibrary(sdl_dep.artifact("SDL2"));