* added compilers lcc and bcc (linux86)
[mascara-docs.git] / compilers / linux86-0.16.17 / libc / regexp / Makefile.org
bloba8be06ebaf1f7542fc86b1b0b5e10829ecd087f6
1 # Things you might want to put in ENV and LENV:
2 # -Dvoid=int            compilers that don't do void
3 # -DCHARBITS=0377       compilers that don't do unsigned char
4 # -DSTATIC=extern       compilers that don't like "static foo();" as forward decl
5 # -DSTRCSPN             library does not have strcspn()
6 # -Dstrchr=index        library does not have strchr()
7 # -DERRAVAIL            have utzoo-compatible error() function and friends
8 # ENV=-DCHARBITS=0377
9 # LENV=-DCHARBITS=0377
11 # Things you might want to put in TEST:
12 # -DDEBUG               debugging hooks
13 # -I.                   regexp.h from current directory, not /usr/include
14 TEST=-I.
16 # Things you might want to put in PROF:
17 # -Dstatic='/* */'      make everything global so profiler can see it.
18 # -p                    profiler
19 PROF=
21 CFLAGS=-O $(ENV) $(TEST) $(PROF)
22 LINTFLAGS=$(LENV) $(TEST) -ha
23 LDFLAGS=-i
25 OBJ=regexp.o regsub.o
26 LSRC=regexp.c regsub.c regerror.c
27 DTR=README dMakefile regexp.3 regexp.h regexp.c regsub.c regerror.c \
28         regmagic.h try.c timer.c tests
30 try:    try.o $(OBJ)
31         cc $(LDFLAGS) try.o $(OBJ) -o try
33 # Making timer will probably require putting stuff in $(PROF) and then
34 # recompiling everything; the following is just the final stage.
35 timer:  timer.o $(OBJ)
36         cc $(LDFLAGS) $(PROF) timer.o $(OBJ) -o timer
38 timer.o:        timer.c timer.t.h
40 timer.t.h:      tests
41         sed 's/ /","/g;s/\\/&&/g;s/.*/{"&"},/' tests >timer.t.h
43 # Regression test.
44 r:      try tests
45         @echo 'No news is good news...'
46         try <tests
48 lint:   timer.t.h
49         @echo 'Complaints about multiply-declared regerror() are legit.'
50         lint $(LINTFLAGS) $(LSRC) try.c
51         lint $(LINTFLAGS) $(LSRC) timer.c
53 regexp.o:       regexp.c regexp.h regmagic.h
54 regsub.o:       regsub.c regexp.h regmagic.h
56 clean:
57         rm -f *.o core mon.out timer.t.h dMakefile dtr try timer
59 dtr:    r makedtr $(DTR)
60         makedtr $(DTR) >dtr
62 dMakefile:      Makefile
63         sed '/^L*ENV=/s/ *-DERRAVAIL//' Makefile >dMakefile