免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
最近访问板块 发新帖
查看: 1292 | 回复: 0
打印 上一主题 下一主题

qemu 编译 [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2011-12-22 08:51 |只看该作者 |倒序浏览
在ubuntu1104中,使用 sudo apt-get source qemu 下载到 qemu-kvm-0.14.0+noroms
然后sudo  ./configure 报告错误
===
Error: zlib check failed
Make sure to have the zlib libs and headers installed.
===
这需要安装zlib
用如下的命令
sudo apt-get install zlib1g-dev
安装好后,再运行configure,就会有下面的这堆配置。
===
ldm@ldm-TOP2:/usr/src/qemu-kvm-0.14.0+noroms$ sudo ./configure

Error: libpci header check failed
Disable KVM Device Assignment capability.

Install prefix    /usr/local
BIOS directory    /usr/local/share/qemu
binary directory  /usr/local/bin
config directory  /usr/local/etc
Manual directory  /usr/local/share/man
ELF interp prefix /usr/gnemul/qemu-%M
Source path       /usr/src/qemu-kvm-0.14.0+noroms
C compiler        gcc
Host C compiler   gcc
CFLAGS            -O2 -g
QEMU_CFLAGS       -m32 -D_FORTIFY_SOURCE=2 -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -Wstrict-prototypes -Wredundant-decls -Wall -Wundef -Wendif-labels -Wwrite-strings -Wmissing-prototypes -fno-strict-aliasing  -fstack-protector-all -Wmissing-include-dirs -Wempty-body -Wnested-externs -Wformat-security -Wformat-y2k -Winit-self -Wignored-qualifiers -Wold-style-declaration -Wold-style-definition -Wtype-limits
LDFLAGS           -Wl,--warn-common -m32 -g
make              make
install           install
host CPU          i386
host big endian   no
target list       x86_64-softmmu
tcg debug enabled no
Mon debug enabled no
gprof enabled     no
sparse enabled    no
strip binaries    yes
profiler          no
static build      no
-Werror enabled   no
SDL support       no
curses support    yes
curl support      no
check support     no
mingw32 support   no
Audio drivers     oss
Extra audio cards ac97 es1370 sb16 hda
Block whitelist  
Mixer emulation   no
VNC TLS support   no
VNC SASL support  no
VNC JPEG support  no
VNC PNG support   no
VNC thread        no
xen support       no
CPU emulation     yes
brlapi support    no
bluez  support    no
Documentation     no
NPTL support      yes
GUEST_BASE        yes
PIE user targets  no
vde support       no
IO thread         no
Linux AIO support no
ATTR/XATTR support no
Install blobs     yes
KVM support       yes
KVM PIT support   yes
KVM device assig. no
fdt support       no
preadv support    yes
fdatasync         yes
madvise           yes
posix_madvise     yes
uuid support      no
vhost-net support yes
Trace backend     nop
Trace output file trace-<pid>
spice support     no
rbd support       no
xfsctl support    no
ldm@ldm-TOP2:/usr/src/qemu-kvm-0.14.0+noroms$
===
然后make,成功,编译出了x86_64-softmmu/qemu-system-x86_64

如果想编qemu-system-arm,可以用如下命令
sudo ./configure --target-list=arm_softmmu
make
Error: libpci header check failed
sudo apt-cache search libpci
sudo apt-get install libpci-dev
正确的命令应该是
sudo ./configure --target-list=arm-softmmu
查看target-list的配置可以打开qemu源根目录下的configure文件,搜索target-list 关键字。
会在arm-softmmu目录下生成qemu-system-arm文件。

安装未执行。另外,./configure --prefix=目录,可以指定安装目录。
从配置时的输出消息中可以看到,安装目录默认为/usr/local

您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP