Makefile.linuxi386 33 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241
  1. #
  2. # Quake Makefile for Linux 2.0
  3. #
  4. # Aug '98 by Zoid <zoid@idsoftware.com>
  5. #
  6. # ELF only
  7. #
  8. BASEVERSION=1.09
  9. VERSION=$(BASEVERSION)$(GLIBC)
  10. # RPM release number
  11. RPM_RELEASE=5
  12. ifneq (,$(findstring libc6,$(shell if [ -e /lib/libc.so.6 ];then echo libc6;fi)))
  13. GLIBC=-glibc
  14. else
  15. GLIBC=
  16. endif
  17. ifneq (,$(findstring alpha,$(shell uname -m)))
  18. ARCH=axp
  19. else
  20. ARCH=i386
  21. endif
  22. NOARCH=noarch
  23. MOUNT_DIR=/grog/Projects/WinQuake
  24. MASTER_DIR=/grog/Projects/QuakeMaster
  25. MESA_DIR=/usr/local/src/Mesa-2.6
  26. TDFXGL_DIR = /home/zoid/3dfxgl
  27. BUILD_DEBUG_DIR=debug$(ARCH)$(GLIBC)
  28. BUILD_RELEASE_DIR=release$(ARCH)$(GLIBC)
  29. EGCS=/usr/local/egcs-1.1.2/bin/gcc
  30. CC=$(EGCS)
  31. BASE_CFLAGS=-Dstricmp=strcasecmp
  32. RELEASE_CFLAGS=$(BASE_CFLAGS) -g -mpentiumpro -O6 -ffast-math -funroll-loops \
  33. -fomit-frame-pointer -fexpensive-optimizations
  34. DEBUG_CFLAGS=$(BASE_CFLAGS) -g
  35. LDFLAGS=-lm
  36. SVGALDFLAGS=-lvga
  37. XLDFLAGS=-L/usr/X11R6/lib -lX11 -lXext -lXxf86dga
  38. XCFLAGS=-DX11
  39. MESAGLLDFLAGS=-L/usr/X11/lib -L/usr/local/lib -L$(MESA_DIR)/lib -lMesaGL -lglide2x -lX11 -lXext -ldl
  40. TDFXGLLDFLAGS=-L$(TDFXGL_DIR)/release$(ARCH)$(GLIBC) -l3dfxgl -lglide2x -ldl
  41. GLLDFLAGS=-L/usr/X11/lib -L/usr/local/lib -lGL -lX11 -lXext -ldl -lXxf86dga -lXxf86vm -lm
  42. GLCFLAGS=-DGLQUAKE -I$(MESA_DIR)/include -I/usr/include/glide
  43. DO_CC=$(CC) $(CFLAGS) -o $@ -c $<
  44. DO_DEBUG_CC=$(CC) $(DEBUG_CFLAGS) -o $@ -c $<
  45. DO_GL_CC=$(CC) $(CFLAGS) $(GLCFLAGS) -o $@ -c $<
  46. DO_GL_DEBUG_CC=$(CC) $(DEBUG_CFLAGS) $(GLCFLAGS) -o $@ -c $<
  47. DO_X11_CC=$(CC) $(CFLAGS) $(XCFLAGS) -o $@ -c $<
  48. DO_X11_DEBUG_CC=$(CC) $(DEBUG_CFLAGS) $(XCFLAGS) -o $@ -c $<
  49. DO_O_CC=$(CC) -O $(CFLAGS) -o $@ -c $<
  50. DO_AS=$(CC) $(CFLAGS) -DELF -x assembler-with-cpp -o $@ -c $<
  51. DO_GL_AS=$(CC) $(CFLAGS) $(GLCFLAGS) -DELF -x assembler-with-cpp -o $@ -c $<
  52. #############################################################################
  53. # SETUP AND BUILD
  54. #############################################################################
  55. TARGETS=$(BUILDDIR)/bin/squake \
  56. $(BUILDDIR)/bin/glquake \
  57. $(BUILDDIR)/bin/glquake.glx \
  58. $(BUILDDIR)/bin/glquake.3dfxgl \
  59. $(BUILDDIR)/bin/quake.x11
  60. # $(BUILDDIR)/bin/unixded
  61. build_debug:
  62. @-mkdir $(BUILD_DEBUG_DIR) \
  63. $(BUILD_DEBUG_DIR)/bin \
  64. $(BUILD_DEBUG_DIR)/glquake \
  65. $(BUILD_DEBUG_DIR)/squake \
  66. $(BUILD_DEBUG_DIR)/unixded \
  67. $(BUILD_DEBUG_DIR)/x11
  68. $(MAKE) targets BUILDDIR=$(BUILD_DEBUG_DIR) CFLAGS="$(DEBUG_CFLAGS)"
  69. build_release:
  70. @-mkdir $(BUILD_RELEASE_DIR) \
  71. $(BUILD_RELEASE_DIR)/bin \
  72. $(BUILD_RELEASE_DIR)/glquake \
  73. $(BUILD_RELEASE_DIR)/squake \
  74. $(BUILD_RELEASE_DIR)/unixded \
  75. $(BUILD_RELEASE_DIR)/x11
  76. $(MAKE) targets BUILDDIR=$(BUILD_RELEASE_DIR) CFLAGS="$(RELEASE_CFLAGS)"
  77. all: build_debug build_release
  78. targets: $(TARGETS)
  79. #############################################################################
  80. # SVGALIB Quake
  81. #############################################################################
  82. SQUAKE_OBJS = \
  83. $(BUILDDIR)/squake/cl_demo.o \
  84. $(BUILDDIR)/squake/cl_input.o \
  85. $(BUILDDIR)/squake/cl_main.o \
  86. $(BUILDDIR)/squake/cl_parse.o \
  87. $(BUILDDIR)/squake/cl_tent.o \
  88. $(BUILDDIR)/squake/chase.o \
  89. $(BUILDDIR)/squake/cmd.o \
  90. $(BUILDDIR)/squake/common.o \
  91. $(BUILDDIR)/squake/console.o \
  92. $(BUILDDIR)/squake/crc.o \
  93. $(BUILDDIR)/squake/cvar.o \
  94. $(BUILDDIR)/squake/draw.o \
  95. $(BUILDDIR)/squake/d_edge.o \
  96. $(BUILDDIR)/squake/d_fill.o \
  97. $(BUILDDIR)/squake/d_init.o \
  98. $(BUILDDIR)/squake/d_modech.o \
  99. $(BUILDDIR)/squake/d_part.o \
  100. $(BUILDDIR)/squake/d_polyse.o \
  101. $(BUILDDIR)/squake/d_scan.o \
  102. $(BUILDDIR)/squake/d_sky.o \
  103. $(BUILDDIR)/squake/d_sprite.o \
  104. $(BUILDDIR)/squake/d_surf.o \
  105. $(BUILDDIR)/squake/d_vars.o \
  106. $(BUILDDIR)/squake/d_zpoint.o \
  107. $(BUILDDIR)/squake/host.o \
  108. $(BUILDDIR)/squake/host_cmd.o \
  109. $(BUILDDIR)/squake/keys.o \
  110. $(BUILDDIR)/squake/menu.o \
  111. $(BUILDDIR)/squake/mathlib.o \
  112. $(BUILDDIR)/squake/model.o \
  113. $(BUILDDIR)/squake/net_dgrm.o \
  114. $(BUILDDIR)/squake/net_loop.o \
  115. $(BUILDDIR)/squake/net_main.o \
  116. $(BUILDDIR)/squake/net_vcr.o \
  117. $(BUILDDIR)/squake/net_udp.o \
  118. $(BUILDDIR)/squake/net_bsd.o \
  119. $(BUILDDIR)/squake/nonintel.o \
  120. $(BUILDDIR)/squake/pr_cmds.o \
  121. $(BUILDDIR)/squake/pr_edict.o \
  122. $(BUILDDIR)/squake/pr_exec.o \
  123. $(BUILDDIR)/squake/r_aclip.o \
  124. $(BUILDDIR)/squake/r_alias.o \
  125. $(BUILDDIR)/squake/r_bsp.o \
  126. $(BUILDDIR)/squake/r_light.o \
  127. $(BUILDDIR)/squake/r_draw.o \
  128. $(BUILDDIR)/squake/r_efrag.o \
  129. $(BUILDDIR)/squake/r_edge.o \
  130. $(BUILDDIR)/squake/r_misc.o \
  131. $(BUILDDIR)/squake/r_main.o \
  132. $(BUILDDIR)/squake/r_sky.o \
  133. $(BUILDDIR)/squake/r_sprite.o \
  134. $(BUILDDIR)/squake/r_surf.o \
  135. $(BUILDDIR)/squake/r_part.o \
  136. $(BUILDDIR)/squake/r_vars.o \
  137. $(BUILDDIR)/squake/screen.o \
  138. $(BUILDDIR)/squake/sbar.o \
  139. $(BUILDDIR)/squake/sv_main.o \
  140. $(BUILDDIR)/squake/sv_phys.o \
  141. $(BUILDDIR)/squake/sv_move.o \
  142. $(BUILDDIR)/squake/sv_user.o \
  143. $(BUILDDIR)/squake/zone.o \
  144. $(BUILDDIR)/squake/view.o \
  145. $(BUILDDIR)/squake/wad.o \
  146. $(BUILDDIR)/squake/world.o \
  147. $(BUILDDIR)/squake/cd_linux.o \
  148. $(BUILDDIR)/squake/sys_linux.o \
  149. $(BUILDDIR)/squake/vid_svgalib.o \
  150. $(BUILDDIR)/squake/snd_dma.o \
  151. $(BUILDDIR)/squake/snd_mem.o \
  152. $(BUILDDIR)/squake/snd_mix.o \
  153. $(BUILDDIR)/squake/snd_linux.o \
  154. \
  155. $(BUILDDIR)/squake/d_copy.o \
  156. $(BUILDDIR)/squake/d_draw.o \
  157. $(BUILDDIR)/squake/d_draw16.o \
  158. $(BUILDDIR)/squake/d_parta.o \
  159. $(BUILDDIR)/squake/d_polysa.o \
  160. $(BUILDDIR)/squake/d_scana.o \
  161. $(BUILDDIR)/squake/d_spr8.o \
  162. $(BUILDDIR)/squake/d_varsa.o \
  163. $(BUILDDIR)/squake/math.o \
  164. $(BUILDDIR)/squake/r_aliasa.o \
  165. $(BUILDDIR)/squake/r_drawa.o \
  166. $(BUILDDIR)/squake/r_edgea.o \
  167. $(BUILDDIR)/squake/r_varsa.o \
  168. $(BUILDDIR)/squake/surf16.o \
  169. $(BUILDDIR)/squake/surf8.o \
  170. $(BUILDDIR)/squake/worlda.o \
  171. $(BUILDDIR)/squake/r_aclipa.o \
  172. $(BUILDDIR)/squake/snd_mixa.o \
  173. $(BUILDDIR)/squake/sys_dosa.o
  174. $(BUILDDIR)/bin/squake : $(SQUAKE_OBJS)
  175. $(CC) $(CFLAGS) -o $@ $(SQUAKE_OBJS) $(SVGALDFLAGS) $(LDFLAGS)
  176. ####
  177. $(BUILDDIR)/squake/cl_demo.o : $(MOUNT_DIR)/cl_demo.c
  178. $(DO_CC)
  179. $(BUILDDIR)/squake/cl_input.o : $(MOUNT_DIR)/cl_input.c
  180. $(DO_CC)
  181. $(BUILDDIR)/squake/cl_main.o : $(MOUNT_DIR)/cl_main.c
  182. $(DO_CC)
  183. $(BUILDDIR)/squake/cl_parse.o : $(MOUNT_DIR)/cl_parse.c
  184. $(DO_CC)
  185. $(BUILDDIR)/squake/cl_tent.o : $(MOUNT_DIR)/cl_tent.c
  186. $(DO_CC)
  187. $(BUILDDIR)/squake/chase.o : $(MOUNT_DIR)/chase.c
  188. $(DO_CC)
  189. $(BUILDDIR)/squake/cmd.o : $(MOUNT_DIR)/cmd.c
  190. $(DO_CC)
  191. $(BUILDDIR)/squake/common.o : $(MOUNT_DIR)/common.c
  192. $(DO_DEBUG_CC)
  193. $(BUILDDIR)/squake/console.o : $(MOUNT_DIR)/console.c
  194. $(DO_CC)
  195. $(BUILDDIR)/squake/crc.o : $(MOUNT_DIR)/crc.c
  196. $(DO_CC)
  197. $(BUILDDIR)/squake/cvar.o : $(MOUNT_DIR)/cvar.c
  198. $(DO_CC)
  199. $(BUILDDIR)/squake/draw.o : $(MOUNT_DIR)/draw.c
  200. $(DO_CC)
  201. $(BUILDDIR)/squake/d_edge.o : $(MOUNT_DIR)/d_edge.c
  202. $(DO_CC)
  203. $(BUILDDIR)/squake/d_fill.o : $(MOUNT_DIR)/d_fill.c
  204. $(DO_CC)
  205. $(BUILDDIR)/squake/d_init.o : $(MOUNT_DIR)/d_init.c
  206. $(DO_CC)
  207. $(BUILDDIR)/squake/d_modech.o : $(MOUNT_DIR)/d_modech.c
  208. $(DO_CC)
  209. $(BUILDDIR)/squake/d_part.o : $(MOUNT_DIR)/d_part.c
  210. $(DO_CC)
  211. $(BUILDDIR)/squake/d_polyse.o : $(MOUNT_DIR)/d_polyse.c
  212. $(DO_CC)
  213. $(BUILDDIR)/squake/d_scan.o : $(MOUNT_DIR)/d_scan.c
  214. $(DO_CC)
  215. $(BUILDDIR)/squake/d_sky.o : $(MOUNT_DIR)/d_sky.c
  216. $(DO_CC)
  217. $(BUILDDIR)/squake/d_sprite.o : $(MOUNT_DIR)/d_sprite.c
  218. $(DO_CC)
  219. $(BUILDDIR)/squake/d_surf.o : $(MOUNT_DIR)/d_surf.c
  220. $(DO_CC)
  221. $(BUILDDIR)/squake/d_vars.o : $(MOUNT_DIR)/d_vars.c
  222. $(DO_CC)
  223. $(BUILDDIR)/squake/d_zpoint.o : $(MOUNT_DIR)/d_zpoint.c
  224. $(DO_CC)
  225. $(BUILDDIR)/squake/host.o : $(MOUNT_DIR)/host.c
  226. $(DO_CC)
  227. $(BUILDDIR)/squake/host_cmd.o : $(MOUNT_DIR)/host_cmd.c
  228. $(DO_CC)
  229. $(BUILDDIR)/squake/keys.o : $(MOUNT_DIR)/keys.c
  230. $(DO_CC)
  231. $(BUILDDIR)/squake/menu.o : $(MOUNT_DIR)/menu.c
  232. $(DO_CC)
  233. $(BUILDDIR)/squake/mathlib.o : $(MOUNT_DIR)/mathlib.c
  234. $(DO_CC)
  235. $(BUILDDIR)/squake/model.o : $(MOUNT_DIR)/model.c
  236. $(DO_CC)
  237. $(BUILDDIR)/squake/net_dgrm.o : $(MOUNT_DIR)/net_dgrm.c
  238. $(DO_CC)
  239. $(BUILDDIR)/squake/net_loop.o : $(MOUNT_DIR)/net_loop.c
  240. $(DO_CC)
  241. $(BUILDDIR)/squake/net_main.o : $(MOUNT_DIR)/net_main.c
  242. $(DO_CC)
  243. $(BUILDDIR)/squake/net_vcr.o : $(MOUNT_DIR)/net_vcr.c
  244. $(DO_CC)
  245. $(BUILDDIR)/squake/net_udp.o : $(MOUNT_DIR)/net_udp.c
  246. $(DO_CC)
  247. $(BUILDDIR)/squake/net_bsd.o : $(MOUNT_DIR)/net_bsd.c
  248. $(DO_CC)
  249. $(BUILDDIR)/squake/nonintel.o : $(MOUNT_DIR)/nonintel.c
  250. $(DO_CC)
  251. $(BUILDDIR)/squake/pr_cmds.o : $(MOUNT_DIR)/pr_cmds.c
  252. $(DO_CC)
  253. $(BUILDDIR)/squake/pr_edict.o : $(MOUNT_DIR)/pr_edict.c
  254. $(DO_CC)
  255. $(BUILDDIR)/squake/pr_exec.o : $(MOUNT_DIR)/pr_exec.c
  256. $(DO_CC)
  257. $(BUILDDIR)/squake/r_aclip.o : $(MOUNT_DIR)/r_aclip.c
  258. $(DO_CC)
  259. $(BUILDDIR)/squake/r_alias.o : $(MOUNT_DIR)/r_alias.c
  260. $(DO_CC)
  261. $(BUILDDIR)/squake/r_bsp.o : $(MOUNT_DIR)/r_bsp.c
  262. $(DO_CC)
  263. $(BUILDDIR)/squake/r_light.o : $(MOUNT_DIR)/r_light.c
  264. $(DO_CC)
  265. $(BUILDDIR)/squake/r_draw.o : $(MOUNT_DIR)/r_draw.c
  266. $(DO_CC)
  267. $(BUILDDIR)/squake/r_efrag.o : $(MOUNT_DIR)/r_efrag.c
  268. $(DO_CC)
  269. $(BUILDDIR)/squake/r_edge.o : $(MOUNT_DIR)/r_edge.c
  270. $(DO_CC)
  271. $(BUILDDIR)/squake/r_misc.o : $(MOUNT_DIR)/r_misc.c
  272. $(DO_CC)
  273. $(BUILDDIR)/squake/r_main.o : $(MOUNT_DIR)/r_main.c
  274. $(DO_CC)
  275. $(BUILDDIR)/squake/r_sky.o : $(MOUNT_DIR)/r_sky.c
  276. $(DO_CC)
  277. $(BUILDDIR)/squake/r_sprite.o : $(MOUNT_DIR)/r_sprite.c
  278. $(DO_CC)
  279. $(BUILDDIR)/squake/r_surf.o : $(MOUNT_DIR)/r_surf.c
  280. $(DO_CC)
  281. $(BUILDDIR)/squake/r_part.o : $(MOUNT_DIR)/r_part.c
  282. $(DO_CC)
  283. $(BUILDDIR)/squake/r_vars.o : $(MOUNT_DIR)/r_vars.c
  284. $(DO_CC)
  285. $(BUILDDIR)/squake/screen.o : $(MOUNT_DIR)/screen.c
  286. $(DO_CC)
  287. $(BUILDDIR)/squake/sbar.o : $(MOUNT_DIR)/sbar.c
  288. $(DO_CC)
  289. $(BUILDDIR)/squake/sv_main.o : $(MOUNT_DIR)/sv_main.c
  290. $(DO_CC)
  291. $(BUILDDIR)/squake/sv_phys.o : $(MOUNT_DIR)/sv_phys.c
  292. $(DO_CC)
  293. $(BUILDDIR)/squake/sv_move.o : $(MOUNT_DIR)/sv_move.c
  294. $(DO_CC)
  295. $(BUILDDIR)/squake/sv_user.o : $(MOUNT_DIR)/sv_user.c
  296. $(DO_CC)
  297. $(BUILDDIR)/squake/zone.o : $(MOUNT_DIR)/zone.c
  298. $(DO_CC)
  299. $(BUILDDIR)/squake/view.o : $(MOUNT_DIR)/view.c
  300. $(DO_CC)
  301. $(BUILDDIR)/squake/wad.o : $(MOUNT_DIR)/wad.c
  302. $(DO_CC)
  303. $(BUILDDIR)/squake/world.o : $(MOUNT_DIR)/world.c
  304. $(DO_CC)
  305. $(BUILDDIR)/squake/cd_linux.o : $(MOUNT_DIR)/cd_linux.c
  306. $(DO_CC)
  307. $(BUILDDIR)/squake/sys_linux.o :$(MOUNT_DIR)/sys_linux.c
  308. $(DO_CC)
  309. $(BUILDDIR)/squake/vid_svgalib.o:$(MOUNT_DIR)/vid_svgalib.c
  310. $(DO_O_CC)
  311. $(BUILDDIR)/squake/snd_dma.o : $(MOUNT_DIR)/snd_dma.c
  312. $(DO_CC)
  313. $(BUILDDIR)/squake/snd_mem.o : $(MOUNT_DIR)/snd_mem.c
  314. $(DO_CC)
  315. $(BUILDDIR)/squake/snd_mix.o : $(MOUNT_DIR)/snd_mix.c
  316. $(DO_CC)
  317. $(BUILDDIR)/squake/snd_linux.o :$(MOUNT_DIR)/snd_linux.c
  318. $(DO_CC)
  319. #####
  320. $(BUILDDIR)/squake/d_copy.o : $(MOUNT_DIR)/d_copy.s
  321. $(DO_AS)
  322. $(BUILDDIR)/squake/d_draw.o : $(MOUNT_DIR)/d_draw.s
  323. $(DO_AS)
  324. $(BUILDDIR)/squake/d_draw16.o : $(MOUNT_DIR)/d_draw16.s
  325. $(DO_AS)
  326. $(BUILDDIR)/squake/d_parta.o : $(MOUNT_DIR)/d_parta.s
  327. $(DO_AS)
  328. $(BUILDDIR)/squake/d_polysa.o : $(MOUNT_DIR)/d_polysa.s
  329. $(DO_AS)
  330. $(BUILDDIR)/squake/d_scana.o : $(MOUNT_DIR)/d_scana.s
  331. $(DO_AS)
  332. $(BUILDDIR)/squake/d_spr8.o : $(MOUNT_DIR)/d_spr8.s
  333. $(DO_AS)
  334. $(BUILDDIR)/squake/d_varsa.o : $(MOUNT_DIR)/d_varsa.s
  335. $(DO_AS)
  336. $(BUILDDIR)/squake/math.o : $(MOUNT_DIR)/math.s
  337. $(DO_AS)
  338. $(BUILDDIR)/squake/r_aliasa.o : $(MOUNT_DIR)/r_aliasa.s
  339. $(DO_AS)
  340. $(BUILDDIR)/squake/r_drawa.o : $(MOUNT_DIR)/r_drawa.s
  341. $(DO_AS)
  342. $(BUILDDIR)/squake/r_edgea.o : $(MOUNT_DIR)/r_edgea.s
  343. $(DO_AS)
  344. $(BUILDDIR)/squake/r_varsa.o : $(MOUNT_DIR)/r_varsa.s
  345. $(DO_AS)
  346. $(BUILDDIR)/squake/surf16.o : $(MOUNT_DIR)/surf16.s
  347. $(DO_AS)
  348. $(BUILDDIR)/squake/surf8.o : $(MOUNT_DIR)/surf8.s
  349. $(DO_AS)
  350. $(BUILDDIR)/squake/worlda.o : $(MOUNT_DIR)/worlda.s
  351. $(DO_AS)
  352. $(BUILDDIR)/squake/r_aclipa.o : $(MOUNT_DIR)/r_aclipa.s
  353. $(DO_AS)
  354. $(BUILDDIR)/squake/snd_mixa.o : $(MOUNT_DIR)/snd_mixa.s
  355. $(DO_AS)
  356. $(BUILDDIR)/squake/sys_dosa.o : $(MOUNT_DIR)/sys_dosa.s
  357. $(DO_AS)
  358. #############################################################################
  359. # X11 Quake
  360. #############################################################################
  361. X11_OBJS = \
  362. $(BUILDDIR)/x11/cl_demo.o \
  363. $(BUILDDIR)/x11/cl_input.o \
  364. $(BUILDDIR)/x11/cl_main.o \
  365. $(BUILDDIR)/x11/cl_parse.o \
  366. $(BUILDDIR)/x11/cl_tent.o \
  367. $(BUILDDIR)/x11/chase.o \
  368. $(BUILDDIR)/x11/cmd.o \
  369. $(BUILDDIR)/x11/common.o \
  370. $(BUILDDIR)/x11/console.o \
  371. $(BUILDDIR)/x11/crc.o \
  372. $(BUILDDIR)/x11/cvar.o \
  373. $(BUILDDIR)/x11/draw.o \
  374. $(BUILDDIR)/x11/d_edge.o \
  375. $(BUILDDIR)/x11/d_fill.o \
  376. $(BUILDDIR)/x11/d_init.o \
  377. $(BUILDDIR)/x11/d_modech.o \
  378. $(BUILDDIR)/x11/d_part.o \
  379. $(BUILDDIR)/x11/d_polyse.o \
  380. $(BUILDDIR)/x11/d_scan.o \
  381. $(BUILDDIR)/x11/d_sky.o \
  382. $(BUILDDIR)/x11/d_sprite.o \
  383. $(BUILDDIR)/x11/d_surf.o \
  384. $(BUILDDIR)/x11/d_vars.o \
  385. $(BUILDDIR)/x11/d_zpoint.o \
  386. $(BUILDDIR)/x11/host.o \
  387. $(BUILDDIR)/x11/host_cmd.o \
  388. $(BUILDDIR)/x11/keys.o \
  389. $(BUILDDIR)/x11/menu.o \
  390. $(BUILDDIR)/x11/mathlib.o \
  391. $(BUILDDIR)/x11/model.o \
  392. $(BUILDDIR)/x11/net_dgrm.o \
  393. $(BUILDDIR)/x11/net_loop.o \
  394. $(BUILDDIR)/x11/net_main.o \
  395. $(BUILDDIR)/x11/net_vcr.o \
  396. $(BUILDDIR)/x11/net_udp.o \
  397. $(BUILDDIR)/x11/net_bsd.o \
  398. $(BUILDDIR)/x11/nonintel.o \
  399. $(BUILDDIR)/x11/pr_cmds.o \
  400. $(BUILDDIR)/x11/pr_edict.o \
  401. $(BUILDDIR)/x11/pr_exec.o \
  402. $(BUILDDIR)/x11/r_aclip.o \
  403. $(BUILDDIR)/x11/r_alias.o \
  404. $(BUILDDIR)/x11/r_bsp.o \
  405. $(BUILDDIR)/x11/r_light.o \
  406. $(BUILDDIR)/x11/r_draw.o \
  407. $(BUILDDIR)/x11/r_efrag.o \
  408. $(BUILDDIR)/x11/r_edge.o \
  409. $(BUILDDIR)/x11/r_misc.o \
  410. $(BUILDDIR)/x11/r_main.o \
  411. $(BUILDDIR)/x11/r_sky.o \
  412. $(BUILDDIR)/x11/r_sprite.o \
  413. $(BUILDDIR)/x11/r_surf.o \
  414. $(BUILDDIR)/x11/r_part.o \
  415. $(BUILDDIR)/x11/r_vars.o \
  416. $(BUILDDIR)/x11/screen.o \
  417. $(BUILDDIR)/x11/sbar.o \
  418. $(BUILDDIR)/x11/sv_main.o \
  419. $(BUILDDIR)/x11/sv_phys.o \
  420. $(BUILDDIR)/x11/sv_move.o \
  421. $(BUILDDIR)/x11/sv_user.o \
  422. $(BUILDDIR)/x11/zone.o \
  423. $(BUILDDIR)/x11/view.o \
  424. $(BUILDDIR)/x11/wad.o \
  425. $(BUILDDIR)/x11/world.o \
  426. $(BUILDDIR)/x11/cd_linux.o \
  427. $(BUILDDIR)/x11/sys_linux.o \
  428. $(BUILDDIR)/x11/vid_x.o \
  429. $(BUILDDIR)/x11/snd_dma.o \
  430. $(BUILDDIR)/x11/snd_mem.o \
  431. $(BUILDDIR)/x11/snd_mix.o \
  432. $(BUILDDIR)/x11/snd_linux.o \
  433. \
  434. $(BUILDDIR)/x11/d_draw.o \
  435. $(BUILDDIR)/x11/d_draw16.o \
  436. $(BUILDDIR)/x11/d_parta.o \
  437. $(BUILDDIR)/x11/d_polysa.o \
  438. $(BUILDDIR)/x11/d_scana.o \
  439. $(BUILDDIR)/x11/d_spr8.o \
  440. $(BUILDDIR)/x11/d_varsa.o \
  441. $(BUILDDIR)/x11/math.o \
  442. $(BUILDDIR)/x11/r_aliasa.o \
  443. $(BUILDDIR)/x11/r_drawa.o \
  444. $(BUILDDIR)/x11/r_edgea.o \
  445. $(BUILDDIR)/x11/r_varsa.o \
  446. $(BUILDDIR)/x11/surf16.o \
  447. $(BUILDDIR)/x11/surf8.o \
  448. $(BUILDDIR)/x11/worlda.o \
  449. $(BUILDDIR)/x11/r_aclipa.o \
  450. $(BUILDDIR)/x11/snd_mixa.o \
  451. $(BUILDDIR)/x11/sys_dosa.o
  452. $(BUILDDIR)/bin/quake.x11 : $(X11_OBJS)
  453. $(CC) $(CFLAGS) -o $@ $(X11_OBJS) $(XLDFLAGS) $(LDFLAGS)
  454. ####
  455. $(BUILDDIR)/x11/cl_demo.o : $(MOUNT_DIR)/cl_demo.c
  456. $(DO_X11_CC)
  457. $(BUILDDIR)/x11/cl_input.o : $(MOUNT_DIR)/cl_input.c
  458. $(DO_X11_CC)
  459. $(BUILDDIR)/x11/cl_main.o : $(MOUNT_DIR)/cl_main.c
  460. $(DO_X11_CC)
  461. $(BUILDDIR)/x11/cl_parse.o : $(MOUNT_DIR)/cl_parse.c
  462. $(DO_X11_CC)
  463. $(BUILDDIR)/x11/cl_tent.o : $(MOUNT_DIR)/cl_tent.c
  464. $(DO_X11_CC)
  465. $(BUILDDIR)/x11/chase.o : $(MOUNT_DIR)/chase.c
  466. $(DO_X11_CC)
  467. $(BUILDDIR)/x11/cmd.o : $(MOUNT_DIR)/cmd.c
  468. $(DO_X11_CC)
  469. $(BUILDDIR)/x11/common.o : $(MOUNT_DIR)/common.c
  470. $(DO_X11_DEBUG_CC)
  471. $(BUILDDIR)/x11/console.o : $(MOUNT_DIR)/console.c
  472. $(DO_X11_CC)
  473. $(BUILDDIR)/x11/crc.o : $(MOUNT_DIR)/crc.c
  474. $(DO_X11_CC)
  475. $(BUILDDIR)/x11/cvar.o : $(MOUNT_DIR)/cvar.c
  476. $(DO_X11_CC)
  477. $(BUILDDIR)/x11/draw.o : $(MOUNT_DIR)/draw.c
  478. $(DO_X11_CC)
  479. $(BUILDDIR)/x11/d_edge.o : $(MOUNT_DIR)/d_edge.c
  480. $(DO_X11_CC)
  481. $(BUILDDIR)/x11/d_fill.o : $(MOUNT_DIR)/d_fill.c
  482. $(DO_X11_CC)
  483. $(BUILDDIR)/x11/d_init.o : $(MOUNT_DIR)/d_init.c
  484. $(DO_X11_CC)
  485. $(BUILDDIR)/x11/d_modech.o : $(MOUNT_DIR)/d_modech.c
  486. $(DO_X11_CC)
  487. $(BUILDDIR)/x11/d_part.o : $(MOUNT_DIR)/d_part.c
  488. $(DO_X11_CC)
  489. $(BUILDDIR)/x11/d_polyse.o : $(MOUNT_DIR)/d_polyse.c
  490. $(DO_X11_CC)
  491. $(BUILDDIR)/x11/d_scan.o : $(MOUNT_DIR)/d_scan.c
  492. $(DO_X11_CC)
  493. $(BUILDDIR)/x11/d_sky.o : $(MOUNT_DIR)/d_sky.c
  494. $(DO_X11_CC)
  495. $(BUILDDIR)/x11/d_sprite.o : $(MOUNT_DIR)/d_sprite.c
  496. $(DO_X11_CC)
  497. $(BUILDDIR)/x11/d_surf.o : $(MOUNT_DIR)/d_surf.c
  498. $(DO_X11_CC)
  499. $(BUILDDIR)/x11/d_vars.o : $(MOUNT_DIR)/d_vars.c
  500. $(DO_X11_CC)
  501. $(BUILDDIR)/x11/d_zpoint.o : $(MOUNT_DIR)/d_zpoint.c
  502. $(DO_X11_CC)
  503. $(BUILDDIR)/x11/host.o : $(MOUNT_DIR)/host.c
  504. $(DO_X11_CC)
  505. $(BUILDDIR)/x11/host_cmd.o : $(MOUNT_DIR)/host_cmd.c
  506. $(DO_X11_CC)
  507. $(BUILDDIR)/x11/keys.o : $(MOUNT_DIR)/keys.c
  508. $(DO_X11_CC)
  509. $(BUILDDIR)/x11/menu.o : $(MOUNT_DIR)/menu.c
  510. $(DO_X11_CC)
  511. $(BUILDDIR)/x11/mathlib.o : $(MOUNT_DIR)/mathlib.c
  512. $(DO_X11_CC)
  513. $(BUILDDIR)/x11/model.o : $(MOUNT_DIR)/model.c
  514. $(DO_X11_CC)
  515. $(BUILDDIR)/x11/net_dgrm.o : $(MOUNT_DIR)/net_dgrm.c
  516. $(DO_X11_CC)
  517. $(BUILDDIR)/x11/net_loop.o : $(MOUNT_DIR)/net_loop.c
  518. $(DO_X11_CC)
  519. $(BUILDDIR)/x11/net_main.o : $(MOUNT_DIR)/net_main.c
  520. $(DO_X11_CC)
  521. $(BUILDDIR)/x11/net_vcr.o : $(MOUNT_DIR)/net_vcr.c
  522. $(DO_X11_CC)
  523. $(BUILDDIR)/x11/net_udp.o : $(MOUNT_DIR)/net_udp.c
  524. $(DO_X11_CC)
  525. $(BUILDDIR)/x11/net_bsd.o : $(MOUNT_DIR)/net_bsd.c
  526. $(DO_X11_CC)
  527. $(BUILDDIR)/x11/nonintel.o : $(MOUNT_DIR)/nonintel.c
  528. $(DO_X11_CC)
  529. $(BUILDDIR)/x11/pr_cmds.o : $(MOUNT_DIR)/pr_cmds.c
  530. $(DO_X11_CC)
  531. $(BUILDDIR)/x11/pr_edict.o : $(MOUNT_DIR)/pr_edict.c
  532. $(DO_X11_CC)
  533. $(BUILDDIR)/x11/pr_exec.o : $(MOUNT_DIR)/pr_exec.c
  534. $(DO_X11_CC)
  535. $(BUILDDIR)/x11/r_aclip.o : $(MOUNT_DIR)/r_aclip.c
  536. $(DO_X11_CC)
  537. $(BUILDDIR)/x11/r_alias.o : $(MOUNT_DIR)/r_alias.c
  538. $(DO_X11_CC)
  539. $(BUILDDIR)/x11/r_bsp.o : $(MOUNT_DIR)/r_bsp.c
  540. $(DO_X11_CC)
  541. $(BUILDDIR)/x11/r_light.o : $(MOUNT_DIR)/r_light.c
  542. $(DO_X11_CC)
  543. $(BUILDDIR)/x11/r_draw.o : $(MOUNT_DIR)/r_draw.c
  544. $(DO_X11_CC)
  545. $(BUILDDIR)/x11/r_efrag.o : $(MOUNT_DIR)/r_efrag.c
  546. $(DO_X11_CC)
  547. $(BUILDDIR)/x11/r_edge.o : $(MOUNT_DIR)/r_edge.c
  548. $(DO_X11_CC)
  549. $(BUILDDIR)/x11/r_misc.o : $(MOUNT_DIR)/r_misc.c
  550. $(DO_X11_CC)
  551. $(BUILDDIR)/x11/r_main.o : $(MOUNT_DIR)/r_main.c
  552. $(DO_X11_CC)
  553. $(BUILDDIR)/x11/r_sky.o : $(MOUNT_DIR)/r_sky.c
  554. $(DO_X11_CC)
  555. $(BUILDDIR)/x11/r_sprite.o : $(MOUNT_DIR)/r_sprite.c
  556. $(DO_X11_CC)
  557. $(BUILDDIR)/x11/r_surf.o : $(MOUNT_DIR)/r_surf.c
  558. $(DO_X11_CC)
  559. $(BUILDDIR)/x11/r_part.o : $(MOUNT_DIR)/r_part.c
  560. $(DO_X11_CC)
  561. $(BUILDDIR)/x11/r_vars.o : $(MOUNT_DIR)/r_vars.c
  562. $(DO_X11_CC)
  563. $(BUILDDIR)/x11/screen.o : $(MOUNT_DIR)/screen.c
  564. $(DO_X11_CC)
  565. $(BUILDDIR)/x11/sbar.o : $(MOUNT_DIR)/sbar.c
  566. $(DO_X11_CC)
  567. $(BUILDDIR)/x11/sv_main.o : $(MOUNT_DIR)/sv_main.c
  568. $(DO_X11_CC)
  569. $(BUILDDIR)/x11/sv_phys.o : $(MOUNT_DIR)/sv_phys.c
  570. $(DO_X11_CC)
  571. $(BUILDDIR)/x11/sv_move.o : $(MOUNT_DIR)/sv_move.c
  572. $(DO_X11_CC)
  573. $(BUILDDIR)/x11/sv_user.o : $(MOUNT_DIR)/sv_user.c
  574. $(DO_X11_CC)
  575. $(BUILDDIR)/x11/zone.o : $(MOUNT_DIR)/zone.c
  576. $(DO_X11_CC)
  577. $(BUILDDIR)/x11/view.o : $(MOUNT_DIR)/view.c
  578. $(DO_X11_CC)
  579. $(BUILDDIR)/x11/wad.o : $(MOUNT_DIR)/wad.c
  580. $(DO_X11_CC)
  581. $(BUILDDIR)/x11/world.o : $(MOUNT_DIR)/world.c
  582. $(DO_X11_CC)
  583. $(BUILDDIR)/x11/cd_linux.o : $(MOUNT_DIR)/cd_linux.c
  584. $(DO_X11_CC)
  585. $(BUILDDIR)/x11/sys_linux.o :$(MOUNT_DIR)/sys_linux.c
  586. $(DO_X11_CC)
  587. $(BUILDDIR)/x11/vid_x.o: $(MOUNT_DIR)/vid_x.c
  588. $(DO_O_CC)
  589. $(BUILDDIR)/x11/snd_dma.o : $(MOUNT_DIR)/snd_dma.c
  590. $(DO_X11_CC)
  591. $(BUILDDIR)/x11/snd_mem.o : $(MOUNT_DIR)/snd_mem.c
  592. $(DO_X11_CC)
  593. $(BUILDDIR)/x11/snd_mix.o : $(MOUNT_DIR)/snd_mix.c
  594. $(DO_X11_CC)
  595. $(BUILDDIR)/x11/snd_linux.o :$(MOUNT_DIR)/snd_linux.c
  596. $(DO_X11_CC)
  597. #####
  598. $(BUILDDIR)/x11/d_copy.o : $(MOUNT_DIR)/d_copy.s
  599. $(DO_AS)
  600. $(BUILDDIR)/x11/d_draw.o : $(MOUNT_DIR)/d_draw.s
  601. $(DO_AS)
  602. $(BUILDDIR)/x11/d_draw16.o : $(MOUNT_DIR)/d_draw16.s
  603. $(DO_AS)
  604. $(BUILDDIR)/x11/d_parta.o : $(MOUNT_DIR)/d_parta.s
  605. $(DO_AS)
  606. $(BUILDDIR)/x11/d_polysa.o : $(MOUNT_DIR)/d_polysa.s
  607. $(DO_AS)
  608. $(BUILDDIR)/x11/d_scana.o : $(MOUNT_DIR)/d_scana.s
  609. $(DO_AS)
  610. $(BUILDDIR)/x11/d_spr8.o : $(MOUNT_DIR)/d_spr8.s
  611. $(DO_AS)
  612. $(BUILDDIR)/x11/d_varsa.o : $(MOUNT_DIR)/d_varsa.s
  613. $(DO_AS)
  614. $(BUILDDIR)/x11/math.o : $(MOUNT_DIR)/math.s
  615. $(DO_AS)
  616. $(BUILDDIR)/x11/r_aliasa.o : $(MOUNT_DIR)/r_aliasa.s
  617. $(DO_AS)
  618. $(BUILDDIR)/x11/r_drawa.o : $(MOUNT_DIR)/r_drawa.s
  619. $(DO_AS)
  620. $(BUILDDIR)/x11/r_edgea.o : $(MOUNT_DIR)/r_edgea.s
  621. $(DO_AS)
  622. $(BUILDDIR)/x11/r_varsa.o : $(MOUNT_DIR)/r_varsa.s
  623. $(DO_AS)
  624. $(BUILDDIR)/x11/surf16.o : $(MOUNT_DIR)/surf16.s
  625. $(DO_AS)
  626. $(BUILDDIR)/x11/surf8.o : $(MOUNT_DIR)/surf8.s
  627. $(DO_AS)
  628. $(BUILDDIR)/x11/worlda.o : $(MOUNT_DIR)/worlda.s
  629. $(DO_AS)
  630. $(BUILDDIR)/x11/r_aclipa.o : $(MOUNT_DIR)/r_aclipa.s
  631. $(DO_AS)
  632. $(BUILDDIR)/x11/snd_mixa.o : $(MOUNT_DIR)/snd_mixa.s
  633. $(DO_AS)
  634. $(BUILDDIR)/x11/sys_dosa.o : $(MOUNT_DIR)/sys_dosa.s
  635. $(DO_AS)
  636. #############################################################################
  637. # GLQuake
  638. #############################################################################
  639. GLQUAKE_OBJS= \
  640. $(BUILDDIR)/glquake/cl_demo.o \
  641. $(BUILDDIR)/glquake/cl_input.o \
  642. $(BUILDDIR)/glquake/cl_main.o \
  643. $(BUILDDIR)/glquake/cl_parse.o \
  644. $(BUILDDIR)/glquake/cl_tent.o \
  645. $(BUILDDIR)/glquake/chase.o \
  646. $(BUILDDIR)/glquake/cmd.o \
  647. $(BUILDDIR)/glquake/common.o \
  648. $(BUILDDIR)/glquake/console.o \
  649. $(BUILDDIR)/glquake/crc.o \
  650. $(BUILDDIR)/glquake/cvar.o \
  651. \
  652. $(BUILDDIR)/glquake/gl_draw.o \
  653. $(BUILDDIR)/glquake/gl_mesh.o \
  654. $(BUILDDIR)/glquake/gl_model.o \
  655. $(BUILDDIR)/glquake/gl_refrag.o \
  656. $(BUILDDIR)/glquake/gl_rlight.o \
  657. $(BUILDDIR)/glquake/gl_rmain.o \
  658. $(BUILDDIR)/glquake/gl_rmisc.o \
  659. $(BUILDDIR)/glquake/gl_rsurf.o \
  660. $(BUILDDIR)/glquake/gl_screen.o \
  661. $(BUILDDIR)/glquake/gl_test.o \
  662. $(BUILDDIR)/glquake/gl_warp.o \
  663. \
  664. $(BUILDDIR)/glquake/host.o \
  665. $(BUILDDIR)/glquake/host_cmd.o \
  666. $(BUILDDIR)/glquake/keys.o \
  667. $(BUILDDIR)/glquake/menu.o \
  668. $(BUILDDIR)/glquake/mathlib.o \
  669. $(BUILDDIR)/glquake/net_dgrm.o \
  670. $(BUILDDIR)/glquake/net_loop.o \
  671. $(BUILDDIR)/glquake/net_main.o \
  672. $(BUILDDIR)/glquake/net_vcr.o \
  673. $(BUILDDIR)/glquake/net_udp.o \
  674. $(BUILDDIR)/glquake/net_bsd.o \
  675. $(BUILDDIR)/glquake/pr_cmds.o \
  676. $(BUILDDIR)/glquake/pr_edict.o \
  677. $(BUILDDIR)/glquake/pr_exec.o \
  678. $(BUILDDIR)/glquake/r_part.o \
  679. $(BUILDDIR)/glquake/sbar.o \
  680. $(BUILDDIR)/glquake/sv_main.o \
  681. $(BUILDDIR)/glquake/sv_phys.o \
  682. $(BUILDDIR)/glquake/sv_move.o \
  683. $(BUILDDIR)/glquake/sv_user.o \
  684. $(BUILDDIR)/glquake/zone.o \
  685. $(BUILDDIR)/glquake/view.o \
  686. $(BUILDDIR)/glquake/wad.o \
  687. $(BUILDDIR)/glquake/world.o \
  688. $(BUILDDIR)/glquake/cd_linux.o \
  689. $(BUILDDIR)/glquake/sys_linux.o \
  690. $(BUILDDIR)/glquake/snd_dma.o \
  691. $(BUILDDIR)/glquake/snd_mem.o \
  692. $(BUILDDIR)/glquake/snd_mix.o \
  693. $(BUILDDIR)/glquake/snd_linux.o \
  694. \
  695. $(BUILDDIR)/glquake/math.o \
  696. $(BUILDDIR)/glquake/worlda.o \
  697. $(BUILDDIR)/glquake/snd_mixa.o \
  698. $(BUILDDIR)/glquake/sys_dosa.o
  699. GLSVGA_OBJS=$(BUILDDIR)/glquake/gl_vidlinux.o
  700. GLX_OBJS=$(BUILDDIR)/glquake/gl_vidlinuxglx.o
  701. $(BUILDDIR)/bin/glquake : $(GLQUAKE_OBJS) $(GLSVGA_OBJS)
  702. $(CC) $(CFLAGS) -o $@ $(GLQUAKE_OBJS) $(GLSVGA_OBJS) $(MESAGLLDFLAGS) $(SVGALDFLAGS) $(LDFLAGS)
  703. $(BUILDDIR)/bin/glquake.glx : $(GLQUAKE_OBJS) $(GLX_OBJS)
  704. $(CC) $(CFLAGS) -o $@ $(GLQUAKE_OBJS) $(GLX_OBJS) $(GLLDFLAGS) $(LDFLAGS)
  705. $(BUILDDIR)/bin/glquake.3dfxgl : $(GLQUAKE_OBJS) $(GLSVGA_OBJS)
  706. $(CC) $(CFLAGS) -o $@ $(GLQUAKE_OBJS) $(GLSVGA_OBJS) $(TDFXGLLDFLAGS) $(SVGALDFLAGS) $(LDFLAGS)
  707. $(BUILDDIR)/glquake/cl_demo.o : $(MOUNT_DIR)/cl_demo.c
  708. $(DO_GL_CC)
  709. $(BUILDDIR)/glquake/cl_input.o : $(MOUNT_DIR)/cl_input.c
  710. $(DO_GL_CC)
  711. $(BUILDDIR)/glquake/cl_main.o : $(MOUNT_DIR)/cl_main.c
  712. $(DO_GL_CC)
  713. $(BUILDDIR)/glquake/cl_parse.o : $(MOUNT_DIR)/cl_parse.c
  714. $(DO_GL_CC)
  715. $(BUILDDIR)/glquake/cl_tent.o : $(MOUNT_DIR)/cl_tent.c
  716. $(DO_GL_CC)
  717. $(BUILDDIR)/glquake/chase.o : $(MOUNT_DIR)/chase.c
  718. $(DO_GL_CC)
  719. $(BUILDDIR)/glquake/cmd.o : $(MOUNT_DIR)/cmd.c
  720. $(DO_GL_CC)
  721. $(BUILDDIR)/glquake/common.o : $(MOUNT_DIR)/common.c
  722. $(DO_GL_DEBUG_CC)
  723. $(BUILDDIR)/glquake/console.o : $(MOUNT_DIR)/console.c
  724. $(DO_GL_CC)
  725. $(BUILDDIR)/glquake/crc.o : $(MOUNT_DIR)/crc.c
  726. $(DO_GL_CC)
  727. $(BUILDDIR)/glquake/cvar.o : $(MOUNT_DIR)/cvar.c
  728. $(DO_GL_CC)
  729. $(BUILDDIR)/glquake/gl_draw.o : $(MOUNT_DIR)/gl_draw.c
  730. $(DO_GL_CC)
  731. $(BUILDDIR)/glquake/gl_mesh.o : $(MOUNT_DIR)/gl_mesh.c
  732. $(DO_GL_CC)
  733. $(BUILDDIR)/glquake/gl_model.o : $(MOUNT_DIR)/gl_model.c
  734. $(DO_GL_CC)
  735. $(BUILDDIR)/glquake/gl_refrag.o : $(MOUNT_DIR)/gl_refrag.c
  736. $(DO_GL_CC)
  737. $(BUILDDIR)/glquake/gl_rlight.o : $(MOUNT_DIR)/gl_rlight.c
  738. $(DO_GL_CC)
  739. $(BUILDDIR)/glquake/gl_rmain.o : $(MOUNT_DIR)/gl_rmain.c
  740. $(DO_GL_CC)
  741. $(BUILDDIR)/glquake/gl_rmisc.o : $(MOUNT_DIR)/gl_rmisc.c
  742. $(DO_GL_CC)
  743. $(BUILDDIR)/glquake/gl_rsurf.o : $(MOUNT_DIR)/gl_rsurf.c
  744. $(DO_GL_CC)
  745. $(BUILDDIR)/glquake/gl_screen.o : $(MOUNT_DIR)/gl_screen.c
  746. $(DO_GL_CC)
  747. $(BUILDDIR)/glquake/gl_test.o : $(MOUNT_DIR)/gl_test.c
  748. $(DO_GL_CC)
  749. $(BUILDDIR)/glquake/gl_vidlinux.o : $(MOUNT_DIR)/gl_vidlinux.c
  750. $(DO_GL_CC)
  751. $(BUILDDIR)/glquake/gl_vidlinuxglx.o : $(MOUNT_DIR)/gl_vidlinuxglx.c
  752. $(DO_GL_CC)
  753. $(BUILDDIR)/glquake/gl_warp.o : $(MOUNT_DIR)/gl_warp.c
  754. $(DO_GL_CC)
  755. $(BUILDDIR)/glquake/host.o : $(MOUNT_DIR)/host.c
  756. $(DO_GL_CC)
  757. $(BUILDDIR)/glquake/host_cmd.o : $(MOUNT_DIR)/host_cmd.c
  758. $(DO_GL_CC)
  759. $(BUILDDIR)/glquake/keys.o : $(MOUNT_DIR)/keys.c
  760. $(DO_GL_CC)
  761. $(BUILDDIR)/glquake/menu.o : $(MOUNT_DIR)/menu.c
  762. $(DO_GL_CC)
  763. $(BUILDDIR)/glquake/mathlib.o : $(MOUNT_DIR)/mathlib.c
  764. $(DO_GL_CC)
  765. $(BUILDDIR)/glquake/net_dgrm.o : $(MOUNT_DIR)/net_dgrm.c
  766. $(DO_GL_CC)
  767. $(BUILDDIR)/glquake/net_loop.o : $(MOUNT_DIR)/net_loop.c
  768. $(DO_GL_CC)
  769. $(BUILDDIR)/glquake/net_main.o : $(MOUNT_DIR)/net_main.c
  770. $(DO_GL_CC)
  771. $(BUILDDIR)/glquake/net_vcr.o : $(MOUNT_DIR)/net_vcr.c
  772. $(DO_GL_CC)
  773. $(BUILDDIR)/glquake/net_udp.o : $(MOUNT_DIR)/net_udp.c
  774. $(DO_GL_CC)
  775. $(BUILDDIR)/glquake/net_bsd.o : $(MOUNT_DIR)/net_bsd.c
  776. $(DO_GL_CC)
  777. $(BUILDDIR)/glquake/pr_cmds.o : $(MOUNT_DIR)/pr_cmds.c
  778. $(DO_GL_CC)
  779. $(BUILDDIR)/glquake/pr_edict.o : $(MOUNT_DIR)/pr_edict.c
  780. $(DO_GL_CC)
  781. $(BUILDDIR)/glquake/pr_exec.o : $(MOUNT_DIR)/pr_exec.c
  782. $(DO_GL_CC)
  783. $(BUILDDIR)/glquake/r_part.o : $(MOUNT_DIR)/r_part.c
  784. $(DO_GL_CC)
  785. $(BUILDDIR)/glquake/sbar.o : $(MOUNT_DIR)/sbar.c
  786. $(DO_GL_CC)
  787. $(BUILDDIR)/glquake/sv_main.o : $(MOUNT_DIR)/sv_main.c
  788. $(DO_GL_CC)
  789. $(BUILDDIR)/glquake/sv_phys.o : $(MOUNT_DIR)/sv_phys.c
  790. $(DO_GL_CC)
  791. $(BUILDDIR)/glquake/sv_move.o : $(MOUNT_DIR)/sv_move.c
  792. $(DO_GL_CC)
  793. $(BUILDDIR)/glquake/sv_user.o : $(MOUNT_DIR)/sv_user.c
  794. $(DO_GL_CC)
  795. $(BUILDDIR)/glquake/zone.o : $(MOUNT_DIR)/zone.c
  796. $(DO_GL_CC)
  797. $(BUILDDIR)/glquake/view.o : $(MOUNT_DIR)/view.c
  798. $(DO_GL_CC)
  799. $(BUILDDIR)/glquake/wad.o : $(MOUNT_DIR)/wad.c
  800. $(DO_GL_CC)
  801. $(BUILDDIR)/glquake/world.o : $(MOUNT_DIR)/world.c
  802. $(DO_GL_CC)
  803. $(BUILDDIR)/glquake/cd_linux.o : $(MOUNT_DIR)/cd_linux.c
  804. $(DO_GL_CC)
  805. $(BUILDDIR)/glquake/sys_linux.o : $(MOUNT_DIR)/sys_linux.c
  806. $(DO_GL_CC)
  807. $(BUILDDIR)/glquake/snd_dma.o : $(MOUNT_DIR)/snd_dma.c
  808. $(DO_GL_CC)
  809. $(BUILDDIR)/glquake/snd_mem.o : $(MOUNT_DIR)/snd_mem.c
  810. $(DO_GL_CC)
  811. $(BUILDDIR)/glquake/snd_mix.o : $(MOUNT_DIR)/snd_mix.c
  812. $(DO_GL_CC)
  813. $(BUILDDIR)/glquake/snd_linux.o : $(MOUNT_DIR)/snd_linux.c
  814. $(DO_GL_CC)
  815. $(BUILDDIR)/glquake/math.o : $(MOUNT_DIR)/math.s
  816. $(DO_GL_AS)
  817. $(BUILDDIR)/glquake/worlda.o : $(MOUNT_DIR)/worlda.s
  818. $(DO_GL_AS)
  819. $(BUILDDIR)/glquake/snd_mixa.o : $(MOUNT_DIR)/snd_mixa.s
  820. $(DO_GL_AS)
  821. $(BUILDDIR)/glquake/sys_dosa.o : $(MOUNT_DIR)/sys_dosa.s
  822. $(DO_GL_AS)
  823. #############################################################################
  824. # RPM
  825. #############################################################################
  826. # Make RPMs. You need to be root to make this work
  827. RPMROOT=/usr/src/redhat
  828. RPM = rpm
  829. RPMFLAGS = -bb
  830. INSTALLDIR = /usr/local/games/quake
  831. TMPDIR = /var/tmp
  832. RPMDIR = $(TMPDIR)/quake-$(VERSION)
  833. BASERPMDIR = $(TMPDIR)/quake-$(BASEVERSION)
  834. rpm: rpm-quake rpm-quake-data rpm-hipnotic rpm-rogue
  835. rpm-quake: quake.spec \
  836. $(BUILD_RELEASE_DIR)/bin/squake \
  837. $(BUILD_RELEASE_DIR)/bin/quake.x11 \
  838. $(BUILD_RELEASE_DIR)/bin/glquake \
  839. $(BUILD_RELEASE_DIR)/bin/glquake.glx \
  840. $(BUILD_RELEASE_DIR)/bin/glquake.3dfxgl
  841. touch $(RPMROOT)/SOURCES/quake-$(VERSION).tar.gz
  842. if [ ! -d RPMS ];then mkdir RPMS;fi
  843. cp $(MOUNT_DIR)/quake.gif $(RPMROOT)/SOURCES/quake.gif
  844. # basic binaries rpm
  845. -mkdirhier $(RPMDIR)/$(INSTALLDIR)
  846. cp $(MOUNT_DIR)/docs/README $(RPMDIR)/$(INSTALLDIR)/.
  847. cp $(BUILD_RELEASE_DIR)/bin/squake $(RPMDIR)/$(INSTALLDIR)/squake
  848. strip $(RPMDIR)/$(INSTALLDIR)/squake
  849. cp $(BUILD_RELEASE_DIR)/bin/quake.x11 $(RPMDIR)/$(INSTALLDIR)/quake.x11
  850. strip $(RPMDIR)/$(INSTALLDIR)/quake.x11
  851. cp $(BUILD_RELEASE_DIR)/bin/glquake $(RPMDIR)/$(INSTALLDIR)/glquake
  852. strip $(RPMDIR)/$(INSTALLDIR)/glquake
  853. cp $(BUILD_RELEASE_DIR)/bin/glquake.glx $(RPMDIR)/$(INSTALLDIR)/glquake.glx
  854. strip $(RPMDIR)/$(INSTALLDIR)/glquake.glx
  855. cp $(BUILD_RELEASE_DIR)/bin/glquake.3dfxgl $(RPMDIR)/$(INSTALLDIR)/glquake.3dfxgl
  856. strip $(RPMDIR)/$(INSTALLDIR)/glquake.3dfxgl
  857. -mkdirhier $(RPMDIR)/usr/lib
  858. cp $(TDFXGL_DIR)/release$(ARCH)$(GLIBC)/lib3dfxgl.so $(RPMDIR)/usr/lib/lib3dfxgl.so
  859. cp $(MESA_DIR)/lib/libMesaGL.so.2.6 $(RPMDIR)/usr/lib/libMesaGL.so.2.6
  860. cp quake.spec $(RPMROOT)/SPECS/.
  861. cd $(RPMROOT)/SPECS; $(RPM) $(RPMFLAGS) quake.spec
  862. rm -rf $(RPMDIR)
  863. rm -f $(RPMROOT)/SOURCES/quake-$(VERSION).tar.gz
  864. mv $(RPMROOT)/RPMS/$(ARCH)/quake-$(VERSION)-$(RPM_RELEASE).$(ARCH).rpm RPMS/.
  865. QUAKEDATADIR=$(TMPDIR)/quake-data-$(BASEVERSION)
  866. rpm-quake-data: quake-data.spec
  867. # data rpm
  868. touch $(RPMROOT)/SOURCES/quake-$(BASEVERSION)-data.tar.gz
  869. -mkdirhier $(QUAKEDATADIR)/$(INSTALLDIR)/id1
  870. cp $(MASTER_DIR)/id1/pak0.pak $(QUAKEDATADIR)/$(INSTALLDIR)/id1/.
  871. cp $(MASTER_DIR)/id1/pak1.pak $(QUAKEDATADIR)/$(INSTALLDIR)/id1/.
  872. cp $(MOUNT_DIR)/docs/README $(QUAKEDATADIR)/$(INSTALLDIR)/.
  873. cp $(MOUNT_DIR)/data/comexp.txt $(QUAKEDATADIR)/$(INSTALLDIR)/.
  874. cp $(MOUNT_DIR)/data/help.txt $(QUAKEDATADIR)/$(INSTALLDIR)/.
  875. cp $(MOUNT_DIR)/data/licinfo.txt $(QUAKEDATADIR)/$(INSTALLDIR)/.
  876. cp $(MOUNT_DIR)/data/manual.txt $(QUAKEDATADIR)/$(INSTALLDIR)/.
  877. cp $(MOUNT_DIR)/data/readme.txt $(QUAKEDATADIR)/$(INSTALLDIR)/.
  878. cp $(MOUNT_DIR)/data/rlicnse.txt $(QUAKEDATADIR)/$(INSTALLDIR)/.
  879. cp $(MOUNT_DIR)/data/slicnse.txt $(QUAKEDATADIR)/$(INSTALLDIR)/.
  880. cp $(MOUNT_DIR)/data/techinfo.txt $(QUAKEDATADIR)/$(INSTALLDIR)/.
  881. cp quake-data.spec $(RPMROOT)/SPECS/.
  882. cd $(RPMROOT)/SPECS; $(RPM) $(RPMFLAGS) quake-data.spec
  883. rm -rf $(QUAKEDATADIR)
  884. rm -f $(RPMROOT)/SOURCES/quake-$(BASEVERSION)-data.tar.gz
  885. mv $(RPMROOT)/RPMS/$(NOARCH)/quake-data-$(BASEVERSION)-$(RPM_RELEASE).$(NOARCH).rpm RPMS/.
  886. RPMHIPNOTICDIR=$(TMPDIR)/quake-hipnotic-$(BASEVERSION)
  887. rpm-hipnotic: quake-hipnotic.spec
  888. touch $(RPMROOT)/SOURCES/quake-hipnotic-$(BASEVERSION).tar.gz
  889. if [ ! -d RPMS ];then mkdir RPMS;fi
  890. cp $(MOUNT_DIR)/quake.gif $(RPMROOT)/SOURCES/quake.gif
  891. -mkdirhier $(RPMHIPNOTICDIR)/$(INSTALLDIR)/hipnotic/docs
  892. cp $(MASTER_DIR)/hipnotic/pak0.pak $(RPMHIPNOTICDIR)/$(INSTALLDIR)/hipnotic/.
  893. cp $(MASTER_DIR)/hipnotic/config.cfg $(RPMHIPNOTICDIR)/$(INSTALLDIR)/hipnotic/.
  894. cp $(MASTER_DIR)/hipnotic/docs/manual.doc $(RPMHIPNOTICDIR)/$(INSTALLDIR)/hipnotic/docs/.
  895. cp $(MASTER_DIR)/hipnotic/docs/manual.htm $(RPMHIPNOTICDIR)/$(INSTALLDIR)/hipnotic/docs/.
  896. cp $(MASTER_DIR)/hipnotic/docs/manual.txt $(RPMHIPNOTICDIR)/$(INSTALLDIR)/hipnotic/docs/.
  897. cp $(MASTER_DIR)/hipnotic/docs/readme.doc $(RPMHIPNOTICDIR)/$(INSTALLDIR)/hipnotic/docs/.
  898. cp $(MASTER_DIR)/hipnotic/docs/readme.htm $(RPMHIPNOTICDIR)/$(INSTALLDIR)/hipnotic/docs/.
  899. cp $(MASTER_DIR)/hipnotic/docs/readme.txt $(RPMHIPNOTICDIR)/$(INSTALLDIR)/hipnotic/docs/.
  900. cp quake-hipnotic.spec $(RPMROOT)/SPECS/.
  901. cd $(RPMROOT)/SPECS; $(RPM) $(RPMFLAGS) quake-hipnotic.spec
  902. rm -rf $(RPMHIPNOTICDIR)
  903. rm -f $(RPMROOT)/SOURCES/quake-hipnotic-$(BASEVERSION).tar.gz
  904. mv $(RPMROOT)/RPMS/$(NOARCH)/quake-hipnotic-$(BASEVERSION)-$(RPM_RELEASE).$(NOARCH).rpm RPMS/.
  905. RPMROGUEDIR=$(TMPDIR)/quake-rogue-$(BASEVERSION)
  906. rpm-rogue: quake-rogue.spec
  907. touch $(RPMROOT)/SOURCES/quake-rogue-$(BASEVERSION).tar.gz
  908. if [ ! -d RPMS ];then mkdir RPMS;fi
  909. cp $(MOUNT_DIR)/quake.gif $(RPMROOT)/SOURCES/quake.gif
  910. -mkdirhier $(RPMROGUEDIR)/$(INSTALLDIR)/rogue/docs
  911. cp $(MASTER_DIR)/rogue/pak0.pak $(RPMROGUEDIR)/$(INSTALLDIR)/rogue/.
  912. cp $(MASTER_DIR)/rogue/docs/manual.doc $(RPMROGUEDIR)/$(INSTALLDIR)/rogue/docs/.
  913. cp $(MASTER_DIR)/rogue/docs/manual.htm $(RPMROGUEDIR)/$(INSTALLDIR)/rogue/docs/.
  914. cp $(MASTER_DIR)/rogue/docs/manual.txt $(RPMROGUEDIR)/$(INSTALLDIR)/rogue/docs/.
  915. cp $(MASTER_DIR)/rogue/docs/readme.doc $(RPMROGUEDIR)/$(INSTALLDIR)/rogue/docs/.
  916. cp $(MASTER_DIR)/rogue/docs/readme.htm $(RPMROGUEDIR)/$(INSTALLDIR)/rogue/docs/.
  917. cp $(MASTER_DIR)/rogue/docs/readme.txt $(RPMROGUEDIR)/$(INSTALLDIR)/rogue/docs/.
  918. cp $(MASTER_DIR)/rogue/docs/ctf.doc $(RPMROGUEDIR)/$(INSTALLDIR)/rogue/docs/.
  919. cp $(MASTER_DIR)/rogue/docs/ctf.htm $(RPMROGUEDIR)/$(INSTALLDIR)/rogue/docs/.
  920. cp $(MASTER_DIR)/rogue/docs/ctf.txt $(RPMROGUEDIR)/$(INSTALLDIR)/rogue/docs/.
  921. cp quake-rogue.spec $(RPMROOT)/SPECS/.
  922. cd $(RPMROOT)/SPECS; $(RPM) $(RPMFLAGS) quake-rogue.spec
  923. rm -rf $(RPMROGUEDIR)
  924. rm -f $(RPMROOT)/SOURCES/quake-rogue-$(BASEVERSION).tar.gz
  925. mv $(RPMROOT)/RPMS/$(NOARCH)/quake-rogue-$(BASEVERSION)-$(RPM_RELEASE).$(NOARCH).rpm RPMS/.
  926. quake.spec : $(MOUNT_DIR)/quake.spec.sh
  927. sh $< $(VERSION) $(RPM_RELEASE) $(INSTALLDIR) > $@
  928. quake-data.spec : $(MOUNT_DIR)/quake-data.spec.sh
  929. sh $< $(BASEVERSION) $(RPM_RELEASE) $(INSTALLDIR) > $@
  930. quake-hipnotic.spec : $(MOUNT_DIR)/quake-hipnotic.spec.sh
  931. sh $< $(BASEVERSION) $(RPM_RELEASE) $(INSTALLDIR) > $@
  932. quake-rogue.spec : $(MOUNT_DIR)/quake-rogue.spec.sh
  933. sh $< $(BASEVERSION) $(RPM_RELEASE) $(INSTALLDIR) > $@
  934. #############################################################################
  935. # MISC
  936. #############################################################################
  937. clean: clean-debug clean-release
  938. rm -f squake.spec glquake.spec quake.x11.spec
  939. clean-debug:
  940. $(MAKE) clean2 BUILDDIR=$(BUILD_DEBUG_DIR) CFLAGS="$(DEBUG_CFLAGS)"
  941. clean-release:
  942. $(MAKE) clean2 BUILDDIR=$(BUILD_RELEASE_DIR) CFLAGS="$(DEBUG_CFLAGS)"
  943. clean2:
  944. -rm -f $(SQUAKE_OBJS) $(X11_OBJS) $(GLQUAKE_OBJS) $(GLSVGA_OBJS) \
  945. $(GLX_OBJS)