|
|
The TAM transition library consists of a header file tam.h and a set of library routines. The file tam.h translates between TAM routines and equivalent sets of low-level ETI routines. For example, the TAM function wcreate is mapped to the conversion library function TAMwcreate, which consists of a series of low-level ETI calls, such as newwin and subwin.
To use the TAM transition library, be sure to include the standard TAM header file tam.h in your application program. So at the beginning of your TAM application program, you should already have
#include <tam.h> /* as usual, for TAM calls */Next, you recompile and link your application program, say tamprog.c, to form an executable, as follows:
cc -I /usr/add-on/include tamprog.c -ltam -locurses -o executable_nameNote the use of the -I option, which tells the compiler where to find the TAM header files. The two uses of the -l option link the requisite library subroutines, the TAM transition library and the low-level ETI library.
Alternatively, you might separately compile one or more TAM application files (say, tam1.c, tam2.c, and main.c) and later link them to form an executable program.
# compile files individually cc -c -I /usr/add-on/include/ tam1.c cc -c -I /usr/add-on/include/ tam2.c cc -c -I /usr/add-on/include/ main.cNote that the -I option is required for the compilation of any file that uses the TAM library.# link objects to form executable cc -o executable_name tam1.o tam2.o main.o -ltam -locurses