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