_fix-external-x11vnc
authorDebian Edu Packaging Team <debian-edu-pkg-team@lists.alioth.debian.org>
Fri, 12 Aug 2022 11:38:21 +0000 (12:38 +0100)
committerDmitry Shachnev <mitya57@debian.org>
Fri, 12 Aug 2022 11:38:21 +0000 (12:38 +0100)
Gbp-Pq: Name 1001_fix-external-x11vnc.patch

plugins/vncserver/x11vnc-builtin/BuiltinX11VncServer.cpp
plugins/vncserver/x11vnc-builtin/CMakeLists.txt

index e867c16b47903780ca32833460eea7ecde2f7bc7..76a74138996d0ec06b2f2715e4bdab261d4843fe 100644 (file)
@@ -32,7 +32,9 @@
 #include "X11VncConfigurationWidget.h"
 
 extern "C" int x11vnc_main( int argc, char * * argv );
+#ifndef VEYON_X11VNC_EXTERNAL
 extern "C" int hasWorkingXShm();
+#endif
 
 
 BuiltinX11VncServer::BuiltinX11VncServer( QObject* parent ) :
@@ -73,11 +75,13 @@ bool BuiltinX11VncServer::runServer( int serverPort, const Password& password )
                cmdline.append( extraArguments.split( QLatin1Char(' ') ) );
        }
 
+#ifndef VEYON_X11VNC_EXTERNAL
        if( hasWorkingXShm() == false )
        {
                vDebug() << "X shared memory extension not available - passing -noshm to x11vnc";
                cmdline.append( QStringLiteral("-noshm") );
        }
+#endif
 
        const auto systemEnv = QProcessEnvironment::systemEnvironment();
 
index 29a207e267362979613f9cb66649c93ae307f156..94e5e97e748ee77859b5e231fde60e1436fff8b4 100644 (file)
@@ -199,6 +199,8 @@ if(NOT VEYON_X11VNC_EXTERNAL)
 
        set_source_files_properties(${x11vnc_SOURCES} ${libvncserver_SOURCES} PROPERTIES
                COMPILE_FLAGS "${COMPILER_WARN_DISABLE_FLAGS} -Wno-deprecated-declarations -Wno-unused-result -Wno-unused-function -Wno-unused-variable -Wno-misleading-indentation")
+else()
+       add_definitions ( -DVEYON_X11VNC_EXTERNAL )
 endif()
 
 set(WITH_PCH OFF)