RTLGNAT version 1.0 Copyright (c) OCERA Consortium. Dec, 2002. Please, read the license terms and conditions in the accompanying file: COPYRIGHT.txt Requirements ============ (Please, see the README.txt if you need more details) 1. Linux with the BigPhysArea patch. 2. RTLinux 3.2-pre1 or 3.2-pre2 and its sources. 3. GNAT 3.14p or GNAT 3.15p. Installation ============ Before starting the RTLGnat installation, please make sure that the GNAT compiler is correctly installed: ftp://cs.nyu.edu/pub/gnat/ If you have RTLinux already installed AND YOU HAVE NOT ALREADY APPLIED OTHER PATCHES TO IT, then you may skip steps 1-9. 0.- Please, be sure that you have the original GNAT compiler distributed by ACT (ftp://cs.nyu.edu/pub/gnat/), and REMOVE any other gnat included in your Linux distribution. Otherwise, broken executables and libraries can be generated. 1.- Unpack the Linux (2.4.18 or later) source tarball. 2.- Apply the BigPhysArea patch to the Linux sources. This patch is available at http://www.polyware.nl/~middelink/En/hob-v4l.html 3.- Apply the RTLinux patch to the Linux source code. Available at http://www.rtlinux-gpl.org or http://www.rtlinux.org 4.- Configure the linux kernel (remember to select the Bigphysarea functionality). 5.- Compile the Linux kernel (make dep; make clean; make ....) 6.- Unpack the RTLGnat tarball in the directory of your choice. For example, /usr/src. This will create the directory /usr/src/RTLGnat-1.0, containing the modified run-time system for RTLGnat (in the adainclude directory), two patches for the three supported versions of RTLinux and some simple examples in the rtl_examples directory. 7.- Apply the patch rtlgnat1.0-RTLinux.patch. The value of depends on what version of RTLinux has been installed. It may be "3.1", "3.2pre1" or "3.2pre2". 8.- Configure and compile RTLinux. You will need to set the default options plus: - Priority inheritance (POSIX Priority Protection) - Dynamic memory manager - POSIX Signals support - Floating Point support 9.- Add the following line to the /etc/lilo.conf file: append="bigphysarea=1024" and run lilo. If you use a different boot loader (like GRUB), then configure it accordingly. 10.- Reboot your computer with the new kernel. 11.- Edit the /usr/src/RTLGnat-1.0/Makefile and modify the path variables to point to the right directories. 12.- Make sure that the proper version of gnat is at the beginning of the PATH variable: export PATH=/usr/gnat/bin:$PATH 13.- You may need root privileges (write access to the GNAT directory) to compile RTLGnat because it will add some files to the standard GNAT distribution. 14.- Compile RTLGnat by running "make" from the /usr/src/RTLGnat-1.0 directory (assuming /usr/src was the directory of your choice in step 10). You will need to manually assign the variables GNAT_PATH, GCC_295 and KERNELS in the first lines of Makefile. 15.- Now RTLGnat has been installed and compiled jointly with the standard Gnat distribution. You can find the RTLGnat examples in $GNAT_PATH/rtl_examples (usually at /usr/gnat/rtl_examples). To compile the examples, just run "make" from the mentioned directory. 16.- Remember to load the RTLinux modules before loading (running) the Ada application): "rtlinux start" RTLGnat 1.0 will be installed in the directory where GNAT is already installed. The modifications to the GNAT installation will include a directory called rts-rtlinux, where the needed libraries will be located, and the executables rtlgnatmake, rtload and rtunload (see next section for an explanation on the use of these commands.) How to compile and run your own Ada applications ================================================ The compilation process will create the "rtlgnatmake" script. This script is the equivalent to "gnatmake" in GNAT for Linux. Simply run: # rtlgnatmake my_app.adb to obtain the application module "my_app" Once you have created your application object module, RTLinux needs to be loaded in order to run your application: # rtlinux start Now you should start up your application by doing: # rtload my_app To terminate and remove your running application just run: # rtunload my_app to remove the module. Enjoy!