* Thu Apr 28 2022 Miroslav Rezanina <mrezanin@redhat.com> - 12.0.0-1

- Rebase to 12.0.0 [bz#2061193]
- Resolves: bz#2061193
  ([ESXi][RHEL9]Open-vm-tools release 12.0.0 has been released - please rebase)
This commit is contained in:
Miroslav Rezanina 2022-04-27 09:02:32 -04:00
parent 430ce977f0
commit 543590857a
5 changed files with 150 additions and 17 deletions

1
.gitignore vendored
View File

@ -22,3 +22,4 @@
/open-vm-tools-11.2.5-17337674.tar.gz
/open-vm-tools-11.3.0-18090558.tar.gz
/open-vm-tools-11.3.5-18557794.tar.gz
/open-vm-tools-12.0.0-19345655.tar.gz

View File

@ -0,0 +1,118 @@
From 5fff493e094bd187580513b1b8469bae1d7d17e8 Mon Sep 17 00:00:00 2001
From: Miroslav Rezanina <mrezanin@redhat.com>
Date: Tue, 29 Mar 2022 02:51:45 -0400
Subject: Fix asyncsocket warnings
With newer gcc, build of open-vm-tools will fail due to several warnings.
Adding fixes to allow build to pass.
Signed-off-by: Miroslav Rezanina <mrezanin@redhat.com>
---
.../lib/asyncsocket/asyncSocketVTable.h | 4 ++--
open-vm-tools/lib/asyncsocket/asyncsocket.c | 20 +++++++++----------
2 files changed, 12 insertions(+), 12 deletions(-)
diff --git a/open-vm-tools/lib/asyncsocket/asyncSocketVTable.h b/open-vm-tools/lib/asyncsocket/asyncSocketVTable.h
index a69b6567..01d5be9d 100644
--- a/open-vm-tools/lib/asyncsocket/asyncSocketVTable.h
+++ b/open-vm-tools/lib/asyncsocket/asyncSocketVTable.h
@@ -131,8 +131,8 @@ typedef struct AsyncSocketVTable {
int timeoutMS);
int (*doOneMsg)(AsyncSocket *s, Bool read, int timeoutMS);
int (*waitForConnection)(AsyncSocket *s, int timeoutMS);
- int (*waitForReadMultiple)(AsyncSocket **asock, int numSock, int timeoutMS,
- int *outIdx);
+ int (*waitForReadMultiple)(AsyncSocket **asock, size_t numSock,
+ int timeoutMS, int *outIdx);
int (*peek)(AsyncSocket *asock, void *buf, int len, void *cb, void *cbData);
/*
diff --git a/open-vm-tools/lib/asyncsocket/asyncsocket.c b/open-vm-tools/lib/asyncsocket/asyncsocket.c
index efddf99b..b841a45e 100644
--- a/open-vm-tools/lib/asyncsocket/asyncsocket.c
+++ b/open-vm-tools/lib/asyncsocket/asyncsocket.c
@@ -370,7 +370,7 @@ static int AsyncTCPSocketRecvPartialBlocking(AsyncSocket *s, void *buf, int len,
static int AsyncTCPSocketSendBlocking(AsyncSocket *s, void *buf, int len,
int *sent, int timeoutMS);
static int AsyncTCPSocketDoOneMsg(AsyncSocket *s, Bool read, int timeoutMS);
-static int AsyncTCPSocketWaitForReadMultiple(AsyncSocket **asock, int numSock,
+static int AsyncTCPSocketWaitForReadMultiple(AsyncSocket **asock, size_t numSock,
int timeoutMS, int *outIdx);
static int AsyncTCPSocketSetOption(AsyncSocket *asyncSocket,
AsyncSocketOpts_Layer layer,
@@ -2807,7 +2807,7 @@ AsyncTCPSocketPeek(AsyncSocket *base, // IN:
static int
AsyncTCPSocketPollWork(AsyncTCPSocket **asock, // IN:
- int numSock, // IN:
+ size_t numSock, // IN:
void *p, // IN:
Bool read, // IN:
int timeoutMS, // IN:
@@ -2827,11 +2827,11 @@ AsyncTCPSocketPollWork(AsyncTCPSocket **asock, // IN:
struct fd_set rwfds;
struct fd_set exceptfds;
#endif
- int i;
+ size_t i;
int retval;
ASSERT(outAsock != NULL && *outAsock == NULL && asock != NULL &&
- numSock > 0);
+ numSock != 0);
for (i = 0; i < numSock; i++) {
if (read && SSL_Pending(asock[i]->sslSock)) {
@@ -2852,7 +2852,7 @@ AsyncTCPSocketPollWork(AsyncTCPSocket **asock, // IN:
retval = poll(pfd, numSock, timeoutMS);
AsyncTCPSocketLock(parentSock);
} else {
- for (i = numSock - 1; i >= 0; i--) {
+ for (i = numSock; i-- > 0; ) {
AsyncTCPSocketUnlock(asock[i]);
}
retval = poll(pfd, numSock, timeoutMS);
@@ -2878,7 +2878,7 @@ AsyncTCPSocketPollWork(AsyncTCPSocket **asock, // IN:
&exceptfds, timeoutMS >= 0 ? &tv : NULL);
AsyncTCPSocketLock(parentSock);
} else {
- for (i = numSock - 1; i >= 0; i--) {
+ for (i = numSock; i-- > 0; ) {
AsyncTCPSocketUnlock(asock[i]);
}
retval = select(1, read ? &rwfds : NULL, read ? NULL : &rwfds,
@@ -3032,7 +3032,7 @@ AsyncTCPSocketPoll(AsyncTCPSocket *s, // IN:
#else
void *p = NULL;
#endif
- int numSock = 0;
+ size_t numSock = 0;
if (read && s->fd == -1) {
if (!s->listenAsock4 && !s->listenAsock6) {
@@ -3078,11 +3078,11 @@ AsyncTCPSocketPoll(AsyncTCPSocket *s, // IN:
static int
AsyncTCPSocketWaitForReadMultiple(AsyncSocket **asock, // IN:
- int numSock, // IN:
+ size_t numSock, // IN:
int timeoutMS, // IN:
int *outIdx) // OUT:
{
- int i;
+ size_t i;
int err;
AsyncTCPSocket *outAsock = NULL;
#ifndef _WIN32
@@ -3096,7 +3096,7 @@ AsyncTCPSocketWaitForReadMultiple(AsyncSocket **asock, // IN:
}
err = AsyncTCPSocketPollWork((AsyncTCPSocket **)asock, numSock, p, TRUE,
timeoutMS, NULL, &outAsock);
- for (i = numSock - 1; i >= 0; i--) {
+ for (i = numSock; i-- > 0; ) {
AsyncTCPSocket *tcpAsock = TCPSocket(asock[i]);
if (outAsock == tcpAsock) {
*outIdx = i;
--
2.31.1

View File

@ -1,13 +0,0 @@
diff --git a/open-vm-tools/lib/pollGtk/pollGtk.c b/open-vm-tools/lib/pollGtk/pollGtk.c
index 4ccaeda..336a8bf 100644
--- a/open-vm-tools/lib/pollGtk/pollGtk.c
+++ b/open-vm-tools/lib/pollGtk/pollGtk.c
@@ -127,7 +127,7 @@ typedef struct Poll {
} Poll;
static Poll *pollState;
-static volatile gsize inited = 0;
+static gsize inited = 0;
static VMwareStatus
PollGtkCallback(PollClassSet classSet, // IN

View File

@ -19,9 +19,9 @@
################################################################################
%global _hardened_build 1
%global majorversion 11.3
%global minorversion 5
%global toolsbuild 18557794
%global majorversion 12.0
%global minorversion 0
%global toolsbuild 19345655
%global toolsversion %{majorversion}.%{minorversion}
%global toolsdaemon vmtoolsd
%global vgauthdaemon vgauthd
@ -51,6 +51,8 @@ ExclusiveArch: x86_64 aarch64
ExclusiveArch: %{ix86} x86_64 aarch64
%endif
Patch0002: 0002-Fix-asyncsocket-warnings.patch
# Source-git patches
BuildRequires: autoconf
@ -143,6 +145,15 @@ This package contains only the user-space programs and utility scripts of
%{name} that are essential for performing service discovery in VMware
virtual machines by vRealize Operations Service Discovery Management Pack.
%package salt-minion
Summary: Script file to install/uninstall salt-minion
Group: System Environment/Libraries
Requires: %{name}%{?_isa} = %{version}-%{release}, systemd, curl, coreutils, gawk, grep
ExclusiveArch: x86_64
%description salt-minion
This package contains a script to setup Salt Minion on VMware virtual machines.
%package devel
Summary: Development libraries for Open Virtual Machine Tools
Requires: %{name}%{?_isa} = %{version}-%{release}
@ -172,6 +183,9 @@ autoreconf -vif
--enable-xmlsec1 \
--enable-resolutionkms \
--enable-servicediscovery \
%ifarch x86_64
--enable-salt-minion \
%endif
%if 0%{?fedora} || 0%{?rhel} >= 8
--with-tirpc \
--without-gtk2 \
@ -346,6 +360,7 @@ fi
%{_libdir}/%{name}/plugins/common/*.so
%dir %{_libdir}/%{name}/plugins/vmsvc
%{_libdir}/%{name}/plugins/vmsvc/libappInfo.so
%{_libdir}/%{name}/plugins/vmsvc/libcomponentMgr.so
%{_libdir}/%{name}/plugins/vmsvc/libdeployPkgPlugin.so
%{_libdir}/%{name}/plugins/vmsvc/libgdp.so
%{_libdir}/%{name}/plugins/vmsvc/libguestInfo.so
@ -374,6 +389,13 @@ fi
%{_libdir}/%{name}/plugins/vmsvc/libserviceDiscovery.so
%{_libdir}/%{name}/serviceDiscovery
%ifarch x86_64
%files salt-minion
%dir %{_libdir}/%{name}/componentMgr/
%dir %{_libdir}/%{name}/componentMgr/saltMinion/
%{_libdir}/%{name}/componentMgr/saltMinion/svtminion.sh
%endif
%files devel
%doc docs/api/build/*
%exclude %{_includedir}/libDeployPkg/
@ -390,6 +412,11 @@ fi
%{_bindir}/vmware-vgauth-smoketest
%changelog
* Thu Apr 28 2022 Miroslav Rezanina <mrezanin@redhat.com> - 12.0.0-1
- Rebase to 12.0.0 [bz#2061193]
- Resolves: bz#2061193
([ESXi][RHEL9]Open-vm-tools release 12.0.0 has been released - please rebase)
* Fri Oct 15 2021 Miroslav Rezanina <mrezanin@redhat.com> - 11.3.5-1
- Rebase to 11.3.5 [bz#2008243]
- Resolves: bz#2008243

View File

@ -1 +1 @@
SHA512 (open-vm-tools-11.3.5-18557794.tar.gz) = fa31f5615c9c90865ba9122f7fcd0831068d48defee30a5f5c620e744b76ccd5b7cc2de20cea4e37b596f99619ffb7bb47774de04e7c4bea666c7c0b6fa1560e
SHA512 (open-vm-tools-12.0.0-19345655.tar.gz) = 5c41ed81eb0e2755ca4a4adf8691f60daf016577d4b98ede36916fb95412f5dfdc086a3a42ef87fcb669ce7026ea1383a2dccc49fe30d192b187b8592a25e935