Fix qga installer
resolves: rhbz#2167436 Signed-off-by: Konstantin Kostiuk <kkostiuk@redhat.com>
This commit is contained in:
parent
79f0389086
commit
93dff1df22
@ -14,6 +14,6 @@ index 91ff57278e..586de296f5 100644
|
||||
+++ b/VERSION
|
||||
@@ -1 +1 @@
|
||||
-7.1.0
|
||||
+105.0.3
|
||||
+105.0.4
|
||||
--
|
||||
2.17.2
|
||||
|
27
0001-qga-win-Remove-change-action-from-MSI-installer.patch
Normal file
27
0001-qga-win-Remove-change-action-from-MSI-installer.patch
Normal file
@ -0,0 +1,27 @@
|
||||
From c84142bfb7021a09c862127dbcd67c7f659d7c40 Mon Sep 17 00:00:00 2001
|
||||
From: Konstantin Kostiuk <kkostiuk@redhat.com>
|
||||
Date: Wed, 8 Feb 2023 17:23:18 +0200
|
||||
Subject: [PATCH 1/2] qga/win: Remove change action from MSI installer
|
||||
|
||||
resolves: rhbz#2167436
|
||||
|
||||
Signed-off-by: Konstantin Kostiuk <kkostiuk@redhat.com>
|
||||
---
|
||||
qga/installer/qemu-ga.wxs | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/qga/installer/qemu-ga.wxs b/qga/installer/qemu-ga.wxs
|
||||
index 51340f7ecc..feb629ec47 100644
|
||||
--- a/qga/installer/qemu-ga.wxs
|
||||
+++ b/qga/installer/qemu-ga.wxs
|
||||
@@ -31,6 +31,7 @@
|
||||
/>
|
||||
<Media Id="1" Cabinet="qemu_ga.$(var.QEMU_GA_VERSION).cab" EmbedCab="yes" />
|
||||
<Property Id="WHSLogo">1</Property>
|
||||
+ <Property Id="ARPNOMODIFY" Value="yes" Secure="yes" />
|
||||
<MajorUpgrade
|
||||
DowngradeErrorMessage="Error: A newer version of QEMU guest agent is already installed."
|
||||
/>
|
||||
--
|
||||
2.25.1
|
||||
|
85
0002-qga-win32-Use-rundll-for-VSS-installation.patch
Normal file
85
0002-qga-win32-Use-rundll-for-VSS-installation.patch
Normal file
@ -0,0 +1,85 @@
|
||||
From 66d7a1b76c052cdf45d30074b6f1dacc456827d1 Mon Sep 17 00:00:00 2001
|
||||
From: Konstantin Kostiuk <kkostiuk@redhat.com>
|
||||
Date: Mon, 13 Feb 2023 17:45:51 +0200
|
||||
Subject: [PATCH 2/2] qga/win32: Use rundll for VSS installation
|
||||
|
||||
Add specific an entry points for rundll which is
|
||||
just a wrapper for COMRegister/COMUnregister functions.
|
||||
|
||||
resolves: rhbz#2167436
|
||||
|
||||
Signed-off-by: Konstantin Kostiuk <kkostiuk@redhat.com>
|
||||
---
|
||||
qga/installer/qemu-ga.wxs | 10 +++++-----
|
||||
qga/vss-win32/install.cpp | 9 +++++++++
|
||||
qga/vss-win32/qga-vss.def | 2 ++
|
||||
3 files changed, 16 insertions(+), 5 deletions(-)
|
||||
|
||||
diff --git a/qga/installer/qemu-ga.wxs b/qga/installer/qemu-ga.wxs
|
||||
index feb629ec47..46ae9e7a13 100644
|
||||
--- a/qga/installer/qemu-ga.wxs
|
||||
+++ b/qga/installer/qemu-ga.wxs
|
||||
@@ -127,22 +127,22 @@
|
||||
</Directory>
|
||||
</Directory>
|
||||
|
||||
- <Property Id="cmd" Value="cmd.exe"/>
|
||||
+ <Property Id="rundll" Value="rundll32.exe"/>
|
||||
<Property Id="REINSTALLMODE" Value="amus"/>
|
||||
|
||||
<?ifdef var.InstallVss?>
|
||||
<CustomAction Id="RegisterCom"
|
||||
- ExeCommand='/c "[qemu_ga_directory]qemu-ga.exe" -s vss-install'
|
||||
+ ExeCommand='"[qemu_ga_directory]qga-vss.dll",DLLCOMRegister'
|
||||
Execute="deferred"
|
||||
- Property="cmd"
|
||||
+ Property="rundll"
|
||||
Impersonate="no"
|
||||
Return="check"
|
||||
>
|
||||
</CustomAction>
|
||||
<CustomAction Id="UnRegisterCom"
|
||||
- ExeCommand='/c "[qemu_ga_directory]qemu-ga.exe" -s vss-uninstall'
|
||||
+ ExeCommand='"[qemu_ga_directory]qga-vss.dll",DLLCOMUnregister'
|
||||
Execute="deferred"
|
||||
- Property="cmd"
|
||||
+ Property="rundll"
|
||||
Impersonate="no"
|
||||
Return="check"
|
||||
>
|
||||
diff --git a/qga/vss-win32/install.cpp b/qga/vss-win32/install.cpp
|
||||
index b57508fbe0..68662a6dfc 100644
|
||||
--- a/qga/vss-win32/install.cpp
|
||||
+++ b/qga/vss-win32/install.cpp
|
||||
@@ -357,6 +357,15 @@ out:
|
||||
return hr;
|
||||
}
|
||||
|
||||
+STDAPI_(void) CALLBACK DLLCOMRegister(HWND, HINSTANCE, LPSTR, int)
|
||||
+{
|
||||
+ COMRegister();
|
||||
+}
|
||||
+
|
||||
+STDAPI_(void) CALLBACK DLLCOMUnregister(HWND, HINSTANCE, LPSTR, int)
|
||||
+{
|
||||
+ COMUnregister();
|
||||
+}
|
||||
|
||||
static BOOL CreateRegistryKey(LPCTSTR key, LPCTSTR value, LPCTSTR data)
|
||||
{
|
||||
diff --git a/qga/vss-win32/qga-vss.def b/qga/vss-win32/qga-vss.def
|
||||
index 927782c31b..ee97a81427 100644
|
||||
--- a/qga/vss-win32/qga-vss.def
|
||||
+++ b/qga/vss-win32/qga-vss.def
|
||||
@@ -1,6 +1,8 @@
|
||||
LIBRARY "QGA-PROVIDER.DLL"
|
||||
|
||||
EXPORTS
|
||||
+ DLLCOMRegister
|
||||
+ DLLCOMUnregister
|
||||
COMRegister PRIVATE
|
||||
COMUnregister PRIVATE
|
||||
DllCanUnloadNow PRIVATE
|
||||
--
|
||||
2.25.1
|
||||
|
@ -6,7 +6,7 @@
|
||||
%define ga_distro "RHEL"
|
||||
|
||||
Name: mingw-qemu-ga-win
|
||||
Version: 105.0.3
|
||||
Version: 105.0.4
|
||||
Release: 1%{?dist}
|
||||
Summary: Qemus Guest agent for Windows
|
||||
|
||||
@ -20,6 +20,8 @@ Source0: http://wiki.qemu.org/download/qemu-%{qemu_version}.tar.bz2
|
||||
|
||||
Patch0001: 0001-Change-Version.patch
|
||||
Patch0002: 0002-qga-win-usb-support.patch
|
||||
Patch0003: 0001-qga-win-Remove-change-action-from-MSI-installer.patch
|
||||
Patch0004: 0002-qga-win32-Use-rundll-for-VSS-installation.patch
|
||||
|
||||
BuildArch: noarch
|
||||
|
||||
@ -64,6 +66,8 @@ This package does not need to be installed on the host OS.
|
||||
%setup -q -n qemu-%{qemu_version}
|
||||
%patch0001 -p1
|
||||
%patch0002 -p1
|
||||
%patch0003 -p1
|
||||
%patch0004 -p1
|
||||
|
||||
%build
|
||||
|
||||
@ -118,6 +122,10 @@ cp build/qga/qemu-ga-x86_64.msi $RPM_BUILD_ROOT%{mingw64_bindir}
|
||||
%{mingw64_bindir}/qemu-ga*
|
||||
|
||||
%changelog
|
||||
* Wed Feb 15 2023 Konstantin Kostiuk <kkostiuk@redhat.com> 105.0.4
|
||||
- Set version to 105.0.4
|
||||
- BZ#2167436
|
||||
|
||||
* Mon Dec 26 2022 Konstantin Kostiuk <kkostiuk@redhat.com> 105.0.3
|
||||
- Set version to 105.0.3
|
||||
- BZ#2090250 - mingw-qemu-ga-win: Add Provides: bundled() to rpm packages [rhel-9]
|
||||
|
Loading…
Reference in New Issue
Block a user