1.4 KiB
1.4 KiB
layout: post title: "Bochs" subtitle: "In two versions" tags: [osdev]
For testing out my os during development, I usually use Bochs
I also usually compile Bochs into two versions. One that has the debugger option enabled and one that runs entirely in a command line environment.
Let's go!
$ curl -L -O http://sourceforge.net/projects/bochs/files/bochs/2.5.1/bochs-2.5.1.tar.gz
$ tar -zxvf bochs-2.5.1.tar.gz
$ mkdir build-bochs
$ cd build-bochs
$ ../bochs-2.5.1/configure --enable-smp --enable-cpu-level=6 --enable-all-optimizations --enable-pci --enable-vmx --enable-logging --enable-fpu --enable-sb16=dummy --enable-cdrom --disable-plugins --disable-docbook --with-term
$ make all
$ make install
And that's the terminal version.
Important note
This configure line won't actually work. I'll update with the new one as soon as I can.
Now we move this to bochs-term and compile the version with the debugger.
$ mv /usr/local/bin/bochs /usr/local/bin/bochs-term
$ rm *
$ ../bochs-2.5.1/configure --enable-smp --enable-cpu-level=6 --enable-all-optimizations --enable-pci --enable-vmx --enable-logging --enable-fpu --enable-sb16=dummy --enable-cdrom --disable-plugins --disable-docbook --enable-debugger --enable-disasm --with-x11
$ make all
$ make install
Finally, copy the bochs bioses to a public place
$ cp -r ../bochs-2.5.1/bios /usr/share/bochs
And that's it.