move platform files to subfolder
This commit is contained in:
parent
ef5275b17f
commit
69ae88c37d
@ -40,7 +40,7 @@ pub fn build(b: *std.Build) !void {
|
|||||||
exe_mod.addImport("embedded_assets", try createEmbeddedAssets(b, assets_dir, &asset_files));
|
exe_mod.addImport("embedded_assets", try createEmbeddedAssets(b, assets_dir, &asset_files));
|
||||||
|
|
||||||
const math_mod = b.createModule(.{
|
const math_mod = b.createModule(.{
|
||||||
.root_source_file = b.path("src/math.zig")
|
.root_source_file = b.path("src/platform/math.zig")
|
||||||
});
|
});
|
||||||
exe_mod.addImport("math", math_mod);
|
exe_mod.addImport("math", math_mod);
|
||||||
|
|
||||||
@ -69,8 +69,8 @@ pub fn build(b: *std.Build) !void {
|
|||||||
}
|
}
|
||||||
const mod_shader = try sokol.shdc.createModule(b, "shader", mod_sokol, .{
|
const mod_shader = try sokol.shdc.createModule(b, "shader", mod_sokol, .{
|
||||||
.shdc_dep = dep_shdc,
|
.shdc_dep = dep_shdc,
|
||||||
.input = "src/shader.glsl",
|
.input = "src/platform/shader.glsl",
|
||||||
.output = "src/shader.zig",
|
.output = "src/platform/shader.zig",
|
||||||
.slang = slang
|
.slang = slang
|
||||||
});
|
});
|
||||||
mod_shader.addImport("math", math_mod);
|
mod_shader.addImport("math", math_mod);
|
||||||
|
|||||||
@ -1,5 +1,4 @@
|
|||||||
const std = @import("std");
|
const std = @import("std");
|
||||||
const CLI = @import("./cli.zig");
|
|
||||||
const log = std.log.scoped(.app);
|
const log = std.log.scoped(.app);
|
||||||
const Allocator = std.mem.Allocator;
|
const Allocator = std.mem.Allocator;
|
||||||
|
|
||||||
@ -10,7 +9,7 @@ const STBImage = @import("stb_image");
|
|||||||
const STBTrueType = @import("stb_truetype");
|
const STBTrueType = @import("stb_truetype");
|
||||||
const Tiled = @import("tiled");
|
const Tiled = @import("tiled");
|
||||||
|
|
||||||
const Platform = @import("./platform.zig");
|
const Platform = @import("platform/root.zig");
|
||||||
const Gfx = Platform.Gfx;
|
const Gfx = Platform.Gfx;
|
||||||
const ImGUI = Platform.ImGUI;
|
const ImGUI = Platform.ImGUI;
|
||||||
const Rect = Platform.Rect;
|
const Rect = Platform.Rect;
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
const std = @import("std");
|
const std = @import("std");
|
||||||
|
|
||||||
const Platform = @import("platform.zig");
|
const Platform = @import("platform/root.zig");
|
||||||
const App = @import("app.zig");
|
const App = @import("app.zig");
|
||||||
|
|
||||||
pub const std_options: std.Options = .{
|
pub const std_options: std.Options = .{
|
||||||
@ -21,5 +21,5 @@ pub fn main(init: std.process.Init) void {
|
|||||||
|
|
||||||
test {
|
test {
|
||||||
std.testing.refAllDecls(@This());
|
std.testing.refAllDecls(@This());
|
||||||
_ = @import("./slot_map.zig");
|
_ = @import("./platform/slot_map.zig");
|
||||||
}
|
}
|
||||||
|
|||||||
@ -15,7 +15,7 @@ const simgui = sokol.imgui;
|
|||||||
|
|
||||||
const ig = @import("cimgui");
|
const ig = @import("cimgui");
|
||||||
|
|
||||||
const Nanoseconds = @import("./platform.zig").Nanoseconds;
|
const Nanoseconds = @import("./root.zig").Nanoseconds;
|
||||||
|
|
||||||
const ImGUI = @This();
|
const ImGUI = @This();
|
||||||
|
|
||||||
Loading…
Reference in New Issue
Block a user