centos 6.5 32bit qemu 环境搭建

安装centos 6.5 32bit software development distribution


解决ssh连接慢的问题
UseDNS no
GSSAPIAuthentication no


securecrt设置
Options -> Session Options -> Emulation,然后把Terminal类型改成xterm,并点中ANSI Color复选框。
Options -> Session Options -> Appearance,将Character设成"UTF-8"即可(缺省是"default")。
字体:建议用fixedsys,这个字体虽然不是最美丽的,但在终端上也是一个不错选择,大家都可以接受。


安装好之后
yum -y install epel-release
yum groupinstall "Development Tools"


安装python
yum -y install python34
然后会有2个版本python
[root@centos ~]# python 
Python 2.6.6 (r266:84292, Nov 22 2013, 12:11:10) 
[GCC 4.4.7 20120313 (Red Hat 4.4.7-4)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> 
[root@centos ~]# python3
Python 3.4.5 (default, Jun  1 2017, 13:52:14) 
[GCC 4.4.7 20120313 (Red Hat 4.4.7-18)] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> qemu cc cannot build an executable
python3会是py文件默认解释器 (default字样)


安装binwalk
cd ~/
git clone https://github.com/ReFirmLabs/binwalk.git
cd binwalk
./setup.py install
发现默认安装到python2.6上去了。
安装到python3.4
python3 setup.py install
cd ~/
rm -rf binwalk


编译一些静态库(qemu静态编译需要)
wget ftp://ftp.gnupg.org/gcrypt/libgpg-error/libgpg-error-1.27.tar.gz
tar xzvf libgpg-error-1.27.tar.gz
cd libgpg-error-1.27
./configure --enable-static
make
make install 


wget --no-check-certificate https://www.gnupg.org/ftp/gcrypt/libgcrypt/libgcrypt-1.8.2.tar.bz2
bunzip2 libgcrypt-1.8.2.tar.bz2 
tar xvf libgcrypt-1.8.2.tar
./configure --enable-static
make
make install 


wget --no-check-certificate https://www.cairographics.org/releases/pixman-0.34.0.tar.gz
tar xzvf pixman-0.34.0.tar.gz
cd pixman-0.34.0
./configure --enable-static
make
make install 


gtk-x11-2.0
我曹怎么还需要这个,放弃了  --disable-gtk,反正只需要命令行的qemu


安装qemu
yum install zlib-static
yum install glib2-devel libfdt-devel libaio-devel libcap-devel libiscsi-devel zlib-devel pixman-devel
yum install glibc-static libtool
yum install glib2-static glibc-utils glibc glib glib-devel glib-networking
yum install glib*
yum install libgcrypt* 无效 好像缺静态库
cd  /opt  
sudo git clone https://github.com/qemu/qemu.git
cd qemu
(可选)git branch -a | grep stable-2
(可选)git checkout stable-2.8
git submodule init  
git submodule update --recursive
export PKG_CONFIG_LIBDIR=/usr/bin/pkg-config
./configure --static --disable-gtk
make -j8
make install  

你可能感兴趣的:(centos 6.5 32bit qemu 环境搭建)