diff --git a/.gitignore b/.gitignore index 29790d0..ae892e8 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,36 @@ +xorg-server-1.9.1.tar.bz2 +/xorg-server-20101125.tar.xz +/xorg-server-20101201.tar.xz +/xorg-server-1.10.0.tar.bz2 +/xorg-server-20110418.tar.xz +/xorg-server-20110510.tar.xz +/xorg-server-20110818.tar.xz +/xorg-server-1.11.0.tar.bz2 +/xorg-server-1.11.1.tar.bz2 +/xorg-server-20111109.tar.xz +/xorg-server-20120103.tar.xz +/xorg-server-20120124.tar.xz +/xorg-server-20120215.tar.xz +/xorg-server-1.12.0.tar.bz2 +/xorg-server-1.12.1.tar.bz2 +/xorg-server-1.12.2.tar.bz2 +/xorg-server-1.12.3.tar.bz2 +/xorg-server-20120717.tar.xz +/xorg-server-20120726.tar.xz +/xorg-server-20120808.tar.xz +/xorg-server-20120822.tar.xz +/xorg-server-1.13.0.tar.bz2 +/xorg-server-1.13.1.tar.bz2 +/xorg-server-20130109.tar.xz +/xorg-server-20130215.tar.xz +/xorg-server-1.14.0.tar.bz2 +/xorg-server-1.14.1.tar.bz2 +/xorg-server-1.14.1.901.tar.bz2 +/xorg-server-1.14.2.tar.bz2 +/xorg-server-1.14.3.tar.bz2 +/xorg-server-1.14.99.3.tar.bz2 +/xorg-server-1.14.99.901.tar.bz2 +/xorg-server-1.14.99.902.tar.bz2 *.bz2 *.xz -*.gz +/xorg-x11-server-1.15.0-1.fc21.src.rpm diff --git a/0001-Xi-return-AlreadyGrabbed-for-key-grabs-255.patch b/0001-Xi-return-AlreadyGrabbed-for-key-grabs-255.patch new file mode 100644 index 0000000..9c846d0 --- /dev/null +++ b/0001-Xi-return-AlreadyGrabbed-for-key-grabs-255.patch @@ -0,0 +1,42 @@ +From 0ad717edcf372425ddf2ba9926857419ab62f4f5 Mon Sep 17 00:00:00 2001 +From: Peter Hutterer +Date: Wed, 29 May 2019 16:19:55 +1000 +Subject: [PATCH xserver] Xi: return AlreadyGrabbed for key grabs > 255 + +We can't have high keycodes because everything in XKB relies on 8 bits. XI2's +API allows for 32-bit keycodes so we have to take those but nothing in the +server is really ready for this. The effect of this right now is that any high +keycode grab is clipped to 255 and thus ends up grabbing a different key +instead. + +https://bugzilla.redhat.com/show_bug.cgi?id=1697804 + +Signed-off-by: Peter Hutterer +--- + Xi/xipassivegrab.c | 10 ++++++++-- + 1 file changed, 8 insertions(+), 2 deletions(-) + +diff --git a/Xi/xipassivegrab.c b/Xi/xipassivegrab.c +index 65d5870f6..d30f51f3c 100644 +--- a/Xi/xipassivegrab.c ++++ b/Xi/xipassivegrab.c +@@ -203,8 +203,14 @@ ProcXIPassiveGrabDevice(ClientPtr client) + ¶m, XI2, &mask); + break; + case XIGrabtypeKeycode: +- status = GrabKey(client, dev, mod_dev, stuff->detail, +- ¶m, XI2, &mask); ++ /* XI2 allows 32-bit keycodes but thanks to XKB we can never ++ * implement this. Just return an error for all keycodes that ++ * cannot work anyway */ ++ if (stuff->detail > 255) ++ status = XIAlreadyGrabbed; ++ else ++ status = GrabKey(client, dev, mod_dev, stuff->detail, ++ ¶m, XI2, &mask); + break; + case XIGrabtypeEnter: + case XIGrabtypeFocusIn: +-- +2.21.0 + diff --git a/0001-autobind-GPUs-to-the-screen.patch b/0001-autobind-GPUs-to-the-screen.patch new file mode 100644 index 0000000..86b96a2 --- /dev/null +++ b/0001-autobind-GPUs-to-the-screen.patch @@ -0,0 +1,293 @@ +From 471289fa1dc359555ceed6302f7d9605ab6be3ea Mon Sep 17 00:00:00 2001 +From: Dave Airlie +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 +[hdegoede@redhat.com: Make configurable, fix with nvidia, submit upstream] +Signed-off-by: Hans de Goede +--- + 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/0001-dix-leave-last.valuators-alone-on-slave-switch.patch b/0001-dix-leave-last.valuators-alone-on-slave-switch.patch new file mode 100644 index 0000000..10c7177 --- /dev/null +++ b/0001-dix-leave-last.valuators-alone-on-slave-switch.patch @@ -0,0 +1,89 @@ +From 13f9b07039484927532d913dbccc664679235bf6 Mon Sep 17 00:00:00 2001 +From: Peter Hutterer +Date: Mon, 25 Mar 2019 13:19:41 +1000 +Subject: [PATCH xserver] dix: leave last.valuators alone on slave switch + +Terms: +dev->last.valuator[] is the last value given to us by the driver +dev->valuator.axisVal[] is the last value sent to the client +dev->last.scroll[] is the abs value of the scroll axis as given by the driver, + used for button emulation calculation (and the remainder) + +This function updates the device's last.valuator state based on the current +master axis state. This way, relative motion continues fluidly when switching +between devices. Before mouse 2 comes into effect, it's valuator state is +updated to wherever the pointer currently is so the relative event applies on +top of that. + +This can only work for x/y axes, all other axes aren't guaranteed to have the +same meaning and/or may not be present: +- xtest device: no valuator 2 +- mouse: valuator 2 is horizontal scroll axis +- tablet: valuator 2 is pressure + +Scaling the current value from the pressure range into the range for +horizontal scrolling makes no sense. And it causes scroll jumps: + +- scroll down, last.valuator == axisVal == 20 +- xdotool click 1, the XTest device doesn't have that valuator +- scroll up + - updateSlaveDeviceCoords reset last.valuator to 0 (axisVal == 20) + - DeviceClassesChangedEvent includes value 20 for the axis + - event is processed, last.value changes from 0 to -1 + - axisVal is updated to -1, causing a jump of -21 + +The same applies when we switch from tablet to mouse wheel if the pressure +value is 0 on proximity out (basically guaranteed). So let's drop this code +altogether and only leave the scaling for the relative x/y motion. + +Signed-off-by: Peter Hutterer +--- + dix/getevents.c | 25 +------------------------ + 1 file changed, 1 insertion(+), 24 deletions(-) + +diff --git a/dix/getevents.c b/dix/getevents.c +index d8955969a..f83dac709 100644 +--- a/dix/getevents.c ++++ b/dix/getevents.c +@@ -331,9 +331,6 @@ rescaleValuatorAxis(double coord, AxisInfoPtr from, AxisInfoPtr to, + static void + updateSlaveDeviceCoords(DeviceIntPtr master, DeviceIntPtr pDev) + { +- int i; +- DeviceIntPtr lastSlave; +- + /* master->last.valuators[0]/[1] is in desktop-wide coords and the actual + * position of the pointer */ + pDev->last.valuators[0] = master->last.valuators[0]; +@@ -358,27 +355,7 @@ updateSlaveDeviceCoords(DeviceIntPtr master, DeviceIntPtr pDev) + screenInfo.height); + } + +- /* calculate the other axis as well based on info from the old +- * slave-device. If the old slave had less axes than this one, +- * last.valuators is reset to 0. +- */ +- if ((lastSlave = master->last.slave) && lastSlave->valuator) { +- for (i = 2; i < pDev->valuator->numAxes; i++) { +- if (i >= lastSlave->valuator->numAxes) { +- pDev->last.valuators[i] = 0; +- valuator_mask_set_double(pDev->last.scroll, i, 0); +- } +- else { +- double val = pDev->last.valuators[i]; +- +- val = rescaleValuatorAxis(val, lastSlave->valuator->axes + i, +- pDev->valuator->axes + i, 0, 0); +- pDev->last.valuators[i] = val; +- valuator_mask_set_double(pDev->last.scroll, i, val); +- } +- } +- } +- ++ /* other axes are left as-is */ + } + + /** +-- +2.20.1 + diff --git a/0001-modesetting-Weaksauce-atomic-property-debugging.patch b/0001-modesetting-Weaksauce-atomic-property-debugging.patch new file mode 100644 index 0000000..7c9b9a0 --- /dev/null +++ b/0001-modesetting-Weaksauce-atomic-property-debugging.patch @@ -0,0 +1,64 @@ +From 6915752b2da77c29bf8c861a6d4f2383e667323b Mon Sep 17 00:00:00 2001 +From: Adam Jackson +Date: Fri, 5 Oct 2018 14:07:46 -0400 +Subject: [PATCH xserver 1/4] modesetting: Weaksauce atomic property debugging + +This would be a good idea to have around for troubleshooting purposes, +but this particular patch is Not Good. + +Signed-off-by: Adam Jackson +--- + hw/xfree86/drivers/modesetting/drmmode_display.c | 16 +++++++++++++--- + 1 file changed, 13 insertions(+), 3 deletions(-) + +diff --git a/hw/xfree86/drivers/modesetting/drmmode_display.c b/hw/xfree86/drivers/modesetting/drmmode_display.c +index cb48aa46b..a8d989a24 100644 +--- a/hw/xfree86/drivers/modesetting/drmmode_display.c ++++ b/hw/xfree86/drivers/modesetting/drmmode_display.c +@@ -415,6 +415,13 @@ drmmode_ConvertToKMode(ScrnInfoPtr scrn, + drmModeModeInfo * kmode, DisplayModePtr mode); + + ++static int ++drmmodeatomicaddproperty(drmModeAtomicReqPtr req, uint32_t obj, uint32_t prop, uint64_t value) ++{ ++ ErrorF("Adding to %p: %x %x %lx\n", req, obj, prop, value); ++ return drmModeAtomicAddProperty(req, obj, prop, value); ++} ++ + static int + plane_add_prop(drmModeAtomicReq *req, drmmode_crtc_private_ptr drmmode_crtc, + enum drmmode_plane_property prop, uint64_t val) +@@ -425,7 +432,8 @@ plane_add_prop(drmModeAtomicReq *req, drmmode_crtc_private_ptr drmmode_crtc, + if (!info) + return -1; + +- ret = drmModeAtomicAddProperty(req, drmmode_crtc->plane_id, ++ ErrorF("Setting %s\n", info->name); ++ ret = drmmodeatomicaddproperty(req, drmmode_crtc->plane_id, + info->prop_id, val); + return (ret <= 0) ? -1 : 0; + } +@@ -467,7 +475,8 @@ crtc_add_prop(drmModeAtomicReq *req, drmmode_crtc_private_ptr drmmode_crtc, + if (!info) + return -1; + +- ret = drmModeAtomicAddProperty(req, drmmode_crtc->mode_crtc->crtc_id, ++ ErrorF("Setting %s\n", info->name); ++ ret = drmmodeatomicaddproperty(req, drmmode_crtc->mode_crtc->crtc_id, + info->prop_id, val); + return (ret <= 0) ? -1 : 0; + } +@@ -482,7 +491,8 @@ connector_add_prop(drmModeAtomicReq *req, drmmode_output_private_ptr drmmode_out + if (!info) + return -1; + +- ret = drmModeAtomicAddProperty(req, drmmode_output->output_id, ++ ErrorF("Setting %s\n", info->name); ++ ret = drmmodeatomicaddproperty(req, drmmode_output->output_id, + info->prop_id, val); + return (ret <= 0) ? -1 : 0; + } +-- +2.20.1 + diff --git a/0001-xf86-dri2-Use-va_gl-as-vdpau_driver-for-Intel-i965-G.patch b/0001-xf86-dri2-Use-va_gl-as-vdpau_driver-for-Intel-i965-G.patch index 2134a44..cce0348 100644 --- a/0001-xf86-dri2-Use-va_gl-as-vdpau_driver-for-Intel-i965-G.patch +++ b/0001-xf86-dri2-Use-va_gl-as-vdpau_driver-for-Intel-i965-G.patch @@ -52,7 +52,7 @@ index 6619e3aa7..1f8ad14bc 100644 /* For non-PCI devices and drmGetDevice fail, just assume that * the 3D driver is named the same as the kernel driver. This is * currently true for vc4 and msm (freedreno). -@@ -1454,12 +1458,14 @@ dri2_probe_driver_name(ScreenPtr pScreen, DRI2InfoPtr info) +@@ -1456,12 +1460,14 @@ dri2_probe_driver_name(ScreenPtr pScreen, DRI2InfoPtr info) xf86DrvMsg(pScreen->myNum, X_ERROR, "[DRI2] Couldn't drmGetVersion() on non-PCI device, " "no driver name found.\n"); @@ -70,7 +70,7 @@ index 6619e3aa7..1f8ad14bc 100644 } for (i = 0; driver_map[i].driver; i++) { -@@ -1467,13 +1473,15 @@ dri2_probe_driver_name(ScreenPtr pScreen, DRI2InfoPtr info) +@@ -1469,13 +1475,15 @@ dri2_probe_driver_name(ScreenPtr pScreen, DRI2InfoPtr info) continue; if (driver_map[i].num_chips_ids == -1) { @@ -88,7 +88,7 @@ index 6619e3aa7..1f8ad14bc 100644 goto out; } } -@@ -1485,9 +1493,9 @@ dri2_probe_driver_name(ScreenPtr pScreen, DRI2InfoPtr info) +@@ -1487,9 +1495,9 @@ dri2_probe_driver_name(ScreenPtr pScreen, DRI2InfoPtr info) dev->deviceinfo.pci->vendor_id, dev->deviceinfo.pci->device_id); out: drmFreeDevice(&dev); @@ -100,21 +100,21 @@ index 6619e3aa7..1f8ad14bc 100644 #endif } -@@ -1604,7 +1612,8 @@ DRI2ScreenInit(ScreenPtr pScreen, DRI2InfoPtr info) +@@ -1610,7 +1618,8 @@ DRI2ScreenInit(ScreenPtr pScreen, DRI2InfoPtr info) + if (info->driverName) { + ds->driverNames[0] = info->driverName; } else { - /* FIXME dri2_probe_driver_name() returns a strdup-ed string, - * currently this gets leaked */ - ds->driverNames[0] = ds->driverNames[1] = dri2_probe_driver_name(pScreen, info); + dri2_probe_driver_name(pScreen, info, + &ds->driverNames[0], &ds->driverNames[1]); if (!ds->driverNames[0]) return FALSE; - + } diff --git a/hw/xfree86/dri2/pci_ids/pci_id_driver_map.h b/hw/xfree86/dri2/pci_ids/pci_id_driver_map.h index da7ea1c1e..7036d1003 100644 --- a/hw/xfree86/dri2/pci_ids/pci_id_driver_map.h +++ b/hw/xfree86/dri2/pci_ids/pci_id_driver_map.h -@@ -60,23 +60,24 @@ static const int vmwgfx_chip_ids[] = { +@@ -66,21 +66,22 @@ static const int vmwgfx_chip_ids[] = { static const struct { int vendor_id; const char *driver; @@ -124,10 +124,8 @@ index da7ea1c1e..7036d1003 100644 } driver_map[] = { - { 0x8086, "i915", i915_chip_ids, ARRAY_SIZE(i915_chip_ids) }, - { 0x8086, "i965", i965_chip_ids, ARRAY_SIZE(i965_chip_ids) }, -- { 0x8086, "i965", NULL, -1 }, + { 0x8086, "i915", "i915", i915_chip_ids, ARRAY_SIZE(i915_chip_ids) }, + { 0x8086, "i965", "va_gl", i965_chip_ids, ARRAY_SIZE(i965_chip_ids) }, -+ { 0x8086, "i965", "va_gl", NULL, -1 }, #ifndef DRIVER_MAP_GALLIUM_ONLY - { 0x1002, "radeon", r100_chip_ids, ARRAY_SIZE(r100_chip_ids) }, - { 0x1002, "r200", r200_chip_ids, ARRAY_SIZE(r200_chip_ids) }, @@ -136,18 +134,19 @@ index da7ea1c1e..7036d1003 100644 #endif - { 0x1002, "r300", r300_chip_ids, ARRAY_SIZE(r300_chip_ids) }, - { 0x1002, "r600", r600_chip_ids, ARRAY_SIZE(r600_chip_ids) }, -- { 0x1002, "radeonsi", NULL, -1 }, +- { 0x1002, "radeonsi", radeonsi_chip_ids, ARRAY_SIZE(radeonsi_chip_ids) }, - { 0x10de, "nouveau", NULL, -1 }, - { 0x1af4, "virtio_gpu", virtio_gpu_chip_ids, ARRAY_SIZE(virtio_gpu_chip_ids) }, - { 0x15ad, "vmwgfx", vmwgfx_chip_ids, ARRAY_SIZE(vmwgfx_chip_ids) }, -- { 0x0000, NULL, NULL, 0 }, + { 0x1002, "r300", "r300", r300_chip_ids, ARRAY_SIZE(r300_chip_ids) }, -+ { 0x1002, "r600", "r600", r600_chip_ids, ARRAY_SIZE(r600_chip_ids) }, -+ { 0x1002, "radeonsi", "radeonsi", NULL, -1 }, ++ { 0x1002, "r600","r600", r600_chip_ids, ARRAY_SIZE(r600_chip_ids) }, ++ { 0x1002, "radeonsi", "radeonsi", radeonsi_chip_ids, ARRAY_SIZE(radeonsi_chip_ids) }, + { 0x10de, "nouveau", "nouveau", NULL, -1 }, + { 0x1af4, "virtio_gpu", "virtio_gpu", virtio_gpu_chip_ids, ARRAY_SIZE(virtio_gpu_chip_ids) }, + { 0x15ad, "vmwgfx", "vmwgfx", vmwgfx_chip_ids, ARRAY_SIZE(vmwgfx_chip_ids) }, -+ { 0x0000, NULL, NULL, NULL, 0 }, + { 0x0000, NULL, NULL, 0 }, }; - #endif /* _PCI_ID_DRIVER_MAP_H_ */ +-- +2.19.0 + diff --git a/0001-xwayland-present-Destroy-sync_callback-in-xwl_presen.patch b/0001-xwayland-present-Destroy-sync_callback-in-xwl_presen.patch new file mode 100644 index 0000000..58c78d2 --- /dev/null +++ b/0001-xwayland-present-Destroy-sync_callback-in-xwl_presen.patch @@ -0,0 +1,36 @@ +From 2e18eec6f03cc4d9d5bf62853c65d341b363f4b3 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Michel=20D=C3=A4nzer?= +Date: Fri, 8 Mar 2019 18:49:04 +0100 +Subject: [PATCH xserver] xwayland/present: Destroy sync_callback in + xwl_present_cleanup + +xwl_present_cleanup frees the struct xwl_present_window memory, +so if there's a pending callback, we have to destroy it to prevent +use-after-free in xwl_present_sync_callback. + +Should fix issue #645. + +Reviewed-by: Olivier Fourdan +--- + hw/xwayland/xwayland-present.c | 5 +++++ + 1 file changed, 5 insertions(+) + +diff --git a/hw/xwayland/xwayland-present.c b/hw/xwayland/xwayland-present.c +index 192f59a653..a1b3109cc2 100644 +--- a/hw/xwayland/xwayland-present.c ++++ b/hw/xwayland/xwayland-present.c +@@ -123,6 +123,11 @@ xwl_present_cleanup(WindowPtr window) + xwl_present_window->frame_callback = NULL; + } + ++ if (xwl_present_window->sync_callback) { ++ wl_callback_destroy(xwl_present_window->sync_callback); ++ xwl_present_window->sync_callback = NULL; ++ } ++ + /* Clear remaining events */ + xorg_list_for_each_entry_safe(event, tmp, &xwl_present_window->event_list, list) { + xorg_list_del(&event->list); +-- +2.20.1 + diff --git a/0002-modesetting-Propagate-more-failure-in-drmmode_set_mo.patch b/0002-modesetting-Propagate-more-failure-in-drmmode_set_mo.patch new file mode 100644 index 0000000..47195a1 --- /dev/null +++ b/0002-modesetting-Propagate-more-failure-in-drmmode_set_mo.patch @@ -0,0 +1,31 @@ +From e262c8ae0039710422c11ae254ddb4ae7e6fac02 Mon Sep 17 00:00:00 2001 +From: Adam Jackson +Date: Fri, 5 Oct 2018 14:03:54 -0400 +Subject: [PATCH xserver 2/4] modesetting: Propagate more failure in + drmmode_set_mode_major + +It's possible that actually setting the mode would fail even though the +check succeeded. We would throw away the error in this case, which would +probably make recovery a bit difficult. + +Signed-off-by: Adam Jackson +--- + hw/xfree86/drivers/modesetting/drmmode_display.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/hw/xfree86/drivers/modesetting/drmmode_display.c b/hw/xfree86/drivers/modesetting/drmmode_display.c +index a8d989a24..33f6cea3b 100644 +--- a/hw/xfree86/drivers/modesetting/drmmode_display.c ++++ b/hw/xfree86/drivers/modesetting/drmmode_display.c +@@ -1540,7 +1540,7 @@ drmmode_set_mode_major(xf86CrtcPtr crtc, DisplayModePtr mode, + + /* if we only tested the mode previously, really set it now */ + if (can_test) +- drmmode_crtc_set_mode(crtc, FALSE); ++ ret = drmmode_crtc_set_mode(crtc, FALSE); + ms->pending_modeset = FALSE; + } + +-- +2.20.1 + diff --git a/0003-modesetting-Factor-out-drmmode_target_output.patch b/0003-modesetting-Factor-out-drmmode_target_output.patch new file mode 100644 index 0000000..fee4296 --- /dev/null +++ b/0003-modesetting-Factor-out-drmmode_target_output.patch @@ -0,0 +1,64 @@ +From e7f0961638818df8ee91edfae0378a02f7177e9f Mon Sep 17 00:00:00 2001 +From: Adam Jackson +Date: Fri, 5 Oct 2018 14:00:33 -0400 +Subject: [PATCH xserver 3/4] modesetting: Factor out drmmode_target_output + +Signed-off-by: Adam Jackson +--- + .../drivers/modesetting/drmmode_display.c | 26 ++++++++++++------- + 1 file changed, 16 insertions(+), 10 deletions(-) + +diff --git a/hw/xfree86/drivers/modesetting/drmmode_display.c b/hw/xfree86/drivers/modesetting/drmmode_display.c +index 33f6cea3b..7924aa396 100644 +--- a/hw/xfree86/drivers/modesetting/drmmode_display.c ++++ b/hw/xfree86/drivers/modesetting/drmmode_display.c +@@ -757,6 +757,21 @@ drmmode_crtc_disable(xf86CrtcPtr crtc) + return ret; + } + ++static xf86OutputPtr ++drmmode_target_output(ScrnInfoPtr scrn, xf86CrtcPtr crtc) ++{ ++ xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(scrn); ++ int o; ++ ++ if (config->output[config->compat_output]->crtc == crtc) ++ return config->output[config->compat_output]; ++ ++ for (o = 0; o < config->num_output; o++) ++ if (config->output[o]->crtc == crtc) ++ return config->output[o]; ++ ++ return NULL; ++} + static int + drmmode_crtc_set_mode(xf86CrtcPtr crtc, Bool test_only) + { +@@ -3448,7 +3463,6 @@ drmmode_set_desired_modes(ScrnInfoPtr pScrn, drmmode_ptr drmmode, Bool set_hw) + xf86CrtcPtr crtc = config->crtc[c]; + drmmode_crtc_private_ptr drmmode_crtc = crtc->driver_private; + xf86OutputPtr output = NULL; +- int o; + + /* Skip disabled CRTCs */ + if (!crtc->enabled) { +@@ -3459,15 +3473,7 @@ drmmode_set_desired_modes(ScrnInfoPtr pScrn, drmmode_ptr drmmode, Bool set_hw) + continue; + } + +- if (config->output[config->compat_output]->crtc == crtc) +- output = config->output[config->compat_output]; +- else { +- for (o = 0; o < config->num_output; o++) +- if (config->output[o]->crtc == crtc) { +- output = config->output[o]; +- break; +- } +- } ++ output = drmmode_target_output(pScrn, crtc); + /* paranoia */ + if (!output) + continue; +-- +2.20.1 + diff --git a/0004-modesetting-Use-atomic-instead-of-per-crtc-walks-whe.patch b/0004-modesetting-Use-atomic-instead-of-per-crtc-walks-whe.patch new file mode 100644 index 0000000..3cc6d8d --- /dev/null +++ b/0004-modesetting-Use-atomic-instead-of-per-crtc-walks-whe.patch @@ -0,0 +1,245 @@ +From e4e389447c59c89d39a5a78a5f19cdfd22d7699c Mon Sep 17 00:00:00 2001 +From: Adam Jackson +Date: Fri, 5 Oct 2018 14:09:35 -0400 +Subject: [PATCH xserver 4/4] modesetting: Use atomic instead of per-crtc walks + where we can + +drmmode_set_desired_modes (reachable from CreateScreenResources, +EnterVT, etc.) currently works by doing ->set_mode_major on each CRTC. +This is silly, as atomic lets us configure every CRTC at once. It's also +fragile, because we're not trying very hard to ensure the intermediate +states are valid. + +This patch introduces drmmode_set_mode_atomic, which blasts the entire +RANDR state into the kernel in an... atomic... fashion. We change +drmmode_set_desired_modes and drmmode_xf86crtc_resize to use this +instead of walking each CRTC. We also change drmmode_crtc_set_mode to +use this, so that client RANDR requests (operating CRTC-at-a-time, since +RANDR doesn't have atomic changes yet) use the same code paths. + +Signed-off-by: Adam Jackson +--- + .../drivers/modesetting/drmmode_display.c | 179 +++++++++++------- + 1 file changed, 109 insertions(+), 70 deletions(-) + +diff --git a/hw/xfree86/drivers/modesetting/drmmode_display.c b/hw/xfree86/drivers/modesetting/drmmode_display.c +index 7924aa396..020678155 100644 +--- a/hw/xfree86/drivers/modesetting/drmmode_display.c ++++ b/hw/xfree86/drivers/modesetting/drmmode_display.c +@@ -772,6 +772,96 @@ drmmode_target_output(ScrnInfoPtr scrn, xf86CrtcPtr crtc) + + return NULL; + } ++ ++static int ++drmmode_set_mode_atomic(ScrnInfoPtr scrn, modesettingPtr ms, Bool test_only) ++{ ++ xf86CrtcConfigPtr xf86_config = XF86_CRTC_CONFIG_PTR(scrn); ++ drmModeAtomicReq *req = drmModeAtomicAlloc(); ++ uint32_t flags = DRM_MODE_ATOMIC_ALLOW_MODESET; ++ int i, j, ret = 0; ++ ++ if (!req) ++ return 1; ++ ++ for (i = 0; i < xf86_config->num_crtc; i++) { ++ xf86CrtcPtr crtc = xf86_config->crtc[i]; ++ drmmode_crtc_private_ptr drmmode_crtc = crtc->driver_private; ++ Bool active = crtc->enabled; ++ uint32_t fb_id; ++ int x, y; ++ drmModeModeInfo kmode; ++ ++ if (active) { ++ drmmode_ConvertToKMode(crtc->scrn, &kmode, &crtc->desiredMode); ++ ret |= drm_mode_ensure_blob(crtc, kmode); ++ ++ /* XXX this probably doesn't belong here */ ++ if (!crtc->mode.HDisplay && crtc->desiredMode.HDisplay) ++ memcpy(&crtc->mode, &crtc->desiredMode, sizeof(crtc->mode)); ++ } ++ ++ ret |= !drmmode_crtc_get_fb_id(crtc, &fb_id, &x, &y); ++ ret |= crtc_add_prop(req, drmmode_crtc, ++ DRMMODE_CRTC_ACTIVE, active); ++ ret |= crtc_add_prop(req, drmmode_crtc, ++ DRMMODE_CRTC_MODE_ID, ++ active ? drmmode_crtc->current_mode->blob_id : 0); ++ ret |= plane_add_props(req, crtc, active ? fb_id : 0, x, y); ++ } ++ ++ for (i = 0; i < xf86_config->num_output; i++) { ++ xf86OutputPtr output = xf86_config->output[i]; ++ drmmode_output_private_ptr drmmode_output = output->driver_private; ++ drmmode_crtc_private_ptr drm_crtc = ++ output->crtc ? output->crtc->driver_private : NULL; ++ ++ if (drmmode_output->output_id == -1) ++ continue; ++ ++ ret |= connector_add_prop(req, drmmode_output, ++ DRMMODE_CONNECTOR_CRTC_ID, ++ drm_crtc ? drm_crtc->mode_crtc->crtc_id : 0); ++ } ++ ++ if (test_only) ++ flags |= DRM_MODE_ATOMIC_TEST_ONLY; ++ ++ if (ret == 0) ++ ret = drmModeAtomicCommit(ms->fd, req, flags, NULL); ++ ++ if (ret == 0 && !test_only) { ++ for (i = 0; i < xf86_config->num_crtc; i++) { ++ xf86CrtcPtr crtc = xf86_config->crtc[i]; ++ for (j = 0; i < xf86_config->num_output; i++) { ++ xf86OutputPtr output = xf86_config->output[j]; ++ drmmode_output_private_ptr drmmode_output = ++ output->driver_private; ++ ++ if (output->crtc == crtc) ++ drmmode_output->current_crtc = crtc; ++ else if (drmmode_output->current_crtc == crtc) ++ drmmode_output->current_crtc = NULL; ++ } ++ } ++ } ++ ++ if (ret == 0 && test_only) { ++ for (i = 0; i < xf86_config->num_crtc; i++) { ++ xf86CrtcPtr crtc = xf86_config->crtc[i]; ++ crtc->mode = crtc->desiredMode; ++ crtc->rotation = crtc->desiredRotation; ++ crtc->x = crtc->desiredX; ++ crtc->y = crtc->desiredY; ++ if (!xf86CrtcRotate(crtc)) ++ ret = 1; ++ } ++ } ++ ++ drmModeAtomicFree(req); ++ return ret; ++} ++ + static int + drmmode_crtc_set_mode(xf86CrtcPtr crtc, Bool test_only) + { +@@ -786,73 +876,12 @@ drmmode_crtc_set_mode(xf86CrtcPtr crtc, Bool test_only) + int x, y; + int i, ret = 0; + ++ if (ms->atomic_modeset) ++ return drmmode_set_mode_atomic(crtc->scrn, ms, test_only); ++ + if (!drmmode_crtc_get_fb_id(crtc, &fb_id, &x, &y)) + return 1; + +- if (ms->atomic_modeset) { +- drmModeAtomicReq *req = drmModeAtomicAlloc(); +- Bool active; +- uint32_t flags = DRM_MODE_ATOMIC_ALLOW_MODESET; +- +- if (!req) +- return 1; +- +- ret |= crtc_add_dpms_props(req, crtc, DPMSModeOn, &active); +- ret |= plane_add_props(req, crtc, active ? fb_id : 0, x, y); +- +- /* Orphaned CRTCs need to be disabled right now in atomic mode */ +- for (i = 0; i < xf86_config->num_crtc; i++) { +- xf86CrtcPtr other_crtc = xf86_config->crtc[i]; +- drmmode_crtc_private_ptr other_drmmode_crtc = other_crtc->driver_private; +- int lost_outputs = 0; +- int remaining_outputs = 0; +- int j; +- +- if (other_crtc == crtc) +- continue; +- +- for (j = 0; j < xf86_config->num_output; j++) { +- xf86OutputPtr output = xf86_config->output[j]; +- drmmode_output_private_ptr drmmode_output = output->driver_private; +- +- if (drmmode_output->current_crtc == other_crtc) { +- if (output->crtc == crtc) +- lost_outputs++; +- else +- remaining_outputs++; +- } +- } +- +- if (lost_outputs > 0 && remaining_outputs == 0) { +- ret |= crtc_add_prop(req, other_drmmode_crtc, +- DRMMODE_CRTC_ACTIVE, 0); +- ret |= crtc_add_prop(req, other_drmmode_crtc, +- DRMMODE_CRTC_MODE_ID, 0); +- } +- } +- +- if (test_only) +- flags |= DRM_MODE_ATOMIC_TEST_ONLY; +- +- if (ret == 0) +- ret = drmModeAtomicCommit(ms->fd, req, flags, NULL); +- +- if (ret == 0 && !test_only) { +- for (i = 0; i < xf86_config->num_output; i++) { +- xf86OutputPtr output = xf86_config->output[i]; +- drmmode_output_private_ptr drmmode_output = output->driver_private; +- +- if (output->crtc == crtc) +- drmmode_output->current_crtc = crtc; +- else if (drmmode_output->current_crtc == crtc) +- drmmode_output->current_crtc = NULL; +- } +- } +- +- drmModeAtomicFree(req); +- return ret; +- } +- + output_ids = calloc(sizeof(uint32_t), xf86_config->num_output); + if (!output_ids) + return -1; +@@ -3199,14 +3228,19 @@ drmmode_xf86crtc_resize(ScrnInfoPtr scrn, int width, int height) + if (!drmmode_glamor_handle_new_screen_pixmap(drmmode)) + goto fail; + +- for (i = 0; i < xf86_config->num_crtc; i++) { +- xf86CrtcPtr crtc = xf86_config->crtc[i]; ++ if (ms->atomic_modeset) { ++ if (drmmode_set_mode_atomic(scrn, ms, FALSE)) ++ goto fail; ++ } else { ++ for (i = 0; i < xf86_config->num_crtc; i++) { ++ xf86CrtcPtr crtc = xf86_config->crtc[i]; + +- if (!crtc->enabled) +- continue; ++ if (!crtc->enabled) ++ continue; + +- drmmode_set_mode_major(crtc, &crtc->mode, +- crtc->rotation, crtc->x, crtc->y); ++ drmmode_set_mode_major(crtc, &crtc->mode, ++ crtc->rotation, crtc->x, crtc->y); ++ } + } + + if (old_fb_id) { +@@ -3457,8 +3491,13 @@ Bool + drmmode_set_desired_modes(ScrnInfoPtr pScrn, drmmode_ptr drmmode, Bool set_hw) + { + xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(pScrn); ++ modesettingPtr ms = modesettingPTR(pScrn); + int c; + ++ /* drmmode_set_mode_atomic returns 0 on success, we return TRUE */ ++ if (ms->atomic_modeset) ++ return !drmmode_set_mode_atomic(pScrn, ms, /* test_only = */ !set_hw); ++ + for (c = 0; c < config->num_crtc; c++) { + xf86CrtcPtr crtc = config->crtc[c]; + drmmode_crtc_private_ptr drmmode_crtc = crtc->driver_private; +-- +2.20.1 + diff --git a/10-quirks.conf b/10-quirks.conf new file mode 100644 index 0000000..47907d8 --- /dev/null +++ b/10-quirks.conf @@ -0,0 +1,38 @@ +# Collection of quirks and blacklist/whitelists for specific devices. + + +# Accelerometer device, posts data through ABS_X/ABS_Y, making X unusable +# http://bugs.freedesktop.org/show_bug.cgi?id=22442 +Section "InputClass" + Identifier "ThinkPad HDAPS accelerometer blacklist" + MatchProduct "ThinkPad HDAPS accelerometer data" + Option "Ignore" "on" +EndSection + +# https://bugzilla.redhat.com/show_bug.cgi?id=523914 +# Mouse does not move in PV Xen guest +# Explicitly tell evdev to not ignore the absolute axes. +Section "InputClass" + Identifier "Xen Virtual Pointer axis blacklist" + MatchProduct "Xen Virtual Pointer" + Option "IgnoreAbsoluteAxes" "off" + Option "IgnoreRelativeAxes" "off" +EndSection + +# https://bugs.freedesktop.org/show_bug.cgi?id=55867 +# Bug 55867 - Doesn't know how to tag XI_TRACKBALL +Section "InputClass" + Identifier "Tag trackballs as XI_TRACKBALL" + MatchProduct "trackball" + MatchDriver "evdev" + Option "TypeName" "TRACKBALL" +EndSection + +# https://bugs.freedesktop.org/show_bug.cgi?id=62831 +# Bug 62831 - Mionix Naos 5000 mouse detected incorrectly +Section "InputClass" + Identifier "Tag Mionix Naos 5000 mouse XI_MOUSE" + MatchProduct "La-VIEW Technology Naos 5000 Mouse" + MatchDriver "evdev" + Option "TypeName" "MOUSE" +EndSection diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..4041668 --- /dev/null +++ b/Makefile @@ -0,0 +1,30 @@ +# Makefile for source rpm: xorg-x11-server +# $Id$ +NAME := xorg-x11-server +SPECFILE = $(firstword $(wildcard *.spec)) + +define find-makefile-common +for d in common ../common ../../common ; do if [ -f $$d/Makefile.common ] ; then if [ -f $$d/CVS/Root -a -w $$d/Makefile.common ] ; then cd $$d ; cvs -Q update ; fi ; echo "$$d/Makefile.common" ; break ; fi ; done +endef + +MAKEFILE_COMMON := $(shell $(find-makefile-common)) + +ifeq ($(MAKEFILE_COMMON),) +# attempt a checkout +define checkout-makefile-common +test -f CVS/Root && { cvs -Q -d $$(cat CVS/Root) checkout common && echo "common/Makefile.common" ; } || { echo "ERROR: I can't figure out how to checkout the 'common' module." ; exit -1 ; } >&2 +endef + +MAKEFILE_COMMON := $(shell $(checkout-makefile-common)) +endif + +include $(MAKEFILE_COMMON) + +ifeq ($(MAKECMDGOALS),me a sandwich) +.PHONY :: me a sandwich +me a: + @: + +sandwich: + @[ `id -u` -ne 0 ] && echo "What? Make it yourself." || echo Okay. +endif diff --git a/commitid b/commitid new file mode 100644 index 0000000..7420e41 --- /dev/null +++ b/commitid @@ -0,0 +1 @@ +d13cb974426f7f1110b0bdb08c4ebb46ff8975f7 diff --git a/gitignore b/gitignore new file mode 100644 index 0000000..524cfc6 --- /dev/null +++ b/gitignore @@ -0,0 +1,306 @@ +Makefile +Makefile.in +.deps +.libs +.msg +*.lo +*.la +*.a +*.o +*~ +.*sw? +*.pbxuser +*.mode1v3 +obj* +build* +local +aclocal.m4 +autom4te.cache +compile +config.guess +config.log +config.status +config.sub +configure +configure.lineno +depcomp +install-sh +libtool +ltmain.sh +missing +TAGS +tags +ylwrap +xorg-server.pc +stamp-h? +do-not-use-config.h +do-not-use-config.h.in +afb/afbbltC.c +afb/afbbltCI.c +afb/afbbltG.c +afb/afbbltO.c +afb/afbbltX.c +afb/afbseg.c +afb/afbtileC.c +afb/afbtileG.c +cfb/cfb8lineCO.c +cfb/cfb8lineCP.c +cfb/cfb8lineG.c +cfb/cfb8lineX.c +cfb/cfb8segC.c +cfb/cfb8segCS.c +cfb/cfb8segX.c +cfb/cfb8setG.c +cfb/cfbbltC.c +cfb/cfbbltG.c +cfb/cfbbltO.c +cfb/cfbbltX.c +cfb/cfbfillarcC.c +cfb/cfbfillarcG.c +cfb/cfbglrop8.c +cfb/cfbply1rctC.c +cfb/cfbply1rctG.c +cfb/cfbseg.c +cfb/cfbsolidC.c +cfb/cfbsolidG.c +cfb/cfbsolidX.c +cfb/cfbtile32C.c +cfb/cfbtile32G.c +cfb/cfbtileoddC.c +cfb/cfbtileoddG.c +cfb/cfbzerarcC.c +cfb/cfbzerarcG.c +cfb/cfbzerarcX.c +cfb32/cfb8lineCO.c +cfb32/cfb8lineCP.c +cfb32/cfb8lineG.c +cfb32/cfb8lineX.c +cfb32/cfb8segC.c +cfb32/cfb8segCS.c +cfb32/cfb8segX.c +cfb32/cfb8setG.c +cfb32/cfbbltC.c +cfb32/cfbbltG.c +cfb32/cfbbltO.c +cfb32/cfbbltX.c +cfb32/cfbfillarcC.c +cfb32/cfbfillarcG.c +cfb32/cfbply1rctC.c +cfb32/cfbply1rctG.c +cfb32/cfbseg.c +cfb32/cfbsolidC.c +cfb32/cfbsolidG.c +cfb32/cfbsolidX.c +cfb32/cfbtile32C.c +cfb32/cfbtile32G.c +cfb32/cfbtileoddC.c +cfb32/cfbtileoddG.c +cfb32/cfbzerarcC.c +cfb32/cfbzerarcG.c +cfb32/cfbzerarcX.c +doc/Xserver.1x +doc/Xserver.man +hw/dmx/Xdmx +hw/dmx/Xdmx.1x +hw/dmx/config/dmxtodmx +hw/dmx/config/dmxtodmx.1x +hw/dmx/config/parser.c +hw/dmx/config/parser.h +hw/dmx/config/scanner.c +hw/dmx/config/vdltodmx +hw/dmx/config/vdltodmx.1x +hw/dmx/config/xdmxconfig +hw/dmx/config/xdmxconfig.1x +hw/dmx/examples/dmxaddinput +hw/dmx/examples/dmxaddscreen +hw/dmx/examples/dmxreconfig +hw/dmx/examples/dmxresize +hw/dmx/examples/dmxrminput +hw/dmx/examples/dmxrmscreen +hw/dmx/examples/dmxwininfo +hw/dmx/examples/ev +hw/dmx/examples/evi +hw/dmx/examples/res +hw/dmx/examples/xbell +hw/dmx/examples/xdmx +hw/dmx/examples/xinput +hw/dmx/examples/xled +hw/dmx/examples/xtest +hw/kdrive/ati/Xati +hw/kdrive/chips/Xchips +hw/kdrive/ephyr/Xephyr +hw/kdrive/epson/Xepson +hw/kdrive/fake/Xfake +hw/kdrive/fbdev/Xfbdev +hw/kdrive/i810/Xi810 +hw/kdrive/mach64/Xmach64 +hw/kdrive/mga/Xmga +hw/kdrive/neomagic/Xneomagic +hw/kdrive/nvidia/Xnvidia +hw/kdrive/pm2/Xpm2 +hw/kdrive/r128/Xr128 +hw/kdrive/sdl/Xsdl +hw/kdrive/sis300/Xsis +hw/kdrive/smi/Xsmi +hw/kdrive/vesa/Xvesa +hw/kdrive/via/Xvia +hw/vfb/Xvfb +hw/vfb/Xvfb.1x +hw/vfb/Xvfb.man +hw/xfree86/Xorg +hw/xfree86/common/xf86Build.h +hw/xfree86/common/xf86DefModeSet.c +hw/xfree86/doc/man/Xorg.1x +hw/xfree86/doc/man/Xorg.man +hw/xfree86/doc/man/xorg.conf.5x +hw/xfree86/doc/man/xorg.conf.man +hw/xfree86/exa/exa.4 +hw/xfree86/exa/exa.4x +hw/xfree86/exa/exa.man +hw/xfree86/fbdevhw/fbdevhw.4x +hw/xfree86/fbdevhw/fbdevhw.man +hw/xfree86/getconfig/cfg.man +hw/xfree86/getconfig/getconfig.1x +hw/xfree86/getconfig/getconfig.5x +hw/xfree86/getconfig/getconfig.man +hw/xfree86/os-support/xorgos.c +hw/xfree86/osandcommon.c +hw/xfree86/ramdac/xf86BitOrder.c +hw/xfree86/scanpci/xf86PciData.c +hw/xfree86/scanpci/xf86PciIds.h +hw/xfree86/utils/cvt/cvt +hw/xfree86/utils/cvt/cvt.man +hw/xfree86/utils/gtf/gtf +hw/xfree86/utils/gtf/gtf.1x +hw/xfree86/utils/gtf/gtf.man +hw/xfree86/utils/ioport/inb +hw/xfree86/utils/ioport/inl +hw/xfree86/utils/ioport/inw +hw/xfree86/utils/ioport/ioport +hw/xfree86/utils/ioport/outb +hw/xfree86/utils/ioport/outl +hw/xfree86/utils/ioport/outw +hw/xfree86/utils/pcitweak/pcitweak +hw/xfree86/utils/pcitweak/pcitweak.1x +hw/xfree86/utils/pcitweak/pcitweak.man +hw/xfree86/utils/scanpci/scanpci +hw/xfree86/utils/scanpci/scanpci.1x +hw/xfree86/utils/scanpci/scanpci.man +hw/xfree86/utils/xorgcfg/XOrgCfg +hw/xfree86/utils/xorgcfg/xorgcfg +hw/xfree86/utils/xorgcfg/xorgcfg.1x +hw/xfree86/utils/xorgcfg/xorgcfg.man +hw/xfree86/utils/xorgconfig/xorgconfig +hw/xfree86/utils/xorgconfig/xorgconfig.1x +hw/xfree86/utils/xorgconfig/xorgconfig.man +hw/xfree86/xaa/l-xaaBitmap.c +hw/xfree86/xaa/l-xaaStipple.c +hw/xfree86/xaa/l-xaaTEGlyph.c +hw/xfree86/xaa/l3-xaaBitmap.c +hw/xfree86/xaa/l3-xaaStipple.c +hw/xfree86/xaa/lf-xaaBitmap.c +hw/xfree86/xaa/lf-xaaStipple.c +hw/xfree86/xaa/lf-xaaTEGlyph.c +hw/xfree86/xaa/lf3-xaaBitmap.c +hw/xfree86/xaa/lf3-xaaStipple.c +hw/xfree86/xaa/m-xaaBitmap.c +hw/xfree86/xaa/m-xaaStipple.c +hw/xfree86/xaa/m-xaaTEGlyph.c +hw/xfree86/xaa/m3-xaaBitmap.c +hw/xfree86/xaa/m3-xaaStipple.c +hw/xfree86/xaa/mf-xaaBitmap.c +hw/xfree86/xaa/mf-xaaStipple.c +hw/xfree86/xaa/mf-xaaTEGlyph.c +hw/xfree86/xaa/mf3-xaaBitmap.c +hw/xfree86/xaa/mf3-xaaStipple.c +hw/xfree86/xaa/s-xaaDashLine.c +hw/xfree86/xaa/s-xaaLine.c +hw/xfree86/xf1bpp/maskbits.c +hw/xfree86/xf1bpp/mfbbitblt.c +hw/xfree86/xf1bpp/mfbbltC.c +hw/xfree86/xf1bpp/mfbbltCI.c +hw/xfree86/xf1bpp/mfbbltG.c +hw/xfree86/xf1bpp/mfbbltO.c +hw/xfree86/xf1bpp/mfbbltX.c +hw/xfree86/xf1bpp/mfbbres.c +hw/xfree86/xf1bpp/mfbbresd.c +hw/xfree86/xf1bpp/mfbclip.c +hw/xfree86/xf1bpp/mfbcmap.c +hw/xfree86/xf1bpp/mfbfillarc.c +hw/xfree86/xf1bpp/mfbfillrct.c +hw/xfree86/xf1bpp/mfbfillsp.c +hw/xfree86/xf1bpp/mfbfont.c +hw/xfree86/xf1bpp/mfbgc.c +hw/xfree86/xf1bpp/mfbgetsp.c +hw/xfree86/xf1bpp/mfbigbblak.c +hw/xfree86/xf1bpp/mfbigbwht.c +hw/xfree86/xf1bpp/mfbhrzvert.c +hw/xfree86/xf1bpp/mfbimage.c +hw/xfree86/xf1bpp/mfbline.c +hw/xfree86/xf1bpp/mfbmisc.c +hw/xfree86/xf1bpp/mfbpablack.c +hw/xfree86/xf1bpp/mfbpainv.c +hw/xfree86/xf1bpp/mfbpawhite.c +hw/xfree86/xf1bpp/mfbpgbblak.c +hw/xfree86/xf1bpp/mfbpgbinv.c +hw/xfree86/xf1bpp/mfbpgbwht.c +hw/xfree86/xf1bpp/mfbpixmap.c +hw/xfree86/xf1bpp/mfbplyblack.c +hw/xfree86/xf1bpp/mfbplyinv.c +hw/xfree86/xf1bpp/mfbplywhite.c +hw/xfree86/xf1bpp/mfbpntwin.c +hw/xfree86/xf1bpp/mfbpolypnt.c +hw/xfree86/xf1bpp/mfbpushpxl.c +hw/xfree86/xf1bpp/mfbscrclse.c +hw/xfree86/xf1bpp/mfbscrinit.c +hw/xfree86/xf1bpp/mfbseg.c +hw/xfree86/xf1bpp/mfbsetsp.c +hw/xfree86/xf1bpp/mfbteblack.c +hw/xfree86/xf1bpp/mfbtewhite.c +hw/xfree86/xf1bpp/mfbtileC.c +hw/xfree86/xf1bpp/mfbtileG.c +hw/xfree86/xf1bpp/mfbwindow.c +hw/xfree86/xf1bpp/mfbzerarc.c +hw/xfree86/xf4bpp/mfbseg.c +hw/xfree86/xf8_32bpp/cfbgc32.c +hw/xfree86/xf8_32bpp/cfbgc8.c +hw/xfree86/xorg.c +hw/xfree86/xorg.conf.example +hw/xfree86/xorg.conf.example.pre +hw/xnest/Xnest +hw/xnest/Xnest.1x +hw/xnest/Xnest.man +hw/xprint/Xprt +hw/xprint/config/C/print/Xprinters.ghostscript +hw/xprint/doc/Xprt.1x +hw/xprint/doc/Xprt.man +hw/xprint/dpmsstubs-wrapper.c +hw/xprint/miinitext-wrapper.c +include/dix-config.h +include/kdrive-config.h +include/xgl-config.h +include/xkb-config.h +include/xorg-config.h +include/xorg-server.h +include/xwin-config.h +mfb/mfbbltC.c +mfb/mfbbltCI.c +mfb/mfbbltG.c +mfb/mfbbltO.c +mfb/mfbbltX.c +mfb/mfbigbblak.c +mfb/mfbigbwht.c +mfb/mfbpablack.c +mfb/mfbpainv.c +mfb/mfbpawhite.c +mfb/mfbpgbblak.c +mfb/mfbpgbinv.c +mfb/mfbpgbwht.c +mfb/mfbplyblack.c +mfb/mfbplyinv.c +mfb/mfbplywhite.c +mfb/mfbseg.c +mfb/mfbteblack.c +mfb/mfbtewhite.c +mfb/mfbtileC.c +mfb/mfbtileG.c diff --git a/import.log b/import.log new file mode 100644 index 0000000..782e371 --- /dev/null +++ b/import.log @@ -0,0 +1,6 @@ +xorg-x11-server-1_5_0-1_fc10:HEAD:xorg-x11-server-1.5.0-1.fc10.src.rpm:1220485219 +xorg-x11-server-1_5_1-1_fc10:HEAD:xorg-x11-server-1.5.1-1.fc10.src.rpm:1222198557 +xorg-x11-server-1_5_2-1_fc10:HEAD:xorg-x11-server-1.5.2-1.fc10.src.rpm:1223667007 +xorg-x11-server-1_5_3-1_fc10:HEAD:xorg-x11-server-1.5.3-1.fc10.src.rpm:1225918317 +xorg-x11-server-1_6_0-1_fc11:HEAD:xorg-x11-server-1.6.0-1.fc11.src.rpm:1235594175 +xorg-x11-server-1_6_1-1_fc11:HEAD:xorg-x11-server-1.6.1-1.fc11.src.rpm:1239742477 diff --git a/make-git-snapshot.sh b/make-git-snapshot.sh new file mode 100755 index 0000000..0d9b2ad --- /dev/null +++ b/make-git-snapshot.sh @@ -0,0 +1,17 @@ +#!/bin/sh + +DIRNAME=xorg-server-$( date +%Y%m%d ) + +rm -rf $DIRNAME +git clone git://git.freedesktop.org/git/xorg/xserver $DIRNAME +cd $DIRNAME +if [ -z "$1" ]; then + git log | head -1 +else + git checkout $1 +fi +git log | head -1 | awk '{ print $2 }' > ../commitid +git repack -a -d +cd .. +tar cf - $DIRNAME | xz -c9 > $DIRNAME.tar.xz +rm -rf $DIRNAME diff --git a/sources b/sources index 888c6f9..d74b6f3 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (xorg-server-21.1.21.tar.xz) = bb2eb4e6756eb9e38b61bd47c017da44bcf5f45f2b7a906b4bb3a56b3d791cec64abb9bf37b224efe1e4fab9cc296f3672c9b2f8e00e1cdfc54337bef63cd16c +SHA512 (xorg-server-1.20.6.tar.bz2) = 9aa0ba4aee92fe628f2b8c41e4fe0134dc86154bb8787f907884ef2fd970e18e68e72ea8a1beb706d11ecf155b2abc9731f1abadff251ed592f8cca3b1240dd6 diff --git a/xorg-x11-server.spec b/xorg-x11-server.spec index 788acf9..b48d6b8 100644 --- a/xorg-x11-server.spec +++ b/xorg-x11-server.spec @@ -1,230 +1,316 @@ +# This package is an experiment in active integration of upstream SCM with +# Fedora packaging. It works something like this: +# +# The "pristine" source is actually a git repo (with no working checkout). +# The first step of %%prep is to check it out and switch to a "fedora" branch. +# If you need to add a patch to the server, just do it like a normal git +# operation, dump it with git-format-patch to a file in the standard naming +# format, and add a PatchN: line. If you want to push something upstream, +# check out the master branch, pull, cherry-pick, and push. + # X.org requires lazy relocations to work. %undefine _hardened_build %undefine _strict_symbol_defs_build -# Released ABI versions: +#global gitdate 20161026 +%global stable_abi 1 + +%if !0%{?gitdate} || %{stable_abi} +# Released ABI versions. Have to keep these manually in sync with the +# source because rpm is a terrible language. %global ansic_major 0 %global ansic_minor 4 -%global videodrv_major 25 -%global videodrv_minor 2 +%global videodrv_major 24 +%global videodrv_minor 0 %global xinput_major 24 -%global xinput_minor 4 +%global xinput_minor 1 %global extension_major 10 %global extension_minor 0 +%endif + +%if 0%{?gitdate} +# For git snapshots, use date for major and a serial number for minor +%global minor_serial 0 +%global git_ansic_major %{gitdate} +%global git_ansic_minor %{minor_serial} +%global git_videodrv_major %{gitdate} +%global git_videodrv_minor %{minor_serial} +%global git_xinput_major %{gitdate} +%global git_xinput_minor %{minor_serial} +%global git_extension_major %{gitdate} +%global git_extension_minor %{minor_serial} +%endif %global pkgname xorg-server -Summary: X.Org X11 X server -Name: xorg-x11-server -Version: 21.1.21 -Release: 1%{?dist} -URL: http://www.x.org -# SPDX -License: Adobe-Display-PostScript AND BSD-3-Clause AND DEC-3-Clause AND HPND AND HPND-sell-MIT-disclaimer-xserver AND HPND-sell-variant AND ICU AND ISC AND MIT AND MIT-open-group AND NTP AND SGI-B-2.0 AND SMLNJ AND X11 AND X11-distribute-modifications-variant +Summary: X.Org X11 X server +Name: xorg-x11-server +Version: 1.20.6 +Release: 1%{?gitdate:.%{gitdate}}%{?dist} +URL: http://www.x.org +License: MIT -Source0: https://www.x.org/pub/individual/xserver/%{pkgname}-%{version}.tar.xz +#VCS: git:git://git.freedesktop.org/git/xorg/xserver +%if 0%{?gitdate} +# git snapshot. to recreate, run: +# ./make-git-snapshot.sh `cat commitid` +Source0: xorg-server-%{gitdate}.tar.xz +#Source0: http://www.x.org/pub/individual/xserver/%{pkgname}-%{version}.tar.bz2 +Source1: make-git-snapshot.sh +Source2: commitid +%else +Source0: https://www.x.org/pub/individual/xserver/%{pkgname}-%{version}.tar.bz2 +Source1: gitignore +%endif + +Source4: 10-quirks.conf Source10: xserver.pamd + # "useful" xvfb-run script -Source20: http://svn.exactcode.de/t2/trunk/package/xorg/xorg-server/xvfb-run.sh +Source20: http://svn.exactcode.de/t2/trunk/package/xorg/xorg-server/xvfb-run.sh + # for requires generation in drivers -Source30: xserver-sdk-abi-requires +Source30: xserver-sdk-abi-requires.release +Source31: xserver-sdk-abi-requires.git + # maintainer convenience script -Source40: driver-abi-rebuild.sh +Source40: driver-abi-rebuild.sh # From Debian use intel ddx driver only for gen4 and older chipsets -Patch0: 06_use-intel-only-on-pre-gen4.diff +Patch1: 06_use-intel-only-on-pre-gen4.diff # Default to xf86-video-modesetting on GeForce 8 and newer -Patch1: 0001-xfree86-use-modesetting-driver-by-default-on-GeForce.patch +Patch2: 0001-xfree86-use-modesetting-driver-by-default-on-GeForce.patch + # Default to va_gl on intel i965 as we use the modesetting drv there # va_gl should probably just be the default everywhere ? -Patch2: 0001-xf86-dri2-Use-va_gl-as-vdpau_driver-for-Intel-i965-G.patch -# because the display-managers are not ready yet, do not upstream -Patch3: 0001-Fedora-hack-Make-the-suid-root-wrapper-always-start-.patch +Patch3: 0001-xf86-dri2-Use-va_gl-as-vdpau_driver-for-Intel-i965-G.patch -BuildRequires: bison -BuildRequires: flex -BuildRequires: gawk -BuildRequires: gcc -BuildRequires: kernel-headers -BuildRequires: libXi-devel -BuildRequires: libXinerama-devel -BuildRequires: libXres-devel -BuildRequires: libXv-devel -BuildRequires: make -BuildRequires: mesa-libEGL-devel -BuildRequires: mesa-libGL-devel >= 9.2 -BuildRequires: meson -BuildRequires: pkgconfig -BuildRequires: pkgconfig(audit) -BuildRequires: pkgconfig(bigreqsproto) >= 1.1.0 -BuildRequires: pkgconfig(compositeproto) >= 0.4 -BuildRequires: pkgconfig(damageproto) >= 1.1 -BuildRequires: pkgconfig(dbus-1) >= 1.0 -BuildRequires: pkgconfig(dri2proto) >= 2.8 -BuildRequires: pkgconfig(dri3proto) >= 1.2 -BuildRequires: pkgconfig(epoxy) -BuildRequires: pkgconfig(epoxy) >= 1.5.4 -BuildRequires: pkgconfig(fixesproto) >= 6.0 -BuildRequires: pkgconfig(fontsproto) >= 2.1.3 -BuildRequires: pkgconfig(gbm) >= 10.2 -BuildRequires: pkgconfig(inputproto) >= 2.3.99.1 -BuildRequires: pkgconfig(kbproto) >= 1.0.3 -BuildRequires: pkgconfig(libdrm) >= 2.4.89 -BuildRequires: pkgconfig(libselinux) >= 2.0.86 -BuildRequires: pkgconfig(libsystemd) >= 209 -BuildRequires: pkgconfig(libudev) >= 143 -BuildRequires: pkgconfig(libunwind) -BuildRequires: pkgconfig(libxcvt) -BuildRequires: pkgconfig(openssl) -BuildRequires: pkgconfig(pciaccess) >= 0.12.901 -BuildRequires: pkgconfig(pixman-1) -BuildRequires: pkgconfig(randrproto) >= 1.6.0 -BuildRequires: pkgconfig(recordproto) >= 1.13.99.1 -BuildRequires: pkgconfig(renderproto) >= 0.11 -BuildRequires: pkgconfig(resourceproto) >= 1.2.0 -BuildRequires: pkgconfig(scrnsaverproto) >= 1.1 -BuildRequires: pkgconfig(videoproto) -BuildRequires: pkgconfig(x11) -BuildRequires: pkgconfig(x11-xcb) -BuildRequires: pkgconfig(xau) -BuildRequires: pkgconfig(xcb-aux) -BuildRequires: pkgconfig(xcb-icccm) -BuildRequires: pkgconfig(xcb-image) -BuildRequires: pkgconfig(xcb-keysyms) -BuildRequires: pkgconfig(xcb-renderutil) -BuildRequires: pkgconfig(xcmiscproto) >= 1.2.0 -BuildRequires: pkgconfig(xdmcp) -BuildRequires: pkgconfig(xext) >= 1.0.99.4 -BuildRequires: pkgconfig(xextproto) >= 7.2.99.901 -BuildRequires: pkgconfig(xf86bigfontproto) >= 1.2.0 -BuildRequires: pkgconfig(xf86vidmodeproto) >= 2.2.99.1 -BuildRequires: pkgconfig(xfont2) >= 2.0 -BuildRequires: pkgconfig(xineramaproto) -BuildRequires: pkgconfig(xkbfile) -BuildRequires: pkgconfig(xproto) >= 7.0.31 -BuildRequires: pkgconfig(xshmfence) >= 1.1 -BuildRequires: pkgconfig(xtrans) >= 1.3.5 -BuildRequires: pkgconfig(xtrans) >= 1.3.5 -BuildRequires: systemtap-sdt-devel -BuildRequires: xorg-x11-util-macros >= 1.17 -BuildRequires: xorg-x11-xtrans-devel >= 1.3.2 +# Submitted upstream, but not going anywhere +Patch5: 0001-autobind-GPUs-to-the-screen.patch + +# because the display-managers are not ready yet, do not upstream +Patch6: 0001-Fedora-hack-Make-the-suid-root-wrapper-always-start-.patch + +# test for https://bugzilla.redhat.com/show_bug.cgi?id=1697591 +# see also https://gitlab.freedesktop.org/xorg/xserver/merge_requests/36 +# ofourdan> Disabling those for now, causing regressions (#1714981, #1723715) +#Patch21: 0001-modesetting-Weaksauce-atomic-property-debugging.patch +#Patch22: 0002-modesetting-Propagate-more-failure-in-drmmode_set_mo.patch +#Patch23: 0003-modesetting-Factor-out-drmmode_target_output.patch +#Patch24: 0004-modesetting-Use-atomic-instead-of-per-crtc-walks-whe.patch + +# Backports from current stable "server-1.20-branch": +# ... + +# Backports from "master" upstream: + +# https://bugzilla.redhat.com/show_bug.cgi?id=1697804 +Patch500: 0001-Xi-return-AlreadyGrabbed-for-key-grabs-255.patch + +BuildRequires: systemtap-sdt-devel +BuildRequires: git +BuildRequires: automake autoconf libtool pkgconfig +BuildRequires: xorg-x11-util-macros >= 1.17 + +BuildRequires: xorg-x11-proto-devel >= 7.7-10 +BuildRequires: xorg-x11-font-utils >= 7.2-11 + +BuildRequires: dbus-devel libepoxy-devel systemd-devel +BuildRequires: xorg-x11-xtrans-devel >= 1.3.2 +BuildRequires: libXfont2-devel libXau-devel libxkbfile-devel libXres-devel +BuildRequires: libfontenc-devel libXtst-devel libXdmcp-devel +BuildRequires: libX11-devel libXext-devel +BuildRequires: libXinerama-devel libXi-devel + +# DMX config utils buildreqs. +BuildRequires: libXt-devel libdmx-devel libXmu-devel libXrender-devel +BuildRequires: libXi-devel libXpm-devel libXaw-devel libXfixes-devel + +BuildRequires: wayland-devel +BuildRequires: wayland-protocols-devel +BuildRequires: pkgconfig(wayland-eglstream-protocols) +BuildRequires: pkgconfig(wayland-client) >= 1.3.0 +BuildRequires: pkgconfig(epoxy) +BuildRequires: pkgconfig(xshmfence) >= 1.1 +BuildRequires: libXv-devel +BuildRequires: pixman-devel >= 0.30.0 +BuildRequires: libpciaccess-devel >= 0.13.1 openssl-devel bison flex flex-devel +BuildRequires: mesa-libGL-devel >= 9.2 +BuildRequires: mesa-libEGL-devel +BuildRequires: mesa-libgbm-devel +# XXX silly... +BuildRequires: libdrm-devel >= 2.4.0 kernel-headers + +BuildRequires: audit-libs-devel libselinux-devel >= 2.0.86-1 +BuildRequires: libudev-devel +# libunwind is Exclusive for the following arches +%ifarch aarch64 %{arm} hppa ia64 mips ppc ppc64 %{ix86} x86_64 +%if !0%{?rhel} +BuildRequires: libunwind-devel +%endif +%endif + +BuildRequires: pkgconfig(xcb-aux) pkgconfig(xcb-image) pkgconfig(xcb-icccm) +BuildRequires: pkgconfig(xcb-keysyms) pkgconfig(xcb-renderutil) %description -X.Org X11 X server. +X.Org X11 X server -%package common -Summary: Xorg server common files -Requires: pixman -Requires: xkbcomp -Requires: xkeyboard-config +%package common +Summary: Xorg server common files +Requires: pixman >= 0.30.0 +Requires: xkeyboard-config xkbcomp -%description common +%description common Common files shared among all X servers. -%package Xorg -Summary: Xorg X server -Requires: libEGL -Requires: system-setup-keyboard -Requires: xorg-x11-drv-libinput -Requires: xorg-x11-server-common >= %{version}-%{release} -Provides: Xorg = %{version}-%{release} -Provides: Xserver +%package Xorg +Summary: Xorg X server +Provides: Xorg = %{version}-%{release} +Provides: Xserver # HdG: This should be moved to the wrapper package once the wrapper gets # its own sub-package: -Provides: xorg-x11-server-wrapper = %{version}-%{release} -Provides: xserver-abi(ansic-%{ansic_major}) = %{ansic_minor} -Provides: xserver-abi(videodrv-%{videodrv_major}) = %{videodrv_minor} -Provides: xserver-abi(xinput-%{xinput_major}) = %{xinput_minor} -Provides: xserver-abi(extension-%{extension_major}) = %{extension_minor} -# Dropped from xorg-x11-server-21.1 -# https://gitlab.freedesktop.org/xorg/xserver/-/commit/b3b81c8c2090cd49410960a021baf0d27fdd2ab3 -Obsoletes: xorg-x11-server-Xdmx < 1.20.15 -# Legacy fbdev devices have been replaced with simpledrm: -# https://fedoraproject.org/wiki/Changes/ReplaceFbdevDrivers -Obsoletes: xorg-x11-drv-fbdev < 0.5.0-19 -Obsoletes: xorg-x11-drv-vesa < 2.6.0-3 -Obsoletes: xorg-x11-drv-armsoc < 1.4.1-10 +Provides: xorg-x11-server-wrapper = %{version}-%{release} +%if !0%{?gitdate} || %{stable_abi} +Provides: xserver-abi(ansic-%{ansic_major}) = %{ansic_minor} +Provides: xserver-abi(videodrv-%{videodrv_major}) = %{videodrv_minor} +Provides: xserver-abi(xinput-%{xinput_major}) = %{xinput_minor} +Provides: xserver-abi(extension-%{extension_major}) = %{extension_minor} +%endif +%if 0%{?gitdate} +Provides: xserver-abi(ansic-%{git_ansic_major}) = %{git_ansic_minor} +Provides: xserver-abi(videodrv-%{git_videodrv_major}) = %{git_videodrv_minor} +Provides: xserver-abi(xinput-%{git_xinput_major}) = %{git_xinput_minor} +Provides: xserver-abi(extension-%{git_extension_major}) = %{git_extension_minor} +%endif +Obsoletes: xorg-x11-glamor < %{version}-%{release} +Provides: xorg-x11-glamor = %{version}-%{release} +Obsoletes: xorg-x11-drv-modesetting < %{version}-%{release} +Provides: xorg-x11-drv-modesetting = %{version}-%{release} +# Dropped from F25 +Obsoletes: xorg-x11-drv-vmmouse < 13.1.0-4 -%description Xorg -X.org X11 is an open source implementation of the X Window System. It provides -the basic low level functionality which full fledged graphical user interfaces -(GUIs) such as GNOME and KDE are designed upon. +Requires: xorg-x11-server-common >= %{version}-%{release} +Requires: system-setup-keyboard +Requires: xorg-x11-drv-libinput +Requires: libEGL + +%description Xorg +X.org X11 is an open source implementation of the X Window System. It +provides the basic low level functionality which full fledged +graphical user interfaces (GUIs) such as GNOME and KDE are designed +upon. -%package Xnest -Summary: A nested server -Requires: xorg-x11-server-common >= %{version}-%{release} -Provides: Xnest +%package Xnest +Summary: A nested server +Requires: xorg-x11-server-common >= %{version}-%{release} +Provides: Xnest -%description Xnest -Xnest is an X server which has been implemented as an ordinary X application. It -runs in a window just like other X applications, but it is an X server itself in -which you can run other software. It is a very useful tool for developers who -wish to test their applications without running them on their real X server. +%description Xnest +Xnest is an X server which has been implemented as an ordinary +X application. It runs in a window just like other X applications, +but it is an X server itself in which you can run other software. It +is a very useful tool for developers who wish to test their +applications without running them on their real X server. -%package Xvfb -Summary: A X Windows System virtual framebuffer X server +%package Xdmx +Summary: Distributed Multihead X Server and utilities +Requires: xorg-x11-server-common >= %{version}-%{release} +Provides: Xdmx + +%description Xdmx +Xdmx is proxy X server that provides multi-head support for multiple displays +attached to different machines (each of which is running a typical X server). +When Xinerama is used with Xdmx, the multiple displays on multiple machines +are presented to the user as a single unified screen. A simple application +for Xdmx would be to provide multi-head support using two desktop machines, +each of which has a single display device attached to it. A complex +application for Xdmx would be to unify a 4 by 4 grid of 1280x1024 displays +(each attached to one of 16 computers) into a unified 5120x4096 display. + + +%package Xvfb +Summary: A X Windows System virtual framebuffer X server # xvfb-run is GPLv2, rest is MIT -License: MIT and GPL-2.0-only -Requires: xorg-x11-server-common >= %{version}-%{release} +License: MIT and GPLv2 +Requires: xorg-x11-server-common >= %{version}-%{release} # required for xvfb-run -Requires: xorg-x11-xauth -Provides: Xvfb -Requires: util-linux +Requires: xorg-x11-xauth +Provides: Xvfb -%description Xvfb -Xvfb (X Virtual Frame Buffer) is an X server that is able to run on machines -with no display hardware and no physical input devices. Xvfb simulates a dumb -framebuffer using virtual memory. Xvfb does not open any devices, but behaves -otherwise as an X display. Xvfb is normally used for testing servers. +%description Xvfb +Xvfb (X Virtual Frame Buffer) is an X server that is able to run on +machines with no display hardware and no physical input devices. +Xvfb simulates a dumb framebuffer using virtual memory. Xvfb does +not open any devices, but behaves otherwise as an X display. Xvfb +is normally used for testing servers. -%package Xephyr -Summary: A nested server -Requires: xorg-x11-server-common >= %{version}-%{release} -Provides: Xephyr +%package Xephyr +Summary: A nested server +Requires: xorg-x11-server-common >= %{version}-%{release} +Provides: Xephyr -%description Xephyr -Xephyr is an X server which has been implemented as an ordinary X application. -It runs in a window just like other X applications, but it is an X server itself -in which you can run other software. It is a very useful tool for developers who -wish to test their applications without running them on their real X server. -Unlike Xnest, Xephyr renders to an X image rather than relaying the X protocol, -and therefore supports the newer X extensions like Render and Composite. +%description Xephyr +Xephyr is an X server which has been implemented as an ordinary +X application. It runs in a window just like other X applications, +but it is an X server itself in which you can run other software. It +is a very useful tool for developers who wish to test their +applications without running them on their real X server. Unlike +Xnest, Xephyr renders to an X image rather than relaying the +X protocol, and therefore supports the newer X extensions like +Render and Composite. -%package devel -Summary: SDK for X server driver module development -Requires: libpciaccess-devel -Requires: libXfont2-devel -Requires: xorg-x11-proto-devel -Requires: xorg-x11-util-macros -Requires: pixman-devel -Requires: pkgconfig -Provides: xorg-x11-server-static +%package Xwayland +Summary: Wayland X Server +Requires: xorg-x11-server-common >= %{version}-%{release} +Requires: libEGL + +%description Xwayland +Xwayland is an X server for running X clients under Wayland. + + +%package devel +Summary: SDK for X server driver module development +Requires: xorg-x11-util-macros +Requires: xorg-x11-proto-devel +Requires: libXfont2-devel +Requires: pkgconfig pixman-devel libpciaccess-devel +Provides: xorg-x11-server-static +Obsoletes: xorg-x11-glamor-devel < %{version}-%{release} +Provides: xorg-x11-glamor-devel = %{version}-%{release} %description devel The SDK package provides the developmental files which are necessary for -developing X server driver modules, and for compiling driver modules outside of -the standard X11 source code tree. Developers writing video drivers, input -drivers, or other X modules should install this package. +developing X server driver modules, and for compiling driver modules +outside of the standard X11 source code tree. Developers writing video +drivers, input drivers, or other X modules should install this package. -%package source -Summary: Xserver source code required to build VNC server (Xvnc) -BuildArch: noarch +%package source +Summary: Xserver source code required to build VNC server (Xvnc) +BuildArch: noarch -%description source -Xserver source code needed to build VNC server (Xvnc). +%description source +Xserver source code needed to build VNC server (Xvnc) %prep -%autosetup -p1 -n %{pkgname}-%{version} +%autosetup -N -n %{pkgname}-%{?gitdate:%{gitdate}}%{!?gitdate:%{version}} +rm -rf .git +cp %{SOURCE1} .gitignore +# ick +%global __scm git +%{expand:%__scm_setup_git -q} +%autopatch +%if 0%{?stable_abi} # check the ABI in the source against what we expect. getmajor() { grep -i ^#define.ABI.$1_VERSION hw/xfree86/common/xf86Module.h | @@ -245,80 +331,74 @@ test `getminor xinput` == %{xinput_minor} test `getmajor extension` == %{extension_major} test `getminor extension` == %{extension_minor} -%build -%meson \ - -D agp=auto \ - -D builder_string="Build ID: %{name} %{version}-%{release}" \ - -D default_font_path="catalogue:/etc/X11/fontpath.d,built-ins" \ - -D devel-docs=false \ - -D dga=true \ - -D docs-pdf=false \ - -D docs=false \ - -D dpms=true \ - -D dri1=false \ - -D dri2=true \ - -D dri3=true \ - -D drm=true \ - -D dtrace=false \ - -D fallback_input_driver=libinput \ - -D glamor=true \ - -D glx=true \ - -D hal=false \ - -D input_thread=true \ - -D int10=false \ - -D ipv6=true \ - -D libunwind=true \ - -D linux_acpi=false \ - -D linux_apm=false \ - -D listen_local=true \ - -D listen_tcp=false \ - -D listen_unix=true \ - -D log_dir="%{_localstatedir}/log" \ - -D mitshm=auto \ - -D module_dir="%{_libdir}/xorg/modules" \ - -D pciaccess=true \ - -D screensaver=true \ - -D secure-rpc=false \ - -D sha1=libcrypto \ - -D suid_wrapper=true \ - -D systemd_logind=true \ - -D udev_kms=true \ - -D udev=true \ - -D vgahw=true \ - -D xace=true \ - -D xcsecurity=true \ - -D xdm-auth-1=true \ - -D xdmcp=true \ - -D xephyr=true \ - -D xf86bigfont=false \ - -D xf86-input-inputtest=true \ - -D xinerama=true \ - -D xkb_output_dir="%{_localstatedir}/lib/xkb" \ - -D xnest=true \ - -D xorg=true \ - -D xpbproxy=false \ - -D xquartz=false \ - -D xres=true \ - -D xselinux=true \ - -D xvfb=true \ - -D xvmc=true \ - -D xv=true \ - -D xwin=false +%endif + +%build + +export CFLAGS="$RPM_OPT_FLAGS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1" +export CXXFLAGS="$RPM_OPT_FLAGS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1" +export LDFLAGS="$RPM_LD_FLAGS -specs=/usr/lib/rpm/redhat/redhat-hardened-ld" + +%ifnarch %{ix86} x86_64 +%global no_int10 --disable-vbe --disable-int10-module +%endif + +%global kdrive --enable-kdrive --enable-xephyr --disable-xfake --disable-xfbdev +%global xservers --enable-xvfb --enable-xnest %{kdrive} --enable-xorg +%global default_font_path "catalogue:/etc/X11/fontpath.d,built-ins" +%global dri_flags --enable-dri --enable-dri2 %{?!rhel:--enable-dri3} --enable-suid-wrapper --enable-glamor +%global bodhi_flags --with-vendor-name="Fedora Project" + +autoreconf -f -v --install || exit 1 + +%configure %{xservers} \ + --enable-dependency-tracking \ + --enable-xwayland-eglstream \ + --disable-static \ + --with-pic \ + %{?no_int10} --with-int10=x86emu \ + --with-default-font-path=%{default_font_path} \ + --with-module-dir=%{_libdir}/xorg/modules \ + --with-builderstring="Build ID: %{name} %{version}-%{release}" \ + --with-os-name="$(hostname -s) $(uname -r)" \ + --with-xkb-output=%{_localstatedir}/lib/xkb \ + --without-dtrace \ + --disable-linux-acpi --disable-linux-apm \ + --enable-xselinux --enable-record --enable-present \ + --enable-config-udev \ + --disable-unit-tests \ + --enable-dmx \ + --enable-xwayland \ + %{dri_flags} %{?bodhi_flags} \ + ${CONFIGURE} + +make V=1 %{?_smp_mflags} -%meson_build %install -%meson_install +%make_install -install -D -m 0644 -p xkb/README.compiled %{buildroot}%{_localstatedir}/lib/xkb/README.compiled -install -D -m 0644 %{SOURCE10} %{buildroot}%{_sysconfdir}/pam.d/xserver +mkdir -p $RPM_BUILD_ROOT%{_libdir}/xorg/modules/{drivers,input} + +mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/pam.d +install -m 644 %{SOURCE10} $RPM_BUILD_ROOT%{_sysconfdir}/pam.d/xserver + +mkdir -p $RPM_BUILD_ROOT%{_datadir}/X11/xorg.conf.d +install -m 644 %{SOURCE4} $RPM_BUILD_ROOT%{_datadir}/X11/xorg.conf.d # make sure the (empty) /etc/X11/xorg.conf.d is there, system-setup-keyboard # relies on it more or less. -mkdir -p %{buildroot}%{_sysconfdir}/X11/xorg.conf.d +mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/X11/xorg.conf.d -install -D -m 0755 %{SOURCE30} %{buildroot}%{_bindir}/xserver-sdk-abi-requires -install -D -m 0755 %{SOURCE20} %{buildroot}%{_bindir}/xvfb-run +%if %{stable_abi} +install -m 755 %{SOURCE30} $RPM_BUILD_ROOT%{_bindir}/xserver-sdk-abi-requires +%else +sed -e s/@MAJOR@/%{gitdate}/g -e s/@MINOR@/%{minor_serial}/g %{SOURCE31} > \ + $RPM_BUILD_ROOT%{_bindir}/xserver-sdk-abi-requires +chmod 755 $RPM_BUILD_ROOT%{_bindir}/xserver-sdk-abi-requires +%endif + +install -m 0755 %{SOURCE20} $RPM_BUILD_ROOT%{_bindir}/xvfb-run # Make the source package %global xserver_source_dir %{_datadir}/xorg-x11-server-source @@ -329,18 +409,24 @@ mkdir -p %{inst_srcdir}/{hw/dmx/doc,man,doc,hw/dmx/doxygen} cp {,%{inst_srcdir}/}hw/xquartz/bundle/cpprules.in cp {,%{inst_srcdir}/}man/Xserver.man cp {,%{inst_srcdir}/}doc/smartsched -#cp {,%{inst_srcdir}/}hw/dmx/doxygen/doxygen.conf.in +cp {,%{inst_srcdir}/}hw/dmx/doxygen/doxygen.conf.in cp {,%{inst_srcdir}/}xserver.ent.in cp {,%{inst_srcdir}/}hw/xfree86/Xorg.sh.in cp xkb/README.compiled %{inst_srcdir}/xkb cp hw/xfree86/xorgconf.cpp %{inst_srcdir}/hw/xfree86 -find . -type f -not -path "./%{_vpath_builddir}/*" | egrep '.*\.(c|h|am|ac|inc|m4|h.in|pc.in|man.pre|pl|txt)$' | +find . -type f | egrep '.*\.(c|h|am|ac|inc|m4|h.in|pc.in|man.pre|pl|txt)$' | xargs tar cf - | (cd %{inst_srcdir} && tar xf -) find %{inst_srcdir}/hw/xfree86 -name \*.c -delete # Remove unwanted files/dirs -find %{buildroot} -type f -name '*.la' -delete +{ + find $RPM_BUILD_ROOT -type f -name '*.la' | xargs rm -f -- || : +# wtf +%ifnarch %{ix86} x86_64 + rm -f $RPM_BUILD_ROOT%{_libdir}/xorg/modules/lib{int10,vbe}.so +%endif +} %files common @@ -350,15 +436,21 @@ find %{buildroot} -type f -name '*.la' -delete %dir %{_localstatedir}/lib/xkb %{_localstatedir}/lib/xkb/README.compiled +%if 1 +%global Xorgperms %attr(4755, root, root) +%else +# disable until module loading is audited +%global Xorgperms %attr(0711,root,root) %caps(cap_sys_admin,cap_sys_rawio,cap_dac_override=pe) +%endif + %files Xorg %config %attr(0644,root,root) %{_sysconfdir}/pam.d/xserver -%{_bindir}/gtf %{_bindir}/X %{_bindir}/Xorg %{_libexecdir}/Xorg -# Disable until module loading is audited -# %attr(0711,root,root) %caps(cap_sys_admin,cap_sys_rawio,cap_dac_override=pe) -%attr(4755, root, root) %{_libexecdir}/Xorg.wrap +%{Xorgperms} %{_libexecdir}/Xorg.wrap +%{_bindir}/cvt +%{_bindir}/gtf %dir %{_libdir}/xorg %dir %{_libdir}/xorg/modules %dir %{_libdir}/xorg/modules/drivers @@ -366,25 +458,28 @@ find %{buildroot} -type f -name '*.la' -delete %dir %{_libdir}/xorg/modules/extensions %{_libdir}/xorg/modules/extensions/libglx.so %dir %{_libdir}/xorg/modules/input -%{_libdir}/xorg/modules/input/inputtest_drv.so -%{_libdir}/xorg/modules/libexa.so %{_libdir}/xorg/modules/libfbdevhw.so -#%%{_libdir}/xorg/modules/libfb.so +%{_libdir}/xorg/modules/libexa.so +%{_libdir}/xorg/modules/libfb.so %{_libdir}/xorg/modules/libglamoregl.so %{_libdir}/xorg/modules/libshadow.so %{_libdir}/xorg/modules/libshadowfb.so %{_libdir}/xorg/modules/libvgahw.so %{_libdir}/xorg/modules/libwfb.so +%ifarch %{ix86} x86_64 +%{_libdir}/xorg/modules/libint10.so +%{_libdir}/xorg/modules/libvbe.so +%endif %{_mandir}/man1/gtf.1* %{_mandir}/man1/Xorg.1* %{_mandir}/man1/Xorg.wrap.1* -%{_mandir}/man4/exa.4* +%{_mandir}/man1/cvt.1* %{_mandir}/man4/fbdevhw.4* -%{_mandir}/man4/inputtestdrv.4* +%{_mandir}/man4/exa.4* %{_mandir}/man4/modesetting.4* +%{_mandir}/man5/Xwrapper.config.5* %{_mandir}/man5/xorg.conf.5* %{_mandir}/man5/xorg.conf.d.5* -%{_mandir}/man5/Xwrapper.config.5* %dir %{_sysconfdir}/X11/xorg.conf.d %dir %{_datadir}/X11/xorg.conf.d %{_datadir}/X11/xorg.conf.d/10-quirks.conf @@ -393,6 +488,24 @@ find %{buildroot} -type f -name '*.la' -delete %{_bindir}/Xnest %{_mandir}/man1/Xnest.1* +%files Xdmx +%{_bindir}/Xdmx +%{_bindir}/dmxaddinput +%{_bindir}/dmxaddscreen +%{_bindir}/dmxreconfig +%{_bindir}/dmxresize +%{_bindir}/dmxrminput +%{_bindir}/dmxrmscreen +%{_bindir}/dmxtodmx +%{_bindir}/dmxwininfo +%{_bindir}/vdltodmx +%{_bindir}/dmxinfo +%{_bindir}/xdmxconfig +%{_mandir}/man1/Xdmx.1* +%{_mandir}/man1/dmxtodmx.1* +%{_mandir}/man1/vdltodmx.1* +%{_mandir}/man1/xdmxconfig.1* + %files Xvfb %{_bindir}/Xvfb %{_bindir}/xvfb-run @@ -402,8 +515,12 @@ find %{buildroot} -type f -name '*.la' -delete %{_bindir}/Xephyr %{_mandir}/man1/Xephyr.1* +%files Xwayland +%{_bindir}/Xwayland + %files devel %doc COPYING +#{_docdir}/xorg-server %{_bindir}/xserver-sdk-abi-requires %{_libdir}/pkgconfig/xorg-server.pc %dir %{_includedir}/xorg @@ -415,198 +532,208 @@ find %{buildroot} -type f -name '*.la' -delete %changelog -* Tue Nov 25 2025 Olivier Fourdan - 21.1.21-1 -- Update to xserver 21.1.21 (#2417000) +* Mon Nov 25 2019 Olivier Fourdan - 1.20.6-1 +- xserver 1.20.6 -* Tue Oct 28 2025 Olivier Fourdan - 21.1.20-1 -- Update to xserver 21.1.20 (#2406803) -- CVE fix for: CVE-2025-62229, CVE-2025-62230, CVE-2025-62231 +* Thu Aug 29 2019 Olivier Fourdan 1.20.5-7 +- Pick latest fixes from xserver stable branch upstream (rhbz#1729925) -* Fri Jul 25 2025 Fedora Release Engineering - 21.1.18-2 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild +* Sat Jul 27 2019 Fedora Release Engineering - 1.20.5-6 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild -* Wed Jul 09 2025 Peter Hutterer -- Update Xvfb SPDX license identifier +* Mon Jul 8 2019 Olivier Fourdan 1.20.5-5 +- Do not include on ARM with glibc to avoid compilation failure. +- Do not force vbe and int10 sdk headers as this enables int10 which does + not build on ARM without -* Wed Jun 18 2025 Olivier Fourdan - 21.1.18-1 -- Update to xserver 21.1.18 -- Contains an additional fix for CVE-2025-49176 +* Mon Jul 8 2019 Olivier Fourdan 1.20.5-4 +- Fix regression causing screen tearing with upstream xserver 1.20.5 + (rhbz#1726419) -* Tue Jun 17 2025 Olivier Fourdan - 21.1.17-1 -- Update to xserver 21.1.17 -- CVE fix for: CVE-2025-49175, CVE-2025-49176, CVE-2025-49177 - CVE-2025-49178, CVE-2025-49179, CVE-2025-49180 +* Fri Jun 28 2019 Olivier Fourdan 1.20.5-3 +- Remove atomic downstream patches causing regressions (#1714981, #1723715) +- Xwayland crashes (#1708119, #1691745) +- Cursor issue with tablet on Xwayland +- Xorg/modesetting issue with flipping pixmaps with Present (#1645553) -* Wed Feb 26 2025 Olivier Fourdan - 21.1.16-1 -- Update to xserver 21.1.16 (#2347558) -- CVE fix for: CVE-2025-26594, CVE-2025-26595, CVE-2025-26596, CVE-2025-26597, - CVE-2025-26598, CVE-2025-26599, CVE-2025-26600, CVE-2025-26601 +* Thu Jun 06 2019 Peter Hutterer 1.20.5-2 +- Return AlreadyGrabbed for keycodes > 255 (#1697804) -* Tue Feb 25 2025 Olivier Fourdan - 21.1.15-3 -- Fix DRI2 failure (#2347345) +* Thu May 30 2019 Adam Jackson - 1.20.5-1 +- xserver 1.20.5 -* Sun Jan 19 2025 Fedora Release Engineering - 21.1.15-2 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_42_Mass_Rebuild +* Tue Apr 23 2019 Adam Jackson - 1.20.4-4 +- Fix some non-atomic modesetting calls to be atomic -* Fri Dec 20 2024 José Expósito - 21.1.15-1 -- Update to v21.1.15 +* Wed Mar 27 2019 Peter Hutterer 1.20.4-3 +- Fix a Qt scrolling bug, don't reset the valuator on slave switch -* Fri Nov 29 2024 Sérgio Basto - 21.1.14-3 -- Revert commit "Fix error copying Xorg.wrap", debugedit-5.1-2 have the real fix +* Thu Mar 21 2019 Adam Jackson - 1.20.4-2 +- Backport an Xwayland crash fix in the Present code -* Mon Nov 18 2024 José Expósito - 21.1.14-2 -- Fix build issues caused by Xorg.wrap -- Restore quirks for Apple silicon - Fixes: 422064e45a42 ("Update X11-server to 21.1.13 and ABI numbers of videodrv and xinput") - Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=2326701 +* Tue Feb 26 2019 Adam Jackson - 1.20.4-1 +- xserver 1.20.4 -* Tue Oct 29 2024 José Expósito - 21.1.14-1 -- Update to v21.1.14 +* Sun Feb 03 2019 Fedora Release Engineering - 1.20.3-4 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild -* Wed Oct 16 2024 Peter Robinson -- Obsolete xorg-x11-drv-armsoc +* Fri Jan 11 2019 Olivier Fourdan - 1.20.3-3 +- More Xwayland/Present fixes from upstream (rhbz#1609181, rhbz#1661748) -* Mon Sep 30 2024 Simone Caronni - 21.1.13-5 -- After removal of int10/vbe, obsolete vesa and fbdev X drivers: - https://fedoraproject.org/wiki/Changes/ReplaceFbdevDrivers +* Thu Dec 06 2018 Olivier Fourdan - 1.20.3-2 +- Xwayland/Present fixes from master upstream -* Sat Sep 28 2024 Simone Caronni - 21.1.13-4 -- Remove all conditionals. Drop int10 everywhere and enable libunwind/dri3 on - ELN. +* Thu Nov 01 2018 Adam Jackson - 1.20.3-1 +- xserver 1.20.3 -* Fri Sep 27 2024 Simone Caronni - 21.1.13-3 -- Switch to meson, drop no longer required patch. -- Drop Obsoletes/Provides that have been removed in ~2014. -- Add build depdendencies as they are searched by meson. -- Format SPEC file. +* Mon Oct 15 2018 Adam Jackson - 1.20.2-1 +- xserver 1.20.2 -* Thu Sep 26 2024 Simone Caronni - 21.1.13-2 -- Drop support for building snapshots. If they need to be built, there are - anyway more simpler ways. -- Trim changelog. -- Drop custom compileri/linker flags that are part of the standard already. +* Thu Oct 4 2018 Hans de Goede - 1.20.1-4 +- Rebase patch to use va_gl as vdpau driver on i965 GPUs, re-fix rhbz#1413733 -* Mon Sep 02 2024 Sérgio Basto - 21.1.13-1 -- Update X11-server to 21.1.13 and ABI numbers of videodrv and xinput -- DMX DDX was dropped -- 0001-Disallow-byte-swapped-clients-by-default.patch is upstreamed -- 0001-autobind-GPUs-to-the-screen.patch is upstreamed -- 0001-xf86-dri2-Use-va_gl-as-vdpau_driver-for-Intel-i965-G.patch updated +* Thu Sep 13 2018 Dave Airlie - 1.20.1-3 +- Build with PIE enabled (this doesn't enable bind now) -* Sat Jul 20 2024 Fedora Release Engineering - 1.20.14-37 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild +* Mon Sep 10 2018 Olivier Fourdan - 1.20.1-2 +- Include patches from upstream to fix Xwayland crashes -* Wed Apr 10 2024 José Expósito - 1.20.14-35 -- Backport fix for invalid Unicode sequence +* Thu Aug 09 2018 Adam Jackson - 1.20.1-1 +- xserver 1.20.1 -* Wed Apr 10 2024 José Expósito - 1.20.14-35 -- Fix regression caused by the fix for CVE-2024-31083 +* Sat Jul 14 2018 Fedora Release Engineering - 1.20.0-5 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild -* Wed Apr 03 2024 José Expósito - 1.20.14-34 -- CVE fix for: CVE-2024-31080, CVE-2024-31081, CVE-2024-31082 and - CVE-2024-31083 +* Tue Jun 12 2018 Adam Jackson - 1.20.0-4 +- Xorg and Xwayland Requires: libEGL -* Mon Mar 04 2024 José Expósito - 1.20.14-33 -- Add util-linux as a dependency of Xvfb +* Fri Jun 01 2018 Adam Williamson - 1.20.0-3 +- Backport fixes for RHBZ#1579067 -* Sat Jan 27 2024 Fedora Release Engineering - 1.20.14-32 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild +* Wed May 16 2018 Adam Jackson - 1.20.0-2 +- Xorg Requires: xorg-x11-drv-libinput -* Fri Jan 19 2024 José Expósito - 1.20.14-31 -- Fix compilation error on i686 +* Thu May 10 2018 Adam Jackson - 1.20.0-1 +- xserver 1.20 -* Fri Jan 19 2024 José Expósito - 1.20.14-30 -- Fix use after free related to CVE-2024-21886 +* Wed Apr 25 2018 Adam Jackson - 1.19.99.905-2 +- Fix xvfb-run's default depth to be 24 -* Tue Jan 16 2024 José Expósito - 1.20.14-29 -- CVE fix for: CVE-2023-6816, CVE-2024-0229, CVE-2024-21885, CVE-2024-21886, - CVE-2024-0408 and CVE-2024-0409 +* Tue Apr 24 2018 Adam Jackson - 1.19.99.905-1 +- xserver 1.20 RC5 -* Wed Dec 13 2023 Peter Hutterer - 1.20.14-28 -- CVE fix for: CVE-2023-6377, CVE-2023-6478 +* Thu Apr 12 2018 Olivier Fourdan - 1.19.99.904-2 +- Re-fix "use type instead of which in xvfb-run (rhbz#1443357)" which + was overridden inadvertently -* Fri Nov 10 2023 Peter Hutterer - 1.20.14-27 -- Update with full SPDX license list +* Tue Apr 10 2018 Adam Jackson - 1.19.99.904-1 +- xserver 1.20 RC4 -* Wed Oct 25 2023 Peter Hutterer - 1.20.14-26 -- CVE fix for: CVE-2023-5367, CVE-2023-5380 +* Mon Apr 02 2018 Adam Jackson - 1.19.99.903-1 +- xserver 1.20 RC3 -* Fri Oct 20 2023 José Expósito -- SPDX migration: license is already SPDX compatible +* Tue Feb 13 2018 Olivier Fourdan 1.19.6-5 +- xwayland: avoid race condition on new keymap +- xwayland: Keep separate variables for pointer and tablet foci (rhbz#1519961) +- xvfb-run now support command line option “--auto-display” -* Fri Sep 29 2023 Orion Poplawski - 1.20.14-25 -- Fix xvfb-run --error-file / auth-file options +* Fri Feb 09 2018 Fedora Release Engineering - 1.19.6-4 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild -* Sat Jul 22 2023 Fedora Release Engineering - 1.20.14-24 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild +* Tue Jan 30 2018 Olivier Fourdan 1.19.6-3 +- Avoid generating a core file when the Wayland compositor is gone. -* Tue Apr 25 2023 Olivier Fourdan - 1.20.14-23 -- Backport fix for a deadlock with DRI3 (#2189434) +* Thu Jan 11 2018 Peter Hutterer 1.19.6-2 +- Fix handling of devices with ID_INPUT=null -* Thu Apr 13 2023 Florian Weimer - 1.20.14-22 -- Make more functions available in fb.h with !FB_ACCESS_WRAPPER +* Wed Dec 20 2017 Adam Jackson - 1.19.6-1 +- xserver 1.19.6 -* Wed Mar 29 2023 Olivier Fourdan - 1.20.14-21 -- CVE fix for: CVE-2023-1393 +* Thu Oct 12 2017 Adam Jackson - 1.19.5-1 +- xserver 1.19.5 -* Thu Feb 23 2023 Olivier Fourdan - 1.20.14-20 -- Fix xvfb-run script with --listen-tcp +* Thu Oct 05 2017 Olivier Fourdan - 1.19.4-1 +- xserver-1.19.4 +- Backport tablet support for Xwayland -* Thu Feb 09 2023 Iker Pedrosa - 1.20.14-19 -- Remove pam_console from service file (#1822209) +* Fri Sep 08 2017 Troy Dawson - 1.19.3-9 +- Cleanup spec file conditionals -* Thu Feb 02 2023 Peter Hutterer - 1.20.14-18 -- CVE-2023-0494: potential use-after-free +* Thu Aug 03 2017 Fedora Release Engineering - 1.19.3-8 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild -* Wed Feb 01 2023 Peter Hutterer - 1.20.14-17 -- Updated conditional fedora statement +* Thu Jul 27 2017 Fedora Release Engineering - 1.19.3-7 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild -* Tue Jan 17 2023 Olivier Fourdan - 1.20.14-16 -- Use the recommended way to apply conditional patches without - conditionalizing the sources (for byte-swapped clients). +* Sun Jul 2 2017 Ville Skyttä - 1.19.3-6 +- Use type instead of which in xvfb-run (rhbz#1443357) -* Fri Jan 13 2023 Leif Liddy 1.20.14-15 -- Xorg server does not correctly select the DCP for the display - without a quirk on Apple silicon machines (#2152414) +* Thu May 04 2017 Orion Poplawski - 1.19.3-5 +- Enable full build for s390/x -* Fri Jan 13 2023 Peter Hutterer - 1.20.14-14 -- Disallow byte-swapped clients (#2159489) +* Mon Apr 24 2017 Ben Skeggs - 1.19.3-4 +- Default to xf86-video-modesetting on GeForce 8 and newer -* Wed Jan 11 2023 Olivier Fourdan - 1.20.14-13 -- Rename boolean config value field from bool to boolean to fix drivers - build failures due to a conflict with C++ and stdbool.h +* Fri Apr 07 2017 Adam Jackson - 1.19.3-3 +- Inoculate against a versioning bug with libdrm 2.4.78 -* Mon Dec 19 2022 Peter Hutterer - 1.20.14-12 -- Fix buggy patch to CVE-2022-46340 +* Thu Mar 23 2017 Hans de Goede - 1.19.3-2 +- Use va_gl as vdpau driver on i965 GPUs (rhbz#1413733) -* Wed Dec 14 2022 Peter Hutterer 1.20.14-11 -- CVE fix for: CVE-2022-4283, CVE-2022-46340, CVE-2022-46341, - CVE-2022-46342, CVE-2022-46343, CVE-2022-46344 +* Wed Mar 15 2017 Adam Jackson - 1.19.3-1 +- xserver 1.19.3 -* Wed Nov 23 2022 Peter Hutterer - 1.20.14-10 -- Drop dependency on xorg-x11-font-utils, it was only there for on - build-time variable that's always the same value anyway (#2145088) +* Thu Mar 02 2017 Adam Jackson - 1.19.2-1 +- xserver 1.19.2 -* Tue Nov 8 2022 Olivier Fourdan - 1.20.14-9 -- Fix CVE-2022-3550, CVE-2022-3551 +* Sat Feb 11 2017 Fedora Release Engineering - 1.19.1-4 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild -* Sat Jul 23 2022 Fedora Release Engineering - 1.20.14-8 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild +* Wed Feb 01 2017 Peter Hutterer 1.19.1-3 +- Fix a few input thread lock issues causing intel crashes (#1384486) -* Tue Jul 12 2022 Olivier Fourdan - 1.20.14-7 -- Fix CVE-2022-2319/ZDI-CAN-16062, CVE-2022-2320/ZDI-CAN-16070 +* Mon Jan 16 2017 Adam Jackson - 1.19.1-2 +- Limit the intel driver only on F26 and up -* Wed Apr 13 2022 Dominik Mierzejewski - 1.20.14-6 -- Don't hardcode fps for fake screen (#2054188) +* Wed Jan 11 2017 Adam Jackson - 1.19.1-1 +- xserver 1.19.1 -* Fri Apr 8 2022 Jocelyn Falempe - 1.20.14-5 -- Fix basic graphic mode not working with simpledrm (#2067151) +* Tue Jan 10 2017 Hans de Goede - 1.19.0-4 +- Follow Debian and only default to the intel ddx on gen4 or older intel GPUs -* Fri Jan 28 2022 Olivier Fourdan - 1.20.14-4 -- Fix build with GCC 12 (#2047134) +* Tue Dec 20 2016 Hans de Goede - 1.19.0-3 +- Add one more patch for better integration with the nvidia binary driver -* Tue Jan 25 2022 Olivier Fourdan - 1.20.14-3 -- Fix crash with NVIDIA proprietary driver with Present (#2046147) +* Thu Dec 15 2016 Hans de Goede - 1.19.0-2 +- Add some patches for better integration with the nvidia binary driver +- Add a patch from upstream fixing a crash (rhbz#1389886) -* Sat Jan 22 2022 Fedora Release Engineering - 1.20.14-2 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild +* Wed Nov 23 2016 Olivier Fourdan 1.19.0-1 +- xserver 1.19.0 +- Fix use after free of cursors in Xwayland (rhbz#1385258) +- Fix an issue where some monitors would show only black, or + partially black when secondary GPU outputs are used + +* Tue Nov 15 2016 Peter Hutterer 1.19.0-0.8.rc2 +- Update device barriers for new master devices (#1384432) + +* Thu Nov 3 2016 Hans de Goede - 1.19.0-0.7.rc2 +- Update to 1.19.0-rc2 +- Fix (hopefully) various crashes in FlushAllOutput() (rhbz#1382444) +- Fix Xwayland crashing in glamor on non glamor capable hw (rhbz#1390018) + +* Tue Nov 1 2016 Ben Crocker - 1.19.0-0.6.20161028 +- Fix Config record allocation during startup: if xorg.conf.d directory +- was absent, a segfault resulted. + +* Mon Oct 31 2016 Adam Jackson - 1.19.0-0.5.20161026 +- Use %%autopatch instead of doing our own custom git-am trick + +* Fri Oct 28 2016 Hans de Goede - 1.19.0-0.4.20161026 +- Add missing Requires: libXfont2-devel to -devel sub-package (rhbz#1389711) + +* Wed Oct 26 2016 Hans de Goede - 1.19.0-0.3.20161026 +- Sync with upstream git, bringing in a bunch if bug-fixes +- Add some extra fixes which are pending upstream +- This also adds PointerWarping emulation to Xwayland, which should improve + compatiblity with many games diff --git a/xserver-1-2-glamor-Always-return-0-from-glamor_fds_from_pixmap-on-error.patch b/xserver-1-2-glamor-Always-return-0-from-glamor_fds_from_pixmap-on-error.patch new file mode 100644 index 0000000..32672f2 --- /dev/null +++ b/xserver-1-2-glamor-Always-return-0-from-glamor_fds_from_pixmap-on-error.patch @@ -0,0 +1,54 @@ +From patchwork Wed May 23 09:43:32 2018 +Content-Type: text/plain; charset="utf-8" +MIME-Version: 1.0 +Content-Transfer-Encoding: 8bit +Subject: [xserver, + 1/2] glamor: Always return 0 from glamor_fds_from_pixmap on error +From: =?utf-8?q?Michel_D=C3=A4nzer?= +X-Patchwork-Id: 224909 +Message-Id: <20180523094333.11076-1-michel@daenzer.net> +To: =?UTF-8?q?Louis-Francis=20Ratt=C3=A9-Boulianne?= , + Daniel Stone +Cc: xorg-devel@lists.x.org +Date: Wed, 23 May 2018 11:43:32 +0200 + +From: Michel Dänzer + +This matches what glamor_egl_fds_from_pixmap and dri3_fds_from_pixmap do +and what proc_dri3_buffers_from_pixmap expects. + +Fixes: c8c276c9569b "glamor: Implement PixmapFromBuffers and + BuffersFromPixmap" +Signed-off-by: Michel Dänzer +--- + glamor/glamor.c | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) + +diff --git a/glamor/glamor.c b/glamor/glamor.c +index d984d20f3..e2c74d17a 100644 +--- a/glamor/glamor.c ++++ b/glamor/glamor.c +@@ -836,20 +836,20 @@ glamor_fds_from_pixmap(ScreenPtr screen, PixmapPtr pixmap, int *fds, + glamor_get_screen_private(pixmap->drawable.pScreen); + + if (!glamor_priv->dri3_enabled) +- return -1; ++ return 0; + switch (pixmap_priv->type) { + case GLAMOR_TEXTURE_DRM: + case GLAMOR_TEXTURE_ONLY: + if (!glamor_pixmap_ensure_fbo(pixmap, pixmap->drawable.depth == 30 ? + GL_RGB10_A2 : GL_RGBA, 0)) +- return -1; ++ return 0; + return glamor_egl_fds_from_pixmap(screen, pixmap, fds, + strides, offsets, + modifier); + default: + break; + } +- return -1; ++ return 0; + } + + _X_EXPORT int diff --git a/xserver-2-2-glamor-Propagate-glamor_fds_from_pixmap-error-in-glamor_fd_from_pixmap.patch b/xserver-2-2-glamor-Propagate-glamor_fds_from_pixmap-error-in-glamor_fd_from_pixmap.patch new file mode 100644 index 0000000..ab92d3f --- /dev/null +++ b/xserver-2-2-glamor-Propagate-glamor_fds_from_pixmap-error-in-glamor_fd_from_pixmap.patch @@ -0,0 +1,58 @@ +From patchwork Wed May 23 09:43:33 2018 +Content-Type: text/plain; charset="utf-8" +MIME-Version: 1.0 +Content-Transfer-Encoding: 8bit +Subject: [xserver, 2/2] glamor: Propagate glamor_fds_from_pixmap error in + glamor_fd_from_pixmap +From: =?utf-8?q?Michel_D=C3=A4nzer?= +X-Patchwork-Id: 224910 +Message-Id: <20180523094333.11076-2-michel@daenzer.net> +To: =?UTF-8?q?Louis-Francis=20Ratt=C3=A9-Boulianne?= , + Daniel Stone +Cc: xorg-devel@lists.x.org +Date: Wed, 23 May 2018 11:43:33 +0200 + +From: Michel Dänzer + +glamor_fds_from_pixmap returns 0 on error, but we were treating that as +success, continuing with uninitialized stride and fd values. + +Also bail if the offset isn't 0, same as in dri3_fd_from_pixmap. + +Fixes: c8c276c9569b "glamor: Implement PixmapFromBuffers and + BuffersFromPixmap" +Signed-off-by: Michel Dänzer +Reviewed-by: Emil Velikov +--- + glamor/glamor.c | 16 +++++++--------- + 1 file changed, 7 insertions(+), 9 deletions(-) + +diff --git a/glamor/glamor.c b/glamor/glamor.c +index e2c74d17a..63f0947fa 100644 +--- a/glamor/glamor.c ++++ b/glamor/glamor.c +@@ -865,17 +865,15 @@ glamor_fd_from_pixmap(ScreenPtr screen, + &modifier); + + /* Pixmaps with multi-planes/modifier are not supported in this interface */ +- if (ret > 1) { +- while (ret > 0) +- close(fds[--ret]); +- return -1; ++ if (ret == 1 && offsets[0] == 0) { ++ *stride = strides[0]; ++ *size = pixmap->drawable.height * *stride; ++ return fds[0]; + } + +- ret = fds[0]; +- *stride = strides[0]; +- *size = pixmap->drawable.height * *stride; +- +- return ret; ++ while (ret > 0) ++ close(fds[--ret]); ++ return -1; + } + + _X_EXPORT int diff --git a/xserver-sdk-abi-requires.git b/xserver-sdk-abi-requires.git new file mode 100755 index 0000000..c033061 --- /dev/null +++ b/xserver-sdk-abi-requires.git @@ -0,0 +1,14 @@ +#!/bin/sh +# +# The X server provides capabilities of the form: +# +# Provides: xserver-abi(ansic-0) = 4 +# +# for an ABI version of 0.4. The major number is encoded into the name so +# that major number changes force upgrades. If we didn't, then +# +# Requires: xserver-abi(ansic) >= 0.4 +# +# would also match 1.0, which is wrong since major numbers mean an ABI break. + +echo "xserver-abi($1-@MAJOR@) >= @MINOR@" diff --git a/xserver-sdk-abi-requires.release b/xserver-sdk-abi-requires.release new file mode 100755 index 0000000..30d77bf --- /dev/null +++ b/xserver-sdk-abi-requires.release @@ -0,0 +1,19 @@ +#!/bin/sh +# +# The X server provides capabilities of the form: +# +# Provides: xserver-abi(ansic-0) = 4 +# +# for an ABI version of 0.4. The major number is encoded into the name so +# that major number changes force upgrades. If we didn't, then +# +# Requires: xserver-abi(ansic) >= 0.4 +# +# would also match 1.0, which is wrong since major numbers mean an ABI break. + +ver=$(pkg-config --variable abi_$1 xorg-server) + +major=$(echo $ver | cut -f 1 -d .) +minor=$(echo $ver | cut -f 2 -d .) + +echo "xserver-abi($1-$major) >= $minor" diff --git a/xserver.pamd b/xserver.pamd index 9374ff6..bf79930 100644 --- a/xserver.pamd +++ b/xserver.pamd @@ -1,4 +1,5 @@ #%PAM-1.0 auth sufficient pam_rootok.so +auth required pam_console.so account required pam_permit.so session optional pam_keyinit.so force revoke diff --git a/xvfb-run.sh b/xvfb-run.sh index dec7dfc..9d088c1 100644 --- a/xvfb-run.sh +++ b/xvfb-run.sh @@ -101,7 +101,7 @@ find_free_servernum() { # Parse the command line. ARGS=$(getopt --options +ade:f:hn:lp:s:w: \ - --long auto-servernum,error-file:,auth-file:,help,server-num:,listen-tcp,xauth-protocol:,server-args:,wait: \ + --long auto-servernum,error-file:auth-file:,help,server-num:,listen-tcp,xauth-protocol:,server-args:,wait: \ --name "$PROGNAME" -- "$@") GETOPT_STATUS=$? @@ -120,7 +120,7 @@ while :; do -f|--auth-file) AUTHFILE="$2"; shift ;; -h|--help) SHOWHELP="yes" ;; -n|--server-num) SERVERNUM="$2"; shift ;; - -l|--listen-tcp) LISTENTCP="-listen tcp" ;; + -l|--listen-tcp) LISTENTCP="" ;; -p|--xauth-protocol) XAUTHPROTO="$2"; shift ;; -s|--server-args) XVFBARGS="$2"; shift ;; -w|--wait) STARTWAIT="$2"; shift ;;