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.

110 lines
5.0 KiB

  1. @REM -----------------------------------------------------------------
  2. @REM
  3. @REM makeupgadvimg.cmd - OvidiuT
  4. @REM Create the upgrade advisor directory
  5. @REM
  6. @REM Copyright (c) Microsoft Corporation. All rights reserved.
  7. @REM
  8. @REM -----------------------------------------------------------------
  9. @if defined _CPCMAGIC goto CPCBegin
  10. @perl -x "%~f0" %*
  11. @goto :EOF
  12. #!perl
  13. use strict;
  14. use lib $ENV{RAZZLETOOLPATH} . "\\PostBuildScripts";
  15. use lib $ENV{RAZZLETOOLPATH};
  16. use PbuildEnv;
  17. use ParseArgs;
  18. sub Usage { print<<USAGE; exit(1) }
  19. makeupgadvimg [-l <language>]
  20. Create the upgrade advisor directory.
  21. USAGE
  22. parseargs('?' => \&Usage);
  23. # *** NEXT FEW LINES ARE TEMPLATE ***
  24. $ENV{"_CPCMAGIC"}++;exit(system($0)>>8);
  25. __END__
  26. :CPCBegin
  27. set _CPCMAGIC=
  28. setlocal ENABLEDELAYEDEXPANSION ENABLEEXTENSIONS
  29. REM
  30. REM *** BEGIN YOUR CMD SCRIPT BELOW ***
  31. REM
  32. @echo off
  33. REM
  34. REM Set local variable's state
  35. REM
  36. set UPGADVBUILDERROR=0
  37. REM
  38. REM We only create upgadv images on x86fre builds
  39. REM
  40. if /i NOT "%_BuildArch%" == "x86" (
  41. goto :upgadv_done
  42. )
  43. if /i NOT "%_BuildType%" == "fre" (
  44. goto :upgadv_done
  45. )
  46. echo.
  47. echo ---------------------------------------
  48. echo Beginning UpgAdv image generation
  49. echo ---------------------------------------
  50. echo.
  51. REM
  52. REM Go ahead and create the UpgAdv image
  53. REM
  54. call logmsg.cmd /t "Creating the UpgAdv image..."
  55. SET UPGADV_TARGET=%_NTPOSTBLD%\upgadv
  56. call ExecuteCmd.cmd "if not exist %UPGADV_TARGET%\i386\system32 md %UPGADV_TARGET%\i386\system32"
  57. call ExecuteCmd.cmd "xcopy /R /Q /C /D /Y %_NTPostBld%\pro\i386\winnt32.exe %UPGADV_TARGET%\i386"
  58. call ExecuteCmd.cmd "xcopy /R /Q /C /D /Y %_NTPostBld%\pro\i386\winnt32.hlp %UPGADV_TARGET%\i386"
  59. call ExecuteCmd.cmd "xcopy /R /Q /C /D /Y %_NTPostBld%\pro\i386\winnt32a.dll %UPGADV_TARGET%\i386"
  60. call ExecuteCmd.cmd "xcopy /R /Q /C /D /Y %_NTPostBld%\pro\i386\winnt32u.dll %UPGADV_TARGET%\i386"
  61. call ExecuteCmd.cmd "xcopy /R /Q /C /D /Y %_NTPostBld%\pro\i386\pidgen.dll %UPGADV_TARGET%\i386"
  62. call ExecuteCmd.cmd "xcopy /R /Q /C /D /Y %_NTPostBld%\pro\i386\winntbba.dll %UPGADV_TARGET%\i386"
  63. call ExecuteCmd.cmd "xcopy /R /Q /C /D /Y %_NTPostBld%\pro\i386\winntbbu.dll %UPGADV_TARGET%\i386"
  64. call ExecuteCmd.cmd "xcopy /R /Q /C /D /Y %_NTPostBld%\pro\i386\hwdb.dll %UPGADV_TARGET%\i386"
  65. call ExecuteCmd.cmd "xcopy /R /Q /C /D /Y %_NTPostBld%\pro\i386\wsdu.dll %UPGADV_TARGET%\i386"
  66. call ExecuteCmd.cmd "xcopy /R /Q /C /D /Y %_NTPostBld%\pro\i386\wsdueng.dll %UPGADV_TARGET%\i386"
  67. call ExecuteCmd.cmd "xcopy /R /Q /C /D /Y %_NTPostBld%\pro\i386\hwcomp.dat %UPGADV_TARGET%\i386"
  68. call ExecuteCmd.cmd "xcopy /R /Q /C /D /Y %_NTPostBld%\pro\i386\txtsetup.sif %UPGADV_TARGET%\i386"
  69. call ExecuteCmd.cmd "xcopy /R /Q /C /D /Y %_NTPostBld%\pro\i386\dosnet.inf %UPGADV_TARGET%\i386"
  70. call ExecuteCmd.cmd "xcopy /R /Q /C /D /Y %_NTPostBld%\pro\i386\system32 %UPGADV_TARGET%\i386"
  71. call ExecuteCmd.cmd "xcopy /R /Q /C /D /Y %_NTPostBld%\pro\i386\setupp.ini %UPGADV_TARGET%\i386"
  72. call ExecuteCmd.cmd "xcopy /R /Q /C /D /Y %_NTPostBld%\pro\i386\intl.inf %UPGADV_TARGET%\i386"
  73. call ExecuteCmd.cmd "xcopy /R /Q /C /D /Y %_NTPostBld%\pro\i386\eula.txt %UPGADV_TARGET%\i386"
  74. call ExecuteCmd.cmd "xcopy /R /Q /C /D /Y %_NTPostBld%\pro\i386\filelist.da_ %UPGADV_TARGET%\i386"
  75. call ExecuteCmd.cmd "xcopy /R /Q /C /D /Y %_NTPostBld%\pro\i386\migisol.ex_ %UPGADV_TARGET%\i386"
  76. call ExecuteCmd.cmd "xcopy /R /Q /C /D /Y %_NTPostBld%\pro\i386\wkstamig.in_ %UPGADV_TARGET%\i386"
  77. call ExecuteCmd.cmd "xcopy /R /Q /C /D /Y %_NTPostBld%\pro\i386\drvindex.inf %UPGADV_TARGET%\i386"
  78. call ExecuteCmd.cmd "xcopy /R /Q /C /D /Y %_NTPostBld%\pro\i386\keyboard.in_ %UPGADV_TARGET%\i386"
  79. call ExecuteCmd.cmd "xcopy /R /Q /C /D /Y %_NTPostBld%\pro\i386\hivesft.inf %UPGADV_TARGET%\i386"
  80. call ExecuteCmd.cmd "xcopy /R /Q /C /D /Y %_NTPostBld%\pro\i386\ntdll.dll %UPGADV_TARGET%\i386\system32"
  81. call ExecuteCmd.cmd "xcopy /R /Q /C /E /I /D /Y %_NTPostBld%\pro\i386\win9xmig %UPGADV_TARGET%\i386\win9xmig"
  82. call ExecuteCmd.cmd "xcopy /R /Q /C /E /I /D /Y %_NTPostBld%\pro\i386\drw %UPGADV_TARGET%\i386\drw"
  83. call ExecuteCmd.cmd "xcopy /R /Q /C /E /I /D /Y %_NTPostBld%\pro\i386\compdata %UPGADV_TARGET%\i386\compdata"
  84. call ExecuteCmd.cmd "xcopy /R /Q /C /E /I /D /Y %_NTPostBld%\pro\i386\win9xupg %UPGADV_TARGET%\i386\win9xupg"
  85. call ExecuteCmd.cmd "xcopy /R /Q /C /E /I /D /Y %_NTPostBld%\pro\i386\winntupg %UPGADV_TARGET%\i386\winntupg"
  86. :upgadv_error
  87. set UPGADVBUILDERROR=%errorlevel%
  88. call logmsg.cmd /t "Done with UpgAdv image generation"
  89. echo.
  90. echo ---------------------------------------
  91. echo Done with UpgAdv image generation
  92. echo ---------------------------------------
  93. echo.
  94. :upgadv_done
  95. seterror.exe "%UPGADVBUILDERROR%"