diff options
author | Martin Ashby <martin@ashbysoft.com> | 2024-05-26 15:02:56 +0100 |
---|---|---|
committer | Martin Ashby <martin@ashbysoft.com> | 2024-05-26 15:02:56 +0100 |
commit | 941f161974115b677ee7514abf45ec7a216f250f (patch) | |
tree | 81bc3c3218ac87d6894cd556709cfed17b3530fc | |
parent | c0b0b259a572bcc65dd2e6d55a126ead9c2ae6ff (diff) | |
download | zigwebserver-main.tar.gz zigwebserver-main.tar.bz2 zigwebserver-main.tar.xz zigwebserver-main.zip |
-rw-r--r-- | build.zig | 8 |
1 files changed, 4 insertions, 4 deletions
@@ -19,21 +19,21 @@ pub fn build(b: *std.Build) void { .name = "zigwebserver-exe", // In this case the main source file is merely a path, however, in more // complicated build scripts, this could be a generated file. - .root_source_file = .{ .path = "src/main.zig" }, + .root_source_file = b.path("src/main.zig"), .target = target, .optimize = optimize, }); const lib = b.addStaticLibrary(.{ .name = "zigwebserver", - .root_source_file = .{ .path = "src/zigwebserver.zig" }, + .root_source_file = b.path("src/zigwebserver.zig"), .target = target, .optimize = optimize, }); b.installArtifact(lib); // for zig module system - _ = b.addModule("zigwebserver", .{ .root_source_file = .{ .path = "src/zigwebserver.zig" } }); + _ = b.addModule("zigwebserver", .{ .root_source_file = b.path("src/zigwebserver.zig") }); // This declares intent for the executable to be installed into the // standard location when the user invokes the "install" step (the default @@ -66,7 +66,7 @@ pub fn build(b: *std.Build) void { // Creates a step for unit testing. This only builds the test executable // but does not run it. const unit_tests = b.addTest(.{ - .root_source_file = .{ .path = "src/main.zig" }, + .root_source_file = b.path("src/main.zig"), .target = target, .optimize = optimize, }); |