From b4d2d9691a5f5768e684de2d58a545fe2997243e Mon Sep 17 00:00:00 2001 From: xushanpu123 <50659045+xushanpu123@users.noreply.github.com> Date: Wed, 29 Jun 2022 10:37:38 +0000 Subject: [PATCH 1/2] add make config --- Makefile | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/Makefile b/Makefile index bb734e4..a8b1016 100644 --- a/Makefile +++ b/Makefile @@ -15,6 +15,21 @@ lab4: test6 test7 lab5: test8 +config: + curl https://sh.rustup.rs -sSf | sh -s -- -y + . $(HOME)/.cargo/env + rustc --version + 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 git tmux python3 ninja-build -y + cd .. && wget https://download.qemu.org/qemu-7.0.0.tar.xz + cd .. && tar xvJf qemu-7.0.0.tar.xz + cd ../qemu-7.0.0 && ./configure --target-list=riscv64-softmmu,riscv64-linux-user + cd ../qemu-7.0.0 && make -j$(nproc) + cd ../qemu-7.0.0 && sudo make install + qemu-system-riscv64 --version + qemu-riscv64 --version + setup: rm -rf ${DIR} mkdir ${DIR} From 0ff1cbe92a77581121ab08e920a6e6cb249a0a6b Mon Sep 17 00:00:00 2001 From: xushanpu123 <50659045+xushanpu123@users.noreply.github.com> Date: Wed, 29 Jun 2022 10:49:31 +0000 Subject: [PATCH 2/2] add make config --- Makefile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index a8b1016..428dc16 100644 --- a/Makefile +++ b/Makefile @@ -1,3 +1,4 @@ +SHELL := /bin/zsh DOCKER_NAME ?= dinghao188/rcore-tutorial DIR := workplace .PHONY: docker build_docker @@ -17,7 +18,7 @@ lab5: test8 config: curl https://sh.rustup.rs -sSf | sh -s -- -y - . $(HOME)/.cargo/env + source /home/codespace/.cargo/env rustc --version sudo apt install autoconf automake autotools-dev curl libmpc-dev libmpfr-dev libgmp-dev \ gawk build-essential bison flex texinfo gperf libtool patchutils bc \