mirror of
https://github.com/ghostty-org/ghostty.git
synced 2025-07-14 07:46:12 +03:00
32 lines
1.1 KiB
Zig
32 lines
1.1 KiB
Zig
const std = @import("std");
|
|
const build_config = @import("build_config.zig");
|
|
|
|
/// See build_config.ExeEntrypoint for why we do this.
|
|
const entrypoint = switch (build_config.exe_entrypoint) {
|
|
.ghostty => @import("main_ghostty.zig"),
|
|
.helpgen => @import("helpgen.zig"),
|
|
.mdgen_ghostty_1 => @import("build/mdgen/main_ghostty_1.zig"),
|
|
.mdgen_ghostty_5 => @import("build/mdgen/main_ghostty_5.zig"),
|
|
.webgen_config => @import("build/webgen/main_config.zig"),
|
|
.webgen_actions => @import("build/webgen/main_actions.zig"),
|
|
.webgen_commands => @import("build/webgen/main_commands.zig"),
|
|
.bench_parser => @import("bench/parser.zig"),
|
|
.bench_stream => @import("bench/stream.zig"),
|
|
.bench_codepoint_width => @import("bench/codepoint-width.zig"),
|
|
.bench_grapheme_break => @import("bench/grapheme-break.zig"),
|
|
.bench_page_init => @import("bench/page-init.zig"),
|
|
};
|
|
|
|
/// The main entrypoint for the program.
|
|
pub const main = entrypoint.main;
|
|
|
|
/// Standard options such as logger overrides.
|
|
pub const std_options: std.Options = if (@hasDecl(entrypoint, "std_options"))
|
|
entrypoint.std_options
|
|
else
|
|
.{};
|
|
|
|
test {
|
|
_ = entrypoint;
|
|
}
|