u8g2-copy/sys/sdl/gm2/Makefile

35 lines
880 B
Makefile
Raw Normal View History

2018-02-21 06:00:54 +08:00
CFLAGS = -g -Wall -Wpointer-arith -I. -I../../../csrc/. -I../../tga/mapgen/. `sdl2-config --cflags`
2017-07-06 18:44:14 +08:00
2017-07-18 05:12:17 +08:00
GMSRC = $(shell ls ../../../csrc/*.c) $(shell ls ../common/*.c )
GMSRC += map.c main.c item.c
2017-07-19 02:14:25 +08:00
#GMSRC += ../../../tools/ugl/ugl_bc.c
GMSRC += ugl_bc.c
2017-07-06 18:44:14 +08:00
2017-07-18 05:12:17 +08:00
GMOBJ = $(GMSRC:.c=.o)
2017-07-06 18:44:14 +08:00
2017-07-18 05:12:17 +08:00
MAPGENSRC = $(shell ls ../../../csrc/*.c) mapgen.c u8g2_d_tga.c
2017-07-19 02:14:25 +08:00
MAPGENSRC += ugl_arrays.c ugl_error.c ugl_parse.c
2017-07-18 05:12:17 +08:00
MAPGENOBJ = $(MAPGENSRC:.c=.o)
2017-07-19 02:14:25 +08:00
UGLSRC = ugl_arrays.c ugl_error.c ugl_parse.c ugl_bc.c ugl_main.c item.c map.c
UGLOBJ = $(UGLSRC:.c=.o)
2017-07-18 05:12:17 +08:00
gm: $(GMOBJ) map.c
2018-02-21 06:00:54 +08:00
$(CC) $(CFLAGS) $(LDFLAGS) $(GMOBJ) `sdl2-config --libs` -o gm
2017-07-18 05:12:17 +08:00
mapgen: $(MAPGENOBJ)
$(CC) $(CFLAGS) $(LDFLAGS) $(MAPGENOBJ) -o mapgen
2017-07-19 02:14:25 +08:00
map.c: mapgen gm.map
2017-07-18 05:12:17 +08:00
./mapgen -o map.c gm.map
2017-07-19 02:14:25 +08:00
ugl: $(UGLOBJ) map.c
$(CC) $(CFLAGS) $(LDFLAGS) $(UGLOBJ) -o ugl
2017-07-06 18:44:14 +08:00
clean:
2017-07-22 02:29:34 +08:00
-rm $(GMOBJ) $(MAPGENOBJ) $(UGLOBJ) gm mapgen ugl map.c
2017-07-06 18:44:14 +08:00