2. Installing RTLINUX
The first step in the compilation of RTLinux kernel, is to download a pre-patched kernel 2.2.18 (x86 only) 2.2.18 (x86 only) or 2.4.0-test1 (x86, PowerPC, Alpha) into /usr/src/ and untar it. Also put a fresh copy of RTLinux kernel (version 3.0) from www.rtlinux.org in /usr/src/rtlinux/. (We will use $ to represent the prompt).
- Now, configure the Linux kernel :
$ cd /usr/src/linux $ make config or $ make menuconfig or $ make xconfig
- For building the kernel image, type :
$ make dep $ make bzImage $ make modules $ make modules_install $ cp arch/i386/boot/bzImage /boot/rtzImage
- Next step is to configure LILO. Type in the following lines in the file
/etc/lilo.conf
image=/boot/rtzImage label=rtl read-only root=/dev/hda1
WARNING: replace /dev/hda1 in the above with your root filesystem. The easiest way to find out which filesystem it should be, take a look at the existing entry in your /etc/lilo.conf for "root=". - Now, restart your computer and load the RTLinux kernel by typing 'rtl'
at the LILO prompt. Then 'cd' to /usr/src/rtlinux/ and configure RTLinux.
$ make config or $ make menuconfig or $ make xconfig
- Finally, for compiling RTLinux
$ make $ make devices $ make install
The last step will create the directory:
/usr/rtlinux-xx (xx denotes the version)
which contains the default installation directory for RTLinux which is needed to create and compile user programs (that is, it contains the include files, utilities, and documentation). It will also create a symbolic link:
/usr/rtlinux
which points to /usr/rtlinux-xx. In order to maintain future compatibility, please make sure that all of your own RTLinux programs use /usr/rtlinux as its default path.
NOTE : If you change any Linux kernel options, please don't forget to do:
$ cd /usr/src/rtlinux $ make clean $ make $ make install
Next Previous Contents