Getting the error
error: root struct of file 'std' has no member named 'build'
const Builder = std.build.Builder;
~~~^~~~~~
When trying to run below with zig build
const std = @import("std");
const Builder = std.build.Builder;
pub fn build(b: *Builder) void {
const mode = b.standardReleaseOptions(); // Use standardReleaseOptions for optimized release build
// Add your custom build configurations here
const exe = b.addExecutable("./main.zig");
exe.setBuildMode(mode);
exe.linkLibC();
exe.addIncludeDir("/usr/lib/llvm-14/include");
exe.addLibPath("/usr/lib/llvm-14/lib");
exe.linkSystemLibrary("c++");
exe.linkSystemLibrary("LLVM-14");
const target = b.standardTargetOptions(.{});
exe.setTarget(target);
b.default_step.dependOn(&exe.step);
}
Version: 0.13.0-dev.46+3648d7df1