blob: 6c76cbd2ca726eb027ac6eb470d8244cace127e0 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
|
include $(top_srcdir)/build/autotools/Makefile.am.silent
UNIT_TESTS = \
test-texture-slicing.c \
test-texture-async.c \
test-texture-material.c \
test-events.c \
test-scale.c \
test-actors.c \
test-actor-clone.c \
test-behave.c \
test-shader-effects.c \
test-depth.c \
test-threads.c \
test-script.c \
test-model.c \
test-grab.c \
test-fullscreen.c \
test-shader.c \
test-cogl-shader-arbfp.c \
test-cogl-shader-glsl.c \
test-animator.c \
test-state.c \
test-state-animator.c \
test-unproject.c \
test-fbo.c \
test-multistage.c \
test-cogl-primitives.c \
test-cogl-tex-tile.c \
test-cogl-tex-convert.c \
test-cogl-tex-foreign.c \
test-cogl-tex-getset.c \
test-cogl-offscreen.c \
test-cogl-tex-polygon.c \
test-cogl-multitexture.c \
test-stage-read-pixels.c \
test-clip.c \
test-paint-wrapper.c \
test-texture-quality.c \
test-layout.c \
test-animation.c \
test-easing.c \
test-binding-pool.c \
test-text.c \
test-text-field.c \
test-cairo-clock.c \
test-cairo-flowers.c \
test-cogl-vertex-buffer.c \
test-bin-layout.c \
test-flow-layout.c \
test-box-layout.c \
test-stage-sizing.c \
test-drag.c \
test-constraints.c \
test-scrolling.c \
test-swipe-action.c \
test-cogl-point-sprites.c \
test-table-layout.c \
test-path-constraint.c \
test-snap-constraint.c \
test-state-script.c \
test-drop.c \
test-devices.c
if X11_TESTS
UNIT_TESTS += test-pixmap.c
endif
if OS_WIN32
SHEXT =
else
SHEXT = $(EXEEXT)
endif
# For convenience, this provides a way to easily run individual unit tests:
wrappers: stamp-test-interactive ../../build/win32/test-interactive-clutter.bat
@true
stamp-test-interactive: Makefile
@wrapper=$(abs_builddir)/wrapper.sh ; \
chmod +x $$wrapper && \
( echo "/stamp-test-interactive" ; \
echo "/stamp-test-unit-names" ; \
echo "/test-interactive" ; \
echo "/test-unit-names.h" ; \
echo "*.o" ; \
echo ".gitignore" ) > .gitignore ; \
for i in $(UNIT_TESTS); \
do \
test_bin=$${i%*.c} ; \
echo " GEN $$test_bin" ; \
( echo "#!/bin/sh" ; \
echo "$$wrapper $$test_bin \$$@" \
) > $$test_bin$(SHEXT) ; \
chmod +x $$test_bin$(SHEXT) ; \
echo "/$$test_bin$(SHEXT)" >> .gitignore ; \
done \
&& echo timestamp > $(@F)
../../build/win32/test-interactive-clutter.bat: Makefile test-interactive$(EXEEXT)
echo " GEN test-interactive-clutter.bat" ; \
for i in $(UNIT_TESTS); \
do \
case $$i in \
test-pixmap.c|test-devices.c) ;; \
*.c) test_bin=$${i%*.c} \
;; \
esac; \
( echo "test-interactive-clutter $$test_bin" ) > $$test_bin-clutter.bat ; \
( echo "test-interactive-clutter $$test_bin" ) >> test-interactive-clutter.bat ; \
done \
&& cp *.bat $(top_srcdir)/build/win32/
../../build/win32/test-unit-names.h: test-unit-names.h
cp test-unit-names.h $(top_srcdir)/build/win32
test-unit-names.h: stamp-test-unit-names
@true
stamp-test-unit-names: Makefile
@( echo "/* ** This file is autogenerated. Do not edit. ** */" ; \
echo "" ; \
echo "const char *test_unit_names[] = {" ) > test-unit-names.h ; \
for i in $(UNIT_TESTS); \
do \
test_bin=$${i%*.c} ; \
echo " \"$$test_bin\"," >> test-unit-names.h ; \
done \
&& echo "};" >> test-unit-names.h \
&& echo timestamp > $(@F)
clean-wrappers:
@for i in $(UNIT_TESTS); \
do \
test_bin=$${i%*.c} ; \
echo " RM $$test_bin"; \
rm -f $$test_bin$(SHEXT); \
done \
&& rm -f $(top_srcdir)/build/win32/*.bat \
&& rm -f *.bat \
&& rm -f stamp-test-interactive
.PHONY: wrappers clean-wrappers
INCLUDES = \
-I$(top_srcdir) \
-I$(top_srcdir)/clutter \
-I$(top_srcdir)/clutter/cogl \
-I$(top_builddir)/clutter \
-I$(top_builddir)/clutter/cogl
common_ldadd = $(top_builddir)/clutter/libclutter-@CLUTTER_API_VERSION@.la
noinst_PROGRAMS = test-interactive
test_interactive_SOURCES = test-main.c test-unit-names.h $(UNIT_TESTS)
test_interactive_CFLAGS = $(CLUTTER_CFLAGS) $(MAINTAINER_CFLAGS)
test_interactive_CPPFLAGS = \
-DTESTS_DATADIR=\""$(abs_top_srcdir)/tests/data"\" \
-DG_DISABLE_SINGLE_INCLUDES \
-DGLIB_DISABLE_DEPRECATION_WARNINGS \
-DCLUTTER_DISABLE_DEPRECATION_WARNINGS
test_interactive_LDFLAGS = -export-dynamic
test_interactive_LDADD = $(CLUTTER_LIBS) $(common_ldadd) -lm
EXTRA_DIST = wrapper.sh.in
DISTCLEANFILES = wrapper.sh .gitignore test-unit-names.h
BUILT_SOURCES = wrappers test-unit-names.h
dist-hook: ../../build/win32/vs9/test-interactive-clutter.vcproj ../../build/win32/vs10/test-interactive-clutter.vcxproj ../../build/win32/vs10/test-interactive-clutter.vcxproj.filters
../../build/win32/vs9/test-interactive-clutter.vcproj: $(top_srcdir)/build/win32/vs9/test-interactive-clutter.vcprojin
for F in $(test_interactive_SOURCES); do \
case $$F in \
test-pixmap.c|test-devices.c) ;; \
*.c) echo ' <File RelativePath="..\..\..\tests\interactive\'$$F'" />' \
;; \
esac; \
done >testinteractive.sourcefiles
$(CPP) -P - <$(top_srcdir)/build/win32/vs9/test-interactive-clutter.vcprojin >$@
rm testinteractive.sourcefiles
../../build/win32/vs10/test-interactive-clutter.vcxproj: $(top_srcdir)/build/win32/vs10/test-interactive-clutter.vcxprojin
for F in $(test_interactive_SOURCES); do \
case $$F in \
test-pixmap.c|test-devices.c) ;; \
*.c) echo ' <ClCompile Include="..\..\..\tests\interactive\'$$F'" />' \
;; \
esac; \
done >testinteractive.vs10.sourcefiles
$(CPP) -P - <$(top_srcdir)/build/win32/vs10/test-interactive-clutter.vcxprojin >$@
rm testinteractive.vs10.sourcefiles
../../build/win32/vs10/test-interactive-clutter.vcxproj.filters: $(top_srcdir)/build/win32/vs10/test-interactive-clutter.vcxproj.filtersin
for F in $(test_interactive_SOURCES); do \
case $$F in \
test-pixmap.c|test-devices.c) ;; \
*.c) echo ' <ClCompile Include="..\..\..\tests\interactive\'$$F'"><Filter>Sources</Filter></ClCompile>' \
;; \
esac; \
done >testinteractive.vs10.sourcefiles.filters
$(CPP) -P - <$(top_srcdir)/build/win32/vs10/test-interactive-clutter.vcxproj.filtersin >$@
rm testinteractive.vs10.sourcefiles.filters
# Let the VS9/VS10 Project files be cleared out before they are re-expanded...
DISTCLEANFILES += ../../build/win32/vs9/test-interactive-clutter.vcproj \
../../build/win32/vs10/test-interactive-clutter.vcxproj \
../../build/win32/vs10/test-interactive-clutter.vcxproj.filters
clean-local: clean-wrappers
|