操作系统篇:环境配置"/>
手写操作系统篇:环境配置
文章目录
- 前言
- C环境配置
- Rust环境配置
- Qemu安装
前言
这篇博客先配置好我们之后的开发环境,下载一些依赖的软件包
建议大家使用ubuntu操作系统
C环境配置
sudo apt-get update && sudo apt-get upgrade
sudo apt-get install git wget build-essential gdb-multiarch qemu-system-misc gcc-riscv64-linux-gnu binutils-riscv64-linux-gnu
Rust环境配置
首先是Rust基本环境配置
这里就不再赘述
设置Rust为缺省版本,并安装一些软件包
rustup install nightly
rustup default nightly
rustup target add riscv64gc-unknown-none-elf
cargo install cargo-binutils
rustup component add llvm-tools-preview
rustup component add rust-src
Qemu安装
sudo apt install autoconf automake autotools-dev curl libmpc-dev libmpfr-dev libgmp-dev \gawk build-essential bison flex texinfo gperf libtool patchutils bc \zlib1g-dev libexpat-dev pkg-config libglib2.0-dev libpixman-1-dev libsdl2-dev \git tmux python3 python3-pip ninja-build
wget .0.0.tar.xz
tar xvJf qemu-7.0.0.tar.xz
cd qemu-7.0.0
./configure --target-list=riscv64-softmmu,riscv64-linux-user
make -j$(nproc)
更多推荐
手写操作系统篇:环境配置
发布评论