1 # Generate basic Nit wrapper for glesv2, must be adapted by hands afterwards
3 cat
/usr
/include/GLES2
/gl2.h | sed \
4 -e
"s/GL_APICALL void GL_APIENTRY \([^ ]*\) /fun \1 \`{ \1/" \
5 -e
"s/GL_APICALL [^ ]* GL_APIENTRY \([^ ]*\) /fun \1: Int \`{ return \1/" \
7 -e
"s/#define GL_\([^ ]*\) .*/fun gl_\1: Int \`{ return GL_\1; \`}/" | grep fun
> $@
9 .PHONY
: glesv2_stub.nit