build: fix build

This commit is contained in:
Loïc Grégoire
2026-03-28 14:52:30 -04:00
parent 5fe832d412
commit 9b6d38bbcc
4 changed files with 7 additions and 5 deletions
+3 -2
View File
@@ -132,6 +132,8 @@ pub fn build(b: *std.Build) void {
}),
});
rtl_tests.root_module.addImport("rtl", rtl_tests.root_module);
const run_tests = b.addRunArtifact(rtl_tests);
const test_step = b.step("test", "Run tests");
@@ -174,8 +176,7 @@ fn addKernel(b: *std.Build, plat: config.Platform, optimize: std.builtin.Optimiz
switch (bl) {
.Limine => "limine",
}
else
@tagName(plat.arch);
else if (plat.os == .linux) "um" else @tagName(plat.arch);
const root_source_file = b.fmt("src/platform/{s}/entry.zig", .{platform_name});
+1 -1
View File
@@ -89,7 +89,7 @@ pub fn getPlatform(config: Config) !Platform {
return error.NoArchConfigured;
};
if (ret.arch == .x86_64 or ret.arch == .aarch64) {
if (ret.os == .freestanding and (ret.arch == .x86_64 or ret.arch == .aarch64)) {
ret.bootloader = blk: {
if (config.get("CONFIG_BOOT_LIMINE")) |val| {
if (std.mem.eql(u8, val, "y")) break :blk .Limine;
+2 -2
View File
@@ -1,10 +1,10 @@
const tagged_ptr = @import("tagged_ptr.zig");
const rtl = @import("rtl");
const std = @import("std");
pub const Node = struct {
left: *Node,
right: *Node,
parent: tagged_ptr.TaggedPtr(Node),
parent: rtl.TaggedPtr(Node),
};
/// Base struct for binary search trees.
+1
View File
@@ -8,6 +8,7 @@ pub const pairing_heap = @import("pairing_heap.zig");
pub const PairingHeap = pairing_heap.PairingHeap;
pub const TaggedPtr = @import("tagged_ptr.zig").TaggedPtr;
pub const bst = @import("bst.zig");
pub const BST = bst.BST;
test {
std.testing.refAllDecls(@This());