i. Preface

I've been working with Linux since kernel 0.97 and with Gnat since version 2.00. In the past five years or so, I've been frustrated by the lack of documentation on Linux Ada programming. Gnat is one of the most powerful development environments for Linux, certainly superior to C or C++, and yet most people have never heard of it. Those that have often ignore it because they can't find enough documentation to install Gnat, let alone to evaluate it.

After my article "Gnat: C++ and Java under Fire", published in the October 1998 edition of Linux Journal, I decided to collect my knowledge of Linux Ada programming and set down what I've learned: from installing Gnat to interfacing with the Linux kernel. I wanted to create a book that had everything I needed in one place to write professional Linux applications. After publishers declined to put it in print because Ada developers are a small (though growing) niche in the Linux market, I decided to publish it online so that the facts about Linux Ada programming would be understood.

This document covers basic software development on Linux, a review of the core Ada 95 language, and an introduction to designing programs that work with the Linux kernel and standard C libraries. It also covers some of the Ada bindings that exist for packages like Motif, TCL and GTK+.

This book tries to describe Linux specifics whenever possible. This is not another UNIX book recycled with the word "Linux" substituted in.

Although many Ada basics are covered, this document assumes the reader is familiar with a high-level programming language such as BASIC, C, C++, Java . Borland Delphi programmers will notice similarities between Delphi and Ada.

Because C is the dominant language in the Linux world, the differences between C and Ada are hilighed throughout the text.

The document is designed to be used as a reference after it's been read, with many tables and examples covering common Linux programming problems.

Although this book covers a lot of material, it is not intended as an exhaustive survey of Linux Ada programming.Linux is in a constant state of development. Refer to your Linux documentation for the latest information and newest features. Also, Ada 95 has several application specific and portability features which are not covered since they are not related to general Linux Ada programming.

Because of the fast pace of Linux development, information in this document may be obsolete, or (to paraphrase Douglas Adams) apocryphal or wildly inaccurate. However, most of the facts have been verified against Gnat 3.11 (or a later version), and most of the examples in this document have been compiled under Gnat.

Ken O. Burtch, September 1999