diff options
author | Patrick J Volkerding <volkerdi@slackware.com> | 2019-11-18 20:14:57 +0000 |
---|---|---|
committer | Eric Hameleers <alien@slackware.com> | 2019-11-19 08:59:51 +0100 |
commit | fa3f92ac782f8531079bf9584fe6714fc3d7c5ed (patch) | |
tree | 77d560418b6292229dc9d6cce590db01d5b278c2 /extra | |
parent | f5de7b702347679403ef7dd832c42e913c931d23 (diff) | |
download | current-fa3f92ac782f8531079bf9584fe6714fc3d7c5ed.tar.gz |
Mon Nov 18 20:14:57 UTC 201920191118201457
a/kernel-firmware-20191118_9581f15-noarch-1.txz: Upgraded.
ap/rpm-4.15.1-x86_64-1.txz: Upgraded.
ap/vim-8.1.2318-x86_64-1.txz: Upgraded.
d/ccache-3.7.6-x86_64-1.txz: Upgraded.
d/vala-0.46.5-x86_64-1.txz: Upgraded.
l/imagemagick-7.0.9_5-x86_64-1.txz: Upgraded.
l/libssh-0.9.2-x86_64-1.txz: Upgraded.
x/xterm-351-x86_64-1.txz: Upgraded.
xap/vim-gvim-8.1.2318-x86_64-1.txz: Upgraded.
extra/tigervnc/tigervnc-1.10.0-x86_64-1.txz: Upgraded.
Diffstat (limited to 'extra')
11 files changed, 647 insertions, 14 deletions
diff --git a/extra/source/tigervnc/patches/force_protocol_3.3_for_UVNCSC.patch b/extra/source/tigervnc/patches/force_protocol_3.3_for_UVNCSC.patch index 56096edc..6e9f523f 100644 --- a/extra/source/tigervnc/patches/force_protocol_3.3_for_UVNCSC.patch +++ b/extra/source/tigervnc/patches/force_protocol_3.3_for_UVNCSC.patch @@ -3,15 +3,15 @@ diff -Naur tigervnc-1.8.0.orig/common/rfb/CConnection.cxx tigervnc-1.8.0/common/ +++ tigervnc-1.8.0/common/rfb/CConnection.cxx 2018-05-15 09:44:02.021640000 +0200 @@ -138,6 +138,13 @@ vlog.info("Server supports RFB protocol version %d.%d", - cp.majorVersion, cp.minorVersion); + server.majorVersion, server.minorVersion); + // Mark's Hack -+ if (cp.minorVersion==16) { -+ cp.setVersion(3,3); ++ if (server.minorVersion==16) { ++ server.setVersion(3,3); + vlog.info("Hack #1 for 3.16"); -+ cp.minorVersion=3; ++ server.minorVersion=3; + } + // The only official RFB protocol versions are currently 3.3, 3.7 and 3.8 - if (cp.beforeVersion(3,3)) { + if (server.beforeVersion(3,3)) { vlog.error("Server gave unsupported RFB protocol version %d.%d", diff --git a/extra/source/tigervnc/patches/xorg-server/0001-Always-install-vbe-and-int10-sdk-headers.patch b/extra/source/tigervnc/patches/xorg-server/0001-Always-install-vbe-and-int10-sdk-headers.patch new file mode 100644 index 00000000..c613eb8f --- /dev/null +++ b/extra/source/tigervnc/patches/xorg-server/0001-Always-install-vbe-and-int10-sdk-headers.patch @@ -0,0 +1,37 @@ +From e96a83d9b1b5a52a41213c7a4840dc96b4f5b06f Mon Sep 17 00:00:00 2001 +From: Adam Jackson <ajax@redhat.com> +Date: Wed, 15 Aug 2012 12:35:21 -0400 +Subject: [PATCH] Always install vbe and int10 sdk headers + +Signed-off-by: Adam Jackson <ajax@redhat.com> +--- + hw/xfree86/Makefile.am | 12 ++---------- + 1 file changed, 2 insertions(+), 10 deletions(-) + +diff --git a/hw/xfree86/Makefile.am b/hw/xfree86/Makefile.am +index b876b79..a170b58 100644 +--- a/hw/xfree86/Makefile.am ++++ b/hw/xfree86/Makefile.am +@@ -26,17 +26,9 @@ if VGAHW + VGAHW_SUBDIR = vgahw + endif + +-if VBE +-VBE_SUBDIR = vbe +-endif +- +-if INT10MODULE +-INT10_SUBDIR = int10 +-endif +- +-SUBDIRS = common ddc x86emu $(INT10_SUBDIR) os-support parser \ ++SUBDIRS = common ddc x86emu int10 os-support parser \ + ramdac $(VGAHW_SUBDIR) loader modes $(DRI_SUBDIR) \ +- $(DRI2_SUBDIR) . $(VBE_SUBDIR) i2c dixmods xkb \ ++ $(DRI2_SUBDIR) . vbe i2c dixmods xkb \ + fbdevhw shadowfb exa $(XF86UTILS_SUBDIR) doc man \ + $(GLAMOR_EGL_SUBDIR) drivers + +-- +2.13.6 + diff --git a/extra/source/tigervnc/patches/xorg-server/0001-autobind-GPUs-to-the-screen.patch b/extra/source/tigervnc/patches/xorg-server/0001-autobind-GPUs-to-the-screen.patch new file mode 100644 index 00000000..86b96a23 --- /dev/null +++ b/extra/source/tigervnc/patches/xorg-server/0001-autobind-GPUs-to-the-screen.patch @@ -0,0 +1,293 @@ +From 471289fa1dc359555ceed6302f7d9605ab6be3ea Mon Sep 17 00:00:00 2001 +From: Dave Airlie <airlied@redhat.com> +Date: Mon, 2 Apr 2018 16:49:02 -0400 +Subject: [PATCH] autobind GPUs to the screen + +This is a modified version of a patch we've been carry-ing in Fedora and +RHEL for years now. This patch automatically adds secondary GPUs to the +master as output sink / offload source making e.g. the use of +slave-outputs just work, with requiring the user to manually run +"xrandr --setprovideroutputsource" before he can hookup an external +monitor to his hybrid graphics laptop. + +There is one problem with this patch, which is why it was not upstreamed +before. What to do when a secondary GPU gets detected really is a policy +decission (e.g. one may want to autobind PCI GPUs but not USB ones) and +as such should be under control of the Desktop Environment. + +Unconditionally adding autobinding support to the xserver will result +in races between the DE dealing with the hotplug of a secondary GPU +and the server itself dealing with it. + +However we've waited for years for any Desktop Environments to actually +start doing some sort of autoconfiguration of secondary GPUs and there +is still not a single DE dealing with this, so I believe that it is +time to upstream this now. + +To avoid potential future problems if any DEs get support for doing +secondary GPU configuration themselves, the new autobind functionality +is made optional. Since no DEs currently support doing this themselves it +is enabled by default. When DEs grow support for doing this themselves +they can disable the servers autobinding through the servers cmdline or a +xorg.conf snippet. + +Signed-off-by: Dave Airlie <airlied@gmail.com> +[hdegoede@redhat.com: Make configurable, fix with nvidia, submit upstream] +Signed-off-by: Hans de Goede <hdegoede@redhat.com> +--- + hw/xfree86/common/xf86Config.c | 19 +++++++++++++++++++ + hw/xfree86/common/xf86Globals.c | 2 ++ + hw/xfree86/common/xf86Init.c | 20 ++++++++++++++++++++ + hw/xfree86/common/xf86Priv.h | 1 + + hw/xfree86/common/xf86Privstr.h | 1 + + hw/xfree86/common/xf86platformBus.c | 4 ++++ + hw/xfree86/man/Xorg.man | 7 +++++++ + hw/xfree86/man/xorg.conf.man | 6 ++++++ + randr/randrstr.h | 3 +++ + randr/rrprovider.c | 22 ++++++++++++++++++++++ + 10 files changed, 85 insertions(+) + +diff --git a/hw/xfree86/common/xf86Config.c b/hw/xfree86/common/xf86Config.c +index 2c1d335..d7d7c2e 100644 +--- a/hw/xfree86/common/xf86Config.c ++++ b/hw/xfree86/common/xf86Config.c +@@ -643,6 +643,7 @@ typedef enum { + FLAG_DRI2, + FLAG_USE_SIGIO, + FLAG_AUTO_ADD_GPU, ++ FLAG_AUTO_BIND_GPU, + FLAG_MAX_CLIENTS, + FLAG_IGLX, + FLAG_DEBUG, +@@ -699,6 +700,8 @@ static OptionInfoRec FlagOptions[] = { + {0}, FALSE}, + {FLAG_AUTO_ADD_GPU, "AutoAddGPU", OPTV_BOOLEAN, + {0}, FALSE}, ++ {FLAG_AUTO_BIND_GPU, "AutoBindGPU", OPTV_BOOLEAN, ++ {0}, FALSE}, + {FLAG_MAX_CLIENTS, "MaxClients", OPTV_INTEGER, + {0}, FALSE }, + {FLAG_IGLX, "IndirectGLX", OPTV_BOOLEAN, +@@ -779,6 +782,22 @@ configServerFlags(XF86ConfFlagsPtr flagsconf, XF86OptionPtr layoutopts) + } + xf86Msg(from, "%sutomatically adding GPU devices\n", + xf86Info.autoAddGPU ? "A" : "Not a"); ++ ++ if (xf86AutoBindGPUDisabled) { ++ xf86Info.autoBindGPU = FALSE; ++ from = X_CMDLINE; ++ } ++ else if (xf86IsOptionSet(FlagOptions, FLAG_AUTO_BIND_GPU)) { ++ xf86GetOptValBool(FlagOptions, FLAG_AUTO_BIND_GPU, ++ &xf86Info.autoBindGPU); ++ from = X_CONFIG; ++ } ++ else { ++ from = X_DEFAULT; ++ } ++ xf86Msg(from, "%sutomatically binding GPU devices\n", ++ xf86Info.autoBindGPU ? "A" : "Not a"); ++ + /* + * Set things up based on the config file information. Some of these + * settings may be overridden later when the command line options are +diff --git a/hw/xfree86/common/xf86Globals.c b/hw/xfree86/common/xf86Globals.c +index e890f05..7b27b4c 100644 +--- a/hw/xfree86/common/xf86Globals.c ++++ b/hw/xfree86/common/xf86Globals.c +@@ -131,6 +131,7 @@ xf86InfoRec xf86Info = { + #else + .autoAddGPU = FALSE, + #endif ++ .autoBindGPU = TRUE, + }; + + const char *xf86ConfigFile = NULL; +@@ -191,6 +192,7 @@ Bool xf86FlipPixels = FALSE; + Gamma xf86Gamma = { 0.0, 0.0, 0.0 }; + + Bool xf86AllowMouseOpenFail = FALSE; ++Bool xf86AutoBindGPUDisabled = FALSE; + + #ifdef XF86VIDMODE + Bool xf86VidModeDisabled = FALSE; +diff --git a/hw/xfree86/common/xf86Init.c b/hw/xfree86/common/xf86Init.c +index ea42ec9..ec255b6 100644 +--- a/hw/xfree86/common/xf86Init.c ++++ b/hw/xfree86/common/xf86Init.c +@@ -76,6 +76,7 @@ + #include "xf86DDC.h" + #include "xf86Xinput.h" + #include "xf86InPriv.h" ++#include "xf86Crtc.h" + #include "picturestr.h" + #include "randrstr.h" + #include "glxvndabi.h" +@@ -237,6 +238,19 @@ xf86PrivsElevated(void) + return PrivsElevated(); + } + ++static void ++xf86AutoConfigOutputDevices(void) ++{ ++ int i; ++ ++ if (!xf86Info.autoBindGPU) ++ return; ++ ++ for (i = 0; i < xf86NumGPUScreens; i++) ++ RRProviderAutoConfigGpuScreen(xf86ScrnToScreen(xf86GPUScreens[i]), ++ xf86ScrnToScreen(xf86Screens[0])); ++} ++ + static void + TrapSignals(void) + { +@@ -770,6 +784,8 @@ InitOutput(ScreenInfo * pScreenInfo, int argc, char **argv) + for (i = 0; i < xf86NumGPUScreens; i++) + AttachUnboundGPU(xf86Screens[0]->pScreen, xf86GPUScreens[i]->pScreen); + ++ xf86AutoConfigOutputDevices(); ++ + xf86VGAarbiterWrapFunctions(); + if (sigio_blocked) + input_unlock(); +@@ -1278,6 +1294,10 @@ ddxProcessArgument(int argc, char **argv, int i) + xf86Info.iglxFrom = X_CMDLINE; + return 0; + } ++ if (!strcmp(argv[i], "-noautoBindGPU")) { ++ xf86AutoBindGPUDisabled = TRUE; ++ return 1; ++ } + + /* OS-specific processing */ + return xf86ProcessArgument(argc, argv, i); +diff --git a/hw/xfree86/common/xf86Priv.h b/hw/xfree86/common/xf86Priv.h +index 4fe2b5f..6566622 100644 +--- a/hw/xfree86/common/xf86Priv.h ++++ b/hw/xfree86/common/xf86Priv.h +@@ -46,6 +46,7 @@ + extern _X_EXPORT const char *xf86ConfigFile; + extern _X_EXPORT const char *xf86ConfigDir; + extern _X_EXPORT Bool xf86AllowMouseOpenFail; ++extern _X_EXPORT Bool xf86AutoBindGPUDisabled; + + #ifdef XF86VIDMODE + extern _X_EXPORT Bool xf86VidModeDisabled; +diff --git a/hw/xfree86/common/xf86Privstr.h b/hw/xfree86/common/xf86Privstr.h +index 21c2e1f..6c71863 100644 +--- a/hw/xfree86/common/xf86Privstr.h ++++ b/hw/xfree86/common/xf86Privstr.h +@@ -98,6 +98,7 @@ typedef struct { + + Bool autoAddGPU; + const char *debug; ++ Bool autoBindGPU; + } xf86InfoRec, *xf86InfoPtr; + + /* ISC's cc can't handle ~ of UL constants, so explicitly type cast them. */ +diff --git a/hw/xfree86/common/xf86platformBus.c b/hw/xfree86/common/xf86platformBus.c +index cef47da..913a324 100644 +--- a/hw/xfree86/common/xf86platformBus.c ++++ b/hw/xfree86/common/xf86platformBus.c +@@ -49,6 +49,7 @@ + #include "Pci.h" + #include "xf86platformBus.h" + #include "xf86Config.h" ++#include "xf86Crtc.h" + + #include "randrstr.h" + int platformSlotClaimed; +@@ -665,6 +666,9 @@ xf86platformAddDevice(int index) + } + /* attach unbound to 0 protocol screen */ + AttachUnboundGPU(xf86Screens[0]->pScreen, xf86GPUScreens[i]->pScreen); ++ if (xf86Info.autoBindGPU) ++ RRProviderAutoConfigGpuScreen(xf86ScrnToScreen(xf86GPUScreens[i]), ++ xf86ScrnToScreen(xf86Screens[0])); + + RRResourcesChanged(xf86Screens[0]->pScreen); + RRTellChanged(xf86Screens[0]->pScreen); +diff --git a/hw/xfree86/man/Xorg.man b/hw/xfree86/man/Xorg.man +index 13a9dc3..745f986 100644 +--- a/hw/xfree86/man/Xorg.man ++++ b/hw/xfree86/man/Xorg.man +@@ -283,6 +283,13 @@ is a comma separated list of directories to search for + server modules. This option is only available when the server is run + as root (i.e, with real-uid 0). + .TP 8 ++.B \-noautoBindGPU ++Disable automatically setting secondary GPUs up as output sinks and offload ++sources. This is equivalent to setting the ++.B AutoBindGPU ++xorg.conf(__filemansuffix__) file option. To ++.B false. ++.TP 8 + .B \-nosilk + Disable Silken Mouse support. + .TP 8 +diff --git a/hw/xfree86/man/xorg.conf.man b/hw/xfree86/man/xorg.conf.man +index 9589262..8d51e06 100644 +--- a/hw/xfree86/man/xorg.conf.man ++++ b/hw/xfree86/man/xorg.conf.man +@@ -672,6 +672,12 @@ Enabled by default. + If this option is disabled, then no GPU devices will be added from the udev + backend. Enabled by default. (May need to be disabled to setup Xinerama). + .TP 7 ++.BI "Option \*qAutoBindGPU\*q \*q" boolean \*q ++If enabled then secondary GPUs will be automatically set up as output-sinks and ++offload-sources. Making e.g. laptop outputs connected only to the secondary ++GPU directly available for use without needing to run ++"xrandr --setprovideroutputsource". Enabled by default. ++.TP 7 + .BI "Option \*qLog\*q \*q" string \*q + This option controls whether the log is flushed and/or synced to disk after + each message. +diff --git a/randr/randrstr.h b/randr/randrstr.h +index f94174b..092d726 100644 +--- a/randr/randrstr.h ++++ b/randr/randrstr.h +@@ -1039,6 +1039,9 @@ RRProviderLookup(XID id, RRProviderPtr *provider_p); + extern _X_EXPORT void + RRDeliverProviderEvent(ClientPtr client, WindowPtr pWin, RRProviderPtr provider); + ++extern _X_EXPORT void ++RRProviderAutoConfigGpuScreen(ScreenPtr pScreen, ScreenPtr masterScreen); ++ + /* rrproviderproperty.c */ + + extern _X_EXPORT void +diff --git a/randr/rrprovider.c b/randr/rrprovider.c +index e4bc2bf..e04c18f 100644 +--- a/randr/rrprovider.c ++++ b/randr/rrprovider.c +@@ -485,3 +485,25 @@ RRDeliverProviderEvent(ClientPtr client, WindowPtr pWin, RRProviderPtr provider) + + WriteEventsToClient(client, 1, (xEvent *) &pe); + } ++ ++void ++RRProviderAutoConfigGpuScreen(ScreenPtr pScreen, ScreenPtr masterScreen) ++{ ++ rrScrPrivPtr pScrPriv = rrGetScrPriv(pScreen); ++ rrScrPrivPtr masterPriv = rrGetScrPriv(masterScreen); ++ RRProviderPtr provider = pScrPriv->provider; ++ RRProviderPtr master_provider = masterPriv->provider; ++ ++ if (!provider || !master_provider) ++ return; ++ ++ if ((provider->capabilities & RR_Capability_SinkOutput) && ++ (master_provider->capabilities & RR_Capability_SourceOutput)) { ++ pScrPriv->rrProviderSetOutputSource(pScreen, provider, master_provider); ++ RRInitPrimeSyncProps(pScreen); ++ } ++ ++ if ((provider->capabilities & RR_Capability_SourceOffload) && ++ (master_provider->capabilities & RR_Capability_SinkOffload)) ++ pScrPriv->rrProviderSetOffloadSink(pScreen, provider, master_provider); ++} +-- +2.16.2 + diff --git a/extra/source/tigervnc/patches/xorg-server/0001-replace-MESA_EGL_NO_X11_HEADERS-hack-with-upstream-E.patch b/extra/source/tigervnc/patches/xorg-server/0001-replace-MESA_EGL_NO_X11_HEADERS-hack-with-upstream-E.patch new file mode 100644 index 00000000..95211479 --- /dev/null +++ b/extra/source/tigervnc/patches/xorg-server/0001-replace-MESA_EGL_NO_X11_HEADERS-hack-with-upstream-E.patch @@ -0,0 +1,81 @@ +From 80d7c1ad75cc4cd3aa844d5ff34fee723966d9fc Mon Sep 17 00:00:00 2001 +From: fafryd <dz1125.bug.tracker@gmail.com> +Date: Sat, 19 Oct 2019 21:58:09 +0200 +Subject: [PATCH] replace MESA_EGL_NO_X11_HEADERS hack with upstream EGL_NO_X11 + +--- + glamor/glamor_egl.h | 2 +- + glamor/glamor_priv.h | 2 +- + hw/xwayland/xwayland-glamor-eglstream.c | 2 +- + hw/xwayland/xwayland-glamor-gbm.c | 2 +- + hw/xwayland/xwayland-glamor.c | 2 +- + 5 files changed, 5 insertions(+), 5 deletions(-) + +diff --git a/glamor/glamor_egl.h b/glamor/glamor_egl.h +index 2f7566b24..af1c707d2 100644 +--- a/glamor/glamor_egl.h ++++ b/glamor/glamor_egl.h +@@ -27,7 +27,7 @@ + #ifndef GLAMOR_EGL_H + #define GLAMOR_EGL_H + +-#define MESA_EGL_NO_X11_HEADERS ++#define EGL_NO_X11 + #include <epoxy/gl.h> + #include <epoxy/egl.h> + #include <glamor_egl_ext.h> +diff --git a/glamor/glamor_priv.h b/glamor/glamor_priv.h +index 7d9a7d4fb..bcdaf4040 100644 +--- a/glamor/glamor_priv.h ++++ b/glamor/glamor_priv.h +@@ -39,7 +39,7 @@ + + #include <epoxy/gl.h> + #ifdef GLAMOR_HAS_GBM +-#define MESA_EGL_NO_X11_HEADERS ++#define EGL_NO_X11 + #include <epoxy/egl.h> + #endif + +diff --git a/hw/xwayland/xwayland-glamor-eglstream.c b/hw/xwayland/xwayland-glamor-eglstream.c +index c62c0d2ac..e665b963e 100644 +--- a/hw/xwayland/xwayland-glamor-eglstream.c ++++ b/hw/xwayland/xwayland-glamor-eglstream.c +@@ -32,7 +32,7 @@ + #include "wayland-eglstream-client-protocol.h" + #include "wayland-eglstream-controller-client-protocol.h" + +-#define MESA_EGL_NO_X11_HEADERS ++#define EGL_NO_X11 + #include <glamor_egl.h> + #include <glamor.h> + #include <glamor_transform.h> +diff --git a/hw/xwayland/xwayland-glamor-gbm.c b/hw/xwayland/xwayland-glamor-gbm.c +index 291e060cf..c92d6073f 100644 +--- a/hw/xwayland/xwayland-glamor-gbm.c ++++ b/hw/xwayland/xwayland-glamor-gbm.c +@@ -35,7 +35,7 @@ + #include <xf86drm.h> + #include <drm_fourcc.h> + +-#define MESA_EGL_NO_X11_HEADERS ++#define EGL_NO_X11 + #include <gbm.h> + #include <glamor_egl.h> + +diff --git a/hw/xwayland/xwayland-glamor.c b/hw/xwayland/xwayland-glamor.c +index 7ea6def61..587ef5ed0 100644 +--- a/hw/xwayland/xwayland-glamor.c ++++ b/hw/xwayland/xwayland-glamor.c +@@ -25,7 +25,7 @@ + + #include "xwayland.h" + +-#define MESA_EGL_NO_X11_HEADERS ++#define EGL_NO_X11 + #include <glamor_egl.h> + + #include <glamor.h> +-- +2.23.0 + diff --git a/extra/source/tigervnc/patches/xorg-server/0001-xfree86-use-modesetting-driver-by-default-on-GeForce.patch b/extra/source/tigervnc/patches/xorg-server/0001-xfree86-use-modesetting-driver-by-default-on-GeForce.patch new file mode 100644 index 00000000..87b28779 --- /dev/null +++ b/extra/source/tigervnc/patches/xorg-server/0001-xfree86-use-modesetting-driver-by-default-on-GeForce.patch @@ -0,0 +1,47 @@ +From aa2f34d80ef3118eae0cce73b610c36cdcb978fe Mon Sep 17 00:00:00 2001 +From: Ben Skeggs <bskeggs@redhat.com> +Date: Sat, 22 Apr 2017 02:26:28 +1000 +Subject: [PATCH xserver] xfree86: use modesetting driver by default on GeForce + 8 and newer + +Signed-off-by: Ben Skeggs <bskeggs@redhat.com> +--- + hw/xfree86/common/xf86pciBus.c | 20 ++++++++++++++++++++ + 1 file changed, 20 insertions(+) + +--- ./hw/xfree86/common/xf86pciBus.c.orig 2019-02-26 13:28:50.000000000 -0600 ++++ ./hw/xfree86/common/xf86pciBus.c 2019-02-26 17:16:04.131096857 -0600 +@@ -37,6 +37,7 @@ + #include <unistd.h> + #include <X11/X.h> + #include <pciaccess.h> ++#include <xf86drm.h> + #include "os.h" + #include "Pci.h" + #include "xf86.h" +@@ -1191,6 +1192,25 @@ + int idx = 0; + + #if defined(__linux__) || defined(__NetBSD__) ++ char busid[32]; ++ int fd; ++ ++ snprintf(busid, sizeof(busid), "pci:%04x:%02x:%02x.%d", ++ dev->domain, dev->bus, dev->dev, dev->func); ++ ++ /* 'modesetting' is preferred for GeForce 8 and newer GPUs */ ++ fd = drmOpenWithType("nouveau", busid, DRM_NODE_RENDER); ++ if (fd >= 0) { ++ uint64_t args[] = { 11 /* NOUVEAU_GETPARAM_CHIPSET_ID */, 0 }; ++ int ret = drmCommandWriteRead(fd, 0 /* DRM_NOUVEAU_GETPARAM */, ++ &args, sizeof(args)); ++ drmClose(fd); ++ if (ret == 0) { ++ if (args[1] == 0x050 || args[1] >= 0x80) ++ break; ++ } ++ } ++ + driverList[idx++] = "nouveau"; + #endif + driverList[idx++] = "nv"; diff --git a/extra/source/tigervnc/patches/xorg-server/c7486613b0dc586f93f6ba293d9b55c69995b05c.patch b/extra/source/tigervnc/patches/xorg-server/c7486613b0dc586f93f6ba293d9b55c69995b05c.patch new file mode 100644 index 00000000..f1c2e7aa --- /dev/null +++ b/extra/source/tigervnc/patches/xorg-server/c7486613b0dc586f93f6ba293d9b55c69995b05c.patch @@ -0,0 +1,23 @@ +From c7486613b0dc586f93f6ba293d9b55c69995b05c Mon Sep 17 00:00:00 2001 +From: Adam Jackson <ajax@redhat.com> +Date: Wed, 9 Oct 2019 15:17:47 -0400 +Subject: [PATCH] meson: Fix another reference to "gl" 9.2.0 + +Previous commit e6ef2b12 missed a spot. +--- + glx/meson.build | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/glx/meson.build b/glx/meson.build +index 745814336..d7a2aa468 100644 +--- a/glx/meson.build ++++ b/glx/meson.build +@@ -74,7 +74,7 @@ if build_glx + common_dep, + dl_dep, + dependency('glproto', version: '>= 1.4.17'), +- dependency('gl', version: '>= 9.2.0'), ++ dependency('gl', version: '>= 1.2.0'), + ], + ) + diff --git a/extra/source/tigervnc/patches/xorg-server/e6ef2b12404dfec7f23592a3524d2a63d9d25802.patch b/extra/source/tigervnc/patches/xorg-server/e6ef2b12404dfec7f23592a3524d2a63d9d25802.patch new file mode 100644 index 00000000..cd9213ee --- /dev/null +++ b/extra/source/tigervnc/patches/xorg-server/e6ef2b12404dfec7f23592a3524d2a63d9d25802.patch @@ -0,0 +1,61 @@ +From e6ef2b12404dfec7f23592a3524d2a63d9d25802 Mon Sep 17 00:00:00 2001 +From: Marvin Schmidt <marv@exherbo.org> +Date: Tue, 24 Sep 2019 09:58:43 +0200 +Subject: [PATCH] build: glx: Lower gl version to work with libglvnd + +When using mesa with libglvnd support, mesa will no longer install the +gl, glx, egl pkg-config files but instead let libglvnd provide them. +libglvnd maintainers decided to change the versioning as it was +mesa-specific previously. Now the libraries have versions of the API +they expose[1]. +This causes problems when building the X server: + + checking for glproto >= 1.4.17 gl >= 9.2.0... no + configure: error: Package requirements (glproto >= 1.4.17 gl >= 9.2.0) were not met: + + Requested 'gl >= 9.2.0' but version of gl is 1.2 + +Lower the version requirement to 1.2 to allow building against libglvnd +provided libraries + +[1] https://github.com/NVIDIA/libglvnd/commit/0dfaea2bcb7cdcc785f95e244223bd004a2d7fba +--- + configure.ac | 4 ++-- + glx/meson.build | 2 +- + 2 files changed, 3 insertions(+), 3 deletions(-) + +diff --git a/configure.ac b/configure.ac +index 03c2e367c..969090b94 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -760,7 +760,7 @@ LIBDRI="dri >= 7.8.0" + LIBDRM="libdrm >= 2.4.89" + LIBEGL="egl" + LIBGBM="gbm >= 10.2.0" +-LIBGL="gl >= 7.1.0" ++LIBGL="gl >= 1.2" + LIBXEXT="xext >= 1.0.99.4" + LIBXFONT="xfont2 >= 2.0.0" + LIBXI="xi >= 1.2.99.1" +@@ -1115,7 +1115,7 @@ case "$DRI2,$HAVE_DRI2PROTO" in + yes,yes | auto,yes) + AC_DEFINE(DRI2, 1, [Build DRI2 extension]) + DRI2=yes +- LIBGL="gl >= 9.2.0" ++ LIBGL="gl >= 1.2" + SDK_REQUIRED_MODULES="$SDK_REQUIRED_MODULES $DRI2PROTO" + ;; + esac +diff --git a/glx/meson.build b/glx/meson.build +index 7f9e549f0..745814336 100644 +--- a/glx/meson.build ++++ b/glx/meson.build +@@ -39,7 +39,7 @@ if build_glx + common_dep, + dl_dep, + dependency('glproto', version: '>= 1.4.17'), +- dependency('gl', version: '>= 9.2.0'), ++ dependency('gl', version: '>= 1.2'), + ], + c_args: [ + glx_align64, diff --git a/extra/source/tigervnc/patches/xorg-server/fix-nouveau-segfault.diff b/extra/source/tigervnc/patches/xorg-server/fix-nouveau-segfault.diff new file mode 100644 index 00000000..db66956f --- /dev/null +++ b/extra/source/tigervnc/patches/xorg-server/fix-nouveau-segfault.diff @@ -0,0 +1,12 @@ +--- ./render/mipict.c.orig 2018-05-10 11:32:37.000000000 -0500 ++++ ./render/mipict.c 2018-05-30 00:01:50.648530333 -0500 +@@ -394,6 +394,9 @@ + CARD32 r, g, b, a; + miIndexedPtr pIndexed; + ++ if(! format) ++ *pixel = (color->alpha >> 8 << 24) | (color->red >> 8 << 16) | (color->green & 0xff00) | (color->blue >> 8); ++ else + switch (format->type) { + case PictTypeDirect: + r = color->red >> (16 - Ones(format->direct.redMask)); diff --git a/extra/source/tigervnc/patches/xorg-server/x11.startwithblackscreen.diff b/extra/source/tigervnc/patches/xorg-server/x11.startwithblackscreen.diff new file mode 100644 index 00000000..8c0e3b54 --- /dev/null +++ b/extra/source/tigervnc/patches/xorg-server/x11.startwithblackscreen.diff @@ -0,0 +1,14 @@ +diff -Nur xorg-server-1.12.1.orig/dix/window.c xorg-server-1.12.1/dix/window.c +--- xorg-server-1.12.1.orig/dix/window.c 2012-03-29 21:57:25.000000000 -0500 ++++ xorg-server-1.12.1/dix/window.c 2012-04-13 22:01:24.456073603 -0500 +@@ -145,8 +145,8 @@ + + Bool bgNoneRoot = FALSE; + +-static unsigned char _back_lsb[4] = { 0x88, 0x22, 0x44, 0x11 }; +-static unsigned char _back_msb[4] = { 0x11, 0x44, 0x22, 0x88 }; ++static unsigned char _back_lsb[4] = { 0x00, 0x00, 0x00, 0x00 }; ++static unsigned char _back_msb[4] = { 0x00, 0x00, 0x00, 0x00 }; + + static Bool WindowParentHasDeviceCursor(WindowPtr pWin, + DeviceIntPtr pDev, CursorPtr pCurs); diff --git a/extra/source/tigervnc/patches/xorg-server/xorg-server.combo.mouse.keyboard.layout.patch b/extra/source/tigervnc/patches/xorg-server/xorg-server.combo.mouse.keyboard.layout.patch new file mode 100644 index 00000000..83f67303 --- /dev/null +++ b/extra/source/tigervnc/patches/xorg-server/xorg-server.combo.mouse.keyboard.layout.patch @@ -0,0 +1,49 @@ +--- b/Xi/exevents.c 2013-12-27 19:38:52.000000000 +0200 ++++ a/Xi/exevents.c 2014-03-04 19:44:15.228721619 +0200 +@@ -665,7 +665,8 @@ + DeepCopyFeedbackClasses(from, to); + + if ((dce->flags & DEVCHANGE_KEYBOARD_EVENT)) +- DeepCopyKeyboardClasses(from, to); ++ /* We need to copy to MASTER_KEYBOARD. Didn't worked with 'to'. */ ++ DeepCopyKeyboardClasses(from, GetMaster(from, MASTER_KEYBOARD)); + if ((dce->flags & DEVCHANGE_POINTER_EVENT)) + DeepCopyPointerClasses(from, to); + } +--- b/dix/getevents.c 2013-12-27 19:38:52.000000000 +0200 ++++ a/dix/getevents.c 2014-03-04 19:46:50.126336327 +0200 +@@ -706,12 +706,19 @@ + { + DeviceIntPtr master; + +- master = +- GetMaster(dev, +- (type & DEVCHANGE_POINTER_EVENT) ? MASTER_POINTER : +- MASTER_KEYBOARD); ++ /* Don't guess the master upon the event type. Use MASTER_ATTACHED, ++ * otherwise we'll never get a DeviceChangedEvent(reason:SlaveSwith). */ ++ master = GetMaster(dev, MASTER_ATTACHED); ++ /* Need to track the slave event type. Other we'le never get a ++ * DeviceChangedEvent(reason:SlaveSwith) for the 'keyboard' if the ++ * 'pointer' has been touched before. */ ++ int slave_type = (type & DEVCHANGE_KEYBOARD_EVENT) | ++ (type & DEVCHANGE_POINTER_EVENT); + +- if (master && master->last.slave != dev) { ++ if (master && ++ ((master->last.slave != dev) || ++ (master->last.slave == dev && master->last.slave_type != slave_type))) { ++ master->last.slave_type = slave_type; + CreateClassesChangedEvent(events, master, dev, + type | DEVCHANGE_SLAVE_SWITCH); + if (IsPointerDevice(master)) { +--- b/include/inputstr.h 2013-12-27 19:38:52.000000000 +0200 ++++ a/include/inputstr.h 2014-03-04 19:47:28.074051116 +0200 +@@ -577,6 +577,7 @@ + double valuators[MAX_VALUATORS]; + int numValuators; + DeviceIntPtr slave; ++ int slave_type; + ValuatorMask *scroll; + int num_touches; /* size of the touches array */ + DDXTouchPointInfoPtr touches; diff --git a/extra/source/tigervnc/tigervnc.SlackBuild b/extra/source/tigervnc/tigervnc.SlackBuild index 20986e32..e681bed5 100755 --- a/extra/source/tigervnc/tigervnc.SlackBuild +++ b/extra/source/tigervnc/tigervnc.SlackBuild @@ -73,13 +73,14 @@ # * Reset build to -1 for inclusion in Slackware's /extra. # 1.6.0-1: 22/feb/2016 by Patrick Volkerding <volkerdi@slackware.com> # 1.9.0-1: 26/jul/2018 by Patrick Volkerding <volkerdi@slackware.com> +# 1.10.0-1: 18/nov/2019 by Patrick Volkerding <volkerdi@slackware.com> # # ----------------------------------------------------------------------------- PKGNAM=tigervnc -VERSION=${VERSION:-1.9.0} +VERSION=${VERSION:-1.10.0} PVER=$(echo $VERSION | cut -f 1,2 -d . | tr -d .) -BUILD=${BUILD:-2} +BUILD=${BUILD:-1} NUMJOBS=${NUMJOBS:-" -j$(expr $(nproc) + 1) "} TAG=${TAG:-} @@ -163,6 +164,20 @@ cd $TMP/tmp-${PKGNAM} tar --owner=root --group=root -xvf $CWD/sources/$PKGNAM-$VERSION.tar.?z* || exit 1 tar --owner=root --group=root -xvf $CWD/sources/xorg-server-${XORG}.tar.?z* || exit 1 +### BEGIN PATCHES FROM source/x/x11/patch +( cd xorg-server-${XORG} + zcat $CWD/patches/xorg-server/x11.startwithblackscreen.diff.gz | patch -p1 --verbose || exit 1 + zcat $CWD/patches/xorg-server/xorg-server.combo.mouse.keyboard.layout.patch.gz | patch -p1 --verbose || exit 1 + zcat $CWD/patches/xorg-server/fix-nouveau-segfault.diff.gz | patch -p1 --verbose || exit 1 + zcat $CWD/patches/xorg-server/0001-Always-install-vbe-and-int10-sdk-headers.patch.gz | patch -p1 --verbose || exit 1 + zcat $CWD/patches/xorg-server/0001-autobind-GPUs-to-the-screen.patch.gz | patch -p1 --verbose || exit 1 + zcat $CWD/patches/xorg-server/0001-xfree86-use-modesetting-driver-by-default-on-GeForce.patch.gz | patch -p1 --verbose || exit 1 + zcat $CWD/patches/xorg-server/e6ef2b12404dfec7f23592a3524d2a63d9d25802.patch.gz | patch -p1 --verbose || exit 1 + zcat $CWD/patches/xorg-server/c7486613b0dc586f93f6ba293d9b55c69995b05c.patch.gz | patch -p1 --verbose || exit 1 + zcat $CWD/patches/xorg-server/0001-replace-MESA_EGL_NO_X11_HEADERS-hack-with-upstream-E.patch.gz | patch -p1 --verbose || exit 1 +) || exit 1 +### END PATCHES FROM source/x/x11/patch + # Make sure ownerships and permissions are sane: chown -R root:root . find . \ @@ -185,13 +200,13 @@ EOT cd $PKGNAM-$VERSION || exit 1 # HACK! Force protocol 3.3 for UVNCSC -patch -p1 < $CWD/patches/force_protocol_3.3_for_UVNCSC.patch +zcat $CWD/patches/force_protocol_3.3_for_UVNCSC.patch.gz | patch -p1 || exit 1 ## Patch to support x.org 1.20 (already included in tigervnc-1.9.0): -#cat $CWD/patches/tigervnc-support-xorg120.patch | patch -p1 --verbose || exit 1 +#zcat $CWD/patches/tigervnc-support-xorg120.patch.gz | patch -p1 --verbose || exit 1 # Explicitly link against libpng to prevent linking errors: -cat $CWD/patches/tigervnc13_link_png.patch | patch -p1 --verbose || exit 1 +zcat $CWD/patches/tigervnc13_link_png.patch.gz | patch -p1 --verbose || exit 1 [ "$DO_APPLET" = "YES" ] && CMAKE_JAVA="ON" || CMAKE_JAVA="OFF" # Explicitly put the java applet into a directory named 'tigervnc': @@ -223,19 +238,20 @@ make V=1 $NUMJOBS || make || exit 1 make DESTDIR=$PKG install || exit 1 # Do we have a patch for X.Org which tigervnc does not have? -if [ ! -f unix/xserver${MAXPATCHVER}.patch -a -f $CWD/patches/xserver${MAXPATCHVER}.patch ] +if [ ! -f unix/xserver${MAXPATCHVER}.patch.gz -a -f $CWD/patches/xserver${MAXPATCHVER}.patch.gz ] then - cp $CWD/patches/xserver${MAXPATCHVER}.patch unix/ + cp $CWD/patches/xserver${MAXPATCHVER}.patch.gz unix/ fi # Prepare the Xvnc sources (we are building out-of-tree, in ./build directory): mkdir -p build/unix -cp -R unix/xserver unix/xserver${MAXPATCHVER}.patch build/unix/ +cp -R unix/xserver unix/xserver${MAXPATCHVER}.patch.gz build/unix/ cp -R ../xorg-server-${XORG}/* build/unix/xserver/ cd build/unix/xserver/ # Patch the xorg-server source to include building vnc driver: - cat ../xserver${MAXPATCHVER}.patch | patch -p1 --verbose + zcat ../xserver${MAXPATCHVER}.patch.gz | patch -p1 --verbose + echo -e "\n*** Building vnc server ***\n" autoreconf -vif |