diff options
Diffstat (limited to 'x11-misc/x11vnc/files')
-rw-r--r-- | x11-misc/x11vnc/files/x11vnc-0.9.16-implicit-function-declaration.patch | 26 | ||||
-rw-r--r-- | x11-misc/x11vnc/files/x11vnc.init.d | 70 | ||||
-rw-r--r-- | x11-misc/x11vnc/files/x11vnc.init.d-r1 | 8 |
3 files changed, 30 insertions, 74 deletions
diff --git a/x11-misc/x11vnc/files/x11vnc-0.9.16-implicit-function-declaration.patch b/x11-misc/x11vnc/files/x11vnc-0.9.16-implicit-function-declaration.patch new file mode 100644 index 000000000000..c6d1c494bd23 --- /dev/null +++ b/x11-misc/x11vnc/files/x11vnc-0.9.16-implicit-function-declaration.patch @@ -0,0 +1,26 @@ +From 351d27d4a846e3d0e5c724e067f44b52e04402f1 Mon Sep 17 00:00:00 2001 +From: Alexander Tsoy <alexander@tsoy.me> +Date: Mon, 6 Mar 2023 00:57:20 +0300 +Subject: [PATCH] Drop AC_FUNC_STAT macro + +This macro is obsolescent and doesn't work with +-Werror=implicit-function-declaration compiler flag +--- + configure.ac | 1 - + 1 file changed, 1 deletion(-) + +diff --git a/configure.ac b/configure.ac +index 6b62ac5..5a386db 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -474,7 +474,6 @@ if test $inaddrt = no ; then + fi + # Checks for library functions. + AC_FUNC_MEMCMP +-AC_FUNC_STAT + AC_FUNC_STRFTIME + AC_FUNC_VPRINTF + AC_FUNC_FORK +-- +2.39.2 + diff --git a/x11-misc/x11vnc/files/x11vnc.init.d b/x11-misc/x11vnc/files/x11vnc.init.d deleted file mode 100644 index b6b16dafb943..000000000000 --- a/x11-misc/x11vnc/files/x11vnc.init.d +++ /dev/null @@ -1,70 +0,0 @@ -#!/sbin/openrc-run -# Copyright 1999-2011 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 - -description="The x11vnc daemon init script" - -depend() { - need net - need xdm -} - -checkconfig() { - - # Set Defaults - X11VNC_RFBAUTH=${X11VNC_RFBAUTH:-/etc/x11vnc.pass} - X11VNC_RFBPORT=${X11VNC_RFBPORT:-5900} - X11VNC_DISPLAY=${X11VNC_DISPLAY:-:0} - X11VNC_LOG=${X11VNC_LOG:-/var/log/x11vnc} - - X11VNC_AUTH="/var/run/x11vnc-${X11VNC_DISPLAY}" - - if [ -n "${X11VNC_AUTOPORT}" ]; then - X11VNC_PORT="" - fi - - if [ ! -f "${X11VNC_RFBAUTH}" -o ! -s "${X11VNC_RFBAUTH}" ]; then - eerror "VNC Password not set, please set one by running: \`x11vnc -storepasswd ${X11VNC_RFBAUTH}\`" - return 1 - fi - checkpath -q -f -m 0600 -o root:root "${X11VNC_RFBAUTH}" - - # Attempt to find X-Auth file - if ! type xauth > /dev/null 2>&1 || - ! xauth -f /root/.Xauthority extract - "${X11VNC_DISPLAY}" > "${X11VNC_AUTH}" 2>/dev/null || - [ ! -s "${X11VNC_AUTH}" ]; then - # Let x11vnc guess at auth - X11VNC_AUTH_OPTS="--env FD_XDM=1 -auth guess" - else - # We found the proper auth - X11VNC_AUTH_OPTS="-auth ${X11VNC_AUTH}" - fi - - if [ ! -f "${X11VNC_AUTH}" ]; then - eerror "Specified X-Authority file '${X11VNC_AUTH}' not found!" - return 1 - fi -} - -start() { - checkconfig || return 1 - - ebegin "Starting ${SVCNAME}" - start-stop-daemon --start \ - --exec /usr/bin/x11vnc -- \ - ${X11VNC_AUTH_OPTS} \ - -rfbauth ${X11VNC_RFBAUTH} \ - ${X11VNC_RFBPORT:+-rfbport} ${X11VNC_RFBPORT} \ - ${X11VNC_AUTOPORT:+-autoport} ${X11VNC_AUTOPORT} \ - -display ${X11VNC_DISPLAY} \ - -o ${X11VNC_LOG} \ - -bg -forever \ - ${X11VNC_OPTS} - eend $? -} - -stop() { - ebegin "Stopping ${SVCNAME}" - start-stop-daemon --stop /usr/bin/x11vnc - eend $? -} diff --git a/x11-misc/x11vnc/files/x11vnc.init.d-r1 b/x11-misc/x11vnc/files/x11vnc.init.d-r1 index 04c36ea361db..8907b3858a31 100644 --- a/x11-misc/x11vnc/files/x11vnc.init.d-r1 +++ b/x11-misc/x11vnc/files/x11vnc.init.d-r1 @@ -16,8 +16,8 @@ checkconfig() { X11VNC_RFBPORT=${X11VNC_RFBPORT:-5900} X11VNC_DISPLAY=${X11VNC_DISPLAY:-:0} X11VNC_LOG=${X11VNC_LOG:-/var/log/x11vnc} - - X11VNC_AUTH="/var/run/x11vnc-${X11VNC_DISPLAY}" + + X11VNC_AUTH="/var/run/x11vnc-${X11VNC_DISPLAY}" if [ -n "${X11VNC_AUTOPORT}" ]; then X11VNC_PORT="" @@ -30,7 +30,7 @@ checkconfig() { checkpath -q -f -m 0600 -o root:root "${X11VNC_RFBAUTH}" # Attempt to find X-Auth file - if ! type xauth > /dev/null 2>&1 || + if ! command -v xauth > /dev/null 2>&1 || ! xauth -f /root/.Xauthority extract - "${X11VNC_DISPLAY}" > "${X11VNC_AUTH}" 2>/dev/null || [ ! -s "${X11VNC_AUTH}" ]; then # Let x11vnc guess at auth @@ -43,7 +43,7 @@ checkconfig() { if [ ! -f "${X11VNC_AUTH}" ]; then eerror "Specified X-Authority file '${X11VNC_AUTH}' not found!" return 1 - fi + fi } start() { |