1 | README: |
---|
2 | |
---|
3 | This directory contains the files for 'cxref', a C language cross |
---|
4 | referencing program. |
---|
5 | |
---|
6 | The makefile will build the program. Use 'make install' to put a copy in |
---|
7 | the right places. Cxref is a driver, and goes in DESTDIR, which will be your |
---|
8 | local bin of choice. LIB is where the programs go that do the work. The |
---|
9 | makefile makes the directory /usr/local/lib/cxref (i.e. LIB) to hold the |
---|
10 | programs. The cxref driver is dependant on where LIB is. I have them set to |
---|
11 | use my BIN. BIN is taken from the environment, since I use the UNIX 4.0 make. |
---|
12 | SORT is the full pathname for the Unix sort program, sometimes /bin/sort, |
---|
13 | other times /usr/bin/sort. Edit the makefile to set everything up properly. |
---|
14 | |
---|
15 | System III and V users should edit the file 'basename.c' to change the |
---|
16 | call to 'rindex' to 'strrchr'. |
---|
17 | |
---|
18 | The flow of information between programs is shown below. |
---|
19 | I suggest that you run the programs separately, successively adding the next |
---|
20 | program in a particular pipeline, to see how the information is transformed. |
---|
21 | The outline below of the flow of control does not necessarily show all |
---|
22 | the arguments that each program requires; see the source code to |
---|
23 | be sure, when you run the programs by hand. |
---|
24 | |
---|
25 | With some work in the cscan.l and cxref.c files, this program could be |
---|
26 | easily made to cross reference other languages. |
---|
27 | |
---|
28 | Here is a list of the files, and what they contain: |
---|
29 | |
---|
30 | README --- this file. |
---|
31 | cxref.1 --- man page. |
---|
32 | makefile --- the makefile. |
---|
33 | |
---|
34 | cxref.c --- driver, calls all the other programs, does arg handling. |
---|
35 | old.cxref.c --- old version, used the shell to do the dirty work. |
---|
36 | (this file can probably be deleted.) |
---|
37 | |
---|
38 | constdefs.h --- header file, used by cscan.l and cxrfilt.c. |
---|
39 | |
---|
40 | cscan.l --- does the work of finding indentifiers and contsants. |
---|
41 | docxref.c --- main program and some other stuff to drive lex. |
---|
42 | |
---|
43 | cxrfilt.c --- filters int and floats to their own files. |
---|
44 | also puts ints and floats back together after sorting. |
---|
45 | |
---|
46 | fmtxref.c --- formats output for printing. |
---|
47 | |
---|
48 | SORT[1-3] --- shell files to save typing during testing and development. |
---|
49 | |
---|
50 | |
---|
51 | For development, the flow of programs is: |
---|
52 | |
---|
53 | docxref files | SORT1 | cxrfilt | fmtxref |
---|
54 | SORT2 < tempfile1 | cxrfilt -i | fmtxref |
---|
55 | SORT3 < tempfile2 | cxrfilt -f | fmtxref |
---|
56 | |
---|
57 | Arnold Robbins, Information and Computer Science, Georgia Tech |
---|
58 | gatech!arnold |
---|
59 | January 1985. |
---|
60 | Copyright (c) 1985 by Arnold Robbins. |
---|
61 | All rights reserved. |
---|