summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristophe Fergeau <cfergeau@redhat.com>2015-10-20 14:35:23 +0300
committerChristophe Fergeau <cfergeau@redhat.com>2015-10-21 18:57:19 +0200
commit0b8a02aef486f2aadd9ef5cdfdb8d88472ef9fd2 (patch)
tree2bfe0f53287f1c160244fc74af888133b67eeaa1
parentfc9e403d7bd83f47fb0ead8c2ecce6733fc13968 (diff)
nsis: Install oVirt guest agent
Now that we are able to generate different installers for SPICE and oVirt, we can install the oVirt agent when building an oVirt installer. Change-Id: I63e071262f8dd807cc1dd362e17fc814460c5254 Signed-off-by: Christophe Fergeau <cfergeau@redhat.com>
-rw-r--r--win-guest-tools.nsis28
1 files changed, 28 insertions, 0 deletions
diff --git a/win-guest-tools.nsis b/win-guest-tools.nsis
index 08e2b58..e13a061 100644
--- a/win-guest-tools.nsis
+++ b/win-guest-tools.nsis
@@ -94,6 +94,11 @@ Section "install"
SetOutPath "$INSTDIR"
File "version.txt"
+!ifdef OVIRT
+ File "bin/OVirtGuestService.exe"
+ File "bin/ovirt-guest-agent.ini"
+!endif
+
SetOutPath "$INSTDIR\32"
File "bin/vdagent_x86/vdagent.exe"
File "bin/vdagent_x86/vdservice.exe"
@@ -166,6 +171,10 @@ Section "install"
Push "PCI\VEN_1AF4&DEV_1000&SUBSYS_00011AF4&REV_00"
Call InstallDriver
+!ifdef OVIRT
+ Call InstallOVirtAgentService
+!endif
+
Call InstallVdAgentService
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${REGKEYNAME}" \
@@ -205,8 +214,12 @@ Section "Uninstall"
Delete /rebootok "$INSTDIR\64\vdservice.exe"
RMDir /rebootok "$INSTDIR\64"
RMDir /rebootok /r "$INSTDIR\drivers"
+!ifdef OVIRT
+ RMDir /rebootok "$INSTDIR\OVirtGuestService.exe"
+!endif
RMDir /rebootok "$INSTDIR"
+
DeleteRegKey HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${REGKEYNAME}"
SectionEnd
@@ -321,6 +334,10 @@ Function ${un}StopServices
push "BalloonService"
Call ${un}StopService
+!ifdef OVIRT
+ push "OVirtGuestService"
+ Call ${un}StopService
+!endif
FunctionEnd
!macroend
@@ -392,6 +409,17 @@ Function InstallVdAgentService
FunctionEnd
+!ifdef OVIRT
+Function InstallOVirtAgentService
+ StrCpy $0 "$INSTDIR\OVirtGuestService.exe"
+
+ push "OVirt Guest Service"
+ push $0
+ push "OVirtGuestService"
+ Call InstallService
+FunctionEnd
+!endif
+
Function InstallBalloonService
Push "Balloon"
Call GetDriverSubdir