Skip to content

Commit

Permalink
new! works fine !
Browse files Browse the repository at this point in the history
  • Loading branch information
BillKek committed Jan 12, 2023
1 parent 58736a6 commit f62caa5
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions build_msys2_mingw64.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
#!/bin/sh

set -xe

PKGS="--static sdl2 glew freetype2"
CFLAGS="-Wall -Wextra -pedantic -ggdb -DGLEW_STATIC `pkg-config --cflags $PKGS` -Isrc -Dassert(expression)=((void)0) "
LIBS="-lm -lopengl32 `pkg-config --libs $PKGS`"
SRC="src/main.c src/la.c src/editor.c src/file_browser.c src/free_glyph.c src/simple_renderer.c src/common.c"
OBJ=$(echo "$SRC" | sed "s/\.c/\.o/g")
OBJ=$(echo "$OBJ" | sed "s/src\// /g")

# wget "https://raw.githubusercontent.com/tsoding/minirent/master/minirent.h" -P /src
gcc -std=c11 $CFLAGS -c $SRC
# some libs linked with c++ stuff
g++ -o life.exe $OBJ $LIBS $LIBS -static

0 comments on commit f62caa5

Please sign in to comment.