comparison arogue7/Makefile @ 125:adfa37e67084

Import Advanced Rogue 7.7 from the Roguelike Restoration Project (r1490)
author John "Elwin" Edwards
date Fri, 08 May 2015 15:24:40 -0400
parents
children
comparison
equal deleted inserted replaced
124:d10fc4a065ac 125:adfa37e67084
1 #
2 # Makefile for rogue
3 #
4 # Advanced Rogue
5 # Copyright (C) 1984, 1985, 1986 Michael Morgan, Ken Dalka and AT&T
6 # All rights reserved.
7 #
8 # Based on "Rogue: Exploring the Dungeons of Doom"
9 # Copyright (C) 1980, 1981 Michael Toy, Ken Arnold and Glenn Wichman
10 # All rights reserved.
11 #
12 # See the file LICENSE.TXT for full copyright and licensing information.
13 #
14
15 #
16 # Makefile for rogue
17 #
18
19
20 DISTNAME=arogue7.7.1
21 PROGRAM=arogue77
22
23 O=o
24
25 HDRS= rogue.h mach_dep.h network.h
26
27 OBJS1 = vers.$(O) actions.$(O) chase.$(O) command.$(O) daemon.$(O) \
28 daemons.$(O) eat.$(O) effects.$(O) encumb.$(O) fight.$(O) init.$(O) \
29 io.$(O) list.$(O) main.$(O) maze.$(O) mdport.$(O) misc.$(O) \
30 monsters.$(O)
31 OBJS2 = move.$(O) new_level.$(O) options.$(O) outside.$(O) pack.$(O) \
32 passages.$(O) player.$(O) potions.$(O) rings.$(O) rip.$(O) rogue.$(O) \
33 rooms.$(O) save.$(O) scrolls.$(O) state.$(O) sticks.$(O) things.$(O) \
34 trader.$(O) util.$(O) weapons.$(O) wear.$(O) wizard.$(O) xcrypt.$(O)
35 OBJS = $(OBJS1) $(OBJS2)
36
37 CFILES= vers.c actions.c chase.c command.c daemon.c \
38 daemons.c eat.c effects.c encumb.c fight.c init.c \
39 io.c list.c main.c maze.c mdport.c misc.c monsters.c \
40 move.c new_level.c options.c outside.c pack.c \
41 passages.c player.c potions.c rings.c rip.c rogue.c \
42 rooms.c save.c scrolls.c state.c sticks.c things.c \
43 trader.c util.c weapons.c wear.c wizard.c xcrypt.c
44 MISC_C=
45 DOCSRC= aguide.mm
46 DOCS = $(PROGRAM).doc $(PROGRAM).html
47 MISC = Makefile $(MISC_C) LICENSE.TXT $(PROGRAM).sln $(PROGRAM).vcproj $(DOCS)\
48 $(DOCSRC)
49
50 CC = gcc
51 ROPTS =
52 COPTS = -O3
53 CFLAGS= $(COPTS) $(ROPTS)
54 LIBS = -lcurses
55 RM = rm -f
56
57 .SUFFIXES: .obj
58
59 .c.obj:
60 $(CC) $(CFLAGS) /c $*.c
61
62 $(PROGRAM): $(HDRS) $(OBJS)
63 $(CC) $(CFLAGS) $(LDFLAGS) $(OBJS) $(LIBS) -o $@
64
65 clean:
66 $(RM) $(OBJS1)
67 $(RM) $(OBJS2)
68 $(RM) core a.exe a.out a.exe.stackdump $(PROGRAM) $(PROGRAM).exe $(PROGRAM).lck
69 $(RM) $(PROGRAM).tar $(PROGRAM).tar.gz $(PROGRAM).zip
70
71 dist.src:
72 make clean
73 tar cf $(DISTNAME)-src.tar $(CFILES) $(HDRS) $(MISC)
74 gzip -f $(DISTNAME)-src.tar
75
76 doc.nroff:
77 tbl aguide.mm | nroff -mm | colcrt - > arogue77.doc
78
79 doc.groff:
80 groff -P-c -t -mm -Tascii aguide.mm | sed -e 's/.\x08//g' > arogue77.doc
81 groff -t -mm -Thtml aguide.mm > arogue77.ht
82
83 dist.irix:
84 make clean
85 make CC=cc COPTS="-woff 1116 -O3" $(PROGRAM)
86 tar cf $(DISTNAME)-irix.tar $(PROGRAM) LICENSE.TXT $(DOCS)
87 gzip -f $(DISTNAME)-irix.tar
88
89 dist.aix:
90 make clean
91 make CC=xlc COPTS="-qmaxmem=16768 -O3 -qstrict" $(PROGRAM)
92 tar cf $(DISTNAME)-aix.tar $(PROGRAM) LICENSE.TXT $(DOCS)
93 gzip -f $(DISTNAME)-aix.tar
94
95 dist.linux:
96 make clean
97 make $(PROGRAM)
98 tar cf $(DISTNAME)-linux.tar $(PROGRAM) LICENSE.TXT $(DOCS)
99 gzip -f $(DISTNAME)-linux.tar
100
101 dist.interix:
102 @$(MAKE) clean
103 @$(MAKE) COPTS="-ansi" $(PROGRAM)
104 tar cf $(DISTNAME)-interix.tar $(PROGRAM) LICENSE.TXT $(DOCS)
105 gzip -f $(DISTNAME)-interix.tar
106
107 dist.cygwin:
108 @$(MAKE) --no-print-directory clean
109 @$(MAKE) --no-print-directory $(PROGRAM)
110 tar cf $(DISTNAME)-cygwin.tar $(PROGRAM).exe LICENSE.TXT $(DOCS)
111 gzip -f $(DISTNAME)-cygwin.tar
112
113 #
114 # Use MINGW32-MAKE to build this target
115 #
116 dist.mingw32:
117 @$(MAKE) --no-print-directory RM="cmd /c del" clean
118 @$(MAKE) --no-print-directory LIBS="-lpdcurses" $(PROGRAM)
119 cmd /c del $(DISTNAME)-mingw32.zip
120 zip $(DISTNAME)-mingw32.zip $(PROGRAM).exe LICENSE.TXT $(DOCS)
121
122 dist.msys:
123 @$(MAKE) --no-print-directory clean
124 @$(MAKE) --no-print-directory LIBS="-lcurses" $(PROGRAM)
125 tar cf $(DISTNAME)-msys.tar $(PROGRAM).exe LICENSE.TXT $(DOCS)
126 gzip -f $(DISTNAME)-msys.tar
127
128 dist.djgpp:
129 @$(MAKE) --no-print-directory clean
130 @$(MAKE) --no-print-directory LDFLAGS="-L$(DJDIR)/LIB" \
131 LIBS="-lpdcurses" $(PROGRAM)
132 rm -f $(DISTNAME)-djgpp.zip
133 zip $(DISTNAME)-djgpp.zip $(PROGRAM).exe LICENSE.TXT $(DOCS)
134
135 #
136 # Use NMAKE to build this targer
137 #
138 dist.win32:
139 @$(MAKE) /NOLOGO O="obj" RM="-del" clean
140 @$(MAKE) /NOLOGO O="obj" CC="CL" \
141 LIBS="..\pdcurses\pdcurses.lib shfolder.lib user32.lib Advapi32.lib" \
142 COPTS="-nologo -I..\pdcurses \
143 -Ox -wd4033 -wd4716" $(PROGRAM)
144 -del $(DISTNAME)-win32.zip
145 zip $(DISTNAME)-win32.zip $(PROGRAM).exe LICENSE.TXT $(DOCS)
146
147
148 actions.o: rogue.h
149 chase.o: rogue.h
150 command.o: rogue.h
151 command.o: mach_dep.h
152 daemon.o: rogue.h
153 daemons.o: rogue.h
154 eat.o: rogue.h
155 edit.o: mach_dep.h
156 edit.o: rogue.h
157 effects.o: rogue.h
158 encumb.o: rogue.h
159 fight.o: rogue.h
160 init.o: rogue.h
161 init.o: mach_dep.h
162 io.o: rogue.h
163 list.o: rogue.h
164 main.o: mach_dep.h
165 main.o: network.h
166 main.o: rogue.h
167 maze.o: rogue.h
168 misc.o: rogue.h
169 monsters.o: rogue.h
170 move.o: rogue.h
171 new_level.o: rogue.h
172 options.o: rogue.h
173 outside.o: rogue.h
174 pack.o: rogue.h
175 passages.o: rogue.h
176 player.o: rogue.h
177 potions.o: rogue.h
178 rings.o: rogue.h
179 rip.o: mach_dep.h
180 rip.o: network.h
181 rip.o: rogue.h
182 rogue.o: rogue.h
183 rooms.o: rogue.h
184 save.o: rogue.h
185 save.o: mach_dep.h
186 scrolls.o: rogue.h
187 sticks.o: rogue.h
188 things.o: rogue.h
189 trader.o: rogue.h
190 util.o: rogue.h
191 weapons.o: rogue.h
192 wear.o: rogue.h
193 wizard.o: rogue.h