diff --git a/build.zig b/build.zig index d0e7a52..3df9378 100644 --- a/build.zig +++ b/build.zig @@ -302,6 +302,8 @@ pub fn emLinkStep(b: *Build, options: EmLinkOptions) !*Build.Step.Run { try emcc_cmd.append(emcc_path); if (options.optimize == .Debug) { try emcc_cmd.append("-Og"); + try emcc_cmd.append("-sSAFE_HEAP=1"); + try emcc_cmd.append("-sSTACK_OVERFLOW_CHECK=1"); } else { try emcc_cmd.append("-sASSERTIONS=0"); if (options.optimize == .ReleaseSmall) { diff --git a/build.zig.zon b/build.zig.zon index deacf66..693d32d 100644 --- a/build.zig.zon +++ b/build.zig.zon @@ -11,8 +11,8 @@ }, .dependencies = .{ .emsdk = .{ - .url = "git+https://github.com/emscripten-core/emsdk#0bbae74935d57ff41739648c12cf90b56668398f", - .hash = "1220f1340cd871b444021c600661f921f96091ce0815fa43008528f4844cece7e245", + .url = "git+https://github.com/emscripten-core/emsdk#c18280c8f3f8f088b4337f0f6a5fdb2be0d67179", + .hash = "12203d61e8947f25993a86b4d73e2d91b4c1d96f1aa07c581b7dffba7cb5ca91bc35", }, }, } diff --git a/src/sokol/c/sokol_gfx.h b/src/sokol/c/sokol_gfx.h index 1202033..f065c72 100644 --- a/src/sokol/c/sokol_gfx.h +++ b/src/sokol/c/sokol_gfx.h @@ -6476,8 +6476,13 @@ _SOKOL_PRIVATE void _sg_dummy_update_image(_sg_image_t* img, const sg_image_data // optional GL loader for win32 #if defined(_SOKOL_USE_WIN32_GL_LOADER) +#ifndef SG_GL_FUNCS_EXT +#define SG_GL_FUNCS_EXT +#endif + // X Macro list of GL function names and signatures #define _SG_GL_FUNCS \ + SG_GL_FUNCS_EXT \ _SG_XMACRO(glBindVertexArray, void, (GLuint array)) \ _SG_XMACRO(glFramebufferTextureLayer, void, (GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer)) \ _SG_XMACRO(glGenFramebuffers, void, (GLsizei n, GLuint * framebuffers)) \