#global gitdate 20151027 # temporary build fix: %define _python_bytecompile_build 0 %bcond_with debug %define enable_builddocs 0 %global build_using_meson 1 # Need this for shared objects that reference X Server, or other modules symbols %define _disable_ld_no_undefined 1 # Alternatives priority for standard libglx.so and mesa libs %define priority 500 %define rel 1 %global __provides_exclude_from %{_datadir}/%{name}-source %global __requires_exclude_from %{_datadir}/%{name}-source # 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 xinput_major 24 %global xinput_minor 4 %global extension_major 10 %global extension_minor 0 %global pkgname xorg-server Name: x11-server Version: 21.1.18 Release: %mkrel %{rel}%{?gitdate:.%{gitdate}} Summary: X11 servers Group: System/X11 URL: https://xorg.freedesktop.org %if 0%{?gitdate} Source0: xorg-server-%{gitdate}.tar.xz %else Source0: https://www.x.org/pub/individual/xserver/%{pkgname}-%{version}.tar.xz Source1: gitignore %endif Source4: 10-quirks.conf Source5: mageia-setup-keyboard-udev Source6: 61-x11-input.rules Source10: xserver.pamd # from RH/FC: # "useful" xvfb-run script Source20: https://svn.exactcode.de/t2/trunk/package/xorg/xorg-server/xvfb-run.sh Source21: https://svn.exactcode.de/t2/trunk/package/xorg/xorg-server/xvfb-run.1 # for requires generation in drivers Source30: xserver-sdk-abi-requires.release # for finding & loading nvidia and flgrx drivers: Source90: 00-modules.conf License: GPLv2+ and MIT # Instructions to setup your repository clone # git://anongit.freedesktop.org/git/xorg/xserver # git checkout origin/server-1.7-branch # git checkout -b mdv-1.7-cherry-picks # git am ../03??-*.patch # git checkout -b mdv-1.7-redhat # git am ../04??-*.patch # git checkout -b mdv-1.7-patches # git am ../09??-*.patch # Sync with server-21.1-branch (https://gitlab.freedesktop.org/xorg/xserver/-/tree/server-21.1-branch?ref_type=heads) # git clone https://gitlab.freedesktop.org/xorg/xserver # git format-patch --start-number 100 xorg-server-21.1.18..origin/server-21.1-branch Patch0101: 0101-glamor_egl-handle-fd-export-failure-in-glamor_egl_fd.patch Patch0102: 0102-glamor_egl-properly-get-FDs-from-multiplanar-GBM-BOs.patch Patch0103: 0103-glamor-xv-Fix-invalid-accessing-of-plane-attributes-.patch Patch0104: 0104-meson-add-glamor-gles2-tests.patch Patch0105: 0105-glamor-transpose-gradients-transparently.patch Patch0106: 0106-glamor-fix-CbCr-format-handling.patch Patch0107: 0107-glamor-use-dual-source-blend-on-GL-2.1-with-ARB_ES2_.patch Patch0108: 0108-glamor-fix-XVideo-run-with-GLES.patch Patch0109: 0109-glamor-handle-EXT_gpu_shader4-in-dual-source-blend-p.patch Patch0110: 0110-glamor-fixes-GL_INVALID_ENUM-errors-on-ES-if-there-i.patch Patch0111: 0111-glamor-add-gl_PointSize-for-ES-shaders.patch Patch0112: 0112-glamor-accelerate-incomplete-textures-for-GL-ES.patch Patch0113: 0113-glamor-support-GLES3-shaders.patch Patch0114: 0114-glamor-Don-t-require-EXT_gpu_shader4-unconditionally.patch Patch0115: 0115-glamor_egl-add-helper-functions-for-contexts.patch Patch0116: 0116-glamor_egl-add-RenderingAPI-option.patch Patch0117: 0117-xorg.conf.man-document-new-RenderingAPI-option.patch Patch0118: 0118-glamor_egl-add-info-message-about-context-API.patch Patch0119: 0119-glamor-add-glvnd_vendor-private.patch Patch0120: 0120-glamor-Lift-the-GLX-EGL-backend-from-Xwayland.patch Patch0121: 0121-xorg-initialize-glamor-provider.patch Patch0122: 0122-glamor_egl-add-support-of-GlxVendorLibrary-option.patch Patch0123: 0123-glamor-xv-do-not-force-a-version-on-XV-shaders.patch Patch0124: 0124-glamor-xv-reuse-ports-and-shaders-when-possible.patch Patch0125: 0125-glamor-xv-prepare-to-one-plane-formats.patch Patch0126: 0126-glamor-xv-enable-UYVY-acceleration.patch Patch0127: 0127-glamor-xv-add-rgba32-format.patch Patch0128: 0128-glamor-xv-add-rgb565.patch Patch0129: 0129-glamor-check-BPP-by-render_format.patch Patch0130: 0130-glamor-xv-fix-UYVY-alignment.patch Patch0131: 0131-glamor-xv-Rewrite-UYVY-shader-to-match-NV12-I420-CSC.patch Patch0132: 0132-Fix-autotools-build-for-Glamor-GLX-provider.patch Patch0133: 0133-glamor-Fallback-to-software-rendering-on-GLSL-link-f.patch Patch0134: 0134-xwayland-glamor-Handle-depth-15-in-gbm_format_for_de.patch Patch0135: 0135-glamor-return-the-result-of-gbm_format_for_depth.patch Patch0136: 0136-glamor-use-gbm_format_for_depth-instead-of-open-codi.patch Patch0137: 0137-glamor-reject-configs-using-unsupported-rgbBits-size.patch Patch0138: 0138-glamor-Fix-dual-blend-on-GLES3.patch # xorg server master branch from 200 Patch0200: 0200-xf86-Accept-devices-with-the-hyperv_drm-driver.patch # Patch0201: 0225-os-Try-to-discover-the-current-seat-with-the-XDG_SEA.patch Patch0202: 0237-meson-Add-dependencies-for-hw-xwin-resource-compilat.patch Patch0203: 0239-meson-Fix-build-of-xwinclip-tool-when-xcb-is-install.patch Patch0204: 0363-meson-Use-system-method-for-locating-tirpc.patch Patch0205: 0396-test-Fix-xephr-mis-spelling.patch Patch0206: 0403-meson-fix-types-for-some-build-options.patch Patch0207: 0408-xf86AutoConfig-try-modesetting-on-all-platforms-we-b.patch Patch0208: 0731-meson-add-option-for-systemd_notify.patch Patch0209: 0742-meson.build-re-enable-the-protocol-unit-tests.patch Patch0210: 2068-modesetting-Check-for-NULL-mode_output-before-printi.patch Patch0211: 2070-os-use-close-on-exec-for-X-server-socket-to-prevent-.patch # # xlibre cherry picking from 500 # https://github.com/X11Libre/xserver Patch0500: 1515-xfixes-xace-fix-pointer-type-mismatch-on-XFixesSelec.patch Patch0501: 2459-Xi-xibarriers-protect-add_master_func-from-allocatio.patch Patch0502: 2464-xkb-fix-NULL-pointer-dereference-in-XkbDDXLoadKeymap.patch Patch0503: 2497-glx-protect-createModeFromConfig-from-allocation-fai.patch Patch0504: 2505-xfree86-utils-gracefully-handle-allocation-failure.patch Patch0505: 2509-xfree86-ddc-safety-check-for-NULL-pointer.patch Patch0506: 2521-dix-protect-ChangeWindowDeviceCursor-from-allocation.patch Patch0507: 2543-exa-protect-against-NULL-pointer-dereference.patch Patch0508: 2809-os-support-systemd-logind-don-t-hard-crash-Xserver-o.patch # Fedora Patches # Default to xf86-video-modesetting on GeForce 8 and newer Patch1: 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 ? Patch3: 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 Patch6: 0001-Fedora-hack-Make-the-suid-root-wrapper-always-start-.patch # Backports from current stable "server-1.20-branch": # # Backports from "master" upstream: # # Mageia patches # git format-patch --start-number 900 mdv-1.6.4-redhat..mdv-1.6.4-patches # todo: requires to be ported to meson Patch900: 0900-Use-a-X-wrapper-that-uses-pam-and-consolehelper-to-g.patch # Patch901: 0901-Don-t-print-information-about-X-Server-being-a-pre-r.patch Source902: 0902-Take-width-into-account-when-choosing-default-mode.patch Source903: 0903-LED-behavior-fixes.patch Patch906: 0906-xfree86-need-to-press-Ctrl-Alt-Bksp-twice-to-termina.patch # force modesetting for AlderLake-P and AlderLake-P with Xe-graphics (bug #31654) Patch950: 0001-Force-modesetting-for-AlderLake-P-and-RaptorLake-P-w.patch # force modesetting for RaptorLake-P with UHD graphics (bug #31654) Patch951: 0001-Force-modesetting-for-RaptorLake-P-with-UHD-graphics.patch # force modesetting for AlderLake-N with UHD graphics (bug #31654) Patch952: 0001-Force-modesetting-for-more-AlderLake-N-with-UHD-grap.patch # force modesetting for RocketLake-S with UHD graphics (bug #31654) Patch953: 0001-Force-modesetting-for-RocketLake-S-with-UHD-graphics.patch # force modesetting for ElkhartLake, JasperLake and TigerLake with UHD and Xe graphics (bug #31654) Patch954: 0001-Force-modesetting-for-ElkhartLake-JasperLake-TigerLa.patch # Fix modesetting driver linking Patch955: 0001-Fix-modesetting_drv.so-linking.patch # Default intel card to modesetting except pre-gen4 which uses intel DDX (originally from debian & fc) Patch956: 06_use-intel-only-on-pre-gen4-rediff.patch Patch957: 0001-Use-modesetting-as-default-for-intel.patch # Candidates for dropping: # 902: by pixel, so that X11 choose the best resolution with a better algorithm # 903: Input subsystem has changed *a lot* since this patch was written... I # fear it might break things now # 906: All this patch does is force users to hit ctrl+alt+bksp twice (with # an annoying sound) IF the hotkey is enabled. If the user chooses to # enable ctrk+alt+bksp, why force him to hit twice? OTOH, the sound is # annoying, and it should teach users to not use ctrl+alt+bksp =D # Do not crash if Xv is not initialized (patch from xorg-devel ML) # The crash happened when v4l was loaded and xv was not registered, # for example on RV610 with radeon driver Patch4001: 1001-do-not-crash-if-xv-not-initialized.patch # (cg) Point the user at the journal rather than a logfile at /dev/null Patch5001: point-user-at-journal-rather-than-dev-null.patch # from Suse Patch5009: N_Disable-HW-Cursor-for-cirrus-and-mgag200-kernel-modules.patch Patch5011: n_raise_default_clients.patch # Security fixes Requires: %{name}-xorg Requires: %{name}-xnest Requires: %{name}-xvfb # This should be removed when any of the vnc packages provide x11-server-xvnc: Obsoletes: %{name}-xvnc < %{version}-%{release} Obsoletes: %{name}-xfake < %{version}-%{release} # temp force new gcc BuildRequires: gcc >= 12.0.1-0.20220227.2 BuildRequires: binutils >= 1:2.38-4 # temp force new glibc BuildRequires: glibc >= 6:2.33-2 # nsl bits gone in glibc 2.32, add separate libnsl dep BuildRequires: pkgconfig(libnsl) # rpc bits gone in glibc 2.32, add separate libtirpc dep BuildRequires: pkgconfig(libtirpc) BuildRequires: systemtap-sdt-devel BuildRequires: git-core BuildRequires: libpam-devel %if %{build_using_meson} BuildRequires: meson BuildRequires: cmake %endif BuildRequires: pkgconfig(egl) BuildRequires: pkgconfig(fontutil) >= 1.1 BuildRequires: pkgconfig(gbm) BuildRequires: pkgconfig(dri) BuildRequires: pkgconfig(gl) BuildRequires: pkgconfig(libxcvt) BuildRequires: pkgconfig(libudev) BuildRequires: pkgconfig(pciaccess) BuildRequires: pkgconfig(pixman-1) >= 0.9.5 BuildRequires: pkgconfig(libsystemd) BuildRequires: pkgconfig(xau) >= 1.0.0 BuildRequires: pkgconfig(xaw7) >= 1.0.1 BuildRequires: pkgconfig(xdmcp) >= 1.0.0 BuildRequires: pkgconfig(xext) >= 1.1 BuildRequires: pkgconfig(xfixes) BuildRequires: pkgconfig(xfont2) BuildRequires: pkgconfig(xi) >= 1.1.3 BuildRequires: pkgconfig(xkbfile) >= 1.0.4 BuildRequires: pkgconfig(xmu) >= 1.0.0 BuildRequires: pkgconfig(xorg-macros) >= 1.10 BuildRequires: pkgconfig(xpm) >= 3.5.4.2 BuildRequires: pkgconfig(xrender) >= 0.9.4 BuildRequires: pkgconfig(xres) >= 1.0.0 BuildRequires: pkgconfig(xtrans) >= 1.3.5 BuildRequires: pkgconfig(xv) BuildRequires: x11-proto-devel >= 7.7-11 # for ./hw/xwin/glx/gen_gl_wrappers.py: %define _python_bytecompile_errors_terminate_build 0 # Probably only needed if we change .l or .y files, but let's have them anyway: BuildRequires: byacc BuildRequires: flex # for xkbcomp patch BuildRequires: pkgconfig(libcrypto) BuildRequires: pkgconfig(dbus-1) BuildRequires: pkgconfig(xtst) >= 1.1 BuildRequires: pkgconfig(epoxy) BuildRequires: pkgconfig(xshmfence) >= 1.1 BuildRequires: pkgconfig(libunwind) BuildRequires: pkgconfig(xcb-aux) pkgconfig(xcb-image) pkgconfig(xcb-icccm) BuildRequires: pkgconfig(xcb-keysyms) pkgconfig(xcb-renderutil) %if %{enable_builddocs} BuildRequires: doxygen BuildRequires: fop BuildRequires: xmlto BuildRequires: pkgconfig(xorg-sgml-doctools) %endif %description X.Org X11 X server. %package common Summary: Xorg server common files Group: System/X11 License: MIT Provides: XFree86 = 7.0.0 Requires: rgb # for 'fixed' and 'cursor' fonts Requires: x11-font-misc-misc Requires: x11-font-cursor-misc Requires: x11-font-alias Requires: x11-data-xkbdata Requires: xkbcomp Requires: udev # else modesetting fails on minimal install: Requires: %{mklibname mesaegl 1} Requires(post): update-alternatives Requires(postun): update-alternatives # nvidia-71xx does not support X.org server >= 1.5 Conflicts: x11-driver-video-nvidia71xx < 71.86.09-2 # old fglrx does not support X.org server >= 1.7 Conflicts: x11-driver-video-fglrx < 8.720 # Fix: missing conflicts to allow upgrade from 2008.0 to cooker # https://qa.mandriva.com/show_bug.cgi?id=36651 Conflicts: x11-driver-video-nvidia-current <= 100.14.19 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} # For proprietary drivers that can support multiple videodrv versions: Provides: xserver-abi(videodrv) = %{videodrv_major}.%{videodrv_minor} %description common X server common files. %package xorg Summary: Xorg X server Group: System/X11 License: MIT Requires: x11-server-common = %{version}-%{release} Requires: x11-data-xkbdata > 1.3-5 Requires: x11-font-alias Requires: libx11-common Requires: x11-driver-input-libinput %rename glamor %rename x11-driver-video-modesetting %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 Group: System/X11 License: MIT Requires: x11-server-common = %{version}-%{release} %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 Group: System/X11 # xvfb-run is GPLv2, rest is MIT License: MIT and GPLv2 Requires: x11-server-common = %{version}-%{release} Requires: xauth %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 Group: System/X11 License: MIT Requires: x11-server-common = %{version}-%{release} %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 Group: Development/X11 License: MIT %define oldxorgnamedevel %mklibname xorg-x11 Requires: libpixman-1-devel Requires: libpciaccess-devel Requires: libxkbfile-devel Requires: libxext-devel >= 1.1 Requires: pkgconfig(xfont2) # pkgconfig file needs dri.pc: Requires: GL-devel %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. %package source Summary: Xserver source code required to build VNC server (Xvnc) Group: Development/X11 License: MIT BuildArch: noarch %description source Xserver source code needed to build VNC server (Xvnc). %prep %autosetup -N -n %{pkgname}-%{?gitdate:%{gitdate}}%{!?gitdate:%{version}} rm -rf .git cp %{SOURCE1} .gitignore # ick %global __scm git %{expand:%__scm_setup_git -q} %autopatch # check the ABI in the source against what we expect. getmajor() { grep -i ^#define.ABI.$1_VERSION hw/xfree86/common/xf86Module.h | tr '(),' ' ' | awk '{ print $4 }' } getminor() { grep -i ^#define.ABI.$1_VERSION hw/xfree86/common/xf86Module.h | tr '(),' ' ' | awk '{ print $5 }' } test `getmajor ansic` == %{ansic_major} test `getminor ansic` == %{ansic_minor} test `getmajor videodrv` == %{videodrv_major} test `getminor videodrv` == %{videodrv_minor} test `getmajor xinput` == %{xinput_major} test `getminor xinput` == %{xinput_minor} test `getmajor extension` == %{extension_major} test `getminor extension` == %{extension_minor} %build %if %{build_using_meson} # build with meson %ifnarch %{ix86} x86_64 %global no_int10 %nil %endif %global xservers -Dxvfb=true -Dxnest=true -Dxephyr=true -Dxorg=true %global default_font_path "catalogue:/etc/X11/fontpath.d,built-ins" %global dri_flags -Ddri2=true -Ddri3=true -Dsuid_wrapper=true -Dglamor=true %global bodhi_flags -Dvendor_name="%_vendor" %meson \ %{xservers} \ -Dlog_dir="%{_logdir}" \ %{?no_int10} -Dint10=x86emu \ -Ddefault_font_path="%{default_font_path}" \ -Dmodule_dir="%{_libdir}/xorg/modules" \ -Dvendor_web="https://bugs.mageia.org" \ %if %{with debug} -Ddebug=true \ %endif -Dbuilder_string="Build ID: %{name} %{version}-%{release}" \ -Ddtrace=false \ -Dxselinux=false \ -Dxcsecurity=true \ -Dudev=true \ -Ddpms=true \ -Dxephyr=true \ %{dri_flags} %{?bodhi_flags} \ -Dsha1=libgcrypt %meson_build %else # build using autotools %ifnarch %{ix86} x86_64 %global no_int10 --disable-vbe --disable-int10-module %endif %global kdrive --enable-kdrive --enable-xephyr %global xservers --enable-xvfb --enable-xnest %{kdrive} --enable-xorg %global default_font_path "catalogue:/etc/X11/fontpath.d,built-ins" %global dri_flags --enable-dri2 --enable-dri3 --enable-suid-wrapper --enable-glamor %global bodhi_flags --with-vendor-name="%_vendor" %if %with debug CFLAGS='-DBUILDDEBUG -O0 -g3' \ %endif autoreconf -f -v --install || exit 1 %configure %{xservers} \ --with-log-dir=%{_logdir} \ --enable-dependency-tracking \ %{?no_int10} --with-int10=x86emu \ --with-default-font-path=%{default_font_path} \ --with-module-dir=%{_libdir}/xorg/modules \ --with-vendor-web="https://bugs.mageia.org" \ %if %{with debug} --enable-debug \ %else --disable-debug \ %endif --with-builderstring="Build ID: %{name} %{version}-%{release}" \ --without-dtrace \ --disable-xselinux --enable-record --enable-present \ --enable-xcsecurity \ --enable-config-udev \ --disable-strict-compilation \ --enable-dpms \ --disable-install-setuid \ --enable-pam \ %{dri_flags} %{?bodhi_flags} \ --with-sha1=libcrypto pushd include && make xorg-server.h dix-config.h xorg-config.h && popd %make_build %endif %install %if %{build_using_meson} %meson_install %else %make_install %endif mkdir -p $RPM_BUILD_ROOT%{_libdir}/xorg/modules/{drivers,input} mkdir -p %{buildroot}%{_sysconfdir}/X11/ ln -s %{_bindir}/Xorg %{buildroot}%{_sysconfdir}/X11/X ln -sf %{_libexecdir}/Xorg.wrap %{buildroot}%{_bindir}/X mkdir -p %{buildroot}%{_sysconfdir}/pam.d install -m 644 %{SOURCE10} $RPM_BUILD_ROOT%{_sysconfdir}/pam.d/xserver mkdir -p %{buildroot}%{_sysconfdir}/security/console.apps touch %{buildroot}%{_sysconfdir}/security/console.apps/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 $RPM_BUILD_ROOT%{_sysconfdir}/X11/xorg.conf.d mkdir -p %{buildroot}%{_sysconfdir}/X11/app-defaults mkdir -p %{buildroot}%{_sysconfdir}/X11/fontpath.d # move README.compiled outside compiled/ dir, so there won't be any problem with x11-data-xkbdata %if !%{build_using_meson} # this is not installed in meson (see bottom of xkb/Makefile.am vs xkb/meson.build) mv -f %{buildroot}%{_datadir}/X11/xkb/compiled/README.compiled %{buildroot}%{_datadir}/X11/xkb/ %endif # (anssi) manage proprietary drivers install -d -m755 %{buildroot}%{_sysconfdir}/ld.so.conf.d/GL cat > %{buildroot}%{_sysconfdir}/ld.so.conf.d/GL/standard.conf << EOF # This file is knowingly empty since the libraries are in standard search # path. Please do not remove this file. EOF touch %{buildroot}%{_sysconfdir}/ld.so.conf.d/GL.conf mkdir -p %{buildroot}/sbin mkdir -p %{buildroot}/lib/udev/rules.d/ install -m 0755 %{SOURCE5} %{buildroot}/sbin/mageia-setup-keyboard install -m 0644 %{SOURCE6} %{buildroot}/lib/udev/rules.d install -m 755 %{SOURCE30} $RPM_BUILD_ROOT%{_bindir}/xserver-sdk-abi-requires install -m 0755 %{SOURCE20} $RPM_BUILD_ROOT%{_bindir}/xvfb-run # Make the source package %global xserver_source_dir %{_datadir}/x11-server-source %global inst_srcdir %{buildroot}/%{xserver_source_dir} mkdir -p %{inst_srcdir}/{Xext,xkb,GL,hw/{xquartz/bundle,xfree86/common}} mkdir -p %{inst_srcdir}/{man,doc} cp {,%{inst_srcdir}/}hw/xquartz/bundle/cpprules.in cp {,%{inst_srcdir}/}man/Xserver.man cp {,%{inst_srcdir}/}doc/smartsched 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 install -m 0755 %{SOURCE21} $RPM_BUILD_ROOT%{_mandir}/man1/xvfb-run.1 install -m 0644 %{SOURCE90} $RPM_BUILD_ROOT/usr/share/X11/xorg.conf.d/ find . -type f | grep -E '.*\.(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 %if %{build_using_meson} # how to avoid install these? rm -rf %{buildroot}%{_datadir}/x11-server-source/build/meson-logs rm -rf %{buildroot}%{_datadir}/x11-server-source/build/meson-private %if !%{enable_builddocs} rm -f %{buildroot}%{_datadir}/doc/xorg-server/Xserver-DTrace.{html,html.db,pdf.db,pdf,ps} %endif %endif # Remove unwanted files/dirs { 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 } %post common %{_sbindir}/update-alternatives \ --install %{_sysconfdir}/ld.so.conf.d/GL.conf gl_conf %{_sysconfdir}/ld.so.conf.d/GL/standard.conf %{priority} # (anssi) %triggerun common -- %{name}-common < 1.3.0.0-17 [ $1 -eq 2 ] || exit 0 # do not run if downgrading current_glconf="$(readlink -e %{_sysconfdir}/ld.so.conf.d/GL.conf)" if [ "${current_glconf#*mesa}" == "gl1.conf" ]; then # This an upgrade of a system with no proprietary drivers enabled, update # the link to point to the new standard.conf instead of libmesagl1.conf (2008.0 change). %{_sbindir}/update-alternatives --set gl_conf %{_sysconfdir}/ld.so.conf.d/GL/standard.conf else # XFdrake did not set symlink to manual mode before 2008.0, so we ensure it here. %{_sbindir}/update-alternatives --set gl_conf "${current_glconf}" fi true %postun common if [ ! -f %{_sysconfdir}/ld.so.conf.d/GL/standard.conf ]; then /usr/sbin/update-alternatives --remove gl_conf %{_sysconfdir}/ld.so.conf.d/GL/standard.conf fi %files %files common %dir %{_libdir}/xorg/modules %dir %{_sysconfdir}/X11 %dir %{_sysconfdir}/X11/app-defaults %dir %{_sysconfdir}/X11/fontpath.d %dir %{_sysconfdir}/ld.so.conf.d/GL %dir %{_sysconfdir}/X11/xorg.conf.d %ghost %{_sysconfdir}/ld.so.conf.d/GL.conf %{_sysconfdir}/ld.so.conf.d/GL/standard.conf %{_bindir}/gtf /sbin/mageia-setup-keyboard /lib/udev/rules.d/61-x11-input.rules %{_libdir}/xorg/modules/* %{_libdir}/xorg/protocol.txt %if !%{build_using_meson} %{_datadir}/X11/xkb/README.compiled %endif %{_mandir}/man1/gtf.* %{_mandir}/man4/* %global Xorgperms %attr(4755, root, root) %files xorg %{_bindir}/X %{_bindir}/Xorg %{_libexecdir}/Xorg %{Xorgperms} %{_libexecdir}/Xorg.wrap %if !%{build_using_meson} %attr(4755,root,root)%{_bindir}/Xwrapper %endif %{_sysconfdir}/X11/X %{_sysconfdir}/pam.d/xserver %{_sysconfdir}/security/console.apps/xserver %{_mandir}/man1/Xorg.1* %{_mandir}/man1/Xorg.wrap.1* %{_mandir}/man1/Xserver.1* %{_mandir}/man5/Xwrapper.config.5* %{_mandir}/man5/xorg.conf.5* %{_mandir}/man5/xorg.conf.d.5* %{_datadir}/X11/xorg.conf.d/00-modules.conf %{_datadir}/X11/xorg.conf.d/10-quirks.conf %files xnest %{_bindir}/Xnest %{_mandir}/man1/Xnest.1* %files xvfb %{_bindir}/Xvfb %{_bindir}/xvfb-run %{_mandir}/man1/Xvfb.1* %{_mandir}/man1/xvfb-run.1* %files xephyr %{_bindir}/Xephyr %{_mandir}/man1/Xephyr.1* %files devel %{_bindir}/xserver-sdk-abi-requires %{_libdir}/pkgconfig/xorg-server.pc %dir %{_includedir}/xorg %{_includedir}/xorg/*.h %{_datadir}/aclocal/xorg-server.m4 %files source %{xserver_source_dir}