Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- const Builder = @import("std").build.Builder;
- pub fn build(b: *Builder) void {
- const mode = b.standardReleaseOptions();
- const exe = b.addExecutable("demo", "src/main.zig");
- exe.setBuildMode(mode);
- exe.linkSystemLibrary("c");
- exe.linkSystemLibrary("/usr/local/Cellar/sdl2/2.0.10/lib/libSDL2.a");
- exe.addIncludeDir("/usr/local/Cellar/sdl2/2.0.10/include/");
- exe.install();
- const run_cmd = exe.run();
- run_cmd.step.dependOn(b.getInstallStep());
- const run_step = b.step("run", "Run the app");
- run_step.dependOn(&run_cmd.step);
- }
Add Comment
Please, Sign In to add comment