在ubuntu上安装QEMU

学习THU的操作系统公开课,安装QEMU来做实验,还可以用来当做ARM开发板。

预备工作:安装SDL 2.0,否则运行起来只有VNC server running on 127.0.0.1:5900

sudo apt-get install libsdl2-2.0
sudo apt-get install libsdl2-dev

1.下载并编译QEMU 3.0.0版本

 wget https://download.qemu.org/qemu-3.0.0.tar.xz
 tar xvJf qemu-3.0.0.tar.xz
 cd qemu-3.0.0
 ./configure
 make

在进行./configure出现两个错误:
(1)ERROR: glib-2.40 gthread-2.0 is required to compile QEMU
解决方法:sudo apt-get install libglib2.0-dev
(2)ERROR: pixman >= 0.21.8 not present. Please install the pixman devel package.
解决方法:sudo apt-get install libpixman-1-dev
./configure完成后的输出中应该有SDL suppport yes

2.安装sudo make install
出现两个错误:
(1)flex: Command not found
解决方法:sudo apt-get install flex
(2)bison: Command not found
解决方法:sudo apt-get install bison
安装好的QEMU在 /usr/local/bin
为了节省空间,安装完成后又make clean了。

猜你喜欢

转载自blog.csdn.net/u013213111/article/details/88871290