]> git.zerfleddert.de Git - micropolis/blame_incremental - src/sim/makefile
use $(MAKE) in recursion to subdirectories
[micropolis] / src / sim / makefile
... / ...
CommitLineData
1XINCLUDE = /usr/include/X11
2TCLHOME = ../tcl
3TKHOME = ../tk
4TCLXHOME = ../tclx
5TCLLIBRARY = /usr/local/lib/tcl
6TKLIBRARY = /usr/local/lib/tk
7
8SDLINCLUDE := $(shell /bin/sh sdl_helper cflags)
9SDLLIBS := $(shell /bin/sh sdl_helper libs)
10
11CC = gcc
12
13OPTFLAGS = -O3
14#OPTFLAGS = -g
15
16#Possible defines:
17#ORIGINAL_MONSTER_BEHAVIOUR: The monster is able to walk over water and not die
18#NO_AIRCRASH: The Aircrash-Disaster is disables completely
19#CAM: ?
20#NET: ?
21
22#DEFINES = -DIS_LINUX -DCAM -DNET
23DEFINES = -DIS_LINUX -DORIGINAL_MONSTER_BEHAVIOUR #-DNO_AIRCRASH
24
25CFLAGS += $(OPTFLAGS) $(DEFINES) -Wall
26
27#LDFLAGS = -Bstatic
28LDFLAGS=-L/usr/X11/lib -L/usr/X11R6/lib
29
30INSTALL = install -s
31
32INCLUDES = \
33 -Iheaders \
34 -I$(XINCLUDE) \
35 -I$(TCLHOME) \
36 -I$(TCLXHOME)/src \
37 -I$(TKHOME) \
38 $(SDLINCLUDE)
39
40CPPFLAGS = $(INCLUDES)
41
42LIBS = $(TCLXHOME)/libtk.a \
43 $(TCLXHOME)/libtcl.a \
44 -lm \
45 -lX11 \
46 -lXext \
47 -lXpm \
48 $(SDLLIBS)
49
50SRCS = \
51 sim.c \
52 s_alloc.c \
53 s_disast.c \
54 s_eval.c \
55 s_gen.c \
56 s_init.c \
57 s_msg.c \
58 s_power.c \
59 s_scan.c \
60 s_sim.c \
61 s_traf.c \
62 s_zone.c \
63 s_fileio.c \
64 g_setup.c \
65 g_ani.c \
66 g_bigmap.c \
67 g_map.c \
68 g_smmaps.c \
69 w_stubs.c \
70 w_sound.c \
71 w_resrc.c \
72 w_keys.c \
73 w_util.c \
74 w_con.c \
75 w_eval.c \
76 w_budget.c \
77 w_graph.c \
78 w_date.c \
79 w_update.c \
80 w_tool.c \
81 w_x.c \
82 w_tk.c \
83 w_sim.c \
84 w_editor.c \
85 w_map.c \
86 w_sprite.c \
87 w_piem.c \
88 w_inter.c \
89 w_cam.c \
90 g_cam.c \
91 w_net.c \
92 rand.c \
93 random.c
94
95HEADERS = \
96 headers/mac.h \
97 headers/macros.h \
98 headers/sim.h \
99 headers/view.h \
100 headers/animtab.h
101
102OBJS = $(SRCS:.c=.o)
103ALLOBJS = $(OBJS)
104
105all: sim
106
107lint:
108 alint $(INCLUDES) $(SRCS) > LINT
109
110sim: $(ALLOBJS) $(TCLXHOME)/libtk.a $(TCLXHOME)/libtcl.a
111 $(CC) $(CFLAGS) $(LDFLAGS) $(INCLUDES) $(ALLOBJS) $(LIBS) -o sim
112
113clean:
114 rm -f $(OBJS) \
115 sim a.out core gmon.out *~ *.BAK Headers/*~
116
117etags:
118 etags $(SRCS) $(HEADERS)
Impressum, Datenschutz