Ignore generated files.
[mesa.git] / progs / glsl / Makefile
1 # progs/demos/Makefile
2
3 TOP = ../..
4 include $(TOP)/configs/current
5
6 INCDIR = $(TOP)/include
7
8 LIB_DEP = $(TOP)/$(LIB_DIR)/$(GL_LIB_NAME) $(TOP)/$(LIB_DIR)/$(GLU_LIB_NAME) $(TOP)/$(LIB_DIR)/$(GLUT_LIB_NAME)
9
10 PROGS = \
11 brick \
12 bump \
13 deriv \
14 mandelbrot \
15 noise \
16 toyball \
17 texdemo1
18
19
20 ##### RULES #####
21
22 .SUFFIXES:
23 .SUFFIXES: .c
24
25
26 # make executable from .c file:
27 .c: $(LIB_DEP)
28 $(CC) -I$(INCDIR) $(CFLAGS) $< $(APP_LIB_DEPS) -o $@
29
30
31 ##### TARGETS #####
32
33 default: $(PROGS)
34
35
36
37 ##### Extra dependencies
38
39 extfuncs.h: $(TOP)/progs/util/extfuncs.h
40 cp $< .
41
42 readtex.c: $(TOP)/progs/util/readtex.c
43 cp $< .
44
45 readtex.h: $(TOP)/progs/util/readtex.h
46 cp $< .
47
48 readtex.o: readtex.c readtex.h
49 $(CC) -c -I$(INCDIR) $(CFLAGS) readtex.c
50
51 brick.c: extfuncs.h
52
53 bump.c: extfuncs.h
54
55 mandelbrot.c: extfuncs.h
56
57 toyball.c: extfuncs.h
58
59 texdemo1: texdemo1.o readtex.o
60 $(CC) -I$(INCDIR) $(CFLAGS) texdemo1.o readtex.o $(APP_LIB_DEPS) -o $@
61
62 texdemo1.o: texdemo1.c readtex.h extfuncs.h
63 $(CC) -c -I$(INCDIR) $(CFLAGS) texdemo1.c
64
65
66 clean:
67 -rm -f $(PROGS)
68 -rm -f *.o *~
69 -rm -f extfuncs.h