Andy-Python-Programmer / aero

Aero is a new modern, experimental, UNIX-like operating system following the monolithic kernel design. Supporting modern PC features such as long mode, 5-level paging, and SMP (multicore), to name a few.

Home Page:https://aero.andypy.dev

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

just reporting aero kernel and shell build success on popos 21.10

omac777 opened this issue · comments

It took roughly a couple of minutes to clone and build your rust kernel and shell. Impressive.

You mentioned "Its already able to run programs such as the GNU coreutils, GNU binutils, Nyancat, TinyCC, GCC."

I didn't see any of these present however. How did you arrive at getting GNU coreutils, GNU binutils, Nyancat, TinyCC, GCC running on Aero kernel and shell?

Thank you and cheers.

Compilation output
$ git clone https://github.com/Andy-Python-Programmer/aero
Cloning into 'aero'...
remote: Enumerating objects: 111709, done.
remote: Counting objects: 100% (12312/12312), done.
remote: Compressing objects: 100% (3533/3533), done.
remote: Total 111709 (delta 10780), reused 9986 (delta 8659), pack-reused 99397
Receiving objects: 100% (111709/111709), 49.28 MiB | 19.68 MiB/s, done.
Resolving deltas: 100% (98879/98879), done.
davidm@pop-os 2022-01-06_12:12:24_EST : ~/tryredox
$ cd aero
davidm@pop-os 2022-01-06_12:12:40_EST : ~/tryredox/aero
$ time ./aero.py 
Cloning into 'bundled/limine'...
remote: Enumerating objects: 17, done.
remote: Counting objects: 100% (17/17), done.
remote: Compressing objects: 100% (11/11), done.
remote: Total 17 (delta 5), reused 9 (delta 5), pack-reused 0
Receiving objects: 100% (17/17), 1.01 MiB | 8.00 MiB/s, done.
Resolving deltas: 100% (5/5), done.
   Compiling compiler_builtins v0.1.66
   Compiling core v0.0.0 (/home/davidm/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/core)
   Compiling bitflags v1.2.1
   Compiling rustc-std-workspace-core v1.99.0 (/home/davidm/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/rustc-std-workspace-core)
   Compiling alloc v0.0.0 (/home/davidm/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/alloc)
   Compiling scopeguard v1.1.0
   Compiling aero_syscall v0.1.0 (/home/davidm/tryredox/aero/src/aero_syscall)
   Compiling lock_api v0.4.5
   Compiling spinning_top v0.2.4
   Compiling spin v0.9.2
   Compiling aero_rt v0.1.0 (/home/davidm/tryredox/aero/userland/aero_rt)
   Compiling linked_list_allocator v0.9.1
   Compiling std v0.1.0 (/home/davidm/tryredox/aero/userland/aero_std)
   Compiling init v0.1.0 (/home/davidm/tryredox/aero/userland/init)
   Compiling aero_shell v0.1.0 (/home/davidm/tryredox/aero/userland/aero_shell)
    Finished release [optimized] target(s) in 19.50s
   Compiling compiler_builtins v0.1.66
   Compiling core v0.0.0 (/home/davidm/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/core)
   Compiling autocfg v1.0.1
   Compiling crossbeam-utils v0.8.5
   Compiling spin v0.5.2
   Compiling cfg-if v1.0.0
   Compiling crossbeam-epoch v0.9.5
   Compiling libc v0.2.107
   Compiling rayon-core v1.9.1
   Compiling scopeguard v1.1.0
   Compiling version_check v0.9.3
   Compiling proc-macro2 v1.0.32
   Compiling either v1.6.1
   Compiling unicode-xid v0.2.2
   Compiling log v0.4.14
   Compiling paste v1.0.6
   Compiling lazy_static v1.4.0
   Compiling memoffset v0.6.4
   Compiling rayon v1.5.1
   Compiling memoffset v0.5.6
   Compiling ahash v0.7.6
   Compiling crossbeam-channel v0.5.1
   Compiling num_cpus v1.13.0
   Compiling quote v1.0.10
   Compiling crossbeam-deque v0.8.1
   Compiling vte_generate_state_changes v0.1.1 (https://github.com/Andy-Python-Programmer/vte#a9d8bf89)
   Compiling nasm-rs v0.2.1
   Compiling aero_kernel v0.1.0 (/home/davidm/tryredox/aero/src/aero_kernel)
   Compiling rustc-std-workspace-core v1.99.0 (/home/davidm/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/rustc-std-workspace-core)
   Compiling alloc v0.0.0 (/home/davidm/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/alloc)
   Compiling bitflags v1.3.2
   Compiling once_cell v1.8.0
   Compiling bit_field v0.10.1
   Compiling utf8parse v0.2.0 (https://github.com/Andy-Python-Programmer/vte#a9d8bf89)
   Compiling arrayvec v0.7.2
   Compiling zero v0.1.2
   Compiling byteorder v1.4.3
   Compiling rustc-demangle v0.1.21
   Compiling linked_list_allocator v0.9.1
   Compiling raw-cpuid v10.2.0
   Compiling aero_syscall v0.1.0 (/home/davidm/tryredox/aero/src/aero_syscall)
   Compiling cpio_reader v0.1.0 (https://github.com/czapek1337/cpio_reader#9e3a58b2)
   Compiling stivale-boot v0.2.6
   Compiling lock_api v0.4.5
   Compiling intrusive-collections v0.9.2
   Compiling xmas-elf v0.8.0
   Compiling vte v0.10.1 (https://github.com/Andy-Python-Programmer/vte#a9d8bf89)
   Compiling aml v0.15.0
   Compiling spin v0.9.2
   Compiling hashbrown v0.11.2
   Compiling lru v0.6.6
warning: unused variable: `sys`
   --> aero_kernel/src/syscall/mod.rs:158:31
    |
158 | extern "C" fn __inner_syscall(sys: &mut SyscallFrame, stack: &mut RegistersFrame) {
    |                               ^^^ help: if this is intentional, prefix it with an underscore: `_sys`
    |
    = note: `#[warn(unused_variables)]` on by default

warning: associated function is never used: `send_ipi`
   --> aero_kernel/src/apic.rs:151:19
    |
151 |     pub unsafe fn send_ipi(&mut self, cpu: usize, vec: u8) {
    |                   ^^^^^^^^
    |
    = note: `#[warn(dead_code)]` on by default

warning: field is never read: `request`
   --> aero_kernel/src/drivers/block/ahci.rs:738:5
    |
738 |     request: Arc<DmaRequest>,
    |     ^^^^^^^^^^^^^^^^^^^^^^^^

warning: field is never read: `interrupt_nr`
  --> aero_kernel/src/drivers/block/ide/channel.rs:97:5
   |
97 |     interrupt_nr: usize,
   |     ^^^^^^^^^^^^^^^^^^^

warning: function is never used: `init_pci_router`
   --> aero_kernel/src/drivers/pci.rs:651:8
    |
651 | pub fn init_pci_router(pci_router: PciRoutingTable) {
    |        ^^^^^^^^^^^^^^^

warning: field is never read: `filesystem`
  --> aero_kernel/src/fs/mod.rs:57:5
   |
57 |     filesystem: Arc<dyn FileSystem>,
   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

warning: field is never read: `origin_entry`
  --> aero_kernel/src/fs/mod.rs:60:5
   |
60 |     origin_entry: DirCacheItem,
   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^

warning: variant is never constructed: `Size2MiB`
   --> aero_kernel/src/mem/paging/frame.rs:146:5
    |
146 |     Size2MiB = 2,
    |     ^^^^^^^^^^^^

warning: `aero_kernel` (bin "aero_kernel") generated 8 warnings
    Finished release [optimized + debuginfo] target(s) in 37.92s
  INFO         loaded bootstrap GDT
  INFO         loaded paging
  INFO         loaded heap
  INFO         loaded IDT
  DEBUG        Found apic at: 0xfee00000
  DEBUG        Disabled PIC
  INFO         Loaded local apic (x2apic=false)
  DEBUG        Found RSDT at 0xffff80007ffe210d
  DEBUG        Storing AP trampoline at 0x1000
  WARN         Unknown MADT entry with id: 4
  INFO         Loaded ACPI
  INFO         loaded TLS
  INFO         loaded GDT
  INFO         loaded PS/2 driver
  INFO         registered redirect (vec=32, gsi=2)
  INFO         loaded PIT
  INFO         Installed initramfs
  DEBUG        installed device `null`
  DEBUG        installed device `kmsg`
  DEBUG        installed device `fb`
  INFO         Installed devfs
  INFO         loaded filesystem
  INFO         loaded userland
  INFO         initialized kernel
  INFO         registered redirect (vec=33, gsi=1)
  DEBUG        installed device `tty`
  INFO         loaded kernel modules
  DEBUG        PCI device (device=HostBridge, vendor=Intel)
  DEBUG        PCI device (device=VgaCompatibleController, vendor=Qemu)
  DEBUG        PCI device (device=EthernetController, vendor=Intel)
  DEBUG        PCI device (device=IsaBridge, vendor=Intel)
  DEBUG        PCI device (device=SataController, vendor=Intel)
  INFO         ahci: starting driver...
  INFO         ahci: controller version 1.0
  DEBUG        PCI device (device=SmBusController, vendor=Intel)
  INFO         loaded PCI driver

real	1m14.150s
user	3m3.705s
sys	0m11.155s
davidm@pop-os 2022-01-06_12:14:00_EST : ~/tryredox/aero

Hey, thanks for reporting back :) Glad it worked without issues, although build times could be improved in the future, maybe by building userland and kernel in parallel.

You mentioned "Its already able to run programs such as the GNU coreutils, GNU binutils, Nyancat, TinyCC, GCC."
I didn't see any of these present however. [...]

These are not built by default to save on time, since they aren't necessary to build and run Aero. If you want to build all of them, you can run ./aero.py --sysroot, but please be aware this may take a long time, since it needs to build the whole GNU toolchain and GNU binutils to be able to compile code for Aero. It took around 15 minutes for me, and I have an i5-4690K paired with 8GB of RAM. It will require around 5GB of free disk space.

In future I might aswell build the sysroot in the nightly images so it's easier for everyone to try Aero out but still be able to run lua, GCC, tcc etc...