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.

95 lines
2.0 KiB

  1. @echo off
  2. REM ------------------------------------------------------------------
  3. REM
  4. REM msi.cmd
  5. REM builds InstMsi.exe
  6. REM
  7. REM Copyright (c) Microsoft Corporation. All rights reserved.
  8. REM
  9. REM ------------------------------------------------------------------
  10. if defined _CPCMAGIC goto CPCBegin
  11. perl -x "%~f0" %*
  12. goto :EOF
  13. #!perl
  14. use strict;
  15. use lib $ENV{RAZZLETOOLPATH} . "\\PostBuildScripts";
  16. use lib $ENV{RAZZLETOOLPATH};
  17. use PbuildEnv;
  18. use ParseArgs;
  19. sub Usage { print<<USAGE; exit(1) }
  20. msi [-l <language>]
  21. build InstMsi.exe
  22. USAGE
  23. parseargs('?' => \&Usage);
  24. # *** NEXT FEW LINES ARE TEMPLATE ***
  25. $ENV{"_CPCMAGIC"}++;exit(system($0)>>8);
  26. __END__
  27. :CPCBegin
  28. set _CPCMAGIC=
  29. setlocal ENABLEDELAYEDEXPANSION ENABLEEXTENSIONS
  30. REM *** BEGIN YOUR CMD SCRIPT BELOW ***
  31. REM
  32. REM Allow for full pass post-build. Necessary for things like pseudo-localization
  33. REM
  34. set NMAKE_FLAGS=/NOLOGO
  35. if exist %_NTPOSTBLD%\build_logs\FullPass.txt (
  36. set NMAKE_FLAGS=%NMAKE_FLAGS% /a
  37. )
  38. REM
  39. REM Build Validation CUB files
  40. REM
  41. pushd %_NTPOSTBLD%\instmsi\cub
  42. call ExecuteCmd.cmd "nmake %NMAKE_FLAGS% /f icecub.mak "
  43. if errorlevel 1 (
  44. call errmsg.cmd "Cannot build MSI Validation CUB files"
  45. popd & goto :EOF
  46. )
  47. popd
  48. REM
  49. REM Build MSI Tool packages
  50. REM
  51. pushd %_NTPOSTBLD%\instmsi\msitools
  52. call ExecuteCmd.cmd "nmake %NMAKE_FLAGS% /f msitool.mak"
  53. if errorlevel 1 (
  54. call errmsg.cmd "Cannot build MSI Tool Packages"
  55. popd & goto :EOF
  56. )
  57. popd
  58. REM Instmsi.exe and the SDK are built only for i386.
  59. if /I NOT "%_BuildArch%"=="x86" (
  60. goto :EOF
  61. )
  62. pushd .
  63. for %%i in (Unicode Ansi) do (
  64. cd /d %_NTPOSTBLD%\instmsi\%%i
  65. call ExecuteCmd.cmd "nmake %NMAKE_FLAGS% /f instmsi.mak"
  66. if errorlevel 1 (
  67. call errmsg.cmd "Cannot build %%i InstMsi.exe"
  68. popd & goto :EOF
  69. )
  70. )
  71. popd
  72. pushd %_NTPOSTBLD%\instmsi\msitools
  73. call ExecuteCmd.cmd "nmake %NMAKE_FLAGS% /f sdkpost.mak"
  74. if errorlevel 1 (
  75. call errmsg.cmd "Cannot build MSI Tool Packages"
  76. popd & goto :EOF
  77. )
  78. popd