home *** CD-ROM | disk | FTP | other *** search
/ PC World 1999 October / PCWorld_1999-10_cd1.bin / Software / Antiviry / normanav.wnt / DATA.Z / NVCNT.NXD < prev    next >
Text File  |  1999-06-17  |  12KB  |  279 lines

  1. ;NVCNT.NXD v4.70
  2. NXD BEGIN
  3.  
  4. set $Source = '{Source}'
  5. set $Target = '{Target}'
  6. set $Folder = '{Folder}'
  7.  
  8. set $Inst_Nvc_Win32 = '{Inst_Nvc_Win32}'
  9. set $Inst_Nvc_ShellExt = $Inst_Nvc_Win32
  10. set $Inst_Book = '{Inst_Book}'
  11. set $Inst_NtService = '{Inst_NtService}'
  12. set $Inst_Nse = 'Yes'
  13. set $Inst_ReadMe = '{Inst_ReadMe}'
  14. set $Inst_InternetUpdate =  'No'
  15. set $Inst_UpdateAtStartup = 'No'
  16. set $Inst_Untbav = '{Inst_Untbav}'
  17.  
  18. set $Icon_Nvc = '{Icon_Nvc_Win32}'
  19. set $Icon_Book = '{Icon_Book}'
  20. set $Icon_NtService = '{Icon_NtService}'
  21. set $Icon_ReadMe = '{Icon_ReadMe}'
  22. set $Icon_InternetUpdate = '{Icon_InternetUpdate}'
  23.  
  24. set $Start_NtService = 'Yes'
  25. set $Start_Nvc_Win32 = 'No'
  26.  
  27. #CheckOs
  28.    if $System ! 'WINNT'
  29.       goto #End
  30.  
  31. #DeleteFiles
  32.    delete $Target+'\NVC.DEF'
  33.    delete $Target+'\NVCBIN.DEF'
  34.    delete $Target+'\NVCMACRO.DEF'
  35.    delete $Target+'\NVCMACRO.CRT'
  36.    delete $Target+'\DOS\NVCLEAN.EXE'
  37.    delete $Target+'\DOS\NVCEXCL.EXE'
  38.  
  39. #MakeDirs
  40.    makedir $Target+'\DOS'
  41.    makedir $Target+'\WIN32'
  42.  
  43. #SetupIni
  44.    setini $Target+'\SETUP.INI' 'NVC'       'Path'    $Target
  45.    setini $Target+'\SETUP.INI' 'NVC|WIN32' 'Path'    $Target
  46.    setini $Target+'\SETUP.INI' 'NVC|WIN32' 'Folder'  $Folder
  47.    setini $Target+'\SETUP.INI' 'NVC|WIN32' 'Version' '4.70'
  48.  
  49. #Nse
  50.    if $Inst_Nse ! 'Yes'
  51.       goto #Nse_End
  52.    getregistry $NseTarget 'HKEY_LOCAL_MACHINE\Software\Norman Data Defense Systems' 'NsePath'
  53.    if $Error = 'FALSE'
  54.       goto #Nse_Engine
  55.    set $NseTarget = $Target+'\NSE'
  56.    setregistry 'HKEY_LOCAL_MACHINE\Software\Norman Data Defense Systems' 'NsePath' $NseTarget
  57.    if $Error = 'FALSE'
  58.       goto #Nse_Engine
  59.    popmessage 'The installation of NVC version 4.70 must be done by a user with administrator rights.'
  60.    goto #end
  61. #Nse_Engine
  62.    set $NSEupdate = 'No'
  63.    makedir $NseTarget
  64.    copy $Source+'\NSE\Ndiskio.SYS' $NseTarget+'\Ndiskio.SYS' update
  65.    copy $Source+'\NSE\NSE32.EXE'   $NseTarget+'\NSE32.EXE'   update
  66.    copy $Source+'\WIN32\NREN.EXE'  $Target+'\WIN32\NREN.EXE' update
  67.    run $NseTarget+'\NSE32.EXE'   '/INSTALL' nowait
  68.    run $Target+'\WIN32\NREN.EXE' '/INSTALL' nowait
  69.    delete $NseTarget+'\NSE_W32.D@L'
  70.    if update $Source+'\NSE\NSE_W32.DLL' $NseTarget+'\NSE_W32.DLL'
  71.      goto #Nse_Dll
  72.    goto #Nse_Def
  73. #Nse_Dll
  74.    rename $NseTarget+'\NSE_W32.DLL' $NseTarget+'\NSE_W32.D@L'
  75.    copy  $Source+'\NSE\NSE_W32.DLL' $NseTarget+'\NSE_W32.DLL' update
  76.    set $NSEupdate = 'Yes'
  77. #Nse_Def
  78. ;copy $Source+'\NSE\UPDATE\NSEUPDAT.ZIP' $NseTarget+'\UPDATE\NSEUPDAT.ZIP' update
  79.    copy $Source+'\NSE\NVCBIN.DEF'   $NseTarget+'\NVCBIN.DEF'   update
  80.    copy $Source+'\NSE\NVCMACRO.DEF' $NseTarget+'\NVCMACRO.DEF' update
  81.    if exist $Source+'\NSE\NVCMACRO.CRT'
  82.       copy $Source+'\NSE\NVCMACRO.CRT' $NseTarget+'\NVCMACRO.CRT' update
  83.    if exist $Source+'\TCP_IP.CFG'
  84.       copy $Source+'\TCP_IP.CFG' $Target+'\TCP_IP.CFG' update
  85.    set $NSEupdate = $Updated
  86. #Nse_End
  87.  
  88. #Nvc_Win32
  89.    if $Inst_Nvc_Win32 ! 'Yes'
  90.       goto #Nvc_Win32_End
  91.    set $Updated = 'No'
  92.    copy $Source+'\WIN32\NVCNT.EXE'    $Target+'\WIN32\NVCNT.EXE'    update
  93.    copy $Source+'\WIN32\NIPXLIB.DLL'  $Target+'\WIN32\NIPXLIB.DLL'  update
  94.    copy $Source+'\WIN32\NVCMSG.DLL'   $Target+'\WIN32\NVCMSG.DLL'   update
  95.    copy $Source+'\WIN32\NVCNT.HLP'    $Target+'\WIN32\NVCNT.HLP'    update
  96.    copy $Source+'\WIN32\NVCNT.CNT'    $Target+'\WIN32\NVCNT.CNT'    update
  97.    copy $Source+'\WIN32\NVC32.EXE'    $Target+'\WIN32\NVC32.EXE'    update
  98.    copy $Source+'\WIN32\NLOG.DLL'     $Target+'\WIN32\NLOG.DLL'     update
  99.    copy $Source+'\WIN32\NLOGSNMP.DLL' $Target+'\WIN32\NLOGSNMP.DLL' update
  100.    copy $Source+'\WIN32\NLOGTXT.DLL'  $Target+'\WIN32\NLOGTXT.DLL'  update
  101.    copy $Source+'\WIN32\NMSG.DLL'     $Target+'\WIN32\NMSG.DLL'     update
  102.    copy $Source+'\WIN32\TROGUARD.EXE' $Target+'\WIN32\TROGUARD.EXE' update
  103.    copy $Source+'\WIN32\TROGUARD.TXT' $Target+'\WIN32\TROGUARD.TXT' update
  104.    copy $Source+'\WIN32\PSAPI.DLL'    $Target+'\WIN32\PSAPI.DLL'    update
  105.    copy $Source+'\NVC32.CFG'          $Target+'\NVC32.CFG'          update
  106.    if !exist $Winsysdir+'\CTL3D32.DLL'
  107.       copy $Source+'\WIN32\CTL3D32.DLL' $Winsysdir+'\CTL3D32.DLL' update
  108.    if $Updated = 'No'
  109.       goto #Scheduling
  110.    register $Folder $Target+'\WIN32\NVCNT.EXE' $Icon_Nvc common
  111.    if $Start_Nvc_Win32 ! 'Yes'
  112.       goto #Scheduling
  113.    register 'Startup' $Target+'\WIN32\NVCNT.EXE' $Icon_Nvc common
  114. #Scheduling
  115.    set $Updated = 'No'
  116.    if exist $Source+'\WIN32\NVCNT.REG'
  117.       copy $Source+'\WIN32\NVCNT.REG' $Target+'\WIN32\NVCNT.REG' update
  118.    if $Updated = 'No'
  119.       goto #Nvc_Win32_End
  120.    run $Windir+'\REGEDIT.EXE' '/s' $Target+'\WIN32\NVCNT.REG' nowait
  121. #Nvc_Win32_End
  122.  
  123. #NVC_ShellExt
  124.    if $Inst_Nvc_ShellExt ! 'Yes'
  125.       goto #Nvc_ShellExt_End
  126.    set $Updated = 'No'
  127.    copy $Source+'\WIN32\NVCSE.DLL'    $Target+'\WIN32\NVCSE.DLL'    update
  128.    copy $Source+'\WIN32\NVCOD.EXE'    $Target+'\WIN32\NVCOD.EXE'    update
  129.    copy $Source+'\WIN32\NVCODRC.DLL'  $Target+'\WIN32\NVCODRC.DLL'  update
  130.    copy $Source+'\WIN32\NVCOD.HLP'    $Target+'\WIN32\NVCOD.HLP'    update
  131.    copy $Source+'\NVC32.CFG'          $Target+'\NVC32.CFG'          update
  132.    if $Updated = 'No'
  133.       goto #Nvc_ShellExt_End
  134.    run $Target+'\WIN32\NVCOD.EXE' '/INSTALL' nowait
  135. #Nvc_ShellExt_End
  136.  
  137. #Book
  138.    if $Inst_Book ! 'Yes'
  139.       goto #Book_End
  140.    set $Updated = 'No'
  141.    copy $Source+'\WIN32\NVCBOOK.HLP' $Target+'\WIN32\NVCBOOK.HLP' update
  142.    if $Updated = 'No'
  143.       goto #Book_End
  144.    register $Folder $Target+'\WIN32\NVCBOOK.HLP' $Icon_Book common
  145. #Book_End
  146.  
  147. #NtService
  148.    if exist $Source+'\WIN32\NVCSRV.REG'
  149.       copy $Source+'\WIN32\NVCSRV.REG' $Target+'\WIN32\NVCSRV.REG' update
  150.    delete $Target+'\WIN32\*.S@S'
  151.    delete $Target+'\WIN32\*.E@E'
  152.    delete $Target+'\WIN32\*.D@L'
  153.    if $Inst_NtService ! 'Yes'
  154.       goto #NtService_End
  155.    getregistry $Data 'HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\NVCSRV' 'DisplayName'
  156.    if $Error = 'FALSE'
  157.       goto #Test_NtService
  158.    getregistry $Data 'HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\EventLog' 'Group'
  159.    if $Error = 'TRUE'
  160.       goto #NtService_End
  161.    setregistry 'HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\EventLog' 'Group' $Data
  162.    if $Error = 'FALSE'
  163.       goto #Test_NtService
  164.    popmessage 'The installation of NVC version 4.70 must be done by a user with administrator rights.'
  165.    goto #End
  166. #Test_NtService
  167.    copy $Source+'\NVC32.CFG'          $Target+'\NVC32.CFG'          update
  168.    copy $Source+'\OFFICES.TXT'        $Target+'\OFFICES.TXT'        update
  169.    copy $Source+'\WIN32\UPDNVC.BAT'   $Target+'\WIN32\UPDNVC.BAT'   update
  170.    copy $Source+'\WIN32\NCFG.EXE'     $Target+'\WIN32\NCFG.EXE'     update
  171.    copy $Source+'\WIN32\NCFGW.EXE'    $Target+'\WIN32\NCFGW.EXE'    update
  172.    copy $Source+'\WIN32\NCFGW.HLP'    $Target+'\WIN32\NCFGW.HLP'    update
  173.    copy $Source+'\WIN32\NCFGW.CNT'    $Target+'\WIN32\NCFGW.CNT'    update
  174.    copy $Source+'\WIN32\NVCPOPUP.HLP' $Target+'\WIN32\NVCPOPUP.HLP' update
  175.    if update $Source+'\WIN32\NVCSRV.EXE'   $Target+'\WIN32\NVCSRV.EXE'
  176.       goto #Do_NtService
  177.    if update $Source+'\WIN32\NVCPOPUP.EXE' $Target+'\WIN32\NVCPOPUP.EXE'
  178.       goto #Do_NtService
  179.    if update $Source+'\WIN32\NVCEVLOG.DLL' $Target+'\WIN32\NVCEVLOG.DLL'
  180.       goto #Do_NtService
  181.    if update $Source+'\WIN32\NVCSNMP.DLL'  $Target+'\WIN32\NVCSNMP.DLL'
  182.       goto #Do_NtService
  183.    if update $Source+'\WIN32\NRMNTVER.DLL' $Target+'\WIN32\NRMNTVER.DLL'
  184.       goto #Do_NtService
  185.    if update $Source+'\WIN32\NIPXLIB.DLL'  $Target+'\WIN32\NIPXLIB.DLL'
  186.       goto #Do_NtService
  187.    if update $Source+'\WIN32\NVCFLT3.SYS'  $Target+'\WIN32\NVCFLT3.SYS'
  188.       goto #Do_NtService
  189.    if update $Source+'\WIN32\NVCREC3.SYS'  $Target+'\WIN32\NVCREC3.SYS'
  190.       goto #Do_NtService
  191.    if update $Source+'\WIN32\NVCFL3.SYS'   $Target+'\WIN32\NVCFL3.SYS'
  192.       goto #Do_NtService
  193.    if update $Source+'\WIN32\NVCFLT4.SYS'  $Target+'\WIN32\NVCFLT4.SYS'
  194.       goto #Do_NtService
  195.    if update $Source+'\WIN32\NVCREC4.SYS'  $Target+'\WIN32\NVCREC4.SYS'
  196.       goto #Do_NtService
  197.    if update $Source+'\WIN32\NVCFL4.SYS'   $Target+'\WIN32\NVCFL4.SYS'
  198.       goto #Do_NtService
  199.    if $NSEupdate ! 'Yes'
  200.       goto #NtService_End
  201.    run $Target+'\WIN32\NCFG.EXE' '-stop'
  202.    run $Target+'\WIN32\NCFG.EXE' '-start'
  203.    goto #NtService_End
  204. #Do_NtService
  205.    delete $Target+'\WIN32\NVCDRV.EXE'
  206.    run $Target+'\WIN32\NCFG.EXE' '-stop'
  207.    rename $Target+'\WIN32\NVCSRV.EXE'   $Target+'\WIN32\NVCSRV.E@E'
  208.    copy   $Source+'\WIN32\NVCSRV.EXE'   $Target+'\WIN32\NVCSRV.EXE'   update
  209.    rename $Target+'\WIN32\NVCPOPUP.EXE' $Target+'\WIN32\NVCPOPUP.E@E'
  210.    copy   $Source+'\WIN32\NVCPOPUP.EXE' $Target+'\WIN32\NVCPOPUP.EXE' update
  211.    rename $Target+'\WIN32\NVCEVLOG.DLL' $Target+'\WIN32\NVCEVLOG.D@L'
  212.    copy   $Source+'\WIN32\NVCEVLOG.DLL' $Target+'\WIN32\NVCEVLOG.DLL' update
  213.    rename $Target+'\WIN32\NVCSNMP.DLL'  $Target+'\WIN32\NVCSNMP.D@L'
  214.    copy   $Source+'\WIN32\NVCSNMP.DLL'  $Target+'\WIN32\NVCSNMP.DLL'  update
  215.    rename $Target+'\WIN32\NRMNTVER.DLL' $Target+'\WIN32\NRMNTVER.D@L'
  216.    copy   $Source+'\WIN32\NRMNTVER.DLL' $Target+'\WIN32\NRMNTVER.DLL' update
  217.    rename $Target+'\WIN32\NIPXLIB.DLL'  $Target+'\WIN32\NIPXLIB.D@L'
  218.    copy   $Source+'\WIN32\NIPXLIB.DLL'  $Target+'\WIN32\NIPXLIB.DLL'  update
  219.    rename $Target+'\WIN32\NVCFLT3.SYS'  $Target+'\WIN32\NVCFLT3.S@S'
  220.    copy   $Source+'\WIN32\NVCFLT3.SYS'  $Target+'\WIN32\NVCFLT3.SYS'  update
  221.    rename $Target+'\WIN32\NVCREC3.SYS'  $Target+'\WIN32\NVCREC3.S@S'
  222.    copy   $Source+'\WIN32\NVCREC3.SYS'  $Target+'\WIN32\NVCREC3.SYS'  update
  223.    rename $Target+'\WIN32\NVCFL3.SYS'   $Target+'\WIN32\NVCFL3.S@S'
  224.    copy   $Source+'\WIN32\NVCFL3.SYS'   $Target+'\WIN32\NVCFL3.SYS'   update
  225.    rename $Target+'\WIN32\NVCFLT4.SYS'  $Target+'\WIN32\NVCFLT4.S@S'
  226.    copy   $Source+'\WIN32\NVCFLT4.SYS'  $Target+'\WIN32\NVCFLT4.SYS'  update
  227.    rename $Target+'\WIN32\NVCREC4.SYS'  $Target+'\WIN32\NVCREC4.S@S'
  228.    copy   $Source+'\WIN32\NVCREC4.SYS'  $Target+'\WIN32\NVCREC4.SYS'  update
  229.    rename $Target+'\WIN32\NVCFL4.SYS'   $Target+'\WIN32\NVCFL4.S@S'
  230.    copy   $Source+'\WIN32\NVCFL4.SYS'   $Target+'\WIN32\NVCFL4.SYS'   update
  231.    set $Deferred = 'Yes'
  232.    run $Target+'\WIN32\NVCSRV.EXE' '-install'
  233.    register $Folder $Target+'\WIN32\NCFGW.EXE' $Icon_NtService common
  234. #NtService_End
  235.  
  236. #ReadMe
  237.    if $Inst_ReadMe ! 'Yes'
  238.       goto #ReadMe_End
  239.    set $Updated = 'No'
  240.    copy $Source+'\README.TXT' $Target+'\README.TXT' update
  241.    if $Updated = 'No'
  242.       goto #ReadMe_End
  243.    register $Folder $Target+'\README.TXT' $Icon_ReadMe common
  244. #ReadMe_End
  245.  
  246. #InternetUpdate
  247.    if $Inst_InternetUpdate ! 'Yes'
  248.       goto #InternetUpdate_End
  249.    set $Updated = 'No'
  250.    copy $Source+'\WIN32\NUF_W32.DLL'  $Target+'\WIN32\NUF_W32.DLL'  update
  251.    copy $Source+'\WIN32\NUPGRADE.EXE' $Target+'\WIN32\NUPGRADE.EXE' update
  252.    if $Updated = 'No'
  253.       goto #InternetUpdate_End
  254.    register $Folder $Target+'\WIN32\NUPGRADE.EXE' $Icon_InternetUpdate
  255.    if $Inst_UpdateAtStartup = 'Yes'
  256.       register 'Startup' $Target+'\WIN32\NUPGRADE.EXE -hidden -wait:5' $Icon_InternetUpdate
  257. #InternetUpdate_End
  258.  
  259. #UnTbav
  260.    if $Inst_Untbav ! 'Yes'
  261.       goto #UnTbav_End
  262.    makedir $Target+'\uninst'
  263.    set $Updated = 'No'
  264.    copy $Source+'\uninst\untbav32.exe' $Target+'\uninst\untbav32.exe' update
  265.    copy $Source+'\uninst\deltbdir.exe' $Target+'\uninst\deltbdir.exe' update
  266.    copy $Source+'\uninst\nrreboot.exe' $Target+'\uninst\nrreboot.exe' update
  267.    if $Updated = 'No'
  268.       goto #UnTbav_End
  269.    popmessage 'ThunderByte Anti Virus is removed, this takes some time.'
  270.    run $Target+'\uninst\UNTBAV32.EXE' '-q -s -c -r'
  271. #UnTbav_End
  272.  
  273.    if $Deferred = 'Yes'
  274.       popmessage 'You must restart the computer to complete the installation of Norman Virus Control.'
  275. #End
  276.  
  277. NXD END
  278.  
  279.