2eb6dda4bc8d7bdb732a1e01a12037de22b5ca4c
[rocksndiamonds.git] / src / libgame / Makefile
1 #=============================================================================#
2 # Makefile for Artsoft Retro-Game Library                                     #
3 # (c) 1994-2002 Holger Schemel, info@artsoft.org                              #
4 #=============================================================================#
5
6 SRCS =  system.c        \
7         gadgets.c       \
8         text.c          \
9         sound.c         \
10         joystick.c      \
11         toons.c         \
12         pcx.c           \
13         image.c         \
14         random.c        \
15         hash.c          \
16         setup.c         \
17         misc.c          \
18         msdos.c         \
19         x11.c           \
20         sdl.c
21
22 OBJS =  system.o        \
23         gadgets.o       \
24         text.o          \
25         sound.o         \
26         joystick.o      \
27         toons.o         \
28         pcx.o           \
29         image.o         \
30         random.o        \
31         hash.o          \
32         setup.o         \
33         misc.o          \
34         msdos.o         \
35         x11.o           \
36         sdl.o
37
38 LIBGAME = libgame.a
39
40
41 all: $(LIBGAME)
42
43 $(LIBGAME): $(OBJS)
44         $(AR) cru $(LIBGAME) $(OBJS)
45         $(RANLIB) $(LIBGAME)
46
47 .c.o:
48         $(CC) $(PROFILING) $(CFLAGS) -c $*.c
49
50 clean:
51         $(RM) $(OBJS)
52         $(RM) $(LIBGAME)
53
54
55 #-----------------------------------------------------------------------------#
56 # development only stuff                                                      #
57 #-----------------------------------------------------------------------------#
58
59 depend:
60         for i in $(SRCS); do $(CPP) $(CFLAGS) -M $$i; done > .depend
61
62 ifeq (.depend,$(wildcard .depend))
63 include .depend
64 endif