3 include ../../build/rules.make
5 ifeq (default, $(PROFILE))
6 # force this, we don't case if CSC is broken. This also
7 # means we can use --options, yay.
9 MCS = MONO_PATH="$(topdir)/class/lib/$(PROFILE)$(PLATFORM_PATH_SEPARATOR)$$MONO_PATH" $(INTERNAL_MCS)
12 XMLDOCDIFF = $(TEST_RUNTIME) ../xmldocdiff.exe
14 all-local $(STD_TARGETS:=-local):
17 @f=../$*.cs; options=`sed -n 's,^// Compiler options:,,p' $$f`; \
18 case $$options in *-t:library*) ext=dll ;; *-t:module*) ext=netmodule ;; *) ext=exe ;; esac; \
19 testlogfile="$*.log" ; \
20 echo '*** $(CSCOMPILE)' "$$options -out:$*.$$ext $$f" > $$testlogfile ; \
21 if $(CSCOMPILE) $$options -out:$*.$$ext $$f >> $$testlogfile 2>&1 ; then \
22 if test -f $*.exe; then \
23 echo '*** $(TEST_RUNTIME) -O=-all ./$*.exe' >> $$testlogfile ; \
24 if $(TEST_RUNTIME) -O=-all ./$*.exe >> $$testlogfile 2>&1 ; then \
25 if test -f $*.xml; then \
26 if $(XMLDOCDIFF) ../$*-ref.xml $*.xml >> $$testlogfile ; then \
27 echo "PASS: $*: xml comparison" > $@ ; \
28 rm -f $$testlogfile ; \
30 echo "FAIL: $*: xml comparison" > $@ ; \
33 echo "PASS: $*" > $@ ; \
34 rm -f $$testlogfile ; \
37 echo "Exit code: $$?" >> $$testlogfile ; \
38 echo "FAIL: $*" > $@ ; \
41 echo "PASS: $*: compilation" > $@ ; \
42 rm -f $$testlogfile ; \
45 echo "Exit code: $$?" >> $$testlogfile ; \
46 echo "FAIL: $*: compilation" > $@ ; \
49 if test ! -f $$testlogfile ; then :; else cat $$testlogfile; fi
51 # test ordering dependencies will be pasted after this