diff options
author | Michael Pavone <pavone@retrodev.com> | 2015-05-28 23:04:49 -0700 |
---|---|---|
committer | Michael Pavone <pavone@retrodev.com> | 2015-05-28 23:04:49 -0700 |
commit | 66aedc9c1a87c8811be4dba263dbcd7ec026cc70 (patch) | |
tree | e3091dbef320a3c875c640442b4c5f39efff6708 | |
parent | 93a29403d334c8dd1253221fd4588209a706f500 (diff) |
Fix crash bug in windows build
-rw-r--r-- | Makefile | 2 | ||||
-rw-r--r-- | render_sdl.c | 2 |
2 files changed, 2 insertions, 2 deletions
@@ -9,7 +9,7 @@ MEM:=mem_win.o BLASTEM:=blastem.exe CC:=wine gcc.exe -CFLAGS:=-g -std=gnu99 -Wreturn-type -Werror=return-type -Werror=implicit-function-declaration -I"C:/MinGW/usr/include/SDL2" -DGLEW_STATIC +CFLAGS:=-O2 -std=gnu99 -Wreturn-type -Werror=return-type -Werror=implicit-function-declaration -I"C:/MinGW/usr/include/SDL2" -DGLEW_STATIC LDFLAGS:= -L"C:/MinGW/usr/lib" -lm -lmingw32 -lSDL2main -lSDL2 -lopengl32 -lglu32 -mwindows CPU:=i686 diff --git a/render_sdl.c b/render_sdl.c index 38b7ed4..9de86dd 100644 --- a/render_sdl.c +++ b/render_sdl.c @@ -107,7 +107,7 @@ const GLushort element_data[] = {0, 1, 2, 3}; GLuint load_shader(char * fname, GLenum shader_type) { - char * parts[] = {getenv("HOME"), "/.config/blastem/shaders/", fname}; + char * parts[] = {get_home_dir(), "/.config/blastem/shaders/", fname}; char * shader_path = alloc_concat_m(3, parts); FILE * f = fopen(shader_path, "r"); free(shader_path); |