1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75
|
##########################################################################
# Makefile for GLFW test programs on Windows using MinGW32.
#-------------------------------------------------------------------------
# To compile the test files using this makefile, run:
# make -f Makefile.win32.mgw
##########################################################################
# Compiler settings
CC = gcc
CFLAGS = -I../include -Wall -O3 -ffast-math
#CFLAGS = -I../include -Wall -O3 -ffast-math -DGLFW_DLL
# Linker settings
LFLAGS = -L../lib/win32 -lglfw -lglu32 -lopengl32 -s
#LFLAGS = -L../lib/win32 -lglfwdll -lglu32 -lopengl32 -s
# Subsystem settings
WINDOWS = -mwindows
CONSOLE = -mconsole
# Default: Build all tests
all: triangle.exe listmodes.exe mthello.exe pong3d.exe mtbench.exe \
particles.exe splitview.exe mipmaps.exe keytest.exe gears.exe \
boing.exe wave.exe
# Rule for triangle
triangle.exe: triangle.c
$(CC) $(CFLAGS) $(WINDOWS) triangle.c $(LFLAGS) -o $@
# Rule for listmodes
listmodes.exe: listmodes.c
$(CC) $(CFLAGS) $(CONSOLE) listmodes.c $(LFLAGS) -o $@
# Rule for mthello
mthello.exe: mthello.c
$(CC) $(CFLAGS) $(CONSOLE) mthello.c $(LFLAGS) -o $@
# Rule for pong3d
pong3d.exe: pong3d.c
$(CC) $(CFLAGS) $(WINDOWS) pong3d.c $(LFLAGS) -lm -o $@
# Rule for mtbench
mtbench.exe: mtbench.c
$(CC) $(CFLAGS) $(CONSOLE) mtbench.c $(LFLAGS) -o $@
# Rule for particles
particles.exe: particles.c
$(CC) $(CFLAGS) $(CONSOLE) particles.c $(LFLAGS) -lm -o $@
# Rule for splitview
splitview.exe: splitview.c
$(CC) $(CFLAGS) $(WINDOWS) splitview.c $(LFLAGS) -lm -o $@
# Rule for mipmaps
mipmaps.exe: mipmaps.c
$(CC) $(CFLAGS) $(WINDOWS) mipmaps.c $(LFLAGS) -lm -o $@
# Rule for keytest
keytest.exe: keytest.c
$(CC) $(CFLAGS) $(CONSOLE) keytest.c $(LFLAGS) -lm -o $@
# Rule for gears
gears.exe: gears.c
$(CC) $(CFLAGS) $(CONSOLE) gears.c $(LFLAGS) -lm -o $@
# Rule for boing
boing.exe: boing.c
$(CC) $(CFLAGS) $(WINDOWS) boing.c $(LFLAGS) -lm -o $@
# Rule for wave
wave.exe: wave.c
$(CC) $(CFLAGS) $(WINDOWS) wave.c $(LFLAGS) -lm -o $@
|