Merge branch '7.8'
[mesa.git] / src / gallium / state_trackers / vega / Makefile
1 # src/gallium/state_trackers/vega/Makefile
2
3 TOP = ../../../..
4 include $(TOP)/configs/current
5
6 VG_LIB = OpenVG
7 VG_LIB_NAME = lib$(VG_LIB).so
8
9 VG_MAJOR = 1
10 VG_MINOR = 0
11 VG_TINY = 0
12
13 ### Lists of source files, included by Makefiles
14
15 VG_SOURCES = \
16 api_context.c \
17 api_filters.c \
18 api_images.c \
19 api_masks.c \
20 api_misc.c \
21 api_paint.c \
22 api_params.c \
23 api_path.c \
24 api_text.c \
25 api_transform.c \
26 vgu.c \
27 vg_context.c \
28 vg_manager.c \
29 vg_state.c \
30 vg_tracker.c \
31 vg_translate.c \
32 polygon.c \
33 bezier.c \
34 path.c \
35 paint.c \
36 arc.c \
37 image.c \
38 renderer.c \
39 stroker.c \
40 mask.c \
41 shader.c \
42 shaders_cache.c
43
44 VG_OBJECTS = $(VG_SOURCES:.c=.o)
45
46 VG_LIBS = $(GALLIUM_AUXILIARIES)
47 VG_LIB_DEPS = $(EXTRA_LIB_PATH) -lm
48
49 ### Include directories
50
51 INCLUDE_DIRS = \
52 -I$(TOP)/include \
53 -I$(TOP)/src/gallium/include \
54 -I$(TOP)/src/gallium/auxiliary
55
56
57 .c.o:
58 $(CC) -c $(INCLUDE_DIRS) $(CFLAGS) $< -o $@
59
60 default: depend $(TOP)/$(LIB_DIR)/$(VG_LIB_NAME)
61
62 # Make the OpenVG library
63 $(TOP)/$(LIB_DIR)/$(VG_LIB_NAME): $(VG_OBJECTS) $(VG_LIBS)
64 $(MKLIB) -o $(VG_LIB) -linker '$(CC)' -ldflags '$(LDFLAGS)' \
65 -major $(VG_MAJOR) \
66 -minor $(VG_MINOR) \
67 -patch $(VG_TINY) \
68 -install $(TOP)/$(LIB_DIR) \
69 $(VG_OBJECTS) $(VG_LIBS) $(VG_LIB_DEPS)
70
71 ######################################################################
72 # Generic stuff
73
74 depend: $(VG_SOURCES)
75 @ echo "running $(MKDEP)"
76 @ rm -f depend # workaround oops on gutsy?!?
77 @ touch depend
78 @ $(MKDEP) $(MKDEP_OPTIONS) $(DEFINES) $(INCLUDE_DIRS) $(VG_SOURCES) \
79 > /dev/null 2>/dev/null
80
81 install: default
82 $(INSTALL) -d $(DESTDIR)$(INSTALL_DIR)/include/VG
83 $(INSTALL) -m 644 $(TOP)/include/VG/*.h $(DESTDIR)$(INSTALL_DIR)/include/VG
84 $(INSTALL) -d $(DESTDIR)$(INSTALL_DIR)/$(LIB_DIR)
85 $(MINSTALL) $(TOP)/$(LIB_DIR)/libOpenVG* $(DESTDIR)$(INSTALL_DIR)/$(LIB_DIR)
86
87 # Emacs tags
88 tags:
89 etags `find . -name \*.[ch]` $(TOP)/include/VG/*.h
90
91 clean:
92 rm -f $(VG_OBJECTS)
93 rm -f depend depend.bak
94
95 sinclude depend