]> andersk Git - splint.git/blob - test/db1/Makefile
Fixed problem with global struct assignments.
[splint.git] / test / db1 / Makefile
1 ###
2 ### Splint db1 test
3 ###
4 ### Taken from sample, second iteration: weakchecks
5 ###
6
7 .SUFFIXES: .lcl .lcs .lh .h .c .o
8 .PHONY: check clean
9
10 ### SHELL = /bin/csh -f
11
12 SPLINT = splint -booltype bool -booltrue TRUE -boolfalse FALSE
13 LCL = $(SPLINT) -specundef +lh +quiet -nof
14 SPLINTLH = $(SPLINT) +lh
15 LCSFILES = bool.lcs dbase.lcs employee.lcs empset.lcs erc.lcs eref.lcs ereftab.lcs 
16
17 MODULES = bool.lcl employee eref empset ereftab erc dbase drive.c
18 OBJS = dbase.o employee.o empset.o erc.o eref.o ereftab.o 
19
20 test: 
21         $(MAKE) -e clean
22         $(MAKE) -e check
23
24 ###
25 ### Removed +showscan, produces different results on different platforms
26 ###
27
28 ### evans 2002-12-17: 2 fewer weak errors because of -abstractcompare default in weak
29
30 check: $(LCSFILES)
31         -$(SPLINT) -showcol -weak $(MODULES) -expect 19
32         -$(SPLINT) -showcol +strict -bounds -modfilesystem +showsummary $(MODULES) -expect 338
33
34 # evans 2002-07-09: 5 bufferoverflowhigh warnings for using sprintf
35
36 ### The following rules generate .lh and .lcs files from .lcl files.  They also
37 ### ensure that .h files appear to be updated whenever the corresponding .lh
38 ### file is updated.
39
40 .lcl.lh:
41         $(LCL) $*.lcl
42
43 .lcl.lcs:
44         $(LCL) $*.lcl
45
46 .lh.h:
47         touch $*.h
48
49 .c.o:
50         $(GCC) -c $*.c 
51
52 ###
53 ### Clean removes junk and all derived files.
54 ### Tidy removes junk and object and executable files.
55 ###
56
57 clean: tidy
58         -@rm -f *.c.html *.lcl.html *.h.html *.lh.html *.lcs *.lh 1> /dev/null
59
60 tidy:
61         -@rm -f ,* .,* *.CKP *.BAK .emacs_[0-9]* core a.out *.*~ *~ *.o drive 11> /dev/null
62
63 ### The following dependencies ensure that imported LCL specs 
64 ### are checked before the specs that import them.
65
66 dbase.lcs:   employee.lcs empset.lcs 
67 empset.lcs:  employee.lcs
68 erc.lcs:     eref.lcs
69 eref.lcl:    employee.lcs
70 ereftab.lcs: employee.lcs eref.lcs
71
72 ### The following dependencies ensure that a .o file is recompiled when the
73 ### corresponding .c file, or one of the .h files it #includes, is changed.
74
75 dbase.o:    dbase.c bool.h dbase.h employee.h empset.h
76 drive.o:    drive.c bool.h dbase.h employee.h empset.h erc.h eref.h ereftab.h 
77 employee.o: employee.c employee.h 
78 empset.o:   empset.c bool.h empset.h erc.h eref.h employee.h employee.h 
79 erc.o:      erc.c bool.h erc.h eref.h employee.h 
80 eref.o:     eref.c eref.h employee.h 
81 ereftab.o:  ereftab.c bool.h ereftab.h erc.h eref.h employee.h 
This page took 0.045994 seconds and 5 git commands to generate.