-Prerequisites:
- - a machine capable of compiling Linux modules
- - a correctly installed kernel source tree. Specifically,
- you need to have the file /usr/src/linux/.config and
- /usr/src/linux/include/linux/autoconf.h. If these are
- not present, you can create them by compiling a new
- kernel. Some distributions don't provide these by
- default.
- - a 2.2 or 2.4 series kernel. 2.0.38 may also work, but
- it's not actively maintained. (But feel free to try it
- and report problems.)
-
-Configure using 'make'. The first time you run make, it will take
-you through configuration options similar to compiling a linux
-kernel. If you need to run the configuration again, use 'make config'.
-Red Hat users note: Red Hat does not ship with kernel headers
-capable of compiling Comedi. You either need to install the
-kernel source RPMs, or download a kernel tarball and build a
-new kernel.
-
-Make the dependency list by running 'make' again.
-
-Compile using 'make'. If this doesn't work, make sure you have the
-basic tools installed to compile. If you can successfully compile
-other things, consult the author, as he has probably made a mistake.
+* Linux source:
+
+In order to compile the Comedi modules, you will need to have
+a correctly configured Linux kernel source tree. The best
+way to get one is to download a tarball from kernel.org and
+compile your own kernel. Comedi should work with most 2.2,
+2.4, and 2.6 Linux kernels. 2.6.x kernels older than 2.6.6 are
+not supported. Support for 2.0.3x is not actively maintained,
+but it should work and bugs will be fixed as they are reported.
+
+You can also prepare a kernel source tree that matches
+the kernel you are currently running if you have its config file (in
+the Debian distibution the config files for the kernel-image packages
+are installed into the /boot directory). The following steps will
+(almost) set up your kernel sources correctly. You will also need
+write permission to the kernel source directory the first time you
+run comedi's configure script, so you might want to unpack the kernel
+source into a directory you own.
+
+1) Get a copy of the kernel source that matches the kernel you are
+ running. Unpack it and copy your kernel config file to '.config'
+ in the top directory of your kernel source.
+2) You might need to edit the file 'Makefile' in the kernel source.
+ At the top of the Makefile, the variable EXTRAVERSION is defined.
+ If necessary, change it to match your kernel (for example, if the command
+ 'uname -r' produces "2.4.16-386" then your EXTRAVERSION should be
+ set as 'EXTRAVERSION=-386'.
+3) Run 'make oldconfig' in your kernel source directory.
+4) Run 'make dep' (for 2.6 kernels, do a 'make modules_prepare' instead
+ or even better a full 'make') in the kernel source directory and
+ you are done.
+
+Red Hat users note: Kernel sources that are distributed with Red
+Hat Linux are not supported, because they are too heavily
+modified. However, there is some information in
+Documentation/comedi/redhat-notes on how to use Red Hat kernels.
+
+* RTAI support:
+
+If you want to use the real-time capabilities of Comedi with
+RTAI, you need to compile and install RTAI first. If you
+don't install the rtai kernel modules, you may get unresolved
+symbols when installing the comedi kernel modules.
+
+* RTLinux support:
+
+If you want to use the real-time capabilities of Comedi with
+RTLinux, you need to compile RTLinux (both the kernel and the
+modules) first. Known working versions are 2.x and 3.0.
+
+* Configuration:
+
+Configure with './configure'. './configure --help' will give the
+configuration options. If the configure script does not exist
+(if you checked comedi out from git for example), it can
+be generated by running './autogen.sh'. The autoconf, automake,
+autoheader, etc. tools are required to generate the configure
+script (automake version >= 1.7 recommended). The --with-linuxdir
+option is particularly useful, as it allows you to specify
+the location of your Linux kernel source directory. If
+you are using an RT-patched kernel, the --with-rtaidir or
+--with-rtlinuxdir options allow you to specify
+the location of your RTAI or RTLinux source directory.
+
+* Compiling:
+
+Compile using 'make'. If this fails for some reason, send the
+_entire_ build log to the mailing list. Without the build
+log, it is impossible to find problems.
+
+* Installation: