legacy package [release 0.9.10-2mamba;Mon Jun 19 2017]

This commit is contained in:
Silvan Calarco 2024-01-06 06:04:50 +01:00
parent ef6b5b9397
commit 1f8d1888dc
5 changed files with 2185 additions and 0 deletions

View File

@ -1,2 +1,4 @@
# libvncserver0 # libvncserver0
LibVNCServer is ripped out of Xvnc to provide an easy API to write one's own vnc server.

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,129 @@
From 53cc1fa18a3b96d2c31a145d971017564fca39bb Mon Sep 17 00:00:00 2001
From: Rex Dieter <rdieter@math.unl.edu>
Date: Thu, 18 Feb 2016 08:29:07 -0600
Subject: [PATCH] use namespaced rfbMax macro (issue #102)
Not using generic 'max', avoids conflicts with stl_algobase.h
---
libvncclient/listen.c | 9 +++------
libvncserver/httpd.c | 2 +-
libvncserver/rfbserver.c | 2 +-
libvncserver/sockets.c | 8 ++++----
rfb/rfbproto.h | 2 +-
5 files changed, 10 insertions(+), 13 deletions(-)
diff --git a/libvncclient/listen.c b/libvncclient/listen.c
index 739cd9f..e989d6a 100644
--- a/libvncclient/listen.c
+++ b/libvncclient/listen.c
@@ -30,9 +30,6 @@
#ifdef WIN32
#define close closesocket
#include <winsock2.h>
-#ifdef _MINGW32
-#undef max
-#endif // #ifdef _MINGW32
#else // #ifdef WIN32
#include <sys/wait.h>
#include <sys/utsname.h>
@@ -99,7 +96,7 @@ listenForIncomingConnections(rfbClient* client)
if(listen6Socket >= 0)
FD_SET(listen6Socket, &fds);
- r = select(max(listenSocket, listen6Socket)+1, &fds, NULL, NULL, NULL);
+ r = select(rfbMax(listenSocket, listen6Socket)+1, &fds, NULL, NULL, NULL);
if (r > 0) {
if (FD_ISSET(listenSocket, &fds))
@@ -195,9 +192,9 @@ listenForIncomingConnectionsNoFork(rfbClient* client, int timeout)
FD_SET(client->listen6Sock, &fds);
if (timeout < 0)
- r = select(max(client->listenSock, client->listen6Sock) +1, &fds, NULL, NULL, NULL);
+ r = select(rfbMax(client->listenSock, client->listen6Sock) +1, &fds, NULL, NULL, NULL);
else
- r = select(max(client->listenSock, client->listen6Sock) +1, &fds, NULL, NULL, &to);
+ r = select(rfbMax(client->listenSock, client->listen6Sock) +1, &fds, NULL, NULL, &to);
if (r > 0)
{
diff --git a/libvncserver/httpd.c b/libvncserver/httpd.c
index 2a778e7..236ab3e 100644
--- a/libvncserver/httpd.c
+++ b/libvncserver/httpd.c
@@ -192,7 +192,7 @@ rfbHttpCheckFds(rfbScreenInfoPtr rfbScreen)
}
tv.tv_sec = 0;
tv.tv_usec = 0;
- nfds = select(max(rfbScreen->httpListen6Sock, max(rfbScreen->httpSock,rfbScreen->httpListenSock)) + 1, &fds, NULL, NULL, &tv);
+ nfds = select(rfbMax(rfbScreen->httpListen6Sock, rfbMax(rfbScreen->httpSock,rfbScreen->httpListenSock)) + 1, &fds, NULL, NULL, &tv);
if (nfds == 0) {
return;
}
diff --git a/libvncserver/rfbserver.c b/libvncserver/rfbserver.c
index 34e1c06..68c2de5 100644
--- a/libvncserver/rfbserver.c
+++ b/libvncserver/rfbserver.c
@@ -369,7 +369,7 @@ rfbNewTCPOrUDPClient(rfbScreenInfoPtr rfbScreen,
}
FD_SET(sock,&(rfbScreen->allFds));
- rfbScreen->maxFd = max(sock,rfbScreen->maxFd);
+ rfbScreen->maxFd = rfbMax(sock,rfbScreen->maxFd);
INIT_MUTEX(cl->outputMutex);
INIT_MUTEX(cl->refCountMutex);
diff --git a/libvncserver/sockets.c b/libvncserver/sockets.c
index f21f162..aaef14b 100644
--- a/libvncserver/sockets.c
+++ b/libvncserver/sockets.c
@@ -193,7 +193,7 @@ rfbInitSockets(rfbScreenInfoPtr rfbScreen)
rfbLog("Autoprobing selected TCP6 port %d\n", rfbScreen->ipv6port);
FD_SET(rfbScreen->listen6Sock, &(rfbScreen->allFds));
- rfbScreen->maxFd = max((int)rfbScreen->listen6Sock,rfbScreen->maxFd);
+ rfbScreen->maxFd = rfbMax((int)rfbScreen->listen6Sock,rfbScreen->maxFd);
#endif
}
else
@@ -220,7 +220,7 @@ rfbInitSockets(rfbScreenInfoPtr rfbScreen)
rfbLog("Listening for VNC connections on TCP6 port %d\n", rfbScreen->ipv6port);
FD_SET(rfbScreen->listen6Sock, &(rfbScreen->allFds));
- rfbScreen->maxFd = max((int)rfbScreen->listen6Sock,rfbScreen->maxFd);
+ rfbScreen->maxFd = rfbMax((int)rfbScreen->listen6Sock,rfbScreen->maxFd);
}
#endif
@@ -236,7 +236,7 @@ rfbInitSockets(rfbScreenInfoPtr rfbScreen)
rfbLog("Listening for VNC connections on TCP port %d\n", rfbScreen->port);
FD_SET(rfbScreen->udpSock, &(rfbScreen->allFds));
- rfbScreen->maxFd = max((int)rfbScreen->udpSock,rfbScreen->maxFd);
+ rfbScreen->maxFd = rfbMax((int)rfbScreen->udpSock,rfbScreen->maxFd);
}
}
@@ -563,7 +563,7 @@ rfbConnect(rfbScreenInfoPtr rfbScreen,
/* AddEnabledDevice(sock); */
FD_SET(sock, &rfbScreen->allFds);
- rfbScreen->maxFd = max(sock,rfbScreen->maxFd);
+ rfbScreen->maxFd = rfbMax(sock,rfbScreen->maxFd);
return sock;
}
diff --git a/rfb/rfbproto.h b/rfb/rfbproto.h
index 8e607e5..bb6bfa5 100644
--- a/rfb/rfbproto.h
+++ b/rfb/rfbproto.h
@@ -93,8 +93,8 @@
#define strncasecmp _strnicmp
#endif
+#define rfbMax(a,b) (((a)>(b))?(a):(b))
#if !defined(WIN32) || defined(__MINGW32__)
-#define max(a,b) (((a)>(b))?(a):(b))
#ifdef LIBVNCSERVER_HAVE_SYS_TIME_H
#include <sys/time.h>
#endif

