hide console on windows
This commit is contained in:
parent
6809b5538c
commit
8b7c50375c
@ -7,6 +7,7 @@ pub fn build(b: *std.Build) !void {
|
|||||||
|
|
||||||
const has_imgui = b.option(bool, "imgui", "ImGui integration") orelse (optimize == .Debug);
|
const has_imgui = b.option(bool, "imgui", "ImGui integration") orelse (optimize == .Debug);
|
||||||
const has_tracy = b.option(bool, "tracy", "Tracy integration") orelse (optimize == .Debug);
|
const has_tracy = b.option(bool, "tracy", "Tracy integration") orelse (optimize == .Debug);
|
||||||
|
const has_console = b.option(bool, "console", "Show console (Window only)") orelse (optimize == .Debug);
|
||||||
|
|
||||||
const exe = b.addExecutable(.{
|
const exe = b.addExecutable(.{
|
||||||
.name = "game_2025_12_13",
|
.name = "game_2025_12_13",
|
||||||
@ -80,6 +81,10 @@ pub fn build(b: *std.Build) !void {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (target.result.os.tag == .windows) {
|
||||||
|
exe.subsystem = if (has_console) .Console else .Windows;
|
||||||
|
}
|
||||||
|
|
||||||
var options = b.addOptions();
|
var options = b.addOptions();
|
||||||
options.addOption(bool, "has_imgui", has_imgui);
|
options.addOption(bool, "has_imgui", has_imgui);
|
||||||
options.addOption(bool, "has_tracy", has_tracy);
|
options.addOption(bool, "has_tracy", has_tracy);
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user