Remove further & all @cImport() usage in interop

Signed-off-by: AnErrupTion <anerruption@disroot.org>
This commit is contained in:
AnErrupTion
2026-04-30 22:48:29 +02:00
parent 15cd0c4779
commit 807f6d249a
2 changed files with 12 additions and 14 deletions

View File

@@ -31,13 +31,8 @@ pub const UsernameEntry = struct {
fn PlatformStruct() type {
return switch (builtin.os.tag) {
.linux => struct {
pub const kd = @cImport({
@cInclude("sys/kd.h");
});
pub const vt = @cImport({
@cInclude("sys/vt.h");
});
pub const kd = @import("kd");
pub const vt = @import("vt");
pub const LedState = c_char;
pub const get_led_state = kd.KDGKBLED;
@@ -197,13 +192,8 @@ fn PlatformStruct() type {
}
},
.freebsd => struct {
pub const kbio = @cImport({
@cInclude("sys/kbio.h");
});
pub const consio = @cImport({
@cInclude("sys/consio.h");
});
pub const kbio = @import("kbio");
pub const consio = @import("consio");
pub const LedState = c_int;
pub const get_led_state = kbio.KDGETLED;