View File

@ -0,0 +1,54 @@
From 7b6243157f042a7bde353abc6fb22aadad6d9e2d Mon Sep 17 00:00:00 2001
From: Floris Bos <bos@je-eigen-domein.nl>
Date: Mon, 29 Dec 2014 00:02:33 +0100
Subject: [PATCH] Fix libva related compile errors
- Make h264.c compile with recent libva version by including va_compat.h
- Only enable libva if libva-x11 is installed
- Modified configure help text
Previous help text suggested libva was only build when --with-libva
was specified, while actual behavior is to build it by default.
Warning: THIS CODE IS UNTESTED. Lacking a h.264 capable VNC server
Also no attempt is made to support platforms not using X11
Signed-off-by: Floris Bos <bos@je-eigen-domein.nl>
---
configure.ac | 5 ++---
libvncclient/h264.c | 4 ++++
2 files changed, 6 insertions(+), 3 deletions(-)
diff --git a/configure.ac b/configure.ac
index ca9f3b3..fe8b1de 100644
--- a/configure.ac
+++ b/configure.ac
@@ -150,12 +150,11 @@ AM_CONDITIONAL(HAVE_LIBSSL, test ! -z "$SSL_LIBS")
# See if we want libva support
-# TODO: check if library actually exists
AH_TEMPLATE(CONFIG_LIBVA, [Build libva support])
AC_ARG_WITH(libva,
-[ --with-libva build libva support],,)
+[ --without-libva disable support for libva],,)
if test "x$with_libva" != "xno"; then
- AC_CHECK_LIB(va, vaInitialize,
+ AC_CHECK_LIB(va-x11, vaGetDisplay,
VA_LIBS="-lva -lva-x11"
[AC_DEFINE(CONFIG_LIBVA) CONFIG_LIBVA="true"], ,)
fi
diff --git a/libvncclient/h264.c b/libvncclient/h264.c
index 1d94454..c63a713 100644
--- a/libvncclient/h264.c
+++ b/libvncclient/h264.c
@@ -20,6 +20,10 @@
#ifdef LIBVNCSERVER_CONFIG_LIBVA
#include <X11/Xlib.h>
+#include <va/va_version.h>
+#if VA_CHECK_VERSION(0,34,0)
+#include <va/va_compat.h>
+#endif
#include <va/va_x11.h>
enum _slice_types {

126
libvncserver0.spec Normal file
View File

@ -0,0 +1,126 @@
Name: libvncserver0
Version: 0.9.10
Release: 2mamba
Summary: LibVNCServer is ripped out of Xvnc to provide an easy API to write one's own vnc server
Group: System/Libraries
Vendor: openmamba
Distribution: openmamba
Packager: Aleph0 <aleph0@openmamba.org>
URL: http://sourceforge.net/projects/libvncserver/
Source: https://github.com/LibVNC/libvncserver.git/LibVNCServer-%{version}/libvncserver-%{version}.tar.bz2
Patch0: libvncserver-0.9.1-backport-x11vnc0.9.5.patch
Patch1: libvncserver-0.9.10-gcc-6.1.0-rfbmax.patch
Patch2: libvncserver-0.9.10-libva-1.7.1.patch
License: GPL
## AUTOBUILDREQ-BEGIN
BuildRequires: glibc-devel
BuildRequires: libX11-devel
BuildRequires: libXau-devel
BuildRequires: libXdmcp-devel
BuildRequires: libXext-devel
BuildRequires: libXfixes-devel
BuildRequires: libbsd-devel
BuildRequires: libdrm-devel
BuildRequires: libffi-devel
BuildRequires: libgcrypt-devel
BuildRequires: libgmp-devel
BuildRequires: libgnutls-devel
BuildRequires: libgpg-error-devel
BuildRequires: libidn-devel
BuildRequires: libjpeg-devel
BuildRequires: libnettle-devel
BuildRequires: libopenssl-devel
BuildRequires: libp11-kit-devel
BuildRequires: libpng-devel
BuildRequires: libtasn1-devel
BuildRequires: libva-devel
BuildRequires: libxcb-devel
BuildRequires: libz-devel
## AUTOBUILDREQ-END
%if "%{stage1}" != "1"
BuildRequires: libdirectfb-devel
%endif
BuildRoot: %{_tmppath}/%{name}-%{version}-root
%description
LibVNCServer is ripped out of Xvnc to provide an easy API to write one's own vnc server.
%package devel
Group: Development/Libraries
Summary: Static libraries and headers for %{name}
Requires: %{name} = %{?epoch:%epoch:}%{version}-%{release}
%description devel
LibVNCServer is ripped out of Xvnc to provide an easy API to write one's own vnc server.
This package contains static libraries and header files need for development.
%prep
%setup -q -n libvncserver-%{version}
%patch1 -p1
%patch2 -p1
%build
./autogen.sh
%configure
%make
%install
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
%makeinstall
%clean
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
%post -p /sbin/ldconfig
%postun -p /sbin/ldconfig
%files
%defattr(-,root,root)
#%{_bindir}/linuxvnc
%{_libdir}/libvncclient.so.*
%{_libdir}/libvncserver.so.*
%doc AUTHORS COPYING
%files devel
%defattr(-,root,root)
%{_bindir}/libvncserver-config
%dir %{_includedir}/rfb
%{_includedir}/rfb/*.h
%{_libdir}/libvncclient.a
%{_libdir}/libvncclient.la
%{_libdir}/libvncclient.so
%{_libdir}/libvncserver.a
%{_libdir}/libvncserver.la
%{_libdir}/libvncserver.so
%{_libdir}/pkgconfig/libvncclient.pc
%{_libdir}/pkgconfig/libvncserver.pc
#%doc examples/*.c
%doc ChangeLog NEWS README TODO
%changelog
* Mon Jun 19 2017 Silvan Calarco <silvan.calarco@mambasoft.it> 0.9.10-2mamba
- legacy package
* Wed Jun 29 2016 Silvan Calarco <silvan.calarco@mambasoft.it> 0.9.10-1mamba
- update to 0.9.10
* Tue Aug 14 2012 Automatic Build System <autodist@mambasoft.it> 0.9.9-1mamba
- automatic version update by autodist
* Sat Apr 02 2011 Automatic Build System <autodist@mambasoft.it> 0.9.8-1mamba
- automatic update by autodist
* Thu Nov 11 2010 Silvan Calarco <silvan.calarco@mambasoft.it> 0.9.7-3mamba
- rebuilt with libjpeg 8
* Sat Sep 12 2009 Silvan Calarco <silvan.calarco@mambasoft.it> 0.9.7-2mamba
- rebuilt against libjpeg 7
* Mon Mar 02 2009 Silvan Calarco <silvan.calarco@mambasoft.it> 0.9.7-1mamba
- automatic update by autodist
* Sat Dec 06 2008 Silvan Calarco <silvan.calarco@mambasoft.it> 0.9.1-2mamba
- added patch to backport changes from x11vnc 0.9.5
* Mon May 12 2008 Aleph0 <aleph0@openmamba.org> 0.9.1-1mamba
- package created by autospec