Skip to content

Commit

Permalink
update build system
Browse files Browse the repository at this point in the history
  • Loading branch information
ColleagueRiley committed May 11, 2024
1 parent cfcda4d commit e71ea28
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ jobs:
# TODO: Support 32bit (i386) static/shared library building
- name: Build Library
run: |
make CUSTOM_CFLAGS="-m32"
make shared CUSTOM_CFLAGS="-m32"
if: matrix.bits == 32

- name: Build Library
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ jobs:
x86_64-w64-mingw32-gcc.exe --version
windres.exe --version
dir C:\msys64\mingw64\bin
make CUSTOM_CFLAGS=-m32 CC=x86_64-w64-mingw32-gcc
make shared CUSTOM_CFLAGS=-m32
shell: cmd
if: |
matrix.compiler == 'mingw-w64' &&
Expand Down
4 changes: 4 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,10 @@ all:
$(AR) rcs libRSGL.a *.o
make examples

shared:
make RSGL.o
$(CC) $(CUSTOM_CFLAGS) RSGL.o -shared -O3 $(LIBS) -lm -o libRSGL.$(EXT)

RSGL.o:
$(CC) $(CUSTOM_CFLAGS) -x c -c -Wall RSGL.h -fPIC -DRSGL_IMPLEMENTATION -DRGFW_NO_JOYSTICK_CODES

Expand Down

0 comments on commit e71ea28

Please sign in to comment.