Chinaunix首页 | 论坛 | 博客
  • 博客访问: 55396
  • 博文数量: 12
  • 博客积分: 935
  • 博客等级: 准尉
  • 技术积分: 230
  • 用 户 组: 普通用户
  • 注册时间: 2005-05-04 18:01
文章分类

全部博文(12)

文章存档

2008年(12)

我的朋友
最近访客

分类:

2008-03-24 10:19:02

zz from :

When we're done, we'll have a floppy disk image. This image can be written to a floppy that a PC can boot from. It can also be used as the El Torito boot file for a bootable CDROM. These images (floppy or CDROM) can also be run in any number of PC emulators. I've done a lot of my testing running them in qemu.

Set Inferno Configuration

Set the appropriate values in mkconfig in the Inferno root directory. Pay particular attention to the variables ROOT, SYSHOST, and OBJTYPE.

Building the Tool Chain

If you're working in Windows, you already have the toolchain in place in C:\Inferno\Nt\386\bin. For other host OSs (Linux, FreeBSD, Plan9), an "mk install" issued at a host OS prompt in the Inferno root directory. Be sure your PATH environmet variable includes your Inferno binaries directory.

Configure the Native Kernel and Install Boostrapping Code

Don't worry, we're not installing the Inferno bootstrapping code to your host machine. We're just building it and putting it in a standard place so we can use it later.
  1. In os/boot/pc in the Inferno tree, issue the command "mk pbs.install 9load.install" at a host OS prompt.
  2. Edit os/pc/pc to set up the kernel configuration. A simple/minimal set of changes to get something that you can see working is:
    1. Change wminit to shell in the init section.
    2. Set the consoleprint variable in the code section to 1.
    3. Add the files /dis/lib/arg.dis and /dis/lib/filepat.dis to the root section.
  3. Create a file in os/pc called plan9.ini. If you're going to boot directly from the floppy, it should include the line: "bootfile=fd0!ipc.gz". If you're going to build a bootable CD, the line should be "bootfile=sdD0!cdboot!ipc.gz". This assumes your CD is the master drive on the second IDE controller, which is probably the most common configuration.

Build the Floppy Image

  1. Issue the "mk" command in os/pc at a host OS prompt.
  2. Issue the "gzip ipc" command in os/pc at an Inferno shell prompt.
  3. Issue the following command in os/pc at an Inferno shell prompt:
    disk/format -b /Inferno/386/pbs -df disk /Inferno/386/9load plan9.ini ipc.gz
The result will be a file called "disk" that can be written raw to a floppy or used to create a bootable CDROM.


//非常难得的文档,关于native inferno的资料非常稀少
阅读(1345) | 评论(0) | 转发(0) |
0

上一篇:没有了

下一篇:临睡肌跃症 (hypnic jerk)

给主人留下些什么吧!~~