Leaked source code of windows server 2003
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.

335 lines
8.8 KiB

  1. ##########################################################################
  2. #
  3. # Microsoft Confidential
  4. # Copyright (C) Microsoft Corporation 1991-1998
  5. # All Rights Reserved.
  6. #
  7. ##########################################################################
  8. #
  9. # Common include file 'sources' files in the shell project.
  10. #
  11. #
  12. # These definitions are required in your sources file:
  13. #
  14. # CCSHELL_DIR
  15. # Path to ccshell root.
  16. #
  17. # FREEBUILD
  18. # Set by makefile.def file for you. One of the following:
  19. # 0 - build debug
  20. # 1 - build retail
  21. #
  22. #
  23. # Definitions used if defined:
  24. #
  25. # TARGET_WIN95
  26. # Build component explicitly for the Win95 platform. If this is
  27. # not defined, default is NT or both.
  28. #
  29. # TARGET_BOTH
  30. # Build component to run on both platforms.
  31. #
  32. # NO_PRIVATE_HEADERS
  33. # If set to 1, this is defined as a manifest constant, so the
  34. # stub headers in shell\inc\stubs do not include the private
  35. # companion headers.
  36. #
  37. # BUILD_PRIVLIB
  38. # Build a private import library too. See the comments in
  39. # makefile.inc.
  40. #
  41. # USE_NT_PRODUCT_VER
  42. # If defined, this will use the NT team's product version
  43. # numbers, as opposed to the IE team's numbers.
  44. #
  45. #
  46. # Environment Variables and their meanings
  47. #
  48. # ATL_DEBUG_QI
  49. # When set to 1, debug builds will also have _ATL_DEBUG_QI
  50. # defined. ATL code spews a bunch of debug stuff during QueryInterface.
  51. #
  52. # ATL_DEBUG_REFCOUNT
  53. # When set to 1, debug builds will also have _ATL_DEBUG_REFCOUNT
  54. # defined. ATL code spews a bunch of debug stuff during AddRef
  55. # and Release.
  56. #
  57. # SHELL_FULL_DEBUG
  58. # If set to 1, then debug builds will also have FULL_DEBUG defined.
  59. # Retail builds unaffected. This is highly encouraged for regular
  60. # development purposes. Not to be set or used by the build labs.
  61. #
  62. # SHELL_BROWSER_INFO
  63. # If set to 1, then the build process generates .sbr files for everything
  64. # in the shell that is compiled. These .sbr files are then rolled into one
  65. # giant bsc file that the MSDEV can use (see the shell\browseinfo dir) to
  66. # index the source.
  67. #
  68. # MEASURE_PERF
  69. # If set to 1, enables performance timing code for both debug and
  70. # retail builds. This code squirts the timings for interesting
  71. # events to the debug terminal.
  72. #
  73. # USE_LEGO
  74. # Define lego macros
  75. #
  76. !if !defined(CCSHELL_DIR)
  77. !error CCSHELL_DIR must be defined in sources file
  78. !endif
  79. #
  80. # Set private paths
  81. #
  82. INCLUDES = \
  83. ..;\
  84. $(CCSHELL_DIR)\inc;\
  85. $(CCSHELL_DIR)\inc\stubs;\
  86. $(WINDOWS_INC_PATH);\
  87. $(BASE_INC_PATH);\
  88. $(SDK_INC_PATH);\
  89. $(INCLUDES)
  90. #
  91. # Skip these files when determining dependencies
  92. #
  93. CONDITIONAL_INCLUDES = $(CONDITIONAL_INCLUDES) \
  94. atlbase.h \
  95. atlcom.h \
  96. atlconv.h \
  97. atlctl.h \
  98. atlctl.cpp \
  99. atliface.h \
  100. atlimpl.cpp \
  101. atlwin.h \
  102. atlwin.cpp \
  103. ia64inst.h \
  104. macapi.h \
  105. macname1.h \
  106. macname2.h \
  107. macocidl.h \
  108. macpub.h \
  109. macwin32.h \
  110. mainwin.h \
  111. mwversion.h \
  112. penwin.h \
  113. pshpck16.h \
  114. rpcerr.h \
  115. rpcmac.h \
  116. setupx.h \
  117. skbapi.h \
  118. statreg.h \
  119. statreg.cpp \
  120. unixstuff.h \
  121. version.h \
  122. winwlm.h \
  123. ..\inc16\shellapi.h \
  124. \vobs\userx\userx\public\sdk\inc\winbase.h \
  125. \vobs\userx\userx\public\sdk\inc\wingdi.h \
  126. \vobs\userx\userx\public\sdk\inc\winuser.h \
  127. \vobs\userx\userx\public\sdk\inc\shellapi.h \
  128. \vobs\userx\userx\public\sdk\inc\winspool.h \
  129. \vobs\userx\userx\public\sdk\inc\prsht.h \
  130. \vobs\userx\userx\public\sdk\inc\commdlg.h \
  131. \vobs\userx\userx\public\sdk\inc\shlobj.h \
  132. \vobs\userx\userx\public\sdk\inc\commctrl.h \
  133. \vobs\userx\userx\public\sdk\inc\shlguid.h \
  134. \vobs\userx\userx\public\sdk\inc\shlwapi.h \
  135. \vobs\userx\userx\public\sdk\inc\intshcut.h
  136. #
  137. # set this so we know when we are stupid
  138. #
  139. !if "$(BUILD_PASS)" == "PASS2"
  140. VERIFY_SOURCES = 1
  141. !endif
  142. !if !defined(TARGET_WIN95)
  143. LIBRARY_PLATFORM_PATH = $(SDK_LIB_DEST)
  144. !else
  145. # (use 'chicago' since that is already used in the NT tree)
  146. INCLUDES = $(INCLUDES);$(CCSHELL_DIR)\inc\win95;
  147. LIBRARY_PLATFORM_PATH = $(SDK_LIB_DEST)\chicago
  148. ALT_PROJECT_TARGET = chicago
  149. !endif
  150. #
  151. # Set common options
  152. #
  153. !if !defined(ATL_VER)
  154. ATL_VER=30
  155. !endif
  156. #
  157. # set the WIN32_XXX_VERSION defines properly
  158. #
  159. # assume latesst IE version
  160. WIN32_IE_VERSION=$(LATEST_WIN32_IE_VERSION)
  161. !if defined(TARGET_WIN95) || defined(TARGET_BOTH)
  162. WIN32_WINNT_VERSION=0x0400
  163. WIN32_WIN95_VERSION=0x0400
  164. SUBSYSTEM_VERSION=4.00
  165. !else
  166. WIN32_WINNT_VERSION=$(LATEST_WIN32_WINNT_VERSION)
  167. WIN32_WIN95_VERSION=$(LATEST_WIN32_WINNT_VERSION)
  168. SUBSYSTEM_VERSION=$(SUBSYSTEM_VERSION_CURRENT)
  169. !endif
  170. # Defining this allows windows.h to include other headers
  171. NOT_LEAN_AND_MEAN= 1
  172. # Don't link to the runtime libs
  173. USE_NOLIBS = 1
  174. # Don't link to NTDLL if this runs on both platforms
  175. !ifdef TARGET_BOTH
  176. NO_NTDLL=1
  177. !endif
  178. !if defined(TARGET_WIN95)
  179. # Don't define WINNT
  180. CHICAGO_PRODUCT = 1
  181. # workaround for makefile.def shortcomming:
  182. #
  183. # makefile.def is too clever for its own good. It think that Win95 builds
  184. # should never define _WIN32_WINNT. But of course, Millennium picked up
  185. # some NT features, so we have to specify explicitly that we like those
  186. # features or we don't get them.
  187. #
  188. C_DEFINES = $(C_DEFINES) -D_WIN32_WINNT=$(WIN32_WINNT_VERSION)
  189. !endif
  190. UMTYPE = windows
  191. #
  192. # Lego options
  193. #
  194. !if defined(USE_LEGO)
  195. NTBBT = 1
  196. NTPROFILEINPUT = 1
  197. !endif
  198. #
  199. # Additional compiler flags
  200. #
  201. C_DEFINES = $(C_DEFINES) -DWIN32 -D_WIN32 -DPOSTSPLIT -DUSE_MIRRORING
  202. !if defined(TARGET_DEMO)
  203. C_DEFINES = $(C_DEFINES) -DWINNT_6DEMO
  204. !endif
  205. !ifdef USE_ICECAP
  206. C_DEFINES = $(C_DEFINES) -DPRODUCT_PROF
  207. !endif
  208. !if !defined(TARGET_WIN95)
  209. C_DEFINES = $(C_DEFINES) -DNT
  210. ! if !defined(NOT_UNICODE)
  211. C_DEFINES = $(C_DEFINES) -DUNICODE -D_UNICODE
  212. ! endif
  213. !endif
  214. # ------ Debug Only Defines --------
  215. !if "$(FREEBUILD)" == "0"
  216. C_DEFINES = $(C_DEFINES) -DDEBUG
  217. LINKER_NOICF = 1 # ICF is s-l-o-w
  218. # Check for missing PURE directives in interface decls (debug only)
  219. C_DEFINES = $(C_DEFINES) -DNO_NOVTABLE
  220. # Define FULL_DEBUG for asserts to break by default
  221. ! if "$(SHELL_FULL_DEBUG)" == "1" || "$(FULL_DEBUG)" == "1"
  222. C_DEFINES = $(C_DEFINES) -DFULL_DEBUG
  223. # Also turn off compiler optimizations when FULL_DEBUG is set
  224. MSC_OPTIMIZATION= /Odi
  225. ! endif
  226. # Allow someone to have ATL_DEBUG_REFCOUNT and ATL_DEBUG_QI set
  227. # in their environment to turn this on
  228. ! if "$(ATL_DEBUG_REFCOUNT)" == "1"
  229. C_DEFINES = $(C_DEFINES) -D_ATL_DEBUG_REFCOUNT
  230. ! endif
  231. ! if "$(ATL_DEBUG_QI)" == "1"
  232. C_DEFINES = $(C_DEFINES) -D_ATL_DEBUG_QI
  233. ! endif
  234. !endif
  235. # ------ End Debug Only Defines --------
  236. !if "$(SHELL_BROWSER_INFO)" == "1"
  237. BROWSER_INFO = 1;
  238. NO_BROWSER_FILE = 1;
  239. USER_ENV_BROWSER_INFO=1
  240. !endif
  241. !if "$(MEASURE_PERF)" == "1"
  242. C_DEFINES = $(C_DEFINES) -DMEASURE_PERF
  243. !endif
  244. !if "$(NO_PRIVATE_HEADERS)" == "1"
  245. C_DEFINES = $(C_DEFINES) -DNO_PRIVATE_HEADERS
  246. !endif
  247. !ifdef USE_NT_PRODUCT_VER
  248. # Use the NT product version numbers
  249. C_DEFINES = $(C_DEFINES) -UNASHVILLE
  250. !else
  251. # Use the IE product version numbers. (The ntverp.h file checks
  252. # for NASHVILLE.)
  253. C_DEFINES = $(C_DEFINES) -DNASHVILLE
  254. !endif
  255. # IE40-only features
  256. FEATURE_IE40 = 1
  257. !ifdef FEATURE_IE40
  258. C_DEFINES = $(C_DEFINES) -DFEATURE_IE40 -DNASH
  259. !endif
  260. # Make warnings equivalent to errors
  261. !if !defined(MSC_WARNING_LEVEL)
  262. MSC_WARNING_LEVEL= /W3
  263. !endif
  264. MSC_WARNING_LEVEL= $(MSC_WARNING_LEVEL) /WX
  265. !if defined(TARGET_WIN95) || defined(TARGET_BOTH)
  266. USE_MAPSYM = 1
  267. !endif
  268. !if !defined(CLEANINF_FLAGS)
  269. # Cleaninf flags
  270. CLEANINF_FLAGS = -w
  271. !endif
  272. # Cleaninf utility
  273. CLEANINF = cleaninf.exe $(CLEANINF_FLAGS)
  274. !ifdef BUILD_PRIVLIB
  275. NTTARGETFILE1 = $(NTTARGETFILE1) $(TARGETPATHLIB)\*\$(PRIVLIB)
  276. !endif
  277. !IF "$(SPVER)" != ""
  278. C_DEFINES=$(C_DEFINES) -DSPVER=$(SPVER)
  279. !ENDIF