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.

155 lines
8.5 KiB

  1. @echo off
  2. rem nt_build.cmd
  3. rem Automated build script for SAPI
  4. echo Running automated SAPI build...
  5. set ORIGINAL_PATH=%PATH%
  6. set SPEECHPATH=c:\nt\enduser\Speech
  7. set SAPI_BUILD_PATH=c:\builds
  8. set RAZZLEPATH=%SPEECHPATH%\common\bin\spgrazzle.cmd
  9. set LOCSTUDIOPATH=%PROGRAMFILES%\LocStudio
  10. set SDNBUILD=%2%
  11. if exist %RAZZLEPATH% goto FoundRazzle
  12. echo Can't find %RAZZLEPATH% ...
  13. echo Fatal error - script dying ...
  14. goto End
  15. :FoundRazzle
  16. if "%2%" == "" goto UsageError
  17. if "%1%" == "" goto UsageError
  18. rem Get build number
  19. echo Generating build number...
  20. cd %SPEECHPATH%
  21. attrib -r %SPEECHPATH%\setup\installer\currver.inc
  22. cscript %SPEECHPATH%\builder\makebldnum.%SDNBUILD%.vbs
  23. set SAPI_BUILD_NUM=%errorlevel%
  24. if "%SDNBUILD%" == "sapi5.01" goto Build501
  25. if "%SDNBUILD%" == "sapi5.10" goto Build510
  26. rem Default to 6.0.xxxx.0 for unknown builds.
  27. set MAJOR=6
  28. set MINOR=0
  29. goto GotMajorMinor
  30. :Build501
  31. set MAJOR=5
  32. set MINOR=0
  33. goto GotMajorMinor
  34. :Build510
  35. set MAJOR=5
  36. set MINOR=1
  37. goto GotMajorMinor
  38. :GotMajorMinor
  39. goto setup
  40. :UsageError
  41. echo.
  42. echo Usage : nt_build [section] [branch]
  43. echo.
  44. echo section = Anything
  45. echo branch = sapi5.01, sapi5.10, sapi6.0
  46. goto End
  47. :setup
  48. REM Build MSMs Here
  49. cd %SPEECHPATH%\builder
  50. set SAPIROOT=%SPEECHPATH%
  51. call makemsm debug
  52. cd %SPEECHPATH%\builder
  53. call makemsm release
  54. :cleanmsm
  55. REM Clean the MSMs
  56. cd %SPEECHPATH%\builder
  57. call cleanmsm
  58. :msmver
  59. REM Set version number in MSMs
  60. echo on
  61. cd %SPEECHPATH%\build
  62. for /f %%f in ('dir /b /s /a-d *.msm') do %SPEECHPATH%\tools\msiquery "UPDATE ModuleSignature SET Version='%MAJOR%.%MINOR%.%SAPI_BUILD_NUM%.0'" %%f
  63. :msi
  64. REM Build MSIs Here
  65. cd %SPEECHPATH%\builder
  66. call makemsi debug
  67. cd %SPEECHPATH%\builder
  68. call makemsi release
  69. :msiver
  70. REM Set version number in MSIs
  71. cd %SPEECHPATH%\setup
  72. %SPEECHPATH%\tools\msiquery "UPDATE Property SET Value='%MAJOR%.%MINOR%.%SAPI_BUILD_NUM%.0' WHERE Property='ProductVersion'" "%SPEECHPATH%\setup\installer\debug\sdk\Output\Build\DiskImages\Disk1\Microsoft Speech SDK 5.1d.msi"
  73. %SPEECHPATH%\tools\msiquery "UPDATE Property SET Value='%MAJOR%.%MINOR%.%SAPI_BUILD_NUM%.0' WHERE Property='ProductVersion'" "%SPEECHPATH%\setup\installer\release\sdk\Output\Build\DiskImages\Disk1\Microsoft Speech SDK 5.1.msi"
  74. :copies
  75. REM Copy MSMs
  76. xcopy %SPEECHPATH%\build\debug\1033\sp5\Sp5-1033\DiskImages\Disk1\Sp5d.Msm %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\debug\msm\1033\ /F /C /Y
  77. xcopy %SPEECHPATH%\build\debug\1033\sp5ccint\Sp5ccint-1033\DiskImages\Disk1\Sp5CCIntd.Msm %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\debug\msm\1033\ /F /C /Y
  78. xcopy %SPEECHPATH%\build\debug\1033\sp5dcint\Sp5dcint-1033\DiskImages\Disk1\Sp5DCIntd.Msm %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\debug\msm\1033\ /F /C /Y
  79. xcopy %SPEECHPATH%\build\debug\1033\sp5intl\Sp5intl-1033\DiskImages\Disk1\Sp5Intld.Msm %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\debug\msm\1033\ /F /C /Y
  80. xcopy %SPEECHPATH%\build\debug\1033\sp5itn\Sp5itn-1033\DiskImages\Disk1\Sp5itnd.Msm %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\debug\msm\1033\ /F /C /Y
  81. xcopy %SPEECHPATH%\build\debug\1033\sp5sr\Sp5sr\DiskImages\Disk1\Sp5SRd.Msm %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\debug\msm\1033\ /F /C /Y
  82. xcopy %SPEECHPATH%\build\debug\1033\sp5ttint\Sp5TTInt\DiskImages\Disk1\Sp5TTIntd.Msm %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\debug\msm\1033\ /F /C /Y
  83. xcopy %SPEECHPATH%\build\debug\1033\spcommon\spcommon-1033\DiskImages\Disk1\Spcommond.Msm %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\debug\msm\1033\ /F /C /Y
  84. xcopy %SPEECHPATH%\build\debug\1041\sp5ccint\Sp5ccint-1041\DiskImages\Disk1\Sp5CCIntd.Msm %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\debug\msm\1041\ /F /C /Y
  85. xcopy %SPEECHPATH%\build\debug\1041\sp5dcint\Sp5dcint-1041\DiskImages\Disk1\Sp5DCIntd.Msm %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\debug\msm\1041\ /F /C /Y
  86. xcopy %SPEECHPATH%\build\debug\1041\sp5intl\Sp5intl-1041\DiskImages\Disk1\Sp5Intld.Msm %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\debug\msm\1041\ /F /C /Y
  87. xcopy %SPEECHPATH%\build\debug\1041\sp5itn\Sp5itn-1041\DiskImages\Disk1\Sp5Itnd.Msm %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\debug\msm\1041\ /F /C /Y
  88. xcopy %SPEECHPATH%\build\debug\2052\sp5ccint\Sp5ccint-2052\DiskImages\Disk1\Sp5CCIntd.Msm %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\debug\msm\2052\ /F /C /Y
  89. xcopy %SPEECHPATH%\build\debug\2052\sp5dcint\Sp5dcint-2052\DiskImages\Disk1\Sp5DCIntd.Msm %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\debug\msm\2052\ /F /C /Y
  90. xcopy %SPEECHPATH%\build\debug\2052\sp5intl\Sp5intl-2052\DiskImages\Disk1\Sp5Intld.Msm %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\debug\msm\2052\ /F /C /Y
  91. xcopy %SPEECHPATH%\build\debug\2052\sp5itn\Sp5itn-2052\DiskImages\Disk1\Sp5itnd.Msm %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\debug\msm\2052\ /F /C /Y
  92. xcopy %SPEECHPATH%\build\debug\2052\sp5ttint\Sp5ttint-2052\DiskImages\Disk1\SP5TTINTd.Msm %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\debug\msm\2052\ /F /C /Y
  93. xcopy %SPEECHPATH%\build\release\1033\sp5\Sp5-1033\DiskImages\Disk1\Sp5.Msm %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\release\msm\1033\ /F /C /Y
  94. xcopy %SPEECHPATH%\build\release\1033\sp5ccint\Sp5ccint-1033\DiskImages\Disk1\Sp5CCInt.Msm %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\release\msm\1033\ /F /C /Y
  95. xcopy %SPEECHPATH%\build\release\1033\sp5dcint\Sp5dcint-1033\DiskImages\Disk1\Sp5DCInt.Msm %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\release\msm\1033\ /F /C /Y
  96. xcopy %SPEECHPATH%\build\release\1033\sp5intl\Sp5intl-1033\DiskImages\Disk1\Sp5Intl.Msm %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\release\msm\1033\ /F /C /Y
  97. xcopy %SPEECHPATH%\build\release\1033\sp5itn\Sp5itn-1033\DiskImages\Disk1\Sp5itn.Msm %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\release\msm\1033\ /F /C /Y
  98. xcopy %SPEECHPATH%\build\release\1033\sp5sr\Sp5sr\DiskImages\Disk1\Sp5SR.Msm %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\release\msm\1033\ /F /C /Y
  99. xcopy %SPEECHPATH%\build\release\1033\sp5ttint\Sp5TTInt\DiskImages\Disk1\Sp5TTInt.Msm %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\release\msm\1033\ /F /C /Y
  100. xcopy %SPEECHPATH%\build\release\1033\spcommon\spcommon-1033\DiskImages\Disk1\Spcommon.Msm %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\release\msm\1033\ /F /C /Y
  101. xcopy %SPEECHPATH%\build\release\1041\sp5ccint\Sp5ccint-1041\DiskImages\Disk1\Sp5CCInt.Msm %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\release\msm\1041\ /F /C /Y
  102. xcopy %SPEECHPATH%\build\release\1041\sp5dcint\Sp5dcint-1041\DiskImages\Disk1\Sp5DCInt.Msm %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\release\msm\1041\ /F /C /Y
  103. xcopy %SPEECHPATH%\build\release\1041\sp5intl\Sp5intl-1041\DiskImages\Disk1\Sp5Intl.Msm %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\release\msm\1041\ /F /C /Y
  104. xcopy %SPEECHPATH%\build\release\1041\sp5itn\Sp5itn-1041\DiskImages\Disk1\Sp5Itn.Msm %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\release\msm\1041\ /F /C /Y
  105. xcopy %SPEECHPATH%\build\release\2052\sp5ccint\Sp5ccint-2052\DiskImages\Disk1\Sp5CCInt.Msm %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\release\msm\2052\ /F /C /Y
  106. xcopy %SPEECHPATH%\build\release\2052\sp5dcint\Sp5dcint-2052\DiskImages\Disk1\Sp5DCInt.Msm %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\release\msm\2052\ /F /C /Y
  107. xcopy %SPEECHPATH%\build\release\2052\sp5intl\Sp5intl-2052\DiskImages\Disk1\Sp5Intl.Msm %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\release\msm\2052\ /F /C /Y
  108. xcopy %SPEECHPATH%\build\release\2052\sp5itn\Sp5itn-2052\DiskImages\Disk1\Sp5itn.Msm %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\release\msm\2052\ /F /C /Y
  109. xcopy %SPEECHPATH%\build\release\2052\sp5ttintr\Sp5TTInt-2052\DiskImages\Disk1\SP5TTINTr.Msm %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\release\msm\2052\ /F /C /Y
  110. REM Copy L&H MSMs
  111. xcopy %SPEECHPATH%\setup\installer\lh\1033\lhttint.msm %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\debug\msm\LH_1033\ /F /C /Y
  112. xcopy %SPEECHPATH%\setup\installer\lh\1033\lhttint.msm %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\release\msm\LH_1033\ /F /C /Y
  113. xcopy %SPEECHPATH%\setup\installer\lh\1041\lhttint.msm %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\debug\msm\LH_1041\ /F /C /Y
  114. xcopy %SPEECHPATH%\setup\installer\lh\1041\lhttint.msm %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\release\msm\LH_1041\ /F /C /Y
  115. xcopy %SPEECHPATH%\setup\installer\lh\shared\LHTTS3000Shared.msm %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\debug\msm\LH_shared\ /F /C /Y
  116. xcopy %SPEECHPATH%\setup\installer\lh\shared\LHTTS3000Shared.msm %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\release\msm\LH_shared\ /F /C /Y
  117. REM Copy MSIs
  118. xcopy %SPEECHPATH%\setup\installer\debug\sdk\Output\Build\DiskImages\Disk1 %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\debug\msi /F /I /C /S /Y
  119. xcopy %SPEECHPATH%\setup\installer\release\sdk\Output\Build\DiskImages\Disk1 %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\release\msi /F /I /C /S /Y
  120. REM Copy MSM/MSI logs
  121. xcopy %SPEECHPATH%\builder\logs\*.* %SAPI_BUILD_PATH%\%SAPI_BUILD_NUM%\logs.msmmsi\ /F /I /C /S /Y
  122. :End
  123. echo.
  124. echo Script End!