Source code of Windows XP (NT5)
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.

78 lines
2.6 KiB

  1. @if "%_echo%" == "" echo off
  2. @rem
  3. @rem If no drive has been specified for the NT development tree, assume
  4. @rem C:. To override this, place a SET _NTDRIVE=X: in your CONFIG.SYS
  5. @rem
  6. if "%_NTDRIVE%" == "" set _NTDRIVE=C:
  7. @rem
  8. @rem If no directory has been specified for the NT development tree, assume
  9. @rem \nt. To override this, place a SET _NTROOT=\xt in your CONFIG.SYS
  10. @rem
  11. if "%_NTROOT%" == "" set _NTROOT=\NT
  12. set _NTBINDIR=%_NTDRIVE%%_NTROOT%
  13. @rem
  14. @rem This command file assumes that the developer has already defined
  15. @rem the USERNAME environment variable to match their email name (e.g.
  16. @rem stevewo).
  17. @rem
  18. @rem We want to remember some environment variables so we can restore later
  19. @rem if necessary (see NTUSER.CMD)
  20. @rem
  21. set _NTUSER=%USERNAME%
  22. @rem
  23. @rem No hidden semantics of where to get libraries and include files. All
  24. @rem information is included in the command lines that invoke the compilers
  25. @rem and linkers.
  26. @rem
  27. set LIB=
  28. set INCLUDE=
  29. @rem
  30. @rem Setup default build parameters.
  31. @rem
  32. @rem If the user doesn't specify the BUILD_DEFAULT_TARGETS, use either -386
  33. @rem (for X86 NT or Win9x hosted builds) or the same as the processor_architecture.
  34. @rem Also set the default architecture to 1 so naked nmake's work from the cmdline.
  35. @rem
  36. if NOT "%BUILD_DEFAULT_TARGETS%" == "" goto BuildDefaultTargetSet
  37. if NOT "%_BuildArch%" == "" goto _BuildArchSet
  38. if "%_BuildArch%" == "" set _BuildArch=%PROCESSOR_ARCHITECTURE%
  39. if "%PROCESSOR_ARCHITECTURE%" == "x86" set 386=1
  40. :_BuildArchSet
  41. set BUILD_DEFAULT_TARGETS=-%_BuildArch%
  42. :BuildDefaultTargetSet
  43. if "%_BuildArch%" == "x86" goto UseX86BuildDefault
  44. set BUILD_DEFAULT=daytona ~win95 ~w95cpp ~w95c ~w5api ~chicago -e -E -w -nmake -i
  45. set NO_MAPSYM=1
  46. goto BuildDefaultSet
  47. :UseX86BuildDefault
  48. set BUILD_DEFAULT=daytona -e -E -w -nmake -i
  49. :BuildDefaultSet
  50. if "%BUILD_MAKE_PROGRAM%" == "" set BUILD_MAKE_PROGRAM=nmake.exe
  51. if "%BUILD_PRODUCT%" == "" set BUILD_PRODUCT=NT
  52. if "%BUILD_PRODUCT_VER%" == "" set BUILD_PRODUCT_VER=500
  53. if "%NUMBER_OF_PROCESSORS%" == "" goto SingleProc
  54. if "%NUMBER_OF_PROCESSORS%" == "1" goto SingleProc
  55. set BUILD_MULTIPROCESSOR=1
  56. :SingleProc
  57. @rem
  58. @rem Setup default nmake parameters.
  59. @rem
  60. if "%NTMAKEENV%" == "" set NTMAKEENV=%_NTBINDIR%\Tools
  61. if "%COPYCMD%" == "" set COPYCMD=/Y
  62. @rem
  63. @rem By default, net uses are NOT persistent. Do this here in case
  64. @rem user wants to override in their setenv.cmd
  65. @rem
  66. net use /PER:NO >nul
  67. @rem
  68. @rem Setup the user specific environment information
  69. @rem
  70. call %_NTBINDIR%\TOOLS\ntuser.cmd
  71. @rem
  72. @rem Optional parameters to this script are command line to execute
  73. @rem
  74. %1 %2 %3 %4 %5 %6 %7 %8 %9