如果没有安装g++、gtk,需要先安装,如果安装过程提示有其它东西没有安装,根据提示安装。
下面是安装流程,摘自官方网站:
This example shows the output of a compilation and installation on Linux.
user$ ls -l bochs-2.5.tar.gz -rw-r--r-- 1 user users 4117999 27. Nov 17:14 bochs-2.5.tar.gz user$ gunzip -c bochs-2.5.tar.gz | tar -xvf - bochs-2.5/ bochs-2.5/.conf.sparc bochs-2.5/build/ bochs-2.5/build/macosx/ bochs-2.5/build/macosx/pbdevelopment.plist bochs-2.5/build/macosx/make-dmg.sh . . . bochs-2.5/memory/memory.cc bochs-2.5/memory/misc_mem.cc bochs-2.5/memory/Makefile.in user$ cd bochs-2.5 user$ ./configure --enable-debugger --enable-disasm checking build system type... x86_64-unknown-linux-gnu checking host system type... x86_64-unknown-linux-gnu checking target system type... x86_64-unknown-linux-gnu checking if you are configuring for another platform... no checking for standard CFLAGS on this platform... checking for gcc... gcc . . . config.status: creating build/win32/nsis/bochs.nsi config.status: creating host/linux/pcidev/Makefile config.status: creating config.h config.status: creating ltdlconf.h user$ make cd iodev && \ make libiodev.a make[1]: Entering directory `/home/volker/Archiv/test/bochs-2.5/iodev' g++ -c -I.. -I./.. -I../instrument/stubs -I./../instrument/stubs -g -O2 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES devices.cc -o devices.o g++ -c -I.. -I./.. -I../instrument/stubs -I./../instrument/stubs -g -O2 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES virt_timer.cc -o virt_timer.o g++ -c -I.. -I./.. -I../instrument/stubs -I./../instrument/stubs -g -O2 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES slowdown_timer.cc -o slowdown_timer.o g++ -c -I.. -I./.. -I../instrument/stubs -I./../instrument/stubs -g -O2 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES pic.cc -o pic.o . . . echo done done /bin/sh ./libtool --mode=link g++ -o bochs -g -O2 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -DBX_SHARE_PATH='"/usr/local/share/bochs"' -export-dynamic logio.o main.o config.o load32bitOShack.o pc_system.o osdep.o plugin.o crc.o \ iodev/libiodev.a cpu/libcpu.a cpu/cpudb/libcpudb.a \ memory/libmemory.a gui/libgui.a \ disasm/libdisasm.a \ fpu/libfpu.a \ -lSM -lICE -lX11 -lXpm -lXrandr \ \ \ \ \ -lm mkdir .libs g++ -o bochs -g -O2 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -DBX_SHARE_PATH=\"/usr/local/share/bochs\" logio.o main.o config.o load32bitOShack.o pc_system.o osdep.o plugin.o crc.o -Wl,--export-dynamic iodev/libiodev.a cpu/libcpu.a cpu/cpudb/libcpudb.a memory/libmemory.a gui/libgui.a disasm/libdisasm.a fpu/libfpu.a -lSM -lICE -lX11 -lXpm -lXrandr -lm gcc -c -I. -I./. -Iinstrument/stubs -I./instrument/stubs -g -O2 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES ./misc/bximage.c -o misc/bximage.o /bin/sh ./libtool --mode=link g++ -o bximage -g -O2 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES misc/bximage.o g++ -o bximage -g -O2 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES misc/bximage.o gcc -c -I. -I./. -Iinstrument/stubs -I./instrument/stubs -g -O2 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES ./misc/bxcommit.c -o misc/bxcommit.o /bin/sh ./libtool --mode=link g++ -o bxcommit -g -O2 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES misc/bxcommit.o g++ -o bxcommit -g -O2 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES misc/bxcommit.o user$ su root# make install cd iodev && \ make libiodev.a make[1]: Entering directory `/home/volker/Archiv/test/bochs-2.5/iodev' . . . for i in CHANGES COPYING README TODO; do if test -f $i; then install -m 644 $i /usr/local/share/doc/bochs; else install -m 644 ./$i /usr/local/share/doc/bochs; fi; done rm -f /usr/local/share/doc/bochs/README cat ./build/linux/README.linux-binary ./README > /usr/local/share/doc/bochs/README install -m 644 ./.bochsrc /usr/local/share/doc/bochs/bochsrc-sample.txt root# exit user$ _
照着做好了,一切ok,官网上说make过程中可能会出现错误,如果出现状况,请看下面:
Of course, make can only do the right thing if the Makefile lists all the dependencies correctly, so human error can sometimes lead make astray. If make refuses to build something that you think it should, or you are getting strange compile errors, try doing make all-clean and then make again. All-clean means to clean up the compiled files in every subdirectory, while make clean means to clean up just the current directory[2]. However, it's important to note that make all-clean leaves the configuration intact. You do not have to run configure again.
If you're really in the mood for cleaning, make dist-clean erases all the configuration information too. In theory, after a dist-clean your directory should look much like when you first untarred it or checked it out. There's usually some extra stuff lying around, but the Makefile tries at least to erase any files that it created.
如果你需要更多细节,请看原网页:
http://bochs.sourceforge.net/cgi-bin/topper.pl?name=New+Bochs+Documentation&url=http://bochs.sourceforge.net/doc/docbook/user/index.html