esapi_LIB_DEPS := -L$(TOP)/$(LIB_DIR) -l$(GLAPI_LIB) $(esapi_LIB_DEPS)
.PHONY: default
-default: depend $(TOP)/$(LIB_DIR)/$(esapi_LIB_NAME) main/dispatch.h main/remap_helper.h
+default: depend $(TOP)/$(LIB_DIR)/$(esapi_LIB_NAME)
$(TOP)/$(LIB_DIR)/$(esapi_LIB_NAME): $(esapi_OBJECTS)
$(MKLIB) -o $(esapi_LIB) -linker '$(CC)' -ldflags '$(LDFLAGS)' \
glapi_mapi_tmp.h: $(GLAPI)/gen/gl_and_es_API.xml $(glapi_gen_mapi_deps)
$(call glapi_gen_mapi,$<,$(ESAPI))
-main/dispatch.h: $(GLAPI)/gen/gl_and_es_API.xml $(glapi_gen_dispatch_deps)
- $(call glapi_gen_dispatch,$<,$(ES))
-
-main/remap_helper.h: $(GLAPI)/gen/gl_and_es_API.xml $(glapi_gen_remap_deps)
- $(call glapi_gen_remap,$<,$(ES))
-
.PHONY: clean
clean:
-rm -f $(esapi_PC)
-rm -f $(esapi_OBJECTS)
-rm -f depend depend.bak
-rm -f glapi_mapi_tmp.h
- -rm -rf main
pcedit = \
-e 's,@INSTALL_DIR@,$(INSTALL_DIR),' \
# then convenience libs (.a) and finally the device drivers:
default: $(DEPENDS) asm_subdirs $(MESA_LIBS) $(DRICORE_LIBS) driver_subdirs
+# include glapi_gen.mk for generating glapi headers for GLES
+GLAPI := $(TOP)/src/mapi/glapi/gen
+include $(GLAPI)/glapi_gen.mk
+
+main/api_exec_es1_dispatch.h: $(GLAPI)/gl_and_es_API.xml $(glapi_gen_dispatch_deps)
+ $(call glapi_gen_dispatch,$<,es1)
+
+main/api_exec_es1_remap_helper.h: $(GLAPI)/gl_and_es_API.xml $(glapi_gen_remap_deps)
+ $(call glapi_gen_remap,$<,es1)
+
+main/api_exec_es1.o: main/api_exec_es1_dispatch.h main/api_exec_es1_remap_helper.h
+
+main/api_exec_es2_dispatch.h: $(GLAPI)/gl_and_es_API.xml $(glapi_gen_dispatch_deps)
+ $(call glapi_gen_dispatch,$<,es2)
+
+main/api_exec_es2_remap_helper.h: $(GLAPI)/gl_and_es_API.xml $(glapi_gen_remap_deps)
+ $(call glapi_gen_remap,$<,es2)
+
+main/api_exec_es2.o: main/api_exec_es2_dispatch.h main/api_exec_es2_remap_helper.h
+
main/api_exec_es1.c: main/APIspec.xml main/es_generator.py main/APIspecutil.py main/APIspec.py
$(PYTHON2) $(PYTHON_FLAGS) main/es_generator.py -S main/APIspec.xml -V GLES1.1 > $@
GLAPI = '#src/mapi/glapi/'
gles_headers = []
gles_headers += env.CodeGenerate(
- target = 'es1api/main/dispatch.h',
+ target = 'main/api_exec_es1_dispatch.h',
script = GLAPI + 'gen/gl_table.py',
source = GLAPI + 'gen/gl_and_es_API.xml',
command = python_cmd + ' $SCRIPT -c es1 -m remap_table -f $SOURCE > $TARGET',
)
gles_headers += env.CodeGenerate(
- target = 'es1api/main/remap_helper.h',
+ target = 'main/api_exec_es1_remap_helper.h',
script = GLAPI + 'gen/remap_helper.py',
source = GLAPI + 'gen/gl_and_es_API.xml',
command = python_cmd + ' $SCRIPT -c es1 -f $SOURCE > $TARGET',
)
gles_headers += env.CodeGenerate(
- target = 'es2api/main/dispatch.h',
+ target = 'main/api_exec_es2_dispatch.h',
script = GLAPI + 'gen/gl_table.py',
source = GLAPI + 'gen/gl_and_es_API.xml',
command = python_cmd + ' $SCRIPT -c es2 -m remap_table -f $SOURCE > $TARGET',
)
gles_headers += env.CodeGenerate(
- target = 'es2api/main/remap_helper.h',
+ target = 'main/api_exec_es2_remap_helper.h',
script = GLAPI + 'gen/remap_helper.py',
source = GLAPI + 'gen/gl_and_es_API.xml',
command = python_cmd + ' $SCRIPT -c es2 -f $SOURCE > $TARGET',
#if FEATURE_remap_table
/* define esLocalRemapTable */
-#include "%sapi/main/dispatch.h"
+#include "main/api_exec_%s_dispatch.h"
#define need_MESA_remap_table
-#include "%sapi/main/remap_helper.h"
+#include "main/api_exec_%s_remap_helper.h"
static void
init_remap_table(void)