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.

79 lines
2.1 KiB

  1. @echo off
  2. REM ------------------------------------------------------------------
  3. REM
  4. REM inetsrv.cmd
  5. REM calls makecab.cmd from \binaries\inetsrv, which will compdir
  6. REM files to the appropriate places after they have been built.
  7. REM For IIS setup to work.
  8. REM
  9. REM Copyright (c) Microsoft Corporation. All rights reserved.
  10. REM
  11. REM ------------------------------------------------------------------
  12. if defined _CPCMAGIC goto CPCBegin
  13. perl -x "%~f0" %*
  14. goto :EOF
  15. #!perl
  16. use strict;
  17. use lib $ENV{RAZZLETOOLPATH} . "\\PostBuildScripts";
  18. use lib $ENV{RAZZLETOOLPATH};
  19. use PbuildEnv;
  20. use ParseArgs;
  21. sub Usage { print<<USAGE; exit(1) }
  22. inetsrv [-l <language>]
  23. Calls _NTPOSTBLD\inetsrv\makecab.cmd which will copy files into place
  24. for IIS setup to work.
  25. USAGE
  26. parseargs('?' => \&Usage);
  27. # *** NEXT FEW LINES ARE TEMPLATE ***
  28. $ENV{"_CPCMAGIC"}++;exit(system($0)>>8);
  29. __END__
  30. :CPCBegin
  31. set _CPCMAGIC=
  32. setlocal ENABLEDELAYEDEXPANSION ENABLEEXTENSIONS
  33. REM *** BEGIN YOUR CMD SCRIPT BELOW ***
  34. REM clean out iis cab file to be regenerated on full build
  35. if exist %_NTPOSTBLD%\build_logs\FullPass.txt (
  36. call ExecuteCmd.cmd "if exist %_NTPostBld%\iis6.cab del %_NTPostBld%\iis6.cab /s/q"
  37. )
  38. REM clean out iis cab file to be regenerated on intl builds
  39. if /i "%lang%" NEQ "usa" (
  40. call ExecuteCmd.cmd "if exist %_NTPostBld%\iis6.cab del %_NTPostBld%\iis6.cab /s/q"
  41. )
  42. if NOT exist %_NTPostBld%\inetsrv\dump (
  43. call logmsg.cmd "!!Warning - no %_NTPostBld%\inetsrv\dump dir!!"
  44. goto End
  45. )
  46. pushd %_NTPostBld%\inetsrv\dump
  47. call makecab.cmd
  48. set ERRORLEVEL=
  49. popd
  50. :CreateCat
  51. REM Create a catalog file for inetsrv
  52. call logmsg.cmd "Creating nt5iis.CAT ..."
  53. pushd %RazzleToolPath%
  54. call createcat -f:%_NTPostBld%\inetsrv\dump\nt5iis.lst -c:nt5iis -t:%_NTPostBld%\inetsrv\dump -o:%_NTPOSTBLD%
  55. popd
  56. REM Now, theat the cab and the cat are generated, you can delete imshare.
  57. if exist %_NTPostBld%\inetsrv\help\ismshare (
  58. rd /s /q %_NTPostBld%\inetsrv\help\ismshare
  59. )
  60. if errorlevel 1 (
  61. call errmsg.cmd "rd /s /q %_NTPostBld%\inetsrv\help\ismshare failed"
  62. goto end
  63. )
  64. goto end
  65. :end
  66. seterror.exe "%errors%"& goto :EOF