Chapter 1. Working With The Nilo Sources

Table of Contents
Configuring Nilo
Building Nilo
Running Nilo
Accessing the Nilo CVS Repository

To use Nilo, you'll need to build an executable version from the source release. Recent snapshots, releases, and documentation is available from the Nilo web site.

To properly configure and build Nilo from source, you also need two other packages Nilo depends on. One is Etherboot, another open source package for booting x86 PCs over a network. Nilo uses Etherboot mostly for it's utility programs for building and manipulating object files and boot imnages.

The other package you'll need is OsKit. The OSKit is a framework and a set of 30 component libraries oriented to operating systems. The goal is that by providing in a modular way not only most of the infrastructure "grunge" needed by an OS, but also many higher-level components, the OSKit's goal is to lower the barrier to entry to OS Research and Development and to lower its costs. Nilo uses OSKit's portable Device Driver Framework so it can use FreeBSD or Linux ethernet card device drivers in source form. Nilo also uses OSkit's low-level kernel support, as well as it's filesystem and GDB support.

Configuring Nilo

Nilo uses GNU autoconf for configuring the source tree to do a build. Autoconf uses feature testing to determine the configuration of the system and tools you'll be building Nilo with. Autoconf uses configure scripts written in the m4 scripting language, which is then converted to a version 7 bourne shell script. It's this shell script that is run to configure Nilo.

Autoconf's behaviour can be modified by the use of environment variables. These are usually limited to the development tools themselves, which are commonly used by Autoconf to determine the other features. These must be set before running configure if you want them to actually have an effect.

CC

The C compiler to use. This defaults to gcc, and then cc as found in your path.

AR

The archiving program to use for building libraries. This defaults to the ar as found in your path. The default flags to ar are -qv.

AS

The assmbler to use. This defaults to the as as found in your path. This assembler must be a recent version of GNU gas that has support for producing 16bit code.

CONFIG_SHELL

This is the sub shelll used to run all the configuration tests. This usually never needs to be set execept when configuring under the Cygwin environment.

Autoconf also supports package specific configure options.

--prefix=PREFIX

Specifiy where to install architecture-independent files. The default is /usr/local.

--exec-prefix=EPREFIX

Specifiy where to install architecture-dependent files. The default is to use the same value as --prefix.

--enable-salone

Enable support to run standalone as a Unix task. This is just fro development and debugging.

--enable-trace

Enable debug tracing support. This will make Nilo print many messages to the console as it runs. This is enabled by default.

--enable-asserts

Enable support for assertions. This is enabled by default.

--enable-large-tftp

Enable support for large tftp blocks. This is enabled by default.

--enable-gdb

Enable remote GDB support. This only works when debuggging Nilo in an embedded environment. This is disabled by default.

--enable-evendor

Enable Extended DHCP Vendor support. This is enabled by default.

--enable-pxe

Enable full PXE compliance.

--with-linuxinclude

Specify the directory where the linux kernel headers are. This defaults to /usr/src/linux.

--with-linuxlib

Specify the directory where the linux libraries are. This defaults to /lib.

--with-etherbootinc=[path]

Specify the directory where the Etherboot header files are. This defaults to searching in your source tree. for the Etherboot release.

--with-oskitinc=[path]

Specify the directory where the OSKit header files are. This defaults to searching in your source tree. for the OSKit release.

--with-driver=driver1,driver2,driver3,...

Specify the drivers to build in. The default is to use all the available drivers.

Configure is typically run from a a seperate object tree so a single source tree can support multiple host architectures. It can also be run from within the source tree.

Example 1-1. Configuring Nilo


      shell prompt> tar zxvf nilo-[date].tar.gz
      shell prompt> mkdir obj
      shell prompt> cd obj
      shell prompt> ../nilo-[date]/configure -v --prefix /opt/local --with-oskitinc=/opt/src/oskit