1 Star 0 Fork 10

ENDEAVOR/oslab

forked from CN-GuoZiyang/oslab 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
setup 1.24 KB
一键复制 编辑 原始数据 按行查看 历史
CN-GuoZiyang 提交于 2020-05-30 13:18 . update setup.
#!/bin/bash
export OSLAB_PATH=$(cd $(dirname "${BASH_SOURCE[0]}") >/dev/null && pwd)
debianSetup() {
sudo dpkg --add-architecture i386
sudo apt update
sudo apt-get install -y binutils
sudo apt-get install -y binutils-common
sudo apt-get install -y build-essential bin86 manpages-dev libc6-dev-i386 zlib1g:i386 libncurses5:i386 libsm-dev:i386 libx11-dev:i386 libxpm-dev:i386 libexpat1:i386
cp $OSLAB_PATH/gcc-3.4-ubuntu.tar.gz /tmp
tar zxvf /tmp/gcc-3.4-ubuntu.tar.gz -C /tmp/
cd /tmp/gcc-3.4
sudo ./inst.sh amd64
cd $OSLAB_PATH
tar zxvf $OSLAB_PATH/linux-0.11.tar.gz -C $OSLAB_PATH
}
archSetup() {
echo "Please make sure you've added the archlinuxcn source!(Y or n)"
read res
if [ $res = "N" -o $res = "n" ]; then
echo "Please add archlinuxcn source first!"
else
sudo pacman -U *.pkg.tar.xz
sudo pacman -S gcc bin86 base-devel lib32-ncurses5-compat-libs
tar zxvf $OSLAB_PATH/linux-0.11.tar.gz -C $OSLAB_PATH
fi
}
if [ $# -lt 1 ]; then
echo "Please add your distro name(debian, archlinux) as the first argument!"
elif [ $1 = "debian" ]; then
debianSetup
elif [ $1 = "archlinux" ]; then
archSetup
else
echo "This distro is not supported!(debian and archlinux is supported at present)"
fi
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/zhushaoxiong_admin/oslab.git
git@gitee.com:zhushaoxiong_admin/oslab.git
zhushaoxiong_admin
oslab
oslab
master

搜索帮助