Update with current status
[gnash.git] / testsuite / misc-mtasc.all / Makefile.am
blob39b0db0c5a3948ff4b691375d2316dcc96fd7cca
1 ## Process this fill with automake to generate Makefile.in
2
3 #   Copyright (C) 2007, 2008, 2009, 2010, 2011, 2012
4 #   Free Software Foundation, Inc.
6 # This program is free software; you can redistribute it and/or modify
7 # it under the terms of the GNU General Public License as published by
8 # the Free Software Foundation; either version 3 of the License, or
9 # (at your option) any later version.
11 # This program is distributed in the hope that it will be useful,
12 # but WITHOUT ANY WARRANTY; without even the implied warranty of
13 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14 # GNU General Public License for more details.
16 # You should have received a copy of the GNU General Public License
17 # along with this program; if not, write to the Free Software
18 # Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
20 AUTOMAKE_OPTIONS = dejagnu
22 # These will get executed and parsed for test output
23 SANE_ASTESTS = \
24         hello.as \
25         inheritance.as \
26         function_test.as \
27         enum.as \
28         exception.as \
29         levels.as \
30         implementsOpTest.as \
31         TextFieldTest.as \
32         super_test1.as \
33         $(NULL)
34 # These ones are the ones for which consistency check fail 
35 BOGUS_ASTESTS = \
36         $(NULL)
37 # This one is host container communication (ExternalInterface) test
38 EXTCOMM_ASTESTS = \
39         extcomm.as \
40         $(NULL)
42 ASTESTS = $(SANE_ASTESTS) $(BOGUS_ASTESTS) $(EXTCOMM_ASTESTS)
45 # These will get compiled to SWFs just as above, but will not be executed as a test
46 # They are for secondary movies to be loaded by the above tests.
47 AUXMOVIES = \
48             level5.as \
49             level99.as \
50             level87.as \
51             $(NULL)
53 EXTRA_DIST = $(ASTESTS) $(AUXMOVIES) TestClass.as Dejagnu.as check.as Derived1.as Base1.as  implementsOp/BExtendingImplementation.as  implementsOp/ImplementationA.as  implementsOp/ImplementationB.as implementsOp/SimpleInterface.as
55 MTASC_FLAGS = -version 6 -cp $(MTASC_CLASSPATH) -cp $(srcdir) -v -header 800:600:20
56 MTASCV8_FLAGS = -version 8 -cp $(MTASC_CLASSPATH) -cp $(srcdir) -v -header 800:600:20
57 MTASC_CPP = $(CPP) -x c -P -I$(srcdir)
59 SANE_ASTESTS_OUT = $(SANE_ASTESTS:.as=.swf)
60 BOGUS_ASTESTS_OUT = $(BOGUS_ASTESTS:.as=.swf)
61 EXTCOMM_ASTESTS_OUT = $(EXTCOMM_ASTESTS:.as=.swf)
62 ASTESTS_OUT = $(SANE_ASTESTS_OUT) $(BOGUS_ASTESTS_OUT) $(EXTCOMM_ASTESTS_OUT)
64 AUXMOVIES_OUT = $(AUXMOVIES:.as=.swf)
66 $(ASTESTS_OUT) $(AUXMOVIES_OUT): Dejagnu.as check.as
69 TEST_DRIVERS = ../simple.exp
70 TEST_CASES = \
71         sanetests-runner \
72         bogustests-runner \
73         extcommtests-runner \
74         $(NULL)
76 sanetests-runner: $(srcdir)/../generic-testrunner.sh $(SANE_ASTESTS_OUT) $(AUXMOVIES_OUT) Makefile
77         sh $(srcdir)/../generic-testrunner.sh -c __END_OF_TEST__ -r 50 -d 30 $(top_builddir) $(SANE_ASTESTS_OUT) > $@
78         chmod 755 $@
80 bogustests-runner: $(srcdir)/../generic-testrunner.sh $(BOGUS_ASTESTS_OUT) $(AUXMOVIES_OUT) Makefile
81         sh $(srcdir)/../generic-testrunner.sh -C __END_OF_TEST__ -r 50 $(top_builddir) $(BOGUS_ASTESTS_OUT) > $@
82         chmod 755 $@
84 extcommtests-runner: $(srcdir)/extcommtests-runner.sh $(EXTCOMM_ASTESTS_OUT) Makefile
85         sh $(srcdir)/extcommtests-runner.sh $(top_builddir) $(top_srcdir) $(EXTCOMM_ASTESTS_OUT) > $@
86         chmod 755 $@
88 extcomm.swf: extcomm.as
89         $(MTASC_CPP) $< > $(@:%.swf=pp_%.as)
90         $(MTASC) $(MTASCV8_FLAGS) -swf $@ -main $(@:%.swf=pp_%.as)
92 .as.swf: 
93         $(MTASC_CPP) $< > $(@:%.swf=pp_%.as) 
94         $(MTASC) $(MTASC_FLAGS) -swf $@ -main $(@:%.swf=pp_%.as)
96 CLEANFILES =  \
97         gnash-dbg.log \
98         site.exp.bak \
99         *-runner \
100         testrun.* \
101         *.swf \
102         *.pp \
103         pp_*.as \
104         *_testrunner \
105         *_Runner
107 check-DEJAGNU: site-update $(TEST_CASES)
108         @runtest=$(RUNTEST); \
109         if $(SHELL) -c "$$runtest --version" > /dev/null 2>&1; then \
110             GNASH_GC_TRIGGER_THRESHOLD=0  GNASHRC=../gnashrc $$runtest $(RUNTESTFLAGS) $(TEST_DRIVERS); true; \
111         else \
112           echo "WARNING: could not find \`runtest'" 1>&2; \
113           for i in "$(TEST_CASES)"; do \
114             GNASH_GC_TRIGGER_THRESHOLD=0  GNASHRC=../gnashrc $(SHELL) $$i; \
115           done; \
116         fi
118 site-update: site.exp
119         @rm -fr site.exp.bak
120         @cp site.exp site.exp.bak
121         @sed -e '/testcases/d' site.exp.bak > site.exp
122         @echo "# This is a list of the pre-compiled testcases" >> site.exp
123         @echo "set testcases \"$(TEST_CASES)\"" >> site.exp