3 # Build Mesa3DGL private libglapi.a
6 include $(SRCDIR)/config/aros.cfg
8 CUR_MESADIR := src/mapi
9 include $(SRCDIR)/$(CURDIR)/../mesa.cfg
10 include $(top_srcdir)/$(CUR_MESADIR)/Makefile.sources
12 #MM- mesa3dgl-linklibs : mesa3d-linklib-glapi
15 -I$(top_srcdir)/include \
16 -iquote $(top_builddir)/$(CUR_MESADIR) \
17 -iquote $(top_srcdir)/$(CUR_MESADIR) \
18 -iquote $(top_mesa3dgldir)/src \
19 -iquote $(SRCDIR)/$(CURDIR)/..
21 USER_CFLAGS += $(MESA_NOWARNFLAGS)
22 USER_CXXFLAGS += $(MESA_NOWARNFLAGS)
24 MAPI_GLAPI_C_FILES := $(filter %.c, $(MAPI_UTIL_FILES))
26 MESA3DGL_GLAPI_SOURCES := \
27 glapi/glapi_dispatch \
28 glapi/glapi_entrypoint \
32 $(MAPI_GLAPI_C_FILES:.c=)
34 MESA3DGL_GLAPI_SOURCES_C := $(addprefix $(top_srcdir)/$(CUR_MESADIR)/, $(MESA3DGL_GLAPI_SOURCES))
36 $(top_builddir)/$(CUR_MESADIR)/glapi/glapitemp.h: $(top_srcdir)/$(CUR_MESADIR)/glapi/gen/gl_apitemp.py
37 %mkdir_q dir="$(dir $@)"
38 $(Q)$(ECHO) "Generating $(if $(filter /%,$@),$(if $(filter $(SRCDIR)/%,$(abspath $@)),$(patsubst $(SRCDIR)/%,%,$(abspath $@)),$(patsubst $(TOP)/%,%,$(abspath $@))),$(patsubst $(SRCDIR)/%,%,$(abspath $(SRCDIR)/$(CURDIR)/$@)))"
39 $(Q)$(PYTHON) $(PYTHON_FLAGS) $< -f $(top_srcdir)/$(CUR_MESADIR)/glapi/gen/gl_and_es_API.xml > $@
41 $(top_builddir)/$(CUR_MESADIR)/glapi/glapitable.h: $(top_srcdir)/$(CUR_MESADIR)/glapi/gen/gl_table.py
42 %mkdir_q dir="$(dir $@)"
43 $(Q)$(ECHO) "Generating $(if $(filter /%,$@),$(if $(filter $(SRCDIR)/%,$(abspath $@)),$(patsubst $(SRCDIR)/%,%,$(abspath $@)),$(patsubst $(TOP)/%,%,$(abspath $@))),$(patsubst $(SRCDIR)/%,%,$(abspath $(SRCDIR)/$(CURDIR)/$@)))"
44 $(Q)$(PYTHON) $(PYTHON_FLAGS) $< -f $(top_srcdir)/$(CUR_MESADIR)/glapi/gen/gl_and_es_API.xml > $@
46 $(top_builddir)/$(CUR_MESADIR)/glapi/glprocs.h: $(top_srcdir)/$(CUR_MESADIR)/glapi/gen/gl_procs.py
47 %mkdir_q dir="$(dir $@)"
48 $(Q)$(ECHO) "Generating $(if $(filter /%,$@),$(if $(filter $(SRCDIR)/%,$(abspath $@)),$(patsubst $(SRCDIR)/%,%,$(abspath $@)),$(patsubst $(TOP)/%,%,$(abspath $@))),$(patsubst $(SRCDIR)/%,%,$(abspath $(SRCDIR)/$(CURDIR)/$@)))"
49 $(Q)$(PYTHON) $(PYTHON_FLAGS) $< -c -f $(top_srcdir)/$(CUR_MESADIR)/glapi/gen/gl_and_es_API.xml > $@
52 mesa3d-linklib-glapi-generate : $(top_builddir)/$(CUR_MESADIR)/glapi/glapitable.h $(top_builddir)/$(CUR_MESADIR)/glapi/glapitemp.h $(top_builddir)/$(CUR_MESADIR)/glapi/glprocs.h
54 #MM mesa3d-linklib-glapi : mesa3d-fetch mesa3d-linklib-glapi-generate
56 %build_linklib mmake=mesa3d-linklib-glapi libname=glapi libdir=$(top_libdir) objdir=$(top_builddir)/$(CUR_MESADIR) files="$(MESA3DGL_GLAPI_SOURCES_C)"