mirror of
https://codeberg.org/ziglang/zig.git
synced 2026-04-26 13:01:34 +03:00
IoUring: update to new Io APIs
This commit is contained in:
@@ -13,6 +13,7 @@ const DevEnv = @import("src/dev.zig").Env;
|
||||
const zig_version: std.SemanticVersion = .{ .major = 0, .minor = 16, .patch = 0 };
|
||||
const stack_size = 46 * 1024 * 1024;
|
||||
|
||||
const IoMode = enum { threaded, evented };
|
||||
const ValueInterpretMode = enum { direct, by_name };
|
||||
|
||||
pub fn build(b: *std.Build) !void {
|
||||
@@ -188,6 +189,7 @@ pub fn build(b: *std.Build) !void {
|
||||
const strip = b.option(bool, "strip", "Omit debug information");
|
||||
const valgrind = b.option(bool, "valgrind", "Enable valgrind integration");
|
||||
const pie = b.option(bool, "pie", "Produce a Position Independent Executable");
|
||||
const io_mode = b.option(IoMode, "io-mode", "How the compiler performs IO") orelse .threaded;
|
||||
const value_interpret_mode = b.option(ValueInterpretMode, "value-interpret-mode", "How the compiler translates between 'std.builtin' types and its internal datastructures") orelse .direct;
|
||||
const value_tracing = b.option(bool, "value-tracing", "Enable extra state tracking to help troubleshoot bugs in the compiler (using the std.debug.Trace API)") orelse false;
|
||||
|
||||
@@ -236,6 +238,7 @@ pub fn build(b: *std.Build) !void {
|
||||
exe_options.addOption(bool, "llvm_has_xtensa", llvm_has_xtensa);
|
||||
exe_options.addOption(bool, "debug_gpa", debug_gpa);
|
||||
exe_options.addOption(DevEnv, "dev", b.option(DevEnv, "dev", "Build a compiler with a reduced feature set for development of specific features") orelse if (only_c) .bootstrap else .full);
|
||||
exe_options.addOption(IoMode, "io_mode", io_mode);
|
||||
exe_options.addOption(ValueInterpretMode, "value_interpret_mode", value_interpret_mode);
|
||||
|
||||
if (link_libc) {
|
||||
@@ -710,6 +713,7 @@ fn addWasiUpdateStep(b: *std.Build, version: [:0]const u8) !void {
|
||||
exe_options.addOption(u32, "tracy_callstack_depth", 0);
|
||||
exe_options.addOption(bool, "value_tracing", false);
|
||||
exe_options.addOption(DevEnv, "dev", .bootstrap);
|
||||
exe_options.addOption(IoMode, "io_mode", .threaded);
|
||||
|
||||
// zig1 chooses to interpret values by name. The tradeoff is as follows:
|
||||
//
|
||||
|
||||
Reference in New Issue
Block a user