define new APP_CC configuration variable for building apps/demos/tests
[mesa.git] / progs / xdemos / Makefile
1 # progs/xdemos/Makefile
2
3 TOP = ../..
4 include $(TOP)/configs/current
5
6
7 INCDIR = $(TOP)/include
8
9 LIB_DEP = $(TOP)/$(LIB_DIR)/$(GL_LIB_NAME) $(TOP)/$(LIB_DIR)/$(GLU_LIB_NAME)
10
11 PROGS = glthreads \
12 glxdemo \
13 glxgears \
14 glxgears_fbconfig \
15 glxcontexts \
16 glxheads \
17 glxinfo \
18 glxpixmap \
19 glxpbdemo \
20 glxswapcontrol \
21 manywin \
22 offset \
23 overlay \
24 pbinfo \
25 pbdemo \
26 sharedtex \
27 texture_from_pixmap \
28 wincopy \
29 xfont \
30 xrotfontdemo \
31 yuvrect_client
32
33 # omit this XMesa API demo: xdemo
34
35
36 ##### RULES #####
37
38 .SUFFIXES:
39 .SUFFIXES: .c
40
41 .c: $(LIB_DEP)
42 $(APP_CC) -I$(INCDIR) $(CFLAGS) $< $(APP_LIB_DEPS) -o $@
43
44
45 ##### TARGETS #####
46
47 default: $(PROGS)
48
49
50 clean:
51 -rm -f $(PROGS)
52 -rm -f *.o *~
53
54
55 # special cases
56 pbinfo: pbinfo.o pbutil.o
57 $(APP_CC) -I$(INCDIR) $(CFLAGS) pbinfo.o pbutil.o $(APP_LIB_DEPS) -o $@
58
59 pbdemo: pbdemo.o pbutil.o
60 $(APP_CC) -I$(INCDIR) $(CFLAGS) pbdemo.o pbutil.o $(APP_LIB_DEPS) -o $@
61
62 pbinfo.o: pbinfo.c pbutil.h
63 $(APP_CC) -c -I. -I$(INCDIR) $(CFLAGS) pbinfo.c
64
65 pbdemo.o: pbdemo.c pbutil.h
66 $(APP_CC) -c -I. -I$(INCDIR) $(CFLAGS) pbdemo.c
67
68 pbutil.o: pbutil.c pbutil.h
69 $(APP_CC) -c -I. -I$(INCDIR) $(CFLAGS) pbutil.c
70
71 glxgears_fbconfig: glxgears_fbconfig.o pbutil.o
72 $(APP_CC) -I$(INCDIR) $(CFLAGS) glxgears_fbconfig.o pbutil.o $(APP_LIB_DEPS) -o $@
73
74 glxgears_fbconfig.o: glxgears_fbconfig.c pbutil.h
75 $(APP_CC) -I$(INCDIR) $(CFLAGS) -c -I. $(CFLAGS) glxgears_fbconfig.c
76
77 xrotfontdemo: xrotfontdemo.o xuserotfont.o
78 $(APP_CC) -I$(INCDIR) $(CFLAGS) xrotfontdemo.o xuserotfont.o $(APP_LIB_DEPS) -o $@
79
80 xuserotfont.o: xuserotfont.c xuserotfont.h
81 $(APP_CC) -c -I. -I$(INCDIR) $(CFLAGS) xuserotfont.c
82
83 xrotfontdemo.o: xrotfontdemo.c xuserotfont.h
84 $(APP_CC) -c -I. -I$(INCDIR) $(CFLAGS) xrotfontdemo.c
85