interplane.Get Omega
Read in your language

aienux

Aienux, the AienOS kernel: boot, scheduling, IPC and capability boundaries. Pre-alpha; host, emulator and physical evidence are labelled separately.

Brought by drakestapleton

branch main Branches Tags History

aienux / vendor / libc / src / unix / hurd / b32.rs

92 lines · 2619 bytes Raw Blame History
1use crate::prelude::*;
2
3pub type __int64_t = c_longlong;
4pub type __uint64_t = c_ulonglong;
5
6pub type int_fast16_t = c_int;
7pub type int_fast32_t = c_int;
8pub type int_fast64_t = c_longlong;
9pub type uint_fast16_t = c_uint;
10pub type uint_fast32_t = c_uint;
11pub type uint_fast64_t = c_ulonglong;
12
13pub type __quad_t = c_longlong;
14pub type __u_quad_t = c_ulonglong;
15pub type __intmax_t = c_longlong;
16pub type __uintmax_t = c_ulonglong;
17
18pub type __squad_type = crate::__int64_t;
19pub type __uquad_type = crate::__uint64_t;
20pub type __sword_type = c_int;
21pub type __uword_type = c_uint;
22pub type __slong32_type = c_long;
23pub type __ulong32_type = c_ulong;
24pub type __s64_type = crate::__int64_t;
25pub type __u64_type = crate::__uint64_t;
26
27pub type __ipc_pid_t = c_ushort;
28
29pub type Elf32_Half = u16;
30pub type Elf32_Word = u32;
31pub type Elf32_Off = u32;
32pub type Elf32_Addr = u32;
33pub type Elf32_Section = u16;
34
35pub type Elf_Addr = crate::Elf32_Addr;
36pub type Elf_Half = crate::Elf32_Half;
37pub type Elf_Ehdr = crate::Elf32_Ehdr;
38pub type Elf_Phdr = crate::Elf32_Phdr;
39pub type Elf_Shdr = crate::Elf32_Shdr;
40pub type Elf_Sym = crate::Elf32_Sym;
41
42s! {
43 pub struct Elf32_Ehdr {
44 pub e_ident: [c_uchar; 16],
45 pub e_type: Elf32_Half,
46 pub e_machine: Elf32_Half,
47 pub e_version: Elf32_Word,
48 pub e_entry: Elf32_Addr,
49 pub e_phoff: Elf32_Off,
50 pub e_shoff: Elf32_Off,
51 pub e_flags: Elf32_Word,
52 pub e_ehsize: Elf32_Half,
53 pub e_phentsize: Elf32_Half,
54 pub e_phnum: Elf32_Half,
55 pub e_shentsize: Elf32_Half,
56 pub e_shnum: Elf32_Half,
57 pub e_shstrndx: Elf32_Half,
58 }
59
60 pub struct Elf32_Shdr {
61 pub sh_name: Elf32_Word,
62 pub sh_type: Elf32_Word,
63 pub sh_flags: Elf32_Word,
64 pub sh_addr: Elf32_Addr,
65 pub sh_offset: Elf32_Off,
66 pub sh_size: Elf32_Word,
67 pub sh_link: Elf32_Word,
68 pub sh_info: Elf32_Word,
69 pub sh_addralign: Elf32_Word,
70 pub sh_entsize: Elf32_Word,
71 }
72
73 pub struct Elf32_Sym {
74 pub st_name: Elf32_Word,
75 pub st_value: Elf32_Addr,
76 pub st_size: Elf32_Word,
77 pub st_info: c_uchar,
78 pub st_other: c_uchar,
79 pub st_shndx: Elf32_Section,
80 }
81
82 pub struct Elf32_Phdr {
83 pub p_type: crate::Elf32_Word,
84 pub p_offset: crate::Elf32_Off,
85 pub p_vaddr: crate::Elf32_Addr,
86 pub p_paddr: crate::Elf32_Addr,
87 pub p_filesz: crate::Elf32_Word,
88 pub p_memsz: crate::Elf32_Word,
89 pub p_flags: crate::Elf32_Word,
90 pub p_align: crate::Elf32_Word,
91 }
92}