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.

180 lines
4.9 KiB

  1. !include ..\makefile.inc
  2. RES_DIR=.\messages\$(ALT_PROJECT)
  3. .SUFFIXES: .sym .map
  4. SRCDIR = .
  5. NAME1=$(DEST)\regedt16
  6. NAME2=$(DEST)\regload
  7. !ifdef NOHELP
  8. DEF =/DNOHELP
  9. !else
  10. DEF=
  11. !endif
  12. INCLUDES=..\inc;$(SDK_INC_PATH)
  13. CFLAGS = -c -W3 -AS -G2sw -Zlp -Os $(DEF)
  14. AFLAGS = -Mx
  15. LFLAGS = /ALIGN:16/NOE/LI/MAP
  16. !if !$(FREEBUILD)
  17. DODEBUG=1
  18. DEF = -DDEBUG $(DEF)
  19. CFLAGS = $(CFLAGS) -Od -Zi
  20. AFLAGS = $(AFLAGS) /Zi
  21. LFLAGS = $(LFLAGS) /CO
  22. !ENDIF
  23. COMMON1 = $(DEST)\cutils1.obj $(DEST)\merge.obj $(DEST)\dbase.obj
  24. COMMON2 = $(DEST)\utils1.obj $(DEST)\regporte.obj $(DEST)\regthunk.obj
  25. OBJ1_1 = $(DEST)\regmain.obj $(DEST)\regedit.obj $(DEST)\filename.obj
  26. OBJ1_2 = $(DEST)\sdkreged.obj $(DEST)\sdbase.obj $(DEST)\virt.obj
  27. OBJ2_1 = $(NAME2).obj
  28. LIB1 = ..\lib\$(ALT_PROJECT)\libw ..\lib\slibcew ..\lib\snocrt ..\lib\commdlg ..\lib\$(DEST)\shell
  29. LIB2 = ..\lib\$(ALT_PROJECT)\libw ..\lib\slibcew ..\lib\snocrt ..\lib\$(DEST)\shell
  30. all: $(NAME1).exe
  31. allall: all $(NAME2).exe
  32. !IFNDEF DODEBUG
  33. !IFDEF DEBUG
  34. nmake DODEBUG=
  35. !ENDIF
  36. !ENDIF
  37. $(DEST)\regedit.res: $(RES_DIR)\regedit.rc $(RES_DIR)\sdkreged.dlg $(RES_DIR)\regedit.rcv
  38. set INCLUDE=$(INCLUDES)
  39. rc16 -I..\inc -r $(DEF) -fo$(DEST)\regedit.res $(RES_DIR)\regedit.rc
  40. $(NAME2).res: $(RES_DIR)\regedit.rc $(RES_DIR)\sdkreged.dlg $(RES_DIR)\regload.rcv
  41. set INCLUDE=$(INCLUDES)
  42. rc16 -I..\inc -r $(DEF) -DREGLOAD -fo$(NAME2).res $(RES_DIR)\regedit.rc
  43. {$(SRCDIR)}.c{$(DEST)}.obj:
  44. set INCLUDE=$(INCLUDES)
  45. cl16 $(CFLAGS) /Fo$*.obj $<
  46. {$(SRCDIR)}.asm{$(DEST)}.obj:
  47. masm $(AFLAGS) $<, $*.obj;
  48. regedt16: $(NAME1).exe
  49. !IFNDEF DODEBUG
  50. !IFDEF DEBUG
  51. nmake DODEBUG= regedt16
  52. !ENDIF
  53. !ENDIF
  54. regload: $(NAME2).exe
  55. !IFNDEF DODEBUG
  56. !IFDEF DEBUG
  57. nmake DODEBUG= regload
  58. !ENDIF
  59. !ENDIF
  60. #International mods
  61. iclean:
  62. del *.rc
  63. del *.dlg
  64. del *.res
  65. $(DEST)\regedt16.exe:$(DEST)\regedt16.tmp $(DEST)\regedit.res
  66. rc16 -I..\inc -t -30 $(DEST)\regedit.res $(NAME1).exe
  67. -binplace -o $(ALT_PROJECT_TARGET) $@
  68. $(NAME2).exe: $(NAME2).tmp $(NAME2).res
  69. rc16 -I..\inc -t -30 $(NAME2).res $(NAME2).exe
  70. -binplace -o $(ALT_PROJECT_TARGET) $@
  71. $(NAME1).tmp $(NAME1).map: $(OBJ1_1) $(OBJ1_2) $(COMMON1) $(COMMON2) regedit.def
  72. $(LINK16) $(LFLAGS) @<<
  73. $(OBJ1_1) +
  74. $(OBJ1_2) +
  75. $(COMMON1) +
  76. $(COMMON2),
  77. $(NAME1).exe,
  78. $(NAME1),
  79. $(LIB1),
  80. regedit.def
  81. <<
  82. cd $(DEST)
  83. mapsym regedt16.map
  84. cd ..\..\..
  85. type regedit.def > $(NAME1).tmp
  86. $(NAME2).tmp $(NAME2).map: $(OBJ2_1) $(COMMON1) $(COMMON2) regload.def
  87. $(LINK16) $(LFLAGS) @<<
  88. $(OBJ2_1) +
  89. $(COMMON1) +
  90. $(COMMON2),
  91. $(NAME2).exe,
  92. $(NAME2),
  93. $(LIB2),
  94. regload.def
  95. <<
  96. cd $(DEST)
  97. mapsym regload.map
  98. cd ..\..\..
  99. type regload.def > $(NAME2).tmp
  100. debug:
  101. nmake DODEBUG=
  102. clean: cleanup all
  103. cleanup:
  104. if exist debug\$(NAME1).exe del debug\$(NAME1).exe
  105. if exist debug\$(NAME2).exe del debug\$(NAME2).exe
  106. if exist debug\$(NAME1).tmp del debug\$(NAME1).tmp
  107. if exist debug\$(NAME2).tmp del debug\$(NAME2).tmp
  108. if exist debug\*.res del debug\*.res
  109. if exist debug\*.obj del debug\*.obj
  110. if exist debug\*.map del debug\*.map
  111. if exist debug\*.sym del debug\*.sym
  112. if exist $(NAME1).exe del $(NAME1).exe
  113. if exist $(NAME2).exe del $(NAME2).exe
  114. if exist $(NAME1).tmp del $(NAME1).tmp
  115. if exist $(NAME2).tmp del $(NAME2).tmp
  116. if exist *.res del *.res
  117. if exist *.obj del *.obj
  118. if exist *.map del *.map
  119. if exist *.sym del *.sym
  120. $(NAME2).obj: regmain.c
  121. set INCLUDE=$(INCLUDES)
  122. cl16 -c -Fo$(NAME2).obj -DREGLOAD $(CFLAGS) regmain.c
  123. depend:
  124. mv makefile makefile.old
  125. sed "/^# START Dependencies/,/^# END Dependencies/D" makefile.old > makefile.sub
  126. del makefile.old
  127. echo # START Dependencies >> makefile.sub
  128. includes -l *.c *.asm >> makefile.sub
  129. echo # END Dependencies >> makefile.sub
  130. # START Dependencies
  131. $(DEST)\cutils1.obj: cutils1.c common.h
  132. $(DEST)\dbase.obj: dbase.c RegEdit.h common.h
  133. $(DEST)\filename.obj: filename.c common.h
  134. $(DEST)\regedit.obj: regedit.c RegEdit.h common.h
  135. $(DEST)\regmain.obj: regmain.c RegEdit.h SDKRegEd.h common.h
  136. $(DEST)\sdbase.obj: sdbase.c SDKRegEd.h common.h
  137. $(DEST)\sdkreged.obj: sdkreged.c SDKRegEd.h common.h
  138. $(DEST)\utils1.obj: utils1.c
  139. $(DEST)\virt.obj: virt.c SDKRegEd.h common.h
  140. $(DEST)\merge.obj: merge.c common.h
  141. $(DEST)\regporte.obj: regporte.c reg1632.h regdef.h regporte.h regresid.h
  142. $(DEST)\regthunk.obj: regthunk.c regporte.h
  143. # END Dependencies