home *** CD-ROM | disk | FTP | other *** search
/ Liren Large Software Subsidy 9 / 09.iso / d / d423_liu / 8.ddi / OEMNSVRP.IN_ / OEMNSVRP.IN
Encoding:
INI File  |  1993-07-24  |  25.5 KB  |  659 lines

  1. [Identification]
  2.     OptionType = NetService
  3. [Options]
  4.     RPCLOCATE
  5. [FileConstants]
  6. UtilityInf      = "UTILITY.INF"
  7. subroutineinf   = "SUBROUTN.INF"
  8. SoftwareType    = "service"
  9. Exit_Code       = 0
  10. [GeneralConstants]
  11. from      = ""
  12. to        = ""
  13. ExitCodeOk     = 0
  14. ExitCodeCancel = 1
  15. ExitCodeFatal  = 2
  16. KeyNull         = ""
  17. MAXIMUM_ALLOWED   = 33554432
  18. RegistryErrorIndex = NO_ERROR
  19. KeyProduct      = ""
  20. KeyParameters   = ""
  21. TRUE            = 1
  22. FALSE           = 0
  23. NoTitle            = 0
  24. ExitState   = "Active"
  25. OldVersionExisted = $(FALSE)
  26. Manufacturer    = "Microsoft"
  27. ProductMajorVersion     = "3"
  28. ProductMinorVersion     = "1"
  29. ProductVersion  = $(ProductMajorVersion)"."$(ProductMinorVersion)
  30. RpcSoftKeyName    = "SOFTWARE\Microsoft\Rpc"
  31. RpcSrvKeyName     = "Software\Microsoft\RPCLOCATOR"
  32. RpcSrvNameRpcss   = "RPCSS"
  33. RpcSrvNameLocator = "RPCLOCATOR"
  34. RpcSrvExeRpcss    = "%SystemRoot%\System32\RPCSS.EXE"
  35. RpcSrvExeLocator  = "%SystemRoot%\System32\LOCATOR.EXE"
  36. LocatorChoiceList   = ^(LocatorData,1)
  37. LocatorEndPointList = ^(LocatorData,2)
  38. LocatorProtocolList = ^(LocatorData,3)
  39. NameServiceKeyName  = "Software\Microsoft\Rpc\NameService"
  40. [LocatorData]
  41. LD_1 = "LocatorWINNT","\pipe\locator","ncacn_np"
  42. LD_2 = "LocatorDCE","","ncacn_ip_tcp"
  43. [date]
  44.     Now = {} ? $(!LIBHANDLE) GetSystemDate
  45. [Identify]
  46.     read-syms Identification
  47.     set Status     = STATUS_SUCCESSFUL
  48.     set Identifier = $(OptionType)
  49.     set Media      = #("Source Media Descriptions", 1, 1)
  50.     Return $(Status) $(Identifier) $(Media)
  51. [ReturnOptions]
  52.     set Status        = STATUS_FAILED
  53.     set OptionList     = {}
  54.     set OptionTextList = {}
  55.     set LanguageList = ^(LanguagesSupported, 1)
  56.     Ifcontains(i) $($0) in $(LanguageList)
  57.         goto returnoptions
  58.     else
  59.         set Status = STATUS_NOLANGUAGE
  60.         goto finish_ReturnOptions
  61.     endif
  62. returnoptions = +
  63.     set OptionList     = ^(Options, 1)
  64.     set OptionTextList = ^(OptionsText$($0), 1)
  65.     set Status         = STATUS_SUCCESSFUL
  66. finish_ReturnOptions = +
  67.     Return $(Status) $(OptionList) $(OptionTextList)
  68. [InstallOption]
  69.     set Option   = $($1)
  70.     set SrcDir   = $($2)
  71.     set AddCopy  = $($3)
  72.     set DoCopy   = $($4)
  73.     set DoConfig = $($5)
  74.     set LanguageList = ^(LanguagesSupported, 1)
  75.     Ifcontains(i) $($0) NOT-IN $(LanguageList)
  76.         Return STATUS_NOLANGUAGE
  77.     endif
  78.     set-subst LF = "\n"
  79.     Debug-Output "OEMNSVRP.INF: active"
  80.     read-syms GeneralConstants
  81.     read-syms FileConstants
  82.     detect date
  83.     read-syms DialogConstants$(!STF_LANGUAGE)
  84.     read-syms FileConstants$(!STF_LANGUAGE)
  85.     set-title  $(FunctionTitle)
  86.     set to   = Begin
  87.     set from = Begin
  88.     set CommonStatus = STATUS_SUCCESSFUL
  89.     EndWait
  90. Begin = +
  91.     Ifstr(i) $(!NTN_InstallMode) == deinstall
  92.         set StartLabel = removeadapter
  93.     else-Ifstr(i) $(!NTN_InstallMode) == update
  94.         set StartLabel = UpgradeSoftware
  95.     else-Ifstr(i) $(!NTN_InstallMode) == bind
  96.         set StartLabel = bindingadapter
  97.     else-Ifstr(i) $(!NTN_InstallMode) == configure
  98.         set StartLabel = configureadapter
  99.     else
  100.         set StartLabel = installadapter
  101.     endif
  102.     set from = $(fatal)
  103.     set to = $(fatal)
  104.     goto $(StartLabel)
  105. configureadapter = +
  106.     OpenRegKey $(!REG_H_LOCAL) "" $(NameServiceKeyName) $(MAXIMUM_ALLOWED) KeyNameService
  107.     Ifstr(i) $(KeyNameService) == ""
  108.         Set RegistryErrorIndex = UNABLE_ACCESS_SOFTWARE_REG
  109.         Goto fatalregistry
  110.     Endif
  111.     Set OldVersionExisted = $(TRUE)
  112.     GetRegValue $(KeyNameService),"Protocol", ProtocolNameValue
  113.     Ifint $(RegLastError) != $(!REG_ERROR_SUCCESS)
  114.         CloseRegKey $(KeyNameService)
  115.         Set RegistryErrorIndex = UNABLE_ACCESS_SOFTWARE_REG
  116.         Goto fatalregistry
  117.     Endif
  118.     Debug-Output "OEMNSVRP.INF: Configure Name Services"
  119. configureretry = +
  120.     read-syms LocatorNames$(!STF_LANGUAGE)
  121.     Set LocatorListboxNames = {$(LocName1),$(LocName2)}
  122.     Set ProtocolName = *($(ProtocolNameValue),4)
  123.     Set LocatorIndex = ~($(LocatorProtocolList),$(ProtocolName))
  124.     Set LocatorInUse = *($(LocatorChoiceList),$(LocatorIndex))
  125.     Set LocatorChosen = $(LocatorInUse)
  126.     Set LocatorChosenName = *($(LocatorListboxNames),$(LocatorIndex))
  127.     GetRegValue $(KeyNameService),"NetworkAddress", NetAddrValue
  128.     Set NetworkAddress = *($(NetAddrValue),4)
  129.     Set NetworkAddressInUse = $(NetworkAddress)
  130.     Ifstr(i) $(LocatorChosen) == "LocatorWINNT"
  131.         Set NetworkAddressDCE = ""
  132.     Else
  133.         Set NetworkAddressDCE = $(NetworkAddress)
  134.     Endif
  135. reinitdialog = +
  136.     Set LocatorLastChosen = $(LocatorChosen)
  137.     Ifstr(i) $(LocatorChosen) == "LocatorWINNT"
  138.         Set NetworkAddress = ""
  139.     Else
  140.         Set NetworkAddress = $(NetworkAddressDCE)
  141.     Endif
  142.     read-syms RpcProviderDlg$(!STF_LANGUAGE)
  143.     ui start "System"
  144.     Ifstr(i) $(DLGEVENT) == "NOTIFY"
  145.         Set LocatorIndex  = ~($(LocatorListboxNames),$(Combo1Out))
  146.         Set LocatorChosen = *($(LocatorChoiceList),$(LocatorIndex))
  147.         Set LocatorChosenName = *($(LocatorListboxNames),$(LocatorIndex))
  148.         Debug-Output "OEMNSVRP.INF: NOTIFY: "$(LocatorChosenName)" = "$(LocatorChosen)
  149.         Set ReInit = YES
  150.         Ifstr(i) $(LocatorChosen) == $(LocatorLastChosen)
  151.             Goto reinitdialog
  152.         Endif
  153.         Ifstr(i) $(LocatorChosen) == "LocatorWINNT"
  154.             Set NetworkAddress = ""
  155.             Set NetworkAddressDCE = $(EditTextOut)
  156.         Endif
  157.         Goto reinitdialog
  158.     Else-Ifstr(i) $(DLGEVENT) != "CONTINUE"
  159.         ui pop 1
  160.         Set CommonStatus = STATUS_USERCANCEL
  161.         Goto configuredone
  162.     Endif
  163.     Set NetworkAddress = $(EditTextOut)
  164.     Set LocatorIndex  = ~($(LocatorListboxNames),$(Combo1Out))
  165.     Set LocatorChosen = *($(LocatorChoiceList),$(LocatorIndex))
  166.     Debug-Output "OEMNSVRP.INF: OK: "$(LocatorChosenName)", "$(LocatorChosen)
  167.     Ifstr(i) $(LocatorChosen) == "LocatorWINNT"
  168.         Ifstr(i) $(NetworkAddress) != ""
  169.             read-syms NonFatalError2$(!STF_LANGUAGE)
  170.             shell "subroutn.inf" SetupMessage $(!STF_LANGUAGE) "NONFATAL" $(NonFatal)
  171.         Endif
  172.         Set NetworkAddress = "\\."
  173.     Else-ifstr(i) $(NetworkAddress) == ""
  174.         read-syms NonFatalError1$(!STF_LANGUAGE)
  175.         shell "subroutn.inf" SetupMessage $(!STF_LANGUAGE) "NONFATAL" $(NonFatal)
  176.         Goto configureretry
  177.     Endif
  178.     Ifstr(i) $(LocatorChosen) == $(LocatorInUse)
  179.         Ifstr(i) $(NetworkAddress) == $(NetworkAddressInUse)
  180.             ui pop 1
  181.             Set CommonStatus = STATUS_USERCANCEL
  182.             Goto configuredone
  183.         Endif
  184.     Endif
  185.     ui pop 1
  186.     Set ProtocolName = *($(LocatorProtocolList),$(LocatorIndex))
  187.     Set EndPointName = *($(LocatorEndPointList),$(LocatorIndex))
  188.     Set NewValueList = {{Protocol,$(NoTitle),$(!REG_VT_SZ),$(ProtocolName)},+
  189.                         {NetworkAddress,$(NoTitle),$(!REG_VT_SZ),$(NetworkAddress)},+
  190.                         {ServerNetworkAddress,$(NoTitle),$(!REG_VT_SZ),$(NetworkAddress)},+
  191.                         {Endpoint,$(NoTitle),$(!REG_VT_SZ),$(EndPointName)}}
  192.     Shell  $(UtilityInf), AddValueList, $(KeyNameService), $(NewValueList)
  193.     Ifint $($ShellCode) != $(!SHELL_CODE_OK)
  194.         Debug-Output "OEMNSVRP.INF: ShellCode error."
  195.         Goto ShellCodeError
  196.     Endif
  197.     set RegistryErrorIndex = $($R0)
  198.     Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  199.        Debug-Output "OEMNSVRP.INF: registry error: add value list."
  200.        Goto fatalregistry
  201.     Endif
  202. configuredone = +
  203.     CloseRegKey $(KeyNameService)
  204.     Goto successful
  205. installadapter = +
  206.     OpenRegKey $(!REG_H_LOCAL) "" $(RpcSrvKeyName) $(MAXIMUM_ALLOWED) KeyProduct
  207.     Ifstr $(KeyProduct) != $(KeyNull)
  208.         CloseRegKey $(KeyProduct)
  209.         Shell $(UtilityInf), VerExistedDlg, $(ProductRPCTitle),+
  210.             $(ProductVersion)
  211.         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  212.             Debug-Output "ShellCode error: cannot get an error string."
  213.             goto ShellCodeError
  214.         endif
  215.         set CommonStatus = STATUS_USERCANCEL
  216.         goto end
  217.     endif
  218.     StartWait
  219.     ifstr(i) $(!NTN_InstallMode) == "install"
  220.         Ifstr(i) $(DoCopy) == "YES"
  221.            Shell $(UtilityInf), DoAskSource, $(!STF_CWDDIR), $(SrcDir) YES
  222.            Ifint $($ShellCode) != $(!SHELL_CODE_OK)
  223.                Goto ShellCodeError
  224.            Else-Ifstr(i) $($R0) == STATUS_FAILED
  225.                Shell $(UtilityInf) RegistryErrorString "ASK_SOURCE_FAIL"
  226.                ifint $($ShellCode) != $(!SHELL_CODE_OK)
  227.                    goto ShellCodeError
  228.                endif
  229.                set Error = $($R0)
  230.                Goto fatal
  231.            Else-Ifstr(i) $($R0) == STATUS_USERCANCEL
  232.                Goto successful
  233.            Endif
  234.            Set SrcDir = $($R1)
  235.         Endif
  236.         install "Install-Option"
  237.         ifstr(i) $(STF_INSTALL_OUTCOME) != STF_SUCCESS
  238.            Shell $(UtilityInf) RegistryErrorString "UNABLE_COPY_FILE"
  239.            ifint $($ShellCode) != $(!SHELL_CODE_OK)
  240.                goto ShellCodeError
  241.            endif
  242.            set Error = $($R0)
  243.            goto fatal
  244.         endif
  245.     endif
  246.     set OEM_ABANDON_ON = TRUE
  247.     Set RpcNameServiceKey     = $(KeyNull)
  248.     Set RpcNetBiosKey         = $(KeyNull)
  249.     Set RpcClientProtocolsKey = $(KeyNull)
  250.     Set RpcServerProtocolsKey = $(KeyNull)
  251.     Set RpcKey                = $(KeyNull)
  252.     Set RegErrorOccured = 0
  253.     CreateRegKey $(!REG_H_LOCAL) {"Rpc",$(NoTitle),GenericClass} "" $(MAXIMUM_ALLOWED) "" RpcKey
  254.     Ifstr(i) $(RpcKey) == $(KeyNull)
  255.       Debug-Output "OEMNSVRD.INF: Registry error creating RPC key; assuming it exists"
  256.       Goto createrpcservices
  257.     Endif
  258.     CreateRegKey $(RpcKey) {"NameService",$(NoTitle),GenericClass}     "" $(MAXIMUM_ALLOWED) "" RpcNameServiceKey
  259.     CreateRegKey $(RpcKey) {"NetBios",$(NoTitle),GenericClass}         "" $(MAXIMUM_ALLOWED) "" RpcNetBiosKey
  260.     CreateRegKey $(RpcKey) {"ServerProtocols",$(NoTitle),GenericClass} "" $(MAXIMUM_ALLOWED) "" RpcServerProtocolsKey
  261.     CreateRegKey $(RpcKey) {"ClientProtocols",$(NoTitle),GenericClass} "" $(MAXIMUM_ALLOWED) "" RpcClientProtocolsKey
  262.     Set KeyCount = 0
  263.     Ifstr(i) $(RpcNameServiceKey) != $(KeyNull)
  264.         Set-add KeyCount = $(KeyCount), 1
  265.     Endif
  266.     Ifstr(i) $(RpcNetBiosKey) != $(KeyNull)
  267.         Set-add KeyCount = $(KeyCount), 1
  268.     Endif
  269.     Ifstr(i) $(RpcServerProtocolsKey) != $(KeyNull)
  270.         Set-add KeyCount = $(KeyCount), 1
  271.     Endif
  272.     Ifstr(i) $(RpcClientProtocolsKey) != $(KeyNull)
  273.         Set-add KeyCount = $(KeyCount), 1
  274.     Endif
  275.     Ifint $(KeyCount) != 4
  276.         Debug-Output "OEMNSVRD.INF: Registry error creating subordinate RPC keys"
  277.         Set RegErrorOccured = 1
  278.         Goto createrpcservices
  279.     Endif
  280.     Set NewValueList = {{Protocol,$(NoTitle),$(!REG_VT_SZ),"ncacn_np"},+
  281.                         {NetworkAddress,$(NoTitle),$(!REG_VT_SZ),"\\."},+
  282.                         {ServerNetworkAddress,$(NoTitle),$(!REG_VT_SZ),"\\."},+
  283.                         {Endpoint,$(NoTitle),$(!REG_VT_SZ),"\pipe\locator"},+
  284.                         {DefaultSyntax,$(NoTitle),$(!REG_VT_DWORD),3}}
  285.     Shell  $(UtilityInf), AddValueList, $(RpcNameServiceKey), $(NewValueList)
  286.     Ifint $($ShellCode) != $(!SHELL_CODE_OK)
  287.         Debug-Output "OEMNSVRP.INF: ShellCode error."
  288.         goto ShellCodeError
  289.     Endif
  290.     set RegistryErrorIndex = $($R0)
  291.     Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  292.        EndWait
  293.        Debug-Output "OEMNSVRP.INF: registry error: add value list."
  294.        Set RegErrorOccured = 1
  295.        goto createrpcservices
  296.     Endif
  297.     Set NewValueList = {{ncacn_np,$(NoTitle),$(!REG_VT_SZ),"rpclts1.dll"},+
  298.                         {ncalrpc,$(NoTitle),$(!REG_VT_SZ),"ncalrpc"}}
  299.     Shell  $(UtilityInf), AddValueList, $(RpcServerProtocolsKey), $(NewValueList)
  300.     Ifint $($ShellCode) != $(!SHELL_CODE_OK)
  301.         Debug-Output "OEMNSVRP.INF: ShellCode error."
  302.         goto ShellCodeError
  303.     Endif
  304.     set RegistryErrorIndex = $($R0)
  305.     Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  306.        EndWait
  307.        Debug-Output "OEMNSVRP.INF: registry error: add value list."
  308.        Set RegErrorOccured = 1
  309.        goto createrpcservices
  310.     Endif
  311.     Set NewValueList = {{ncacn_np,$(NoTitle),$(!REG_VT_SZ),"rpcltc1.dll"},+
  312.                         {ncalrpc,$(NoTitle),$(!REG_VT_SZ),"ncalrpc"}}
  313.     Shell  $(UtilityInf), AddValueList, $(RpcClientProtocolsKey), $(NewValueList)
  314.     Ifint $($ShellCode) != $(!SHELL_CODE_OK)
  315.         Debug-Output "OEMNSVRP.INF: ShellCode error."
  316.         goto ShellCodeError
  317.     Endif
  318.     set RegistryErrorIndex = $($R0)
  319.     Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  320.        EndWait
  321.        Debug-Output "OEMNSVRP.INF: registry error: add value list."
  322.        Set RegErrorOccured = 1
  323.        goto createrpcservices
  324.     Endif
  325. createrpcservices =+
  326.     Ifstr(i) $(RpcNameServiceKey) != $(KeyNull)
  327.         CloseRegKey $(RpcNameServiceKey)
  328.     Endif
  329.     Ifstr(i) $(RpcNetBiosKey) != $(KeyNull)
  330.         CloseRegKey $(RpcNetBiosKey)
  331.     Endif
  332.     Ifstr(i) $(RpcClientProtocolsKey) != $(KeyNull)
  333.         CloseRegKey $(RpcClientProtocolsKey)
  334.     Endif
  335.     Ifstr(i) $(RpcServerProtocolsKey) != $(KeyNull)
  336.         CloseRegKey $(RpcServerProtocolsKey)
  337.     Endif
  338.     Ifstr(i) $(RpcKey) != $(KeyNull)
  339.         CloseRegKey $(RpcKey)
  340.     Endif
  341.     Ifint $(RegErrorOccured) != 0
  342.        Goto fatalregistry
  343.     Endif
  344.     Shell $(UtilityInf), AddSoftwareComponent, $(Manufacturer), +
  345.         $(RpcSrvNameLocator), +
  346.         $(RpcSrvNameLocator), +
  347.         $(RpcSrvDisplayNameLocator), $(STF_CONTEXTINFNAME), +
  348.         $(RpcSrvExeLocator), "service", "", {}, "", ""
  349.     set RegistryErrorIndex = $($R0)
  350.     Ifint $($ShellCode) != $(!SHELL_CODE_OK)
  351.         Debug-Output "OEMNSVRP.INF: ShellCode error creating RPCLOCATOR service: "$($ShellCode)
  352.         Goto ShellCodeError
  353.     Endif
  354.     Set SoftProductKey  = $($R1)
  355.     Set SoftNetRuleKey  = $($R2)
  356.     CloseRegKey $($R3)
  357.     Set RpcLocatorParametersKey = $($R4)
  358.     CloseRegKey $($R5)
  359.     Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  360.        EndWait
  361.        Debug-Output "OEMNSVRP.INF: Registry error: creating RPCLOCATE software product"
  362.        CloseRegKey $(SoftProductKey)
  363.        CloseRegKey $(SoftNetRuleKey)
  364.        CloseRegKey $(RpcLocatorParametersKey)
  365.        Goto fatalregistry
  366.     Endif
  367.     Set NewValueList = {{SoftwareType,$(NoTitle),$(!REG_VT_SZ),$(SoftwareType)},+
  368.                        {MajorVersion,$(NoTitle),$(!REG_VT_DWORD),$(ProductMajorVersion)},+
  369.                        {MinorVersion,$(NoTitle),$(!REG_VT_DWORD),$(ProductMinorVersion)},+
  370.                        {Title,$(NoTitle),$(!REG_VT_SZ),$(ProductRPCTitle)},+
  371.                        {Description,$(NoTitle),$(!REG_VT_SZ),$(RpcSrvDisplayNameLocator)},+
  372.                        {InstallDate,$(NoTitle),$(!REG_VT_DWORD),*($(Now),1)}}
  373.     Shell  $(UtilityInf), AddValueList, $(SoftProductKey), $(NewValueList)
  374.     Set RegistryErrorIndex = $($R0)
  375.     CloseRegKey $(SoftProductKey)
  376.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  377.         Debug-Output "ShellCode error."
  378.         goto ShellCodeError
  379.     endif
  380.     Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  381.         EndWait
  382.         Debug-Output "OEMNSVRP.INF: Registry error: add value list to RPCLOCATE product"
  383.         CloseRegKey $(SoftNetRuleKey)
  384.         CloseRegKey $(RpcLocatorParametersKey)
  385.         goto fatalregistry
  386.     endif
  387.     Set NewValueList = {{InfOption,$(NoTitle),$(!REG_VT_SZ),$(Option)}}
  388.     Shell  $(UtilityInf), AddValueList, $(SoftNetRuleKey), $(NewValueList)
  389.     set RegistryErrorIndex = $($R0)
  390.     CloseRegKey $(SoftNetRuleKey)
  391.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  392.         CloseRegKey $(RpcLocatorParametersKey)
  393.         Debug-Output "ShellCode error."
  394.         goto ShellCodeError
  395.     endif
  396.     Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  397.         EndWait
  398.         CloseRegKey $(RpcLocatorParametersKey)
  399.         Debug-Output "OEMNSVSV.INF: Registry error: add value list."
  400.         goto fatalregistry
  401.     Endif
  402.    Set NewValueList = {{ExpirationAge,$(NoTitle),$(!REG_VT_DWORD),3600}}
  403.    Shell  $(UtilityInf), AddValueList, $(RpcLocatorParametersKey), $(NewValueList)
  404.    Ifint $($ShellCode) != $(!SHELL_CODE_OK)
  405.        Debug-Output "OEMNSVRP.INF: ShellCode error."
  406.        goto ShellCodeError
  407.    Endif
  408.    set RegistryErrorIndex = $($R0)
  409.    CloseRegKey $(RpcLocatorParametersKey)
  410.    Shell $(UtilityInf), CreateService, $(RpcSrvNameRpcss), +
  411.          $(RpcSrvDisplayNameRpcss), $(RpcSrvExeRpcss), "service", "", {}, "", ""
  412.    Ifint $($ShellCode) != $(!SHELL_CODE_OK)
  413.        Debug-Output "OEMNSVRP.INF: ShellCode error creating RPCSS service: "$($ShellCode)
  414.        goto ShellCodeError
  415.    endif
  416.    Set RegistryErrorIndex = $($R0)
  417.    CloseRegKey $($R1)
  418.    CloseRegKey $($R2)
  419.    CloseRegKey $($R3)
  420.    Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  421.       EndWait
  422.       Debug-Output "OEMNSVRD.INF: Registry error: creating RPCSS service"
  423.       Goto fatalregistry
  424.    Endif
  425.    Ifstr(i) $(!STF_PRODUCT) == "LANMANNT"
  426.        Set AclIndex = 4
  427.    Else
  428.        Set AclIndex = 3
  429.    Endif
  430.    LibraryProcedure NCPA_RESULT $(!NCPA_HANDLE), CPlSetup $(!STF_HWND),+
  431.          SECURESVC, $(RpcSrvNameLocator), $(AclIndex)
  432.    LibraryProcedure NCPA_RESULT $(!NCPA_HANDLE), CPlSetup $(!STF_HWND),+
  433.          SECURESVC, $(RpcSrvNameRpcss), $(AclIndex)
  434.    EndWait
  435.    goto successful
  436. bindingadapter =+
  437.     set Error = "RPC INF file invoked during bindings review."
  438.     goto fatal
  439. removeadapter = +
  440.     Debug-Output "OEMNSVRP.INF: Remove component "$(RpcSrvNameLocator)
  441.     Shell $(UtilityInf), RemoveSoftwareComponent, $(Manufacturer), $(RpcSrvNameLocator), FALSE
  442.     Debug-Output "OEMNSVRP.INF: Remove service "$(RpcSrvNameRpcss)
  443.     Shell $(UtilityInf), RemoveService, $(RpcSrvNameRpcss), $(UseSvcctrl)
  444.     goto end
  445. UpgradeSoftware = +
  446.     set Error = "Upgrade/update not supported for this product yet."
  447.     goto fatal
  448.     ifstr(i) $(ProductKeyName) == $(!NTN_RegBase)
  449.         OpenRegKey $(!REG_H_LOCAL) "" $(ProductKeyName) $(MAXIMUM_ALLOWED) KeyProduct
  450.         Ifstr $(KeyProduct) != $(KeyNull)
  451.             GetRegValue $(KeyProduct),"MajorVersion", VersionInfo
  452.             set Version = *($(VersionInfo), 4)
  453.             Shell $(UtilityInf), GetInfFileNameFromRegistry, $(KeyProduct)
  454.             ifint $($ShellCode) != $(!SHELL_CODE_OK)
  455.                 Debug-Output "ShellCode error"
  456.                 goto ShellCodeError
  457.             endif
  458.             set !UG_Filename = $($R0)
  459.             ifstr(i) $(!UG_Filename) != ""
  460.                 install "Install-Update"
  461.                 ifstr(i) $(STF_INSTALL_OUTCOME) != STF_SUCCESS
  462.                     goto fatal
  463.                 endif
  464.             endif
  465.             SetRegValue $(KeyProduct) {MajorVersion,$(NoTitle),$(!REG_VT_SZ),$(ProductMajorVersion)}
  466.             SetRegValue $(KeyProduct) {MinorVersion,$(NoTitle),$(!REG_VT_SZ),$(ProductMinorVersion)}
  467.             ifint $(Version) != $(ProductVersion)
  468.             endif
  469.             CloseRegKey $(KeyProduct)
  470.         else
  471.             goto fatalregistry
  472.         endif
  473.     endif
  474.     goto end
  475. successful = +
  476.     goto end
  477. warning = +
  478.     Shell $(subroutineinf) SetupMessage, $(!STF_LANGUAGE), "WARNING", $(Error)
  479.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  480.         goto ShellCodeError
  481.     endif
  482.     ifstr(i) $($R1) == "OK"
  483.         goto $(to)
  484.     else-ifstr(i) $($R1) == "CANCEL"
  485.         goto $(from)
  486.     else
  487.         goto "end"
  488.     endif
  489. nonfatal = +
  490.     ifstr(i) $(Error) == ""
  491.         Shell $(UtilityInf) RegistryErrorString "SETUP_FAIL"
  492.         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  493.             goto ShellCodeError
  494.         endif
  495.         set Error = $($R0)
  496.     endif
  497.     Shell $(subroutineinf) SetupMessage, $(!STF_LANGUAGE), "NONFATAL", $(Error)
  498.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  499.         goto ShellCodeError
  500.     endif
  501.     ifstr(i) $($R1) == "OK"
  502.         goto $(from)
  503.     else
  504.         goto "end"
  505.     endif
  506. fatalregistry = +
  507.     Shell $(UtilityInf) RegistryErrorString $(RegistryErrorIndex)
  508.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  509.         goto ShellCodeError
  510.     endif
  511.     set Error = $($R0)
  512.     goto fatal
  513. fatal = +
  514.     ifstr(i) $(Error) == ""
  515.         Shell $(UtilityInf) RegistryErrorString "SETUP_FAIL"
  516.         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  517.             goto ShellCodeError
  518.         endif
  519.         set Error = $($R0)
  520.     endif
  521.     Shell $(subroutineinf) SetupMessage, $(!STF_LANGUAGE), "FATAL", $(Error)
  522.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  523.         goto ShellCodeError
  524.     endif
  525.     goto setfailed
  526. ShellCodeError = +
  527.     set DlgType      = "MessageBox"
  528.     set STF_MB_TITLE = $(ShellCodeErrorTitle)
  529.     set STF_MB_TEXT  = $(ShellCodeErrorText) 
  530.     set STF_MB_TYPE  = 1
  531.     set STF_MB_ICON  = 3
  532.     set STF_MB_DEF   = 1
  533.     ui start "Error Message"
  534.     goto setfailed
  535. setfailed = +
  536.     set CommonStatus = STATUS_FAILED
  537.     ifstr(i) $(OEM_ABANDON_ON) == TRUE
  538.         set OEM_ABANDON_ON = FALSE
  539.         goto removeadapter
  540.     endif
  541.     goto end
  542. end = +
  543.     goto term
  544. term = +
  545.     Return $(CommonStatus)
  546. [Install-Option]
  547.     set STF_VITAL = ""
  548.     ifstr(i) $(AddCopy) == "YES"
  549.         AddSectionFilesToCopyList Files-$(Option) $(SrcDir) $(!STF_WINDOWSSYSPATH)
  550.     endif
  551.     ifstr(i) $(DoCopy) == "YES"
  552.        set !STF_NCPA_FLUSH_COPYLIST = TRUE
  553.        CopyFilesInCopyList
  554.     endif
  555.     ifstr(i) $(DoConfig) == "YES"
  556.     endif
  557.     Exit
  558. [Install-Update]
  559.    set STF_VITAL        = ""
  560.    set STF_OVERWRITE    = "VERIFYSOURCEOLDER"
  561.    AddSectionFilesToCopyList Files-$(Option) $(SrcDir) $(!STF_WINDOWSSYSPATH)
  562.    AddSectionFilesToCopyList Files-Inf $(SrcDir) $(!STF_WINDOWSSYSPATH)
  563.    set !STF_NCPA_FLUSH_COPYLIST = TRUE
  564.    CopyFilesInCopyList
  565.    exit
  566. [Source Media Descriptions]
  567.     1    = "Windows NT Advanced Server Setup Disk #1"   , TAGFILE = disk1
  568.     2    = "Windows NT Advanced Server Setup Disk #2"   , TAGFILE = disk2
  569.     3    = "Windows NT Advanced Server Setup Disk #3"   , TAGFILE = disk3
  570.     4    = "Windows NT Advanced Server Setup Disk #4"   , TAGFILE = disk4
  571.     5    = "Windows NT Advanced Server Setup Disk #5"   , TAGFILE = disk5
  572.     6    = "Windows NT Advanced Server Setup Disk #6"   , TAGFILE = disk6
  573.     7    = "Windows NT Advanced Server Setup Disk #7"   , TAGFILE = disk7
  574.     8    = "Windows NT Advanced Server Setup Disk #8"   , TAGFILE = disk8
  575.     9    = "Windows NT Advanced Server Setup Disk #9"   , TAGFILE = disk9
  576.     10    = "Windows NT Advanced Server Setup Disk #10"  , TAGFILE = disk10
  577.     11    = "Windows NT Advanced Server Setup Disk #11"  , TAGFILE = disk11
  578.     12    = "Windows NT Advanced Server Setup Disk #12"  , TAGFILE = disk12
  579.     13    = "Windows NT Advanced Server Setup Disk #13"  , TAGFILE = disk13
  580.     14    = "Windows NT Advanced Server Setup Disk #14"  , TAGFILE = disk14
  581.     15    = "Windows NT Advanced Server Setup Disk #15"  , TAGFILE = disk15
  582.     16    = "Windows NT Advanced Server Setup Disk #16"  , TAGFILE = disk16
  583.     17    = "Windows NT Advanced Server Setup Disk #17"  , TAGFILE = disk17
  584.     18    = "Windows NT Advanced Server Setup Disk #18"  , TAGFILE = disk18
  585.     19    = "Windows NT Advanced Server Setup Disk #19"  , TAGFILE = disk19
  586.     20    = "Windows NT Advanced Server Setup Disk #20"  , TAGFILE = disk20
  587.     21    = "Windows NT Advanced Server Setup Disk #21"  , TAGFILE = disk21
  588.     22    = "Windows NT Advanced Server Setup Disk #22"  , TAGFILE = disk22
  589.     23    = "Windows NT Advanced Server Setup Disk #23"  , TAGFILE = disk23
  590.     24    = "Windows NT Advanced Server Setup Disk #24"  , TAGFILE = disk24
  591.     25    = "Windows NT Advanced Server Setup Disk #25"  , TAGFILE = disk25
  592.     26    = "Windows NT Advanced Server Setup Disk #26"  , TAGFILE = disk26
  593.     27    = "Windows NT Advanced Server Setup Disk #27"  , TAGFILE = disk27
  594.     28    = "Windows NT Advanced Server Setup Disk #28"  , TAGFILE = disk28
  595.     29    = "Windows NT Advanced Server Setup Disk #29"  , TAGFILE = disk29
  596. [ProductType]
  597. STF_PRODUCT  = LanmanNT
  598. STF_PLATFORM = I386
  599. [Files-Inf]
  600. 2,    oemsetup.inf,     SIZE=1000,    RENAME=$(!UG_Filename)
  601. [Files-RPCLOCATE]
  602. 19,LOCATOR.EXE , SIZE=104960
  603. 21,RPCSS.EXE , SIZE=38912
  604. [LanguagesSupported]
  605.     ENG
  606. [OptionsTextENG]
  607.     RPCLOCATE   = "RPC Name Service Provider"
  608. [LocatorNamesENG]
  609. LocName1 = "Windows NT Locator"
  610. LocName2 = "DCE Cell Directory Service"
  611. [FileConstantsENG]
  612. ProCaption   = "Windows NT Setup"
  613. ProCancel    = "Cancel"
  614. ProCancelMsg = "Windows NT Networking is not correctly installed.  "+
  615.                "Are you sure you want to cancel copying files?"
  616. ProCancelCap = "Network Setup Message"
  617. ProText1     = "Copying:"
  618. ProText2     = "To:"
  619. FunctionTitle   = "RPC Locator Service Setup"
  620. ProductSoftwareDescription      = "Microsoft RPC Locator Service"
  621. ProductRPCTitle   = "RPC Name Service Provider"
  622. RpcSrvDisplayNameRpcss   = "Remote Procedure Call (RPC) Service"
  623. RpcSrvDisplayNameLocator = "Remote Procedure Call (RPC) Locator"
  624. ShellCodeErrorTitle     = "Error: "$(FunctionTitle)
  625. ShellCodeErrorText      = "Shell Code Error."
  626. [DialogConstantsENG]
  627. Help        = "&Help"
  628. Exit        = "Cancel"
  629. OK          = "OK"
  630. HelpContext = ""
  631. Continue    = "C&ontinue"
  632. Cancel      = "C&ancel"
  633. [RpcProviderDlgENG]
  634. Caption = "RPC Name Service Provider Configuration"
  635. Edit1Label = "Network &Address:"
  636. Combo1Label = "&Name Service Provider:"
  637. Help        = "&Help"
  638. Continue    = "OK"
  639. Cancel      = "Cancel"
  640. DlgType = Combination
  641. DlgTemplate = "RPCPROVIDE"
  642. EditTextIn = $(NetworkAddress)
  643. EditFocus = "ALL"
  644. EditTextLim = 50
  645. Combo1List  = $(LocatorListboxNames)
  646. Combo1Out   = $(LocatorChosenName)
  647. ComboListItemsIn  = {Combo1List}
  648. ComboListItemsOut = {Combo1Out}
  649. HelpContext = $(!IDH_DB_RPCLOCATE_INS)
  650. ExitState   = "Active"
  651. NotifyFields = { YES }
  652. [NonFatalError1ENG]
  653. NonFatal = "No network address was entered."
  654. [NonFatalError2ENG]
  655. NonFatal = "Network address ignored for Windows NT Locator"
  656.  
  657.  
  658.  
  659.