Rust 中的玩具浏览器 + 操作系统 = wasabi
Toy web browser and OS in Rust ("sabi" in Japanese) = WasabiOS
rustup --version && \
make --version && \
clang --version && \
qemu-system-x86_64 --version && \
echo "This machine is ready to build WasabiOS!"rustup can be installed via: https://www.rust-lang.org/tools/installmake can be installed with: sudo apt install makeclang can be installed with: sudo apt install clangqemu-system-x86_64 can be installed with: sudo apt install qemu-system-x86./scripts/setup_dev_crostini.sh
bash # to reload environment variables./scripts/setup_dev_macos.sh
zsh # to reload environment variablesmake runmake internal_run_app_test INIT="app_name_here"For example, to create a "hello2" app, run following commands outside of WasabiOS checkout:
cargo new hello2
cd hello2
cargo add noli --git https://github.com/hikalium/wasabi.git
rustup target add x86_64-unknown-none
wget https://raw.githubusercontent.com/hikalium/wasabi/main/rust-toolchain.toml
wget https://raw.githubusercontent.com/hikalium/wasabi/main/external_app_template/MakefileThen, please make sure following lines are added at the beginning of src/main.rs:
#![no_std]
#![cfg_attr(not(target_os = "linux"), no_main)]
use noli::prelude::*;
entry_point!(main);Now, you can run apps with:
make
/path/to/wasabi/scripts/run_with_app.sh ./target/x86_64-unknown-none/release/hello2make run MORE_QEMU_FLAGS='-nographic'
make run MORE_QEMU_FLAGS="-d int,cpu_reset --no-reboot" 2>&1 | cargo run --bin=dbgutil
make run MORE_QEMU_FLAGS="-d int,cpu_reset --no-reboot" 2>&1tshark -r log/dump_net1.pcap(qemu) info usbhost
Bus 2, Addr 37, Port 3.2.1, Speed 5000 Mb/s
Class ff: USB device 0b95:1790, AX88179
(qemu) device_add usb-host,hostbus=2,hostport=3.2.1make commitAfter installing GitHub CLI and Docker, run:
# Check if Docker works without root
docker run hello-world
# Install act extention
gh extension install https://github.com/nektos/gh-act
# Run
gh act
# Run without docker pull (useful when uprev the container)
gh act --pull=falseTry uninstalling all the toolchains installed and make again to install the desired version, with this:
rustup toolchain uninstall `rustup toolchain list | cut -d ' ' -f 1`
makeAlso, it is possible that your neovim installation is outdated.
FYI: hikalium is using this version of neovim.
hikalium, d0iasm
MIT
暂无开放 Issues,或尚未同步最近议题。