Add a couple of test apps for line/unfilled polygon clipping.
[mesa.git] / progs / tests / Makefile
1 # progs/tests/Makefile
2
3
4 # These programs aren't intended to be included with the normal distro.
5 # They're not too interesting but they're good for testing.
6
7 TOP = ../..
8 include $(TOP)/configs/current
9
10
11 LIBS = -L$(TOP)/$(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) $(APP_LIB_DEPS)
12
13 SOURCES = \
14 afsmultiarb.c \
15 antialias.c \
16 arbfpspec.c \
17 arbfptest1.c \
18 arbfptexture.c \
19 arbfptrig.c \
20 arbnpot.c \
21 arbnpot-mipmap.c \
22 arbvptest1.c \
23 arbvptest3.c \
24 arbvptorus.c \
25 arbvpwarpmesh.c \
26 arraytexture.c \
27 blendminmax.c \
28 blendsquare.c \
29 bufferobj.c \
30 bug_3050.c \
31 bug_3101.c \
32 bug_3195.c \
33 copypixrate.c \
34 crossbar.c \
35 cva.c \
36 dinoshade.c \
37 drawbuffers.c \
38 exactrast.c \
39 floattex.c \
40 fbotest1.c \
41 fbotest2.c \
42 fbotexture.c \
43 fog.c \
44 fogcoord.c \
45 fptest1.c \
46 fptexture.c \
47 getprocaddress.c \
48 interleave.c \
49 invert.c \
50 jkrahntest.c \
51 lineclip.c \
52 manytex.c \
53 minmag.c \
54 mipmap_limits.c \
55 multipal.c \
56 no_s3tc.c \
57 packedpixels.c \
58 pbo.c \
59 prog_parameter.c \
60 projtex.c \
61 random.c \
62 readrate.c \
63 seccolor.c \
64 shader_api.c \
65 sharedtex.c \
66 stencil_twoside.c \
67 stencilwrap.c \
68 stencil_wrap.c \
69 subtexrate.c \
70 tex1d.c \
71 texcompress2.c \
72 texfilt.c \
73 texline.c \
74 texobjshare.c \
75 texrect.c \
76 texwrap.c \
77 unfilledclip.c \
78 vao-01.c \
79 vao-02.c \
80 vparray.c \
81 vptest1.c \
82 vptest2.c \
83 vptest3.c \
84 vptorus.c \
85 vpwarpmesh.c \
86 yuvrect.c \
87 yuvsquare.c \
88 zreaddraw.c
89
90 PROGS = $(SOURCES:%.c=%)
91
92 INCLUDES = -I. -I$(TOP)/include
93
94 UTIL_FILES = readtex.h readtex.c
95
96
97 ##### TARGETS #####
98
99 default: $(UTIL_FILES) $(PROGS)
100
101 clean:
102 rm -f $(PROGS)
103 rm -f *.o
104 rm -f getproclist.h
105
106 ##### RULES #####
107
108 .SUFFIXES:
109 .SUFFIXES: .c
110
111 .c:
112 $(CC) $(INCLUDES) $(CFLAGS) $(LDFLAGS) $< $(LIBS) -o $@
113
114 .c.o:
115 $(CC) -c $(INCLUDES) $(CFLAGS) $(DEFINES) $< -o $@
116
117 .S.o:
118 $(CC) -c $(INCLUDES) $(CFLAGS) $(DEFINES) $< -o $@
119
120 # auto code generation
121 getprocaddress: getprocaddress.c getproclist.h
122
123 getproclist.h: $(TOP)/src/mesa/glapi/gl_API.xml getprocaddress.c getprocaddress.py
124 python getprocaddress.py > getproclist.h
125
126 arraytexture: arraytexture.o readtex.o
127 $(CC) $(CFLAGS) arraytexture.o readtex.o $(LIBS) -o $@
128
129 arraytexture.o: arraytexture.c readtex.h
130 $(CC) -c $(INCLUDES) $(CFLAGS) $(DEFINES) arraytexture.c -o $@
131
132 afsmultiarb: afsmultiarb.o readtex.o
133 $(CC) $(CFLAGS) $(LDFLAGS) afsmultiarb.o readtex.o $(LIBS) -o $@
134
135 afsmultiarb.o: afsmultiarb.c readtex.h
136 $(CC) -c $(INCLUDES) $(CFLAGS) $(DEFINES) afsmultiarb.c -o $@
137
138 drawbuffers: drawbuffers.o
139 $(CC) $(CFLAGS) $(LDFLAGS) drawbuffers.o $(LIBS) -o $@
140
141 drawbuffers.o: drawbuffers.c extfuncs.h
142 $(CC) -c $(INCLUDES) $(CFLAGS) $(DEFINES) drawbuffers.c -o $@
143
144 texrect: texrect.o readtex.o
145 $(CC) $(CFLAGS) $(LDFLAGS) texrect.o readtex.o $(LIBS) -o $@
146
147 texrect.o: texrect.c readtex.h
148 $(CC) -c $(INCLUDES) $(CFLAGS) $(DEFINES) texrect.c -o $@
149
150 bug_3195: bug_3195.o readtex.o
151 $(CC) $(CFLAGS) $(LDFLAGS) bug_3195.o readtex.o $(LIBS) -o $@
152
153 bug_3195.o: bug_3195.c readtex.h
154 $(CC) -c $(INCLUDES) $(CFLAGS) $(DEFINES) bug_3195.c -o $@
155
156 invert: invert.o readtex.o
157 $(CC) $(CFLAGS) $(LDFLAGS) invert.o readtex.o $(LIBS) -o $@
158
159 invert.o: invert.c readtex.h
160 $(CC) -c $(INCLUDES) $(CFLAGS) $(DEFINES) invert.c -o $@
161
162 readtex.o: readtex.c
163 $(CC) -c $(INCLUDES) $(CFLAGS) $(DEFINES) readtex.c -o $@
164
165
166 readtex.h: $(TOP)/progs/util/readtex.h
167 ln -s $(TOP)/progs/util/readtex.h .
168
169 readtex.c: $(TOP)/progs/util/readtex.c
170 ln -s $(TOP)/progs/util/readtex.c .
171
172 extfuncs.h: $(TOP)/progs/util/extfuncs.h
173 ln -s $(TOP)/progs/util/extfuncs.h .
174
175
176
177 # Emacs tags
178 tags:
179 etags `find . -name \*.[ch]` `find ../include`