Team Fortress 2 Source Code as on 22/4/2020
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

251 lines
6.2 KiB

  1. #
  2. # TF Stats Makefile for Linux 2.0
  3. #
  4. # Jul '99 by Mike Harrington <[email protected]>
  5. # (modified by Wes Cumberland <[email protected]>)
  6. #
  7. #
  8. VERSION=1.0.0.0
  9. VERSION_FN=$(VERSION)$(GLIBC)
  10. RPM_RELEASE=0
  11. ifneq (,$(findstring libc6,$(shell if [ -e /lib/libc.so.6* ];then echo libc6;fi)))
  12. GLIBC=-glibc
  13. else
  14. GLIBC=
  15. endif
  16. ifneq (,$(findstring alpha,$(shell uname -m)))
  17. ARCH=axp
  18. RPMARCH=alpha
  19. else
  20. ARCH=i386
  21. RPMARCH=i386
  22. endif
  23. MOUNT_DIR=/momma
  24. BUILD_DEBUG_DIR=$(MOUNT_DIR)/tfstats/debug
  25. BUILD_RELEASE_DIR=$(MOUNT_DIR)/tfstats/release
  26. TFSTATS_DIR=$(MOUNT_DIR)/tfstats
  27. CC=/usr/bin/g++
  28. STDCPP_INC= #/usr/local/lib/gcc-lib/H-libstdc++/include/g++-v3
  29. STDCPP_LIB= #/usr/local/lib/gcc-lib/H-libstdc++/lib
  30. BASE_CFLAGS=-Dstricmp=strcasecmp -Dstrnicmp=strncasecmp -Iregexp/include
  31. RELEASE_CFLAGS=$(BASE_CFLAGS) -m486 -O1
  32. RELEASE_NOOP_CFLAGS=$(BASE_CFLAGS) -m486
  33. DEBUG_CFLAGS=$(BASE_CFLAGS) -g -D_DEBUG -DDEBUG -Wall
  34. LDFLAGS= -static /momma/tfstats/regexp/lib/libregex++.a -ldl -lm \
  35. -lstdc++
  36. AR=ar
  37. RANLIB=ranlib
  38. DO_CC_NOOPT=$(CC) -DNO_NAMESPACE -D_WONCRYPT_NOEXCEPTIONS -w $(CFLAGS_NOOPT) -o $@ -c $<
  39. DO_CC=$(CC) -DNO_NAMESPACE -D_WONCRYPT_NOEXCEPTIONS -w $(CFLAGS) -o $@ -c $<
  40. DO_W_CC=$(CC) -DNO_NAMESPACE -D_WONCRYPT_NOEXCEPTIONS $(CFLAGS) -Wall -o $@ -c $<
  41. DO_CRYPT_CC=$(CC) -x c++ -DNO_NAMESPACE -D_WONCRYPT_NOEXCEPTIONS $(CFLAGS) -I$(WON_INC) -o $@ -c $<
  42. #############################################################################
  43. # SETUP AND BUILD
  44. #############################################################################
  45. default: build_debug
  46. TARGETS=\
  47. $(BUILDDIR)/tfstats_l
  48. make_build_dir:
  49. for x in $(BUILDDIR) \
  50. $(BUILDDIR)/tfstats ; do \
  51. if [ ! -d $$x ];then mkdir $$x;fi;done
  52. build_debug:
  53. $(MAKE) targets BUILDDIR=$(BUILD_DEBUG_DIR) CFLAGS="$(DEBUG_CFLAGS)" CFLAGS_NOOPT="$(DEBUG_CFLAGS)"
  54. build_release:
  55. $(MAKE) targets BUILDDIR=$(BUILD_RELEASE_DIR) CFLAGS="$(RELEASE_CFLAGS)" CFLAGS_NOOPT="$(RELEASE_NOOP_CFLAGS)"
  56. all: build_debug build_release
  57. targets: $(TARGETS)
  58. clean:
  59. rm -f $(BUILD_DEBUG_DIR)/*.o
  60. #############################################################################
  61. # TF Stats Program
  62. #############################################################################
  63. TFSTATS_OBJS = \
  64. $(BUILDDIR)/Argument.o \
  65. $(BUILDDIR)/EventList.o \
  66. $(BUILDDIR)/LogEvent.o \
  67. $(BUILDDIR)/LogEventIOStreams.o \
  68. $(BUILDDIR)/CureAward.o \
  69. $(BUILDDIR)/KamikazeAward.o \
  70. $(BUILDDIR)/SentryRebuildAward.o \
  71. $(BUILDDIR)/SharpshooterAward.o \
  72. $(BUILDDIR)/SurvivalistAward.o \
  73. $(BUILDDIR)/TalkativeAward.o \
  74. $(BUILDDIR)/TeamKillAward.o \
  75. $(BUILDDIR)/WeaponAwards.o \
  76. $(BUILDDIR)/CustomAward.o \
  77. $(BUILDDIR)/CustomAwardList.o \
  78. $(BUILDDIR)/CustomAwardTriggers.o \
  79. $(BUILDDIR)/Award.o \
  80. $(BUILDDIR)/CVars.o \
  81. $(BUILDDIR)/DialogueReadout.o \
  82. $(BUILDDIR)/MatchResults.o \
  83. $(BUILDDIR)/scoreboard.o \
  84. $(BUILDDIR)/WhoKilledWho.o \
  85. $(BUILDDIR)/Report.o \
  86. $(BUILDDIR)/HTML.o \
  87. $(BUILDDIR)/main.o \
  88. $(BUILDDIR)/TextFile.o \
  89. $(BUILDDIR)/util.o \
  90. $(BUILDDIR)/PlayerSpecifics.o \
  91. $(BUILDDIR)/StaticOutputFiles.o \
  92. $(BUILDDIR)/TFStatsReport.o \
  93. $(BUILDDIR)/Player.o \
  94. $(BUILDDIR)/MatchInfo.o \
  95. $(BUILDDIR)/memdbg.o \
  96. $(BUILDDIR)/pid.o \
  97. $(BUILDDIR)/binresources.o \
  98. $(BUILDDIR)/tfstatsapplication.o \
  99. $(BUILDDIR)/plrpersist.o \
  100. $(BUILDDIR)/tfstatsosinterface.o \
  101. $(BUILDDIR)/allplayersstats.o \
  102. $(BUILDDIR)/playerreport.o
  103. $(BUILDDIR)/tfstats_l : $(TFSTATS_OBJS)
  104. $(CC) $(CFLAGS) -L/usr/local/lib -o $@ $(TFSTATS_OBJS) $(LDFLAGS)
  105. $(BUILDDIR)/buildnum.o : $(TFSTATS_DIR)/buildnum.cpp
  106. $(DO_CC)
  107. $(BUILDDIR)/Argument.o : $(TFSTATS_DIR)/Argument.cpp
  108. $(DO_CC)
  109. $(BUILDDIR)/EventList.o : $(TFSTATS_DIR)/EventList.cpp
  110. $(DO_CC)
  111. $(BUILDDIR)/LogEvent.o : $(TFSTATS_DIR)/LogEvent.cpp
  112. $(DO_CC)
  113. $(BUILDDIR)/Player.o : $(TFSTATS_DIR)/Player.cpp
  114. $(DO_CC)
  115. $(BUILDDIR)/MatchInfo.o : $(TFSTATS_DIR)/MatchInfo.cpp
  116. $(DO_CC)
  117. $(BUILDDIR)/LogEventIOStreams.o : $(TFSTATS_DIR)/LogEventIOStreams.cpp
  118. $(DO_CC)
  119. $(BUILDDIR)/CureAward.o : $(TFSTATS_DIR)/CureAward.cpp
  120. $(DO_CC)
  121. $(BUILDDIR)/KamikazeAward.o : $(TFSTATS_DIR)/KamikazeAward.cpp
  122. $(DO_CC)
  123. $(BUILDDIR)/SentryRebuildAward.o : $(TFSTATS_DIR)/SentryRebuildAward.cpp
  124. $(DO_CC)
  125. $(BUILDDIR)/SharpshooterAward.o : $(TFSTATS_DIR)/SharpshooterAward.cpp
  126. $(DO_CC)
  127. $(BUILDDIR)/SurvivalistAward.o : $(TFSTATS_DIR)/SurvivalistAward.cpp
  128. $(DO_CC)
  129. $(BUILDDIR)/TalkativeAward.o : $(TFSTATS_DIR)/TalkativeAward.cpp
  130. $(DO_CC)
  131. $(BUILDDIR)/TeamKillAward.o : $(TFSTATS_DIR)/TeamKillAward.cpp
  132. $(DO_CC)
  133. $(BUILDDIR)/WeaponAwards.o : $(TFSTATS_DIR)/WeaponAwards.cpp
  134. $(DO_CC)
  135. $(BUILDDIR)/CustomAward.o : $(TFSTATS_DIR)/CustomAward.cpp
  136. $(DO_CC)
  137. $(BUILDDIR)/CustomAwardList.o : $(TFSTATS_DIR)/CustomAwardList.cpp
  138. $(DO_CC)
  139. $(BUILDDIR)/CustomAwardTriggers.o : $(TFSTATS_DIR)/CustomAwardTriggers.cpp
  140. $(DO_CC)
  141. $(BUILDDIR)/Award.o : $(TFSTATS_DIR)/Award.cpp
  142. $(DO_CC)
  143. $(BUILDDIR)/CVars.o : $(TFSTATS_DIR)/CVars.cpp
  144. $(DO_CC)
  145. $(BUILDDIR)/DialogueReadout.o : $(TFSTATS_DIR)/DialogueReadout.cpp
  146. $(DO_CC)
  147. $(BUILDDIR)/MatchResults.o : $(TFSTATS_DIR)/MatchResults.cpp
  148. $(DO_CC)
  149. $(BUILDDIR)/scoreboard.o : $(TFSTATS_DIR)/scoreboard.cpp
  150. $(DO_CC)
  151. $(BUILDDIR)/WhoKilledWho.o : $(TFSTATS_DIR)/WhoKilledWho.cpp
  152. $(DO_CC)
  153. $(BUILDDIR)/Report.o : $(TFSTATS_DIR)/Report.cpp
  154. $(DO_CC)
  155. $(BUILDDIR)/HTML.o : $(TFSTATS_DIR)/HTML.cpp
  156. $(DO_CC)
  157. $(BUILDDIR)/main.o : $(TFSTATS_DIR)/main.cpp
  158. $(DO_CC)
  159. $(BUILDDIR)/TextFile.o : $(TFSTATS_DIR)/TextFile.cpp
  160. $(DO_CC)
  161. $(BUILDDIR)/util.o : $(TFSTATS_DIR)/util.cpp
  162. $(DO_CC)
  163. $(BUILDDIR)/binresources.o : $(TFSTATS_DIR)/binresources.cpp
  164. $(DO_CC)
  165. $(BUILDDIR)/PlayerSpecifics.o : $(TFSTATS_DIR)/PlayerSpecifics.cpp
  166. $(DO_CC)
  167. $(BUILDDIR)/StaticOutputFiles.o : $(TFSTATS_DIR)/StaticOutputFiles.cpp
  168. $(DO_CC)
  169. $(BUILDDIR)/TFStatsReport.o : $(TFSTATS_DIR)/TFStatsReport.cpp
  170. $(DO_CC)
  171. $(BUILDDIR)/memdbg.o : $(TFSTATS_DIR)/memdbg.cpp
  172. $(DO_CC)
  173. $(BUILDDIR)/pid.o : $(TFSTATS_DIR)/pid.cpp
  174. $(DO_CC)
  175. $(BUILDDIR)/tfstatsapplication.o : $(TFSTATS_DIR)/tfstatsapplication.cpp
  176. $(DO_CC)
  177. $(BUILDDIR)/playerreport.o : $(TFSTATS_DIR)/playerreport.cpp
  178. $(DO_CC)
  179. $(BUILDDIR)/plrpersist.o : $(TFSTATS_DIR)/plrpersist.cpp
  180. $(DO_CC)
  181. $(BUILDDIR)/tfstatsosinterface.o : $(TFSTATS_DIR)/tfstatsosinterface.cpp
  182. $(DO_CC)
  183. $(BUILDDIR)/allplayersstats.o : $(TFSTATS_DIR)/allplayersstats.cpp
  184. $(DO_CC)