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.

80 lines
1.8 KiB

  1. @REM -----------------------------------------------------------------
  2. @REM
  3. @REM msi.cmd - msidev
  4. @REM builds InstMsi.exe
  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. msi [-l <language>]
  20. build InstMsi.exe
  21. USAGE
  22. parseargs('?' => \&Usage);
  23. # *** TEMPLATE CODE ***
  24. $ENV{"_CPCMAGIC"}++;exit(system($0)>>8);
  25. __END__
  26. @:CPCBegin
  27. @set _CPCMAGIC=
  28. @setlocal ENABLEDELAYEDEXPANSION ENABLEEXTENSIONS
  29. @if not defined DEBUG echo off
  30. @REM *** 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 %_NTPOSTBLD%\instmsi\msitools
  63. call ExecuteCmd.cmd "nmake %NMAKE_FLAGS% /f sdkpost.mak"
  64. if errorlevel 1 (
  65. call errmsg.cmd "Cannot build MSI Tool Packages"
  66. popd & goto :EOF
  67. )
  68. popd