* Cache.cs: When using sliding expiration update the cache objects
[mono.git] / mcs / errors / Makefile
1 thisdir = errors
2 SUBDIRS = 
3 include ../build/rules.make
4
5 # force this, we don't case if CSC is broken. This also
6 # means we can use --options, yay.
7
8 MCS = $(INTERNAL_MCS)
9 LOCAL_MCS_FLAGS = /nowarn:162 --wlevel 4
10
11 RUNTEST_PL = ./runtest.pl
12
13 DISTFILES = \
14         CONTRIBUTORS_README     \
15         README.tests            \
16         errors.txt              \
17         fail                    \
18         runtest.pl              \
19         $(wildcard *.cs)
20
21 #all-local: run-test-local test-multi-local
22 all-local:
23
24 test-local:
25
26 # again, run-test is when the tests actually happen, so
27 # don't compile on make test.
28
29 run-test-local:
30         @ failed=false; \
31         for i in cs*.cs; do \
32                 case $$i in \
33                         cs[0-9]*-[0-9]*cs) \
34                         error=`echo $$i | sed -e 's/cs*//' -e 's/.cs//' -e 's/-.*//'`; \
35                         ;;\
36                         cs[0-9-]*cs)  \
37                         error=`echo $$i | sed -e 's/cs*//' -e 's/.cs//'`; \
38                         ;;\
39                 esac; \
40                 echo -n "Running test $$i ... "; \
41                 options=`fgrep "// Compiler options:" $$i | sed -e 's/\/\/ Compiler options://'`; \
42                 if $(CSCOMPILE) --expect-error $$error $$i $$options > /dev/null; \
43                 then echo OK; \
44                 else echo FAILED; \
45                      flist="$$flist $$i"; \
46                      failed=true; \
47                 fi; \
48         done; \
49         if $$failed; then \
50                 echo "The compiler failed to flag the following errors: $$flist"; \
51         else \
52                 echo All tests passed; \
53         fi
54
55 test-multi-local:
56         @ failed=false; \
57         for i in error-*.cs; do \
58                 echo -n "Running test $$i ... "; \
59                 if MCS='$(INTERNAL_MCS)' $(RUNTEST_PL) $$i > /dev/null; \
60                 then echo OK; \
61                 else echo FAILED; \
62                      flist="$$flist $$i"; \
63                      failed=true; \
64                 fi; \
65         done; \
66         if $$failed; then \
67                 echo "The following tests failed: $$flist"; \
68         else \
69                 echo All tests passed; \
70         fi
71
72 clean-local:
73         rm -f *.exe
74         rm -f *.dll
75
76 dist-local: dist-default
77
78 install-local uninstall-local: