Update with current status
[gnash.git] / testsuite / libbase.all / Makefile.am
blobde3eb2f78e2fd8b715fecd8db1ee77804316fd34
1 ## Process this fill with automake to generate Makefile.in
2
3 #   Copyright (C) 2005, 2006,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 LDADD = \
23         $(top_builddir)/libbase/libgnashbase.la \
24         $(top_builddir)/librender/libgnashrender.la \
25         $(CROSS_LDFLAGS) \
26         $(BOOST_LIBS) \
27         $(LIBINTL) \
28         $(AGG_LIBS) \
29         $(OPENVG_LIBS) \
30         $(EGL_LIBS) \
31         $(NULL)
33 if ANDROID
34 LDADD +=  -lui -llog
35 endif   # ANDROID
37 AM_LDFLAGS = $(CROSS_LDFLAGS)
38 AM_CXXFLAGS = $(CROSS_CXXFLAGS)
40 # AM_CPPFLAGS isn't right here since per-program *_CPPFLAGS override global
41 # AM_CPPFLAGS
42 AM_CPPFLAGS = \
43         -I$(top_srcdir)/libbase \
44         -I$(top_srcdir)/libcore  \
45         -I$(top_srcdir)/testsuite \
46         $(MING_CFLAGS) \
47         $(BOOST_CFLAGS) \
48         $(PTHREAD_CFLAGS) \
49         $(DEJAGNU_CFLAGS) \
50         $(NULL)
52 abs_builddir=`(cd $(top_builddir)/testsuite/libbase; pwd)`
54 CLEANFILES = \
55         testrun.sum \
56         testrun.log \
57         gnash-dbg.log \
58         site.exp.bak \
59         NoSeekFileTestCache \
60         $(NULL)
62 check_PROGRAMS = \
63         NoSeekFileTest \
64         URLTest \
65         RcTest \
66         IntTypesTest \
67         Point2dTest \
68         snappingrangetest \
69         Range2dTest \
70         string_tableTest \
71         $(NULL)
73 #if CURL
74 ## This test needs an http server running to be useful
75 #check_PROGRAMS += CurlStreamTest
76 #CurlStreamTest_SOURCES = CurlStreamTest.cpp
77 #CurlStreamTest_CPPFLAGS = '-DINPUT="$(srcdir)/CurlStreamTest.cpp"'
78 #endif
80 NoSeekFileTest_SOURCES = NoSeekFileTest.cpp
81 NoSeekFileTest_CPPFLAGS = $(AM_CPPFLAGS) \
82         '-DINPUT="$(srcdir)/NoSeekFileTest.cpp"'
83 NoSeekFileTest_LDADD = $(LDADD)
85 URLTest_SOURCES = URLTest.cpp
86 URLTest_CPPFLAGS =  $(AM_CPPFLAGS) \
87         '-DBUILDDIR="$(abs_builddir)"'
88 URLTest_LDADD = $(LDADD)
90 RcTest_SOURCES = RcTest.cpp
91 RcTest_CPPFLAGS =  $(AM_CPPFLAGS) \
92         -DSRCDIR="$(srcdir)"
93 RcTest_LDADD = $(LDADD)
95 IntTypesTest_SOURCES = IntTypesTest.cpp
96 IntTypesTest_CPPFLAGS =  $(AM_CPPFLAGS) \
97         -DSRCDIR="$(srcdir)"
98 IntTypesTest_LDADD = $(LDADD)
100 # Test the Memory class
101 #memtest_SOURCES = memtest.cpp
103 Point2dTest_SOURCES = Point2dTest.cpp
104 Point2dTest_LDADD = $(LDADD)
106 Range2dTest_SOURCES = Range2dTest.cpp
107 Range2dTest_LDADD = $(LDADD)
109 snappingrangetest_SOURCES = snappingrangetest.cpp
110 snappingrangetest_LDADD= $(LDADD)
112 string_tableTest_SOURCES = string_tableTest.cpp
113 string_tableTest_CPPFLAGS =  $(AM_CPPFLAGS) \
114         -DSRCDIR="$(srcdir)"
115 string_tableTest_LDFLAGS = $(BOOST_LIBS)
116 string_tableTest_LDADD = $(LDADD)
118 TEST_DRIVERS = ../simple.exp
119 TEST_CASES = \
120         $(check_PROGRAMS) \
121         $(NULL)
123 check-DEJAGNU: site-update $(TEST_CASES)
124         @runtest=$(RUNTEST); \
125         if $(SHELL) -c "$$runtest --version" > /dev/null 2>&1; then \
126             $$runtest $(RUNTESTFLAGS) $(TEST_DRIVERS); \
127         else \
128           echo "WARNING: could not find \`runtest'" 1>&2; \
129           for i in "$(TEST_CASES)"; do \
130             $(SHELL) $$i; \
131           done; \
132         fi
134 site-update: site.exp
135         @rm -fr site.exp.bak
136         @cp site.exp site.exp.bak
137         @sed -e '/testcases/d' site.exp.bak > site.exp
138         @echo "# This is a list of the pre-compiled testcases" >> site.exp
139         @echo "set testcases \"$(TEST_CASES)\"" >> site.exp