4 LIBS
= $$(sdl-config
--libs
) -lSDL_mixer
-lSDL_image
5 CFLAGS
= -Wall
$$(sdl-config
--cflags)
7 SRC
= tennix.c game.c graphics.c input.c sound.c
8 OBJ
= tennix.o game.o graphics.o input.o sound.o
11 DATAFILES
= data
/*.bmp data
/*.png data
/*.wav
14 $(CC
) $(CFLAGS
) -o tennix
$(OBJ
) $(LIBS
)
15 test -x
`which upx` && test -f tennix.exe
&& `which upx` tennix.exe || true
17 tennix.o
: tennix.c tennix.h game.h graphics.h input.h sound.h
18 graphics.o
: graphics.c graphics.h tennix.h input.h
19 game.o
: game.c game.h graphics.h tennix.h sound.h
20 sound.o
: sound.c sound.h tennix.h
23 zip tennix-
$(RELEASE
).zip tennix.exe
$(WIN32LIBS
) $(DATAFILES
)
26 tar czvf tennix-
$(RELEASE
)-bin.
tar.gz tennix
$(DATAFILES
)
29 rm -f
*.o tennix
{,.exe
}
32 rm -f tennix-
$(RELEASE
).zip tennix-
$(RELEASE
)-bin.
tar.gz
34 .PHONY
: distclean clean release-bin release-win32