vbox的更動 96687 路徑 trunk/src/VBox/Additions/WINNT
- 時間撮記:
- 2022-9-11 上午12:34:46 (2 年 以前)
- 位置:
- trunk/src/VBox/Additions/WINNT/Installer
- 檔案:
-
- 修改 5 筆資料
圖例:
- 未更動
- 新增
- 刪除
-
trunk/src/VBox/Additions/WINNT/Installer/VBoxGuestAdditions.nsi
r96686 r96687 862 862 ${LogVerbose} "Installation completed." 863 863 864 ; 865 ; Dump UI log to on success too. Only works with non-silent installs. 866 ; (This has to be done here rather than in .onInstSuccess, because by 867 ; then the log is no longer visible in the UI.) 868 ; 869 ${IfNot} ${Silent} 870 StrCpy $0 "$INSTDIR\install_ui.log" 871 Push $0 872 Call DumpLog 873 ${EndIf} 874 864 875 SectionEnd 865 876 877 ;; 866 878 ; !!! NOTE: This function *has* to be right under the last section; otherwise it does 867 879 ; *not* get called! Don't ask me why ... !!! … … 896 908 FunctionEnd 897 909 910 ;; 898 911 ; This function is called when a critical error occurred, caused by 899 912 ; the Abort command 913 ; 900 914 Function .onInstFailed 901 915 … … 907 921 ${EndIf} 908 922 909 ; Dump UI log to see what happend. 910 ; Only works with non-silent installs. 911 IfSilent +4 +1 923 ; Dump UI log to see what happend. Only works with non-silent installs. 924 ${IfNot} ${Silent} 912 925 StrCpy $0 "$INSTDIR\install_ui.log" 913 926 Push $0 914 927 Call DumpLog 928 ${EndIf} 915 929 916 930 ; Set overall exit code … … 919 933 FunctionEnd 920 934 935 ;; 921 936 ; This function is called when installation was successful! 937 ; 922 938 Function .onInstSuccess 923 939 -
trunk/src/VBox/Additions/WINNT/Installer/VBoxGuestAdditionsCommon.nsh
r96686 r96687 468 468 ${If} ${FileExists} "$g_strSystemDir\shutdown.exe" 469 469 ; Try to abort the shutdown 470 ${CmdExecute} "$\"$g_strSystemDir\shutdown.exe$\" -a" "true"470 ${CmdExecute} "$\"$g_strSystemDir\shutdown.exe$\" -a" 'non-zero-exitcode=log' 471 471 ${Else} 472 472 ${LogVerbose} "Shutting down not supported: Binary $\"$g_strSystemDir\shutdown.exe$\" not found" -
trunk/src/VBox/Additions/WINNT/Installer/VBoxGuestAdditionsExternal.nsh
r96686 r96687 33 33 ; code other than 0 the installer will be aborted. 34 34 ; 35 ; @param Command line (full qualified and quoted). 36 ; @param If set to "false" the installer aborts if the external program reports 37 ; an exit code other than 0, "true" just prints a warning and continues 38 ; execution. 35 ; @param ${cmdline} Command line (full qualified and quoted). 36 ; @param ${options} Either 'non-zero-exitcode=log' or 'non-zero-exitcode=abort'. 37 ; Controls how to handle non-zero exit codes, in the latter 38 ; case they will trigger an installation abort, while in the 39 ; form only a warning in the log file. 39 40 ; 40 !macro _cmdExecute cmdline option al41 !macro _cmdExecute cmdline options 41 42 ; Save $0 & $1 42 43 Push $0 43 44 Push $1 45 46 ; Check that the options are valid. 47 ${IfNot} ${options} != "exitcode=0" 48 ${AndIfNot} ${options} != "ignore-exitcode" 49 Abort "Internal error in _cmdExecute: options=${options} cmdline=${cmdline}" 50 ${EndIf} 44 51 45 52 ; … … 63 70 ; 64 71 ${If} $0 <> 0 65 ${If} ${option al} == "false"72 ${If} ${options} == "exitcode=0" 66 73 ${LogVerbose} "Error excuting $\"${cmdline}$\" (exit code: $0) -- aborting installation" 67 74 Abort "Error excuting $\"${cmdline}$\" (exit code: $0) -- aborting installation" -
trunk/src/VBox/Additions/WINNT/Installer/VBoxGuestAdditionsNT4.nsh
r96605 r96687 162 162 163 163 ; Install guest driver 164 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" service create $\"VBoxGuest$\" $\"VBoxGuest Support Driver$\" 1 1 $\"$SYSDIR\drivers\VBoxGuest.sys$\" $\"Base$\"" "false"164 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" service create $\"VBoxGuest$\" $\"VBoxGuest Support Driver$\" 1 1 $\"$SYSDIR\drivers\VBoxGuest.sys$\" $\"Base$\"" 'non-zero-exitcode=abort' 165 165 166 166 ; Bugfix: Set "Start" to 1, otherwise, VBoxGuest won't start on boot-up! … … 173 173 174 174 ; Video driver 175 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" driver nt4-install-video" "false"175 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" driver nt4-install-video" 'non-zero-exitcode=abort' 176 176 177 177 ; Create the VBoxService service 178 178 ; No need to stop/remove the service here! Do this only on uninstallation! 179 179 ${LogVerbose} "Installing VirtualBox service ..." 180 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" service create $\"VBoxService$\" $\"VirtualBox Guest Additions Service$\" 16 2 $\"%SystemRoot%\system32\VBoxService.exe$\" $\"Base$\"" "false"180 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" service create $\"VBoxService$\" $\"VirtualBox Guest Additions Service$\" 16 2 $\"%SystemRoot%\system32\VBoxService.exe$\" $\"Base$\"" 'non-zero-exitcode=abort' 181 181 182 182 ; Create the Shared Folders service ... … … 196 196 197 197 ; Add the shared folders network provider 198 ;${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" netprovider add VBoxSF" "false"198 ;${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" netprovider add VBoxSF" 'non-zero-exitcode=abort' 199 199 200 200 Goto done … … 244 244 245 245 ; Remove the guest driver service 246 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" service delete VBoxGuest" "true"246 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" service delete VBoxGuest" 'non-zero-exitcode=log' 247 247 Delete /REBOOTOK "$SYSDIR\drivers\VBoxGuest.sys" 248 248 249 249 ; Delete the VBoxService service 250 250 Call ${un}StopVBoxService 251 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" service delete VBoxService" "true"251 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" service delete VBoxService" 'non-zero-exitcode=log' 252 252 DeleteRegValue HKLM "Software\Microsoft\Windows\CurrentVersion\Run" "VBoxService" 253 253 Delete /REBOOTOK "$SYSDIR\VBoxService.exe" … … 264 264 265 265 ; Delete the VBoxVideo service 266 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" service delete VBoxVideo" "true"266 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" service delete VBoxVideo" 'non-zero-exitcode=log' 267 267 268 268 ; Delete the VBox video driver files -
trunk/src/VBox/Additions/WINNT/Installer/VBoxGuestAdditionsW2KXP.nsh
r96686 r96687 141 141 142 142 ; Write the new value in the adapter config (VBoxVideo.sys) using hex values in binary format 143 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" registry write HKLM $reg_path_device CustomXRes REG_BIN $g_iScreenX DWORD" "false"144 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" registry write HKLM $reg_path_device CustomYRes REG_BIN $g_iScreenY DWORD" "false"145 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" registry write HKLM $reg_path_device CustomBPP REG_BIN $g_iScreenBpp DWORD" "false"143 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" registry write HKLM $reg_path_device CustomXRes REG_BIN $g_iScreenX DWORD" 'non-zero-exitcode=abort' 144 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" registry write HKLM $reg_path_device CustomYRes REG_BIN $g_iScreenY DWORD" 'non-zero-exitcode=abort' 145 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" registry write HKLM $reg_path_device CustomBPP REG_BIN $g_iScreenBpp DWORD" 'non-zero-exitcode=abort' 146 146 147 147 ; ... and tell Windows to use that mode on next start! … … 198 198 FILE "$%PATH_OUT%\bin\additions\vbox-legacy-timestamp-ca.cer" 199 199 FILE "$%PATH_OUT%\bin\additions\VBoxCertUtil.exe" 200 ${CmdExecute} "$\"$INSTDIR\cert\VBoxCertUtil.exe$\" add-trusted-publisher --root $\"$INSTDIR\cert\vbox-legacy-timestamp-ca.cer$\"" "true"201 ${CmdExecute} "$\"$INSTDIR\cert\VBoxCertUtil.exe$\" display-all" "true"200 ${CmdExecute} "$\"$INSTDIR\cert\VBoxCertUtil.exe$\" add-trusted-publisher --root $\"$INSTDIR\cert\vbox-legacy-timestamp-ca.cer$\"" 'non-zero-exitcode=log' 201 ${CmdExecute} "$\"$INSTDIR\cert\VBoxCertUtil.exe$\" display-all" 'non-zero-exitcode=log' 202 202 ${EndIf} 203 203 !endif … … 354 354 ${If} $g_bNoGuestDrv == "false" 355 355 ${LogVerbose} "Installing guest driver ..." 356 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" driver install $\"$INSTDIR\VBoxGuest.inf$\" $\"$INSTDIR\install_drivers.log$\"" "false"356 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" driver install $\"$INSTDIR\VBoxGuest.inf$\" $\"$INSTDIR\install_drivers.log$\"" 'non-zero-exitcode=abort' 357 357 ${Else} 358 358 ${LogVerbose} "Guest driver installation skipped!" … … 362 362 ${If} $g_bWithWDDM == "true" 363 363 ${LogVerbose} "Installing WDDM video driver..." 364 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" driver install $\"$INSTDIR\VBoxWddm.inf$\" $\"$INSTDIR\install_drivers.log$\"" "false"364 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" driver install $\"$INSTDIR\VBoxWddm.inf$\" $\"$INSTDIR\install_drivers.log$\"" 'non-zero-exitcode=abort' 365 365 ${Else} 366 366 ${LogVerbose} "Installing video driver ..." 367 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" driver install $\"$INSTDIR\VBoxVideo.inf$\" $\"$INSTDIR\install_drivers.log$\"" "false"367 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" driver install $\"$INSTDIR\VBoxVideo.inf$\" $\"$INSTDIR\install_drivers.log$\"" 'non-zero-exitcode=abort' 368 368 ${EndIf} 369 369 ${Else} … … 379 379 ; so this .INF file needs to be installed using "InstallHinfSection" which is implemented 380 380 ; with VBoxDrvInst's "driver executeinf" routine 381 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" driver install $\"$INSTDIR\VBoxMouse.inf$\"" "false"381 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" driver install $\"$INSTDIR\VBoxMouse.inf$\"" 'non-zero-exitcode=abort' 382 382 ${Else} 383 383 ${LogVerbose} "Mouse driver installation skipped!" … … 389 389 ; 390 390 ${LogVerbose} "Installing VirtualBox service ..." 391 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" service create $\"VBoxService$\" $\"VirtualBox Guest Additions Service$\" 16 2 $\"%SystemRoot%\System32\VBoxService.exe$\" $\"Base$\"" "false"391 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" service create $\"VBoxService$\" $\"VirtualBox Guest Additions Service$\" 16 2 $\"%SystemRoot%\System32\VBoxService.exe$\" $\"Base$\"" 'non-zero-exitcode=abort' 392 392 393 393 ; Set service description … … 402 402 ; Create the Shared Folders service ... 403 403 ; No need to stop/remove the service here! Do this only on uninstallation! 404 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" service create $\"VBoxSF$\" $\"VirtualBox Shared Folders$\" 2 1 $\"\SystemRoot\System32\drivers\VBoxSF.sys$\" $\"NetworkProvider$\"" "false"404 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" service create $\"VBoxSF$\" $\"VirtualBox Shared Folders$\" 2 1 $\"\SystemRoot\System32\drivers\VBoxSF.sys$\" $\"NetworkProvider$\"" 'non-zero-exitcode=abort' 405 405 406 406 ; ... and the link to the network provider … … 410 410 411 411 ; Add default network providers (if not present or corrupted) 412 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" netprovider add WebClient" "false"413 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" netprovider add LanmanWorkstation" "false"414 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" netprovider add RDPNP" "false"412 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" netprovider add WebClient" 'non-zero-exitcode=abort' 413 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" netprovider add LanmanWorkstation" 'non-zero-exitcode=abort' 414 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" netprovider add RDPNP" 'non-zero-exitcode=abort' 415 415 416 416 ; Add the shared folders network provider 417 417 ${LogVerbose} "Adding network provider (Order = $g_iSfOrder) ..." 418 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" netprovider add VBoxSF $g_iSfOrder" "false"418 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" netprovider add VBoxSF $g_iSfOrder" 'non-zero-exitcode=abort' 419 419 420 420 … … 518 518 ; Remove VirtualBox video driver 519 519 ${LogVerbose} "Uninstalling video driver ..." 520 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" driver uninstall $\"$INSTDIR\VBoxVideo.inf$\"" "true"521 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" service delete VBoxVideo" "true"520 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" driver uninstall $\"$INSTDIR\VBoxVideo.inf$\"" 'non-zero-exitcode=log' 521 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" service delete VBoxVideo" 'non-zero-exitcode=log' 522 522 Delete /REBOOTOK "$g_strSystemDir\drivers\VBoxVideo.sys" 523 523 Delete /REBOOTOK "$g_strSystemDir\VBoxDisp.dll" … … 527 527 528 528 ${LogVerbose} "Uninstalling WDDM video driver..." 529 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" driver uninstall $\"$INSTDIR\VBoxWddm.inf$\"" "true"530 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" service delete VBoxWddm" "true"529 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" driver uninstall $\"$INSTDIR\VBoxWddm.inf$\"" 'non-zero-exitcode=log' 530 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" service delete VBoxWddm" 'non-zero-exitcode=log' 531 531 ;misha> @todo driver file removal (as well as service removal) should be done as driver package uninstall 532 532 ; could be done with "VBoxDrvInst.exe /u", e.g. by passing additional arg to it denoting that driver package is to be uninstalled … … 535 535 ; Obsolete files begin 536 536 ${LogVerbose} "Uninstalling WDDM video driver for Windows 8..." 537 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" driver uninstall $\"$INSTDIR\VBoxVideoW8.inf$\"" "true"538 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" service delete VBoxVideoW8" "true"537 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" driver uninstall $\"$INSTDIR\VBoxVideoW8.inf$\"" 'non-zero-exitcode=log' 538 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" service delete VBoxVideoW8" 'non-zero-exitcode=log' 539 539 ;misha> @todo driver file removal (as well as service removal) should be done as driver package uninstall 540 540 ; could be done with "VBoxDrvInst.exe /u", e.g. by passing additional arg to it denoting that driver package is to be uninstalled … … 542 542 543 543 ${LogVerbose} "Uninstalling WDDM video driver for Windows Vista and 7..." 544 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" driver uninstall $\"$INSTDIR\VBoxVideoWddm.inf$\"" "true"544 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" driver uninstall $\"$INSTDIR\VBoxVideoWddm.inf$\"" 'non-zero-exitcode=log' 545 545 ; Always try to remove both VBoxVideoWddm & VBoxVideo services no matter what is installed currently 546 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" service delete VBoxVideoWddm" "true"546 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" service delete VBoxVideoWddm" 'non-zero-exitcode=log' 547 547 ;misha> @todo driver file removal (as well as service removal) should be done as driver package uninstall 548 548 ; could be done with "VBoxDrvInst.exe /u", e.g. by passing additional arg to it denoting that driver package is to be uninstalled … … 579 579 ; Remove mouse driver 580 580 ${LogVerbose} "Removing mouse driver ..." 581 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" service delete VBoxMouse" "true"581 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" service delete VBoxMouse" 'non-zero-exitcode=log' 582 582 Delete /REBOOTOK "$g_strSystemDir\drivers\VBoxMouse.sys" 583 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" registry delmultisz $\"SYSTEM\CurrentControlSet\Control\Class\{4D36E96F-E325-11CE-BFC1-08002BE10318}$\" $\"UpperFilters$\" $\"VBoxMouse$\"" "true"583 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" registry delmultisz $\"SYSTEM\CurrentControlSet\Control\Class\{4D36E96F-E325-11CE-BFC1-08002BE10318}$\" $\"UpperFilters$\" $\"VBoxMouse$\"" 'non-zero-exitcode=log' 584 584 585 585 ; Delete the VBoxService service 586 586 Call ${un}StopVBoxService 587 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" service delete VBoxService" "true"587 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" service delete VBoxService" 'non-zero-exitcode=log' 588 588 DeleteRegValue HKLM "Software\Microsoft\Windows\CurrentVersion\Run" "VBoxService" 589 589 Delete /REBOOTOK "$g_strSystemDir\VBoxService.exe" … … 604 604 ; Remove guest driver 605 605 ${LogVerbose} "Removing guest driver ..." 606 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" driver uninstall $\"$INSTDIR\VBoxGuest.inf$\"" "true"607 608 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" service delete VBoxGuest" "true"606 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" driver uninstall $\"$INSTDIR\VBoxGuest.inf$\"" 'non-zero-exitcode=log' 607 608 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" service delete VBoxGuest" 'non-zero-exitcode=log' 609 609 Delete /REBOOTOK "$g_strSystemDir\drivers\VBoxGuest.sys" 610 610 Delete /REBOOTOK "$g_strSystemDir\VBCoInst.dll" ; Deprecated, does not get installed anymore … … 616 616 ; Remove shared folders driver 617 617 ${LogVerbose} "Removing shared folders driver ..." 618 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" netprovider remove VBoxSF" "true"619 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" service delete VBoxSF" "true"618 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" netprovider remove VBoxSF" 'non-zero-exitcode=log' 619 ${CmdExecute} "$\"$INSTDIR\VBoxDrvInst.exe$\" service delete VBoxSF" 'non-zero-exitcode=log' 620 620 Delete /REBOOTOK "$g_strSystemDir\VBoxMRXNP.dll" ; The network provider DLL will be locked 621 621 !if $%KBUILD_TARGET_ARCH% == "amd64"
注意:
瀏覽 TracChangeset
來幫助您使用更動檢視器