minor tweaks
[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 = $(APP_LIB_DEPS)
12
13 SOURCES = antialias.c \
14 arbfpspec.c \
15 arbfptest1.c \
16 arbfptexture.c \
17 arbfptrig.c \
18 arbvptest1.c \
19 arbvptest3.c \
20 arbvptorus.c \
21 arbvpwarpmesh.c \
22 blendminmax.c \
23 blendsquare.c \
24 bufferobj.c \
25 cva.c \
26 dinoshade.c \
27 floattex.c \
28 fogcoord.c \
29 fptest1.c \
30 fptexture.c \
31 getprocaddress.c \
32 manytex.c \
33 multipal.c \
34 packedpixels.c \
35 pbo.c \
36 projtex.c \
37 seccolor.c \
38 sharedtex.c \
39 stencilwrap.c \
40 tex1d.c \
41 texline.c \
42 texrect.c \
43 texwrap.c \
44 vparray.c \
45 vptest1.c \
46 vptest2.c \
47 vptest3.c \
48 vptorus.c \
49 vpwarpmesh.c \
50 yuvrect.c \
51 yuvsquare.c \
52 zreaddraw.c
53
54 PROGS = $(SOURCES:%.c=%)
55
56 INCLUDES = -I. -I$(TOP)/include
57
58 UTIL_FILES = readtex.h readtex.c
59
60
61 ##### RULES #####
62
63 .SUFFIXES:
64 .SUFFIXES: .c
65
66 .c:
67 $(CC) $(INCLUDES) $(CFLAGS) $< $(LIBS) -o $@
68
69 .c.o:
70 $(CC) -c $(INCLUDES) $(CFLAGS) $(DEFINES) $< -o $@
71
72 .S.o:
73 $(CC) -c $(INCLUDES) $(CFLAGS) $(DEFINES) $< -o $@
74
75
76 ##### TARGETS #####
77
78 default: $(UTIL_FILES) $(PROGS)
79
80 clean:
81 rm -f $(PROGS)
82 rm -f *.o
83 rm -f getproclist.h
84
85
86 # auto code generation
87 getprocaddress: getprocaddress.c getproclist.h
88
89 getproclist.h: $(TOP)/src/mesa/glapi/APIspec getprocaddress.c getprocaddress.py
90 python getprocaddress.py > getproclist.h
91
92
93 texrect: texrect.o readtex.o
94 $(CC) texrect.o readtex.o $(LIBS) -o $@
95
96 texrect.o: texrect.c readtex.h
97 $(CC) -c $(INCLUDES) $(CFLAGS) $(DEFINES) $< -o $@
98
99 readtex.o: readtex.c
100 $(CC) -c $(INCLUDES) $(CFLAGS) $(DEFINES) $< -o $@
101
102
103 readtex.h: $(TOP)/progs/util/readtex.h
104 ln -s $(TOP)/progs/util/readtex.h .
105
106 readtex.c: $(TOP)/progs/util/readtex.c
107 ln -s $(TOP)/progs/util/readtex.c .
108
109
110
111
112 # Emacs tags
113 tags:
114 etags `find . -name \*.[ch]` `find ../include`