================================================================
  Compilation Instructions (Aug 25, 2001)
================================================================

Mac-on-linux consists of two parts:

	- Mac-on-Linux kernel modules
	- User program


Building MOL
=============

	Building MOL is straightforward:

		bash$ make clean
		bash$ make
		bash$ make install


	If you only want to (re)build the kernel module,
	it is sufficient to do

		bash$ make clean
		bash$ make modules
		bash$ make install_modules
	
	To compile the mol user binary you will need

		  - flex
		  - bison
		  - A bugfree binutils package (2.10.0.33 is OK)

	When compiling the kernel module it is *essential* /usr/src/linux
	contains the kernel source of the running kernel (or at least the
	kernel headers part). If the kernel source is located somewhere else,
	build as follows:

		bash$ make clean
		bash$ make modules KERNEL_TREE=/path/to/kernel/source


Building RPMs
=============

	There are built-in targets for generating RPMs. The
	following makefile targets are available:

	  rpm:     	Builds mol and mol-kmods
	  mods_rpm:	Builds mol-kmods
	  mol_rpm: 	Builds mol

	It is possible to include support for more than one
	kernel version by putting the kernel source of the
	kernels in a directory THE_DIR and do

	   bash$ make mods_rpm KERNEL_TREES=THE_DIR

	Similarly, to rebuild the mol-kmods.src.rpm with support for
	the kernels in THE_DIR

	   bash$ rpm --rebuild mol-kmods.src.rpm --define 'kernel_trees THE_DIR'


Running MOL
============

	The file '/etc/molrc' contains various runtime-settings
	(which volumes to mount etc).

	After editing the 'molrc' file (usually it is sufficient 
	to change which HFS partitions to export), start MOL:

		bash$ startmol

	If you are running an unpatched 2.2.X kernel, then
	MOL hooks will be installed automatically provided that
	the file /boot/System.map file is up to date. If the
	System.map file is invalid, then there will be an
	error message. Try

		bash$ startmol vmlinux

	where 'vmlinux' is the kernel image currently running,
	or

		bash$ startmol System.map

	where 'System.map' corresponds to the running kernel
	(or even better - replace the incorrect one in the
	/boot directory)


More information, as well as a user guide, is available on 
<http://www.maconlinux.org>.

