Changeset 35651 in vbox for trunk/src/VBox
- Timestamp:
- Jan 20, 2011 2:15:49 PM (14 years ago)
- Location:
- trunk/src/VBox/Additions/WINNT/Installer
- Files:
-
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Additions/WINNT/Installer/Makefile.kmk
r35579 r35651 178 178 -E 'PATH_TARGET_X86=$(subst /,\,$(PATH_OUT_BASE)/win.x86/$(KBUILD_TYPE)/obj)' \ 179 179 -E 'VBOX_PATH_ADDITIONS_WIN_X86=$(subst /,\,$(VBOX_PATH_ADDITIONS.win.x86))' \ 180 -E 'VBOX_PATH_DIFX=$(subst /,\,$(VBOX_PATH_DIFX))' \ 180 181 -E 'VBOX_VENDOR=$(VBOX_VENDOR)' \ 181 182 -E 'VBOX_VENDOR_SHORT=$(VBOX_VENDOR_SHORT)' \ -
trunk/src/VBox/Additions/WINNT/Installer/VBoxGuestAdditions.nsi
r35365 r35651 2 2 !if $%BUILD_TYPE% == "debug" 3 3 !define _DEBUG ; Turn this on to get extra output 4 !endif 5 6 !ifdef _DEBUG 7 ; Scratch directory for plugin tests 8 !addincludedir .\PluginTest 9 !addplugindir .\PluginTest 4 10 !endif 5 11 … … 555 561 !endif 556 562 563 FILE "$%VBOX_PATH_DIFX%\DIFxAPI.dll" 557 564 FILE "$%PATH_OUT%\bin\additions\VBoxDrvInst.exe" 558 565 … … 636 643 Call Common_CopyFiles 637 644 638 Call NT _Main645 Call NT4_Main 639 646 goto success 640 647 !endif -
trunk/src/VBox/Additions/WINNT/Installer/VBoxGuestAdditionsCommon.nsh
r35365 r35651 66 66 ; WDDM Video driver 67 67 SetOutPath "$0\VBoxVideoWddm" 68 68 69 69 !ifdef VBOX_SIGN_ADDITIONS 70 70 FILE "$%PATH_OUT%\bin\additions\VBoxVideoWddm.cat" … … 86 86 FILE "$%PATH_OUT%\bin\additions\wined3dwddm.dll" 87 87 !endif ; $%VBOX_WITH_CROGL% == "1" 88 88 89 89 !if $%BUILD_TARGET_ARCH% == "amd64" 90 90 FILE "$%PATH_OUT%\bin\additions\VBoxDispD3D-x86.dll" … … 155 155 SetOutPath "$0\Tools" 156 156 FILE "$%PATH_OUT%\bin\additions\VBoxDrvInst.exe" 157 FILE "$%VBOX_PATH_DIFX%\DIFxAPI.dll" 157 158 158 159 !if $%BUILD_TARGET_ARCH% == "x86" -
trunk/src/VBox/Additions/WINNT/Installer/VBoxGuestAdditionsNT4.nsh
r34099 r35651 1 1 2 Function NT _SetVideoResolution2 Function NT4_SetVideoResolution 3 3 4 4 ; Check for all required parameters … … 10 10 missingParms: 11 11 12 DetailPrint "Missing display parameters for NT , setting default (640x480, 8 BPP) ..."12 DetailPrint "Missing display parameters for NT4, setting default (640x480, 8 BPP) ..." 13 13 14 14 StrCpy $g_iScreenX '640' ; Default value … … 21 21 haveParms: 22 22 23 DetailPrint "Setting display parameters for NT ($g_iScreenXx$g_iScreenY, $g_iScreenBpp BPP) ..."23 DetailPrint "Setting display parameters for NT4 ($g_iScreenXx$g_iScreenY, $g_iScreenBpp BPP) ..." 24 24 25 25 WriteRegDWORD HKLM "SYSTEM\CurrentControlSet\Hardware Profiles\Current\System\CurrentControlSet\Services\vboxvideo\Device0" "DefaultSettings.BitsPerPel" $g_iScreenBpp … … 33 33 FunctionEnd 34 34 35 Function NT _SaveMouseDriverInfo35 Function NT4_SaveMouseDriverInfo 36 36 37 37 Push $0 … … 72 72 FunctionEnd 73 73 74 Function NT _Prepare74 Function NT4_Prepare 75 75 76 76 ${If} $g_bNoVBoxServiceExit == "false" … … 92 92 FunctionEnd 93 93 94 Function NT _CopyFiles95 96 DetailPrint "Copying files ..."94 Function NT4_CopyFiles 95 96 DetailPrint "Copying files for NT4 ..." 97 97 98 98 SetOutPath "$INSTDIR" … … 119 119 FunctionEnd 120 120 121 Function NT _InstallFiles122 123 DetailPrint "Installing Drivers..."121 Function NT4_InstallFiles 122 123 DetailPrint "Installing drivers for NT4 ..." 124 124 125 125 ; Install guest driver 126 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" /createsvc"VBoxGuest" "VBoxGuest Support Driver" 1 1 "$SYSDIR\drivers\VBoxGuestNT.sys" "Base"'126 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" service create "VBoxGuest" "VBoxGuest Support Driver" 1 1 "$SYSDIR\drivers\VBoxGuestNT.sys" "Base"' 127 127 128 128 ; Bugfix: Set "Start" to 1, otherwise, VBoxGuest won't start on boot-up! … … 143 143 ; Create the VBoxService service 144 144 ; No need to stop/remove the service here! Do this only on uninstallation! 145 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" /createsvc"VBoxService" "VirtualBox Guest Additions Service" 16 2 "system32\VBoxServiceNT.exe" "Base"'145 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" service create "VBoxService" "VirtualBox Guest Additions Service" 16 2 "system32\VBoxServiceNT.exe" "Base"' 146 146 147 147 ; Create the Shared Folders service ... … … 161 161 162 162 ; Add the shared folders network provider 163 ;nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" /addnetproviderVBoxSF'163 ;nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" netprovider add VBoxSF' 164 164 ;Pop $0 ; Ret value 165 166 !ifdef _DEBUG167 ;DetailPrint "VBoxDrvInst::AddProvider VBoxSF: $0"168 !endif169 170 165 ;IntCmp $0 0 +1 error error ; Check ret value (0=OK, 1=Error) 171 166 … … 173 168 174 169 error: 175 Abort "ERROR: Could not install files for Windows NT ! Installation aborted."170 Abort "ERROR: Could not install files for Windows NT4! Installation aborted." 176 171 177 172 done: … … 179 174 FunctionEnd 180 175 181 Function NT _Main176 Function NT4_Main 182 177 183 178 SetOutPath "$INSTDIR" 184 179 185 Call NT _Prepare186 Call NT _CopyFiles180 Call NT4_Prepare 181 Call NT4_CopyFiles 187 182 188 183 ; This removes the flag "new display driver installed on the next bootup 189 184 WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\RunOnce" "VBoxGuestInst" '"$INSTDIR\RegCleanup.exe"' 190 185 191 Call NT _SaveMouseDriverInfo192 Call NT _InstallFiles193 Call NT _SetVideoResolution186 Call NT4_SaveMouseDriverInfo 187 Call NT4_InstallFiles 188 Call NT4_SetVideoResolution 194 189 195 190 ; Write mouse driver name to registry overwriting the default name … … 198 193 FunctionEnd 199 194 200 !macro NT _UninstallInstDir un201 Function ${un}NT _UninstallInstDir195 !macro NT4_UninstallInstDir un 196 Function ${un}NT4_UninstallInstDir 202 197 203 198 ; Delete remaining files … … 207 202 FunctionEnd 208 203 !macroend 209 !insertmacro NT _UninstallInstDir ""210 !insertmacro NT _UninstallInstDir "un."211 212 !macro NT _Uninstall un213 Function ${un}NT _Uninstall204 !insertmacro NT4_UninstallInstDir "" 205 !insertmacro NT4_UninstallInstDir "un." 206 207 !macro NT4_Uninstall un 208 Function ${un}NT4_Uninstall 214 209 215 210 Push $0 216 211 217 212 ; Remove the guest driver service 218 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" /delsvcVBoxGuest'213 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" service delete VBoxGuest' 219 214 Delete /REBOOTOK "$SYSDIR\drivers\VBoxGuestNT.sys" 220 215 221 216 ; Delete the VBoxService service 222 217 Call ${un}StopVBoxService 223 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" /delsvcVBoxService'218 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" service delete VBoxService' 224 219 Pop $0 ; Ret value 225 220 DeleteRegValue HKLM "Software\Microsoft\Windows\CurrentVersion\Run" "VBoxService" … … 230 225 DeleteRegValue HKLM "Software\Microsoft\Windows\CurrentVersion\Run" "VBoxTray" 231 226 WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\RunOnce" "VBoxTrayDel" "$SYSDIR\cmd.exe /c del /F /Q $SYSDIR\VBoxTray.exe" 232 Delete /REBOOTOK "$SYSDIR\VBoxTray.exe" 227 Delete /REBOOTOK "$SYSDIR\VBoxTray.exe" ; If it can't be removed cause it's running, try next boot with "RunOnce" key above! 233 228 Delete /REBOOTOK "$SYSDIR\VBoxHook.dll" 234 229 … … 237 232 238 233 ; Delete the VBoxVideo service 239 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" /delsvcVBoxVideo'234 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" service delete VBoxVideo' 240 235 241 236 ; Delete the VBox video driver files … … 259 254 FunctionEnd 260 255 !macroend 261 !insertmacro NT _Uninstall ""262 !insertmacro NT _Uninstall "un."256 !insertmacro NT4_Uninstall "" 257 !insertmacro NT4_Uninstall "un." -
trunk/src/VBox/Additions/WINNT/Installer/VBoxGuestAdditionsUninstall.nsh
r34677 r35651 1 2 ; @todo Replace this crappy stuff with a "VBoxDrvInst /delnetprovider"3 !macro RemoveFromProvider un4 Function ${un}RemoveFromProvider5 Exch $06 Push $17 Push $28 Push $39 Push $410 Push $511 Push $612 13 ReadRegStr $1 HKLM "$R0" "ProviderOrder"14 StrCpy $5 $1 1 -1 # copy last char15 StrCmp $5 "," +2 # if last char != ,16 StrCpy $1 "$1," # append ,17 Push $118 Push "$0,"19 Call ${un}StrStr ; Find `$0,` in $120 Pop $2 ; pos of our dir21 StrCmp $2 "" unRemoveFromPath_done22 ; else, it is in path23 # $0 - path to add24 # $1 - path var25 StrLen $3 "$0,"26 StrLen $4 $227 StrCpy $5 $1 -$4 # $5 is now the part before the path to remove28 StrCpy $6 $2 "" $3 # $6 is now the part after the path to remove29 StrCpy $3 $5$630 31 StrCpy $5 $3 1 -1 # copy last char32 StrCmp $5 "," 0 +2 # if last char == ,33 StrCpy $3 $3 -1 # remove last char34 35 WriteRegStr HKLM "$R0" "ProviderOrder" $336 37 unRemoveFromPath_done:38 Pop $639 Pop $540 Pop $441 Pop $342 Pop $243 Pop $144 Pop $045 FunctionEnd46 !macroend47 !insertmacro RemoveFromProvider ""48 !insertmacro RemoveFromProvider "un."49 50 !macro RemoveProvider un51 Function ${un}RemoveProvider52 Push $R053 StrCpy $R0 "VBoxSF"54 Push $R055 StrCpy $R0 "SYSTEM\CurrentControlSet\Control\NetworkProvider\HWOrder"56 Call ${un}RemoveFromProvider57 StrCpy $R0 "VBoxSF"58 Push $R059 StrCpy $R0 "SYSTEM\CurrentControlSet\Control\NetworkProvider\Order"60 Call ${un}RemoveFromProvider61 Pop $R062 FunctionEnd63 !macroend64 !insertmacro RemoveProvider ""65 !insertmacro RemoveProvider "un."66 1 67 2 !macro UninstallCommon un … … 74 9 ; Remove common files 75 10 Delete /REBOOTOK "$INSTDIR\VBoxDrvInst.exe" 11 Delete /REBOOTOK "$INSTDIR\DIFxAPI.dll" 76 12 77 13 Delete /REBOOTOK "$INSTDIR\VBoxVideo.inf" -
trunk/src/VBox/Additions/WINNT/Installer/VBoxGuestAdditionsVista.nsh
r31864 r35651 19 19 20 20 SetOutPath "$INSTDIR" 21 22 ; VBoxNET drivers are not tested yet - commented out until officially supported and released 23 ;nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" /i "PCI\VEN_1022&DEV_2000&SUBSYS_20001022&REV_40" "$INSTDIR\VBoxNET.inf" "Net"' 24 ;Pop $0 ; Ret value 25 ;IntCmp $0 0 +1 error error ; Check ret value (0=OK, 1=Error) 26 ;Goto done 27 21 ; Nothing here yet 28 22 Goto done 29 23 … … 64 58 Delete /REBOOTOK "$g_strSystemDir\VBoxCredProv.dll" 65 59 66 !if $%BUILD_TARGET_ARCH% == "x86" ; 32-bit67 ; Remove network card driver68 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" /u "PCI\VEN_1022&DEV_2000&SUBSYS_20001022&REV_40"'69 Pop $0 ; Ret value70 ; @todo Add error handling here!71 !endif72 73 60 FunctionEnd 74 61 !macroend -
trunk/src/VBox/Additions/WINNT/Installer/VBoxGuestAdditionsW2KXP.nsh
r35365 r35651 26 26 ; Or: \Registry\Machine\System\CurrentControlSet\Control\Video\vboxvideo\Device0 27 27 ; Result: Machine\System\CurrentControlSet\Control\Video\{28B74D2B-F0A9-48E0-8028-D76F6BB1AE65}\0000 28 Push "$tmp" 29 Push "\" 30 Push ">" 31 Push ">" 32 Push "0" 33 Push "2" 34 Push "0" 28 Push "$tmp" ; String 29 Push "\" ; SubString 30 Push ">" ; SearchDirection 31 Push ">" ; StrInclusionDirection 32 Push "0" ; IncludeSubString 33 Push "2" ; Loops 34 Push "0" ; CaseSensitive 35 35 Call StrStrAdv 36 Pop $tmppath 36 Pop $tmppath ; $1 only contains the full path 37 37 StrCmp $tmppath "" dev_not_found 38 38 … … 112 112 113 113 ; Write the new value in the adapter config (VBoxVideo.sys) using hex values in binary format 114 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" /registry write HKLM $reg_path_device CustomXRes REG_BIN $g_iScreenX DWORD'115 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" /registry write HKLM $reg_path_device CustomYRes REG_BIN $g_iScreenY DWORD'116 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" /registry write HKLM $reg_path_device CustomBPP REG_BIN $g_iScreenBpp DWORD'114 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" registry write HKLM $reg_path_device CustomXRes REG_BIN $g_iScreenX DWORD' 115 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" registry write HKLM $reg_path_device CustomYRes REG_BIN $g_iScreenY DWORD' 116 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" registry write HKLM $reg_path_device CustomBPP REG_BIN $g_iScreenBpp DWORD' 117 117 118 118 ; ... and tell Windows to use that mode on next start! … … 177 177 FILE "$%PATH_OUT%\bin\additions\VBCoInst.dll" 178 178 FILE "$%PATH_OUT%\bin\additions\VBoxTray.exe" 179 FILE "$%PATH_OUT%\bin\additions\VBoxControl.exe" 179 FILE "$%PATH_OUT%\bin\additions\VBoxControl.exe" ; Not used by W2K and up, but required by the .INF file 180 180 181 181 ; WHQL fake … … 193 193 ; WDDM Video driver 194 194 SetOutPath "$INSTDIR" 195 195 196 196 !ifdef VBOX_SIGN_ADDITIONS 197 197 FILE "$%PATH_OUT%\bin\additions\VBoxVideoWddm.cat" … … 213 213 FILE "$%PATH_OUT%\bin\additions\wined3dwddm.dll" 214 214 !endif ; $%VBOX_WITH_CROGL% == "1" 215 215 216 216 !if $%BUILD_TARGET_ARCH% == "amd64" 217 217 FILE "$%PATH_OUT%\bin\additions\VBoxDispD3D-x86.dll" … … 230 230 !endif ; $%VBOX_WITH_CROGL% == "1" 231 231 !endif ; $%BUILD_TARGET_ARCH% == "amd64" 232 232 233 233 Goto doneCr 234 234 ${EndIf} … … 323 323 DetailPrint "Installing Drivers..." 324 324 325 Push $0 ; For fetching results 326 325 327 drv_video: 326 328 … … 329 331 ${If} $g_bWithWDDM == "true" 330 332 DetailPrint "Installing WDDM video driver ..." 331 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" /i "PCI\VEN_80EE&DEV_BEEF&SUBSYS_00000000&REV_00" "$INSTDIR\VBoxVideoWddm.inf" "Display"'333 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" driver install "$INSTDIR\VBoxVideoWddm.inf"' 332 334 ${Else} 333 335 DetailPrint "Installing video driver ..." 334 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" /i "PCI\VEN_80EE&DEV_BEEF&SUBSYS_00000000&REV_00" "$INSTDIR\VBoxVideo.inf" "Display"'335 ${EndIf} 336 Pop $0 336 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" driver install "$INSTDIR\VBoxVideo.inf"' 337 ${EndIf} 338 Pop $0 ; Ret value 337 339 LogText "Video driver result: $0" 338 IntCmp $0 0 +1 error error 340 IntCmp $0 0 +1 error error ; Check ret value (0=OK, 1=Error) 339 341 340 342 drv_guest: … … 342 344 StrCmp $g_bNoGuestDrv "true" drv_mouse 343 345 DetailPrint "Installing guest driver ..." 344 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" /i "PCI\VEN_80EE&DEV_CAFE&SUBSYS_00000000&REV_00" "$INSTDIR\VBoxGuest.inf" "Media"'345 Pop $0 346 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" driver install "$INSTDIR\VBoxGuest.inf"' 347 Pop $0 ; Ret value 346 348 LogText "Guest driver result: $0" 347 349 IntCmp $0 0 +1 error error ; Check ret value (0=OK, 1=Error) … … 351 353 StrCmp $g_bNoMouseDrv "true" vbox_service 352 354 DetailPrint "Installing mouse filter ..." 353 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" /inf "$INSTDIR\VBoxMouse.inf"' 354 Pop $0 ; Ret value 355 ; The mouse filter does not contain any device IDs but a "DefaultInstall" section; 356 ; so this .INF file needs to be installed using "InstallHinfSection" which is implemented 357 ; with VBoxDrvInst's "driver executeinf" routine 358 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" driver executeinf "$INSTDIR\VBoxMouse.inf"' 359 Pop $0 ; Ret value 355 360 LogText "Mouse driver returned: $0" 356 361 IntCmp $0 0 +1 error error ; Check ret value (0=OK, 1=Error) … … 362 367 ; Create the VBoxService service 363 368 ; No need to stop/remove the service here! Do this only on uninstallation! 364 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" /createsvc"VBoxService" "VirtualBox Guest Additions Service" 16 2 "system32\VBoxService.exe" "Base"'365 Pop $0 369 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" service create "VBoxService" "VirtualBox Guest Additions Service" 16 2 "system32\VBoxService.exe" "Base"' 370 Pop $0 ; Ret value 366 371 LogText "VBoxService returned: $0" 367 372 … … 375 380 ; Create the Shared Folders service ... 376 381 ; No need to stop/remove the service here! Do this only on uninstallation! 377 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" /createsvc"VBoxSF" "VirtualBox Shared Folders" 2 1 "system32\drivers\VBoxSF.sys" "NetworkProvider"'382 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" service create "VBoxSF" "VirtualBox Shared Folders" 2 1 "system32\drivers\VBoxSF.sys" "NetworkProvider"' 378 383 379 384 ; ... and the link to the network provider … … 383 388 384 389 ; Add default network providers (if not present or corrupted) 385 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" /addnetproviderWebClient'386 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" /addnetproviderLanmanWorkstation'387 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" /addnetproviderRDPNP'390 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" netprovider add WebClient' 391 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" netprovider add LanmanWorkstation' 392 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" netprovider add RDPNP' 388 393 389 394 ; Add the shared folders network provider 390 395 DetailPrint "Adding network provider (Order = $g_iSfOrder) ..." 391 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" /addnetproviderVBoxSF $g_iSfOrder'392 Pop $0 396 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" netprovider add VBoxSF $g_iSfOrder' 397 Pop $0 ; Ret value 393 398 IntCmp $0 0 +1 error error ; Check ret value (0=OK, 1=Error) 394 399 … … 427 432 done: 428 433 434 Pop $0 435 429 436 FunctionEnd 430 437 … … 472 479 Delete /REBOOTOK "$INSTDIR\VBoxControl.exe" 473 480 Delete /REBOOTOK "$INSTDIR\VBoxService.exe" ; File from an older installation maybe, not present here anymore 474 481 475 482 !if $%VBOX_WITH_WDDM% == "1" 476 483 Delete /REBOOTOK "$%PATH_OUT%\bin\additions\VBoxVideoWddm.cat" … … 489 496 Delete /REBOOTOK "$%PATH_OUT%\bin\additions\VBoxD3D9wddm.dll" 490 497 Delete /REBOOTOK "$%PATH_OUT%\bin\additions\wined3dwddm.dll" 491 ; try to delete libWine in case it is there from old installation498 ; Try to delete libWine in case it is there from old installation 492 499 Delete /REBOOTOK "$%PATH_OUT%\bin\additions\libWine.dll" 493 500 494 501 !if $%BUILD_TARGET_ARCH% == "amd64" 495 502 Delete /REBOOTOK "$%PATH_OUT%\bin\additions\VBoxDispD3D-x86.dll" … … 527 534 Push $0 528 535 529 ; Remove VirtualBox graphics adapter & PCI base drivers 530 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" /u "PCI\VEN_80EE&DEV_BEEF&SUBSYS_00000000&REV_00"' 531 Pop $0 ; Ret value 536 ; Remove VirtualBox video driver 537 DetailPrint "Uninstalling video driver ..." 538 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" driver uninstall "$INSTDIR\VBoxVideo.inf' 539 Pop $0 ; Ret value 532 540 ; @todo Add error handling here! 533 534 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" /u "PCI\VEN_80EE&DEV_CAFE&SUBSYS_00000000&REV_00"' 535 Pop $0 ; Ret value 536 ; @todo Add error handling here! 537 538 ; @todo restore old drivers 541 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" service delete VBoxVideo' 542 Delete /REBOOTOK "$g_strSystemDir\drivers\VBoxVideo.sys" 543 Delete /REBOOTOK "$g_strSystemDir\VBoxDisp.dll" 539 544 540 545 ; Remove video driver 541 546 !if $%VBOX_WITH_WDDM% == "1" 542 ; always try to remove both VBoxVideoWddm & VBoxVideo services no matter what is installed currently 543 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" /delsvc VBoxVideoWddm' 547 DetailPrint "Uninstalling WDDM video driver ..." 548 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" driver install "$INSTDIR\VBoxVideoWddm.inf"' 549 Pop $0 ; Ret value 550 ; Always try to remove both VBoxVideoWddm & VBoxVideo services no matter what is installed currently 551 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" service delete VBoxVideoWddm' 552 Pop $0 ; Ret value 544 553 ;misha> @todo driver file removal (as well as service removal) should be done as driver package uninstall 545 ; could be done with "VBoxDrvInst.exe /u", e.g. by passing additional arg to it denoting that driver package is to be uninstalled 554 ; could be done with "VBoxDrvInst.exe /u", e.g. by passing additional arg to it denoting that driver package is to be uninstalled 546 555 Delete /REBOOTOK "$g_strSystemDir\drivers\VBoxVideoWddm.sys" 547 556 Delete /REBOOTOK "$g_strSystemDir\VBoxDispD3D.dll" 548 557 !endif ; $%VBOX_WITH_WDDM% == "1" 549 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" /delsvc VBoxVideo'550 Delete /REBOOTOK "$g_strSystemDir\drivers\VBoxVideo.sys"551 Delete /REBOOTOK "$g_strSystemDir\VBoxDisp.dll"552 553 ; Remove mouse driver554 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" /delsvc VBoxMouse'555 Pop $0 ; Ret value556 Delete /REBOOTOK "$g_strSystemDir\drivers\VBoxMouse.sys"557 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" /reg_delmultisz "SYSTEM\CurrentControlSet\Control\Class\{4D36E96F-E325-11CE-BFC1-08002BE10318}" "UpperFilters" "VBoxMouse"'558 Pop $0 ; Ret value559 ; @todo Add error handling here!560 561 ; Delete the VBoxService service562 Call ${un}StopVBoxService563 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" /delsvc VBoxService'564 Pop $0 ; Ret value565 DeleteRegValue HKLM "Software\Microsoft\Windows\CurrentVersion\Run" "VBoxService"566 Delete /REBOOTOK "$g_strSystemDir\VBoxService.exe"567 568 ; GINA569 Delete /REBOOTOK "$g_strSystemDir\VBoxGINA.dll"570 ReadRegStr $0 HKLM "SOFTWARE\Microsoft\Windows NT\CurrentVersion\WinLogon" "GinaDLL"571 ${If} $0 == "VBoxGINA.dll"572 DeleteRegValue HKLM "SOFTWARE\Microsoft\Windows NT\CurrentVersion\WinLogon" "GinaDLL"573 ${EndIf}574 575 ; Delete VBoxTray576 Call ${un}StopVBoxTray577 DeleteRegValue HKLM "Software\Microsoft\Windows\CurrentVersion\Run" "VBoxTray"578 579 ; Remove guest driver580 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" /delsvc VBoxGuest'581 Pop $0 ; Ret value582 Delete /REBOOTOK "$g_strSystemDir\drivers\VBoxGuest.sys"583 Delete /REBOOTOK "$g_strSystemDir\vbcoinst.dll"584 Delete /REBOOTOK "$g_strSystemDir\VBoxTray.exe"585 Delete /REBOOTOK "$g_strSystemDir\VBoxHook.dll"586 DeleteRegValue HKLM "Software\Microsoft\Windows\CurrentVersion\Run" "VBoxTray" ; Remove VBoxTray autorun587 Delete /REBOOTOK "$g_strSystemDir\VBoxControl.exe"588 589 ; Remove shared folders driver590 call ${un}RemoveProvider ; Remove Shared Folders network provider from registry591 ; @todo Add a /delnetprovider to VBoxDrvInst for doing this job!592 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" /delsvc VBoxSF'593 Delete /REBOOTOK "$g_strSystemDir\VBoxMRXNP.dll" ; The network provider DLL will be locked594 Delete /REBOOTOK "$g_strSystemDir\drivers\VBoxSF.sys"595 558 596 559 !if $%VBOX_WITH_CROGL% == "1" … … 667 630 !endif ; VBOX_WITH_CROGL 668 631 632 ; Remove mouse driver 633 DetailPrint "Removing mouse driver ..." 634 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" service delete VBoxMouse' 635 Pop $0 ; Ret value 636 Delete /REBOOTOK "$g_strSystemDir\drivers\VBoxMouse.sys" 637 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" registry delmultisz "SYSTEM\CurrentControlSet\Control\Class\{4D36E96F-E325-11CE-BFC1-08002BE10318}" "UpperFilters" "VBoxMouse"' 638 Pop $0 ; Ret value 639 ; @todo Add error handling here! 640 641 ; Delete the VBoxService service 642 Call ${un}StopVBoxService 643 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" service delete VBoxService' 644 Pop $0 ; Ret value 645 DeleteRegValue HKLM "Software\Microsoft\Windows\CurrentVersion\Run" "VBoxService" 646 Delete /REBOOTOK "$g_strSystemDir\VBoxService.exe" 647 648 ; GINA 649 Delete /REBOOTOK "$g_strSystemDir\VBoxGINA.dll" 650 ReadRegStr $0 HKLM "SOFTWARE\Microsoft\Windows NT\CurrentVersion\WinLogon" "GinaDLL" 651 ${If} $0 == "VBoxGINA.dll" 652 DetailPrint "Removing GINA ..." 653 DeleteRegValue HKLM "SOFTWARE\Microsoft\Windows NT\CurrentVersion\WinLogon" "GinaDLL" 654 ${EndIf} 655 656 ; Delete VBoxTray 657 Call ${un}StopVBoxTray 658 DeleteRegValue HKLM "Software\Microsoft\Windows\CurrentVersion\Run" "VBoxTray" 659 660 ; Remove guest driver 661 DetailPrint "Removing guest driver ..." 662 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" driver uninstall "$INSTDIR\VBoxGuest.inf"' 663 Pop $0 ; Ret value 664 ; @todo Add error handling here! 665 666 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" service delete VBoxGuest' 667 Pop $0 ; Ret value 668 Delete /REBOOTOK "$g_strSystemDir\drivers\VBoxGuest.sys" 669 Delete /REBOOTOK "$g_strSystemDir\vbcoinst.dll" 670 Delete /REBOOTOK "$g_strSystemDir\VBoxTray.exe" 671 Delete /REBOOTOK "$g_strSystemDir\VBoxHook.dll" 672 DeleteRegValue HKLM "Software\Microsoft\Windows\CurrentVersion\Run" "VBoxTray" ; Remove VBoxTray autorun 673 Delete /REBOOTOK "$g_strSystemDir\VBoxControl.exe" 674 675 ; Remove shared folders driver 676 DetailPrint "Removing shared folders driver ..." 677 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" netprovider remove VBoxSF' 678 Pop $0 ; Ret value 679 nsExec::ExecToLog '"$INSTDIR\VBoxDrvInst.exe" service delete VBoxSF' 680 Pop $0 ; Ret value 681 Delete /REBOOTOK "$g_strSystemDir\VBoxMRXNP.dll" ; The network provider DLL will be locked 682 Delete /REBOOTOK "$g_strSystemDir\drivers\VBoxSF.sys" 683 669 684 Pop $0 670 685
Note:
See TracChangeset
for help on using the changeset viewer.