mutter/mutter.spec

258 lines
10 KiB
RPMSpec

#
# spec file for package mutter
#
# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
%define api_major 3
%define api_minor 0
%define libmutter libmutter-%{api_major}-%{api_minor}
Name: mutter
Version: 3.30.2
Release: 0
Summary: Window and compositing manager based on Clutter
License: GPL-2.0-or-later
Group: System/GUI/GNOME
URL: https://www.gnome.org
Source0: https://download.gnome.org/sources/mutter/3.30/%{name}-%{version}.tar.xz
# PATCH-FIX-UPSTREAM mutter-fix-startup.patch bgo#768531 -- Fix slow startup notification on wayland
Patch0: mutter-fix-startup.patch
# PATCH-FEATURE-UPSTREAM mutter-iconcache-Support-RGB16_565-format-for-16-bit-color-.patch FATE#323412 bgo#781704 bsc#1024748 vliaskovitis@suse.com -- iconcache: Support RGB16_565 format for 16-bit sessions
Patch1: mutter-iconcache-Support-RGB16_565-format-for-16-bit-color-.patch
# PATCH-FIX-OPENSUSE mutter-xwayland-create-xauthority.patch bsc#1084737 hpj@suse.com -- Create and pass an Xauthority file to Xwayland and session
Patch2: mutter-xwayland-create-xauthority.patch
# PATCH-FIX-OPENSUSE mutter-Lower-HIDPI_LIMIT-to-144.patch fate#326682, bsc#1125467 qkzhu@suse.com -- Lower HIDPI_LIMIT to 144
Patch3: mutter-Lower-HIDPI_LIMIT-to-144.patch
# PATCH-FIX-UPSTREAM mutter-Avoid_double-free_crash.patch -- cogl-auto-texture: Avoid a double-free crash
Patch4: mutter-Avoid_double-free_crash.patch
# PATCH-FIX-UPSTREAM mutter-clutter-offscreen-effect-fix.patch -- clutter-offscreen-effect: Disable if no texture
Patch5: mutter-clutter-offscreen-effect-fix.patch
# PATCH-FIX-UPSTREAM mutter-clutter-Avoid-rounding-compensation.patch -- clutter: Avoid rounding compensation when invalidating 2D actors
Patch6: mutter-clutter-Avoid-rounding-compensation.patch
# PATCH-FIX-UPSTREAM mutter-Fix-monitor-recording-on-HiDPI.patch -- screen-cast: Fix monitor recording on HiDPI
Patch7: mutter-Fix-monitor-recording-on-HiDPI.patch
# PATCH-FIX-UPSTREAM mutter-monitor-manager-Dont-use_switch-config.patch -- monitor-manager: Don't use switch-config when ensuring configuration
Patch8: mutter-monitor-manager-Dont-use_switch-config.patch
## SLE-only patches start at 1000
# PATCH-FEATURE-SLE mutter-SLE-bell.patch FATE#316042 bnc#889218 idonmez@suse.com -- make audible bell work out of the box.
Patch1000: mutter-SLE-bell.patch
# PATCH-FIX-SLE mutter-SLE-relax-some-constraints-on-CSD-windows.patch bnc#883491 cxiong@suse.com -- Relax some constraints on window positioning for CSD windows s.t. they can be placed at the very top of the monitor.
Patch1001: mutter-SLE-relax-some-constraints-on-CSD-windows.patch
# PATCH-FIX-UPSTREAM mutter-SLE-bsc984738-grab-display.patch bsc#984738 bgo#769387 hpj@suse.com -- Revert a upstream commit to avoid X11 race condition that results in wrong dialog sizes.
Patch1002: mutter-SLE-bsc984738-grab-display.patch
BuildRequires: Mesa-libGLESv3-devel
BuildRequires: fdupes
BuildRequires: libtool
BuildRequires: pkgconfig
BuildRequires: translation-update-upstream
BuildRequires: zenity
BuildRequires: pkgconfig(cairo) >= 1.10.0
BuildRequires: pkgconfig(egl)
BuildRequires: pkgconfig(gbm) >= 17.1
BuildRequires: pkgconfig(gio-unix-2.0) >= 2.53.2
BuildRequires: pkgconfig(glesv2)
BuildRequires: pkgconfig(gnome-desktop-3.0)
BuildRequires: pkgconfig(gobject-introspection-1.0) >= 0.9.5
BuildRequires: pkgconfig(gsettings-desktop-schemas) >= 3.19.3
BuildRequires: pkgconfig(gtk+-3.0) >= 3.19.7
BuildRequires: pkgconfig(gudev-1.0) >= 232
BuildRequires: pkgconfig(json-glib-1.0)
BuildRequires: pkgconfig(libcanberra-gtk3)
BuildRequires: pkgconfig(libdrm) >= 2.4.83
BuildRequires: pkgconfig(libinput)
BuildRequires: pkgconfig(libpipewire-0.2)
BuildRequires: pkgconfig(libstartup-notification-1.0)
BuildRequires: pkgconfig(libsystemd)
BuildRequires: pkgconfig(libudev) >= 136
BuildRequires: pkgconfig(libwacom)
BuildRequires: pkgconfig(pango) >= 1.2.0
BuildRequires: pkgconfig(sm)
BuildRequires: pkgconfig(upower-glib) >= 0.99.0
BuildRequires: pkgconfig(wayland-protocols) >= 1.10
BuildRequires: pkgconfig(wayland-server) >= 1.13.0
BuildRequires: pkgconfig(x11)
BuildRequires: pkgconfig(x11-xcb)
BuildRequires: pkgconfig(xcb-randr)
BuildRequires: pkgconfig(xcomposite) >= 0.2
BuildRequires: pkgconfig(xcursor)
BuildRequires: pkgconfig(xdamage)
BuildRequires: pkgconfig(xext)
BuildRequires: pkgconfig(xfixes)
BuildRequires: pkgconfig(xi)
BuildRequires: pkgconfig(xinerama)
BuildRequires: pkgconfig(xkbcommon) >= 0.4.3
BuildRequires: pkgconfig(xkbcommon-x11)
BuildRequires: pkgconfig(xkbfile)
BuildRequires: pkgconfig(xkeyboard-config)
BuildRequires: pkgconfig(xrandr) >= 1.5.0
BuildRequires: pkgconfig(xrender)
BuildRequires: pkgconfig(xtst)
Requires: zenity
Recommends: %{name}-lang
Provides: windowmanager
# Obsolete the now private typelib.
Obsoletes: typelib-1_0-Meta-3_0
%description
Mutter is a window and compositing manager based on Clutter, forked
from Metacity.
%package -n %{libmutter}
Summary: Window and compositing manager based on Clutter
# we need the gsettings schema; hopefully, they'll stay backwards compatible
# (since we can't require = version, to not break SLPP)
Group: System/Libraries
Requires: %{name}-data >= %{version}
# We need to obsolete the old mutter libs, as otherwise upgrading is impossible
# This makes me believe we should probably fold libmutter into the main package
# with the next update (3.30)
Obsoletes: libmutter-1-0
Obsoletes: libmutter0
%description -n %{libmutter}
Mutter is a window and compositing manager based on Clutter, forked
from Metacity.
This package contains a library for shared features.
%package data
Summary: Data files for mutter, a window and compositing manager based on Clutter
Group: System/GUI/GNOME
Requires: %{name} = %{version}
%description data
Mutter is a window and compositing manager based on Clutter, forked
from Metacity.
This package contains data files needed by mutter and its library.
%package devel
Summary: Development files for mutter, a window and compositing manager
Group: Development/Libraries/GNOME
Requires: %{libmutter} = %{version}
Requires: %{name} = %{version}
%description devel
This subpackage contains libraries and header files for developing
applications that want to make use of the mutter library.
%lang_package
%prep
%setup -q
%patch0 -p1
%patch1 -p1
%patch2 -p1
%patch3 -p1
%patch4 -p1
%patch5 -p1
%patch6 -p1
%patch7 -p1
%patch8 -p1
# SLE-only patches and translations.
translation-update-upstream
%if !0%{?is_opensuse}
%patch1000 -p1
%patch1001 -p1
%patch1002 -p1
%endif
%build
autoreconf -fiv
%configure \
--enable-wayland \
--enable-native-backend \
--disable-static \
--enable-egl-device \
--enable-gles2=yes \
--enable-compile-warnings=maximum \
--enable-remote-desktop \
%{nil}
%make_build
%install
%make_install
find %{buildroot}%{_libdir} -type f -name '*.la' -delete -print
%find_lang %{name} %{?no_lang_C}
%fdupes %{buildroot}%{_prefix}
%post -n %{libmutter} -p /sbin/ldconfig
%postun -n %{libmutter} -p /sbin/ldconfig
%files
%license COPYING
%doc NEWS
%{_mandir}/man1/mutter.1%{?ext_man}
%{_bindir}/mutter
%{_libexecdir}/mutter-restart-helper
%{_datadir}/applications/mutter.desktop
# These so files are not split out since they are private to mutter
%{_libdir}/mutter/libmutter-clutter-%{api_major}.so
%{_libdir}/mutter/libmutter-cogl-gles2-%{api_major}.so
%{_libdir}/mutter/libmutter-cogl-pango-%{api_major}.so
%{_libdir}/mutter/libmutter-cogl-path-%{api_major}.so
%{_libdir}/mutter/libmutter-cogl-%{api_major}.so
%{_libdir}/mutter/plugins/default.so
# These typelibs are not split out since they are private to mutter
%{_libdir}/mutter/Cally-%{api_major}.typelib
%{_libdir}/mutter/Clutter-%{api_major}.typelib
%{_libdir}/mutter/ClutterX11-%{api_major}.typelib
%{_libdir}/mutter/Cogl-%{api_major}.typelib
%{_libdir}/mutter/CoglPango-%{api_major}.typelib
%{_libdir}/mutter/Meta-%{api_major}.typelib
%files -n %{libmutter}
%{_libdir}/libmutter-%{api_major}.so.*
%dir %{_libdir}/mutter/
# users of libmutter need this directory
%dir %{_libdir}/mutter/plugins/
%files data
# Do not depend on g-c-c just for a directory
%dir %{_datadir}/gnome-control-center
%dir %{_datadir}/gnome-control-center/keybindings
%{_datadir}/gnome-control-center/keybindings/50-mutter-windows.xml
%{_datadir}/gnome-control-center/keybindings/50-mutter-navigation.xml
%{_datadir}/gnome-control-center/keybindings/50-mutter-system.xml
%{_datadir}/gnome-control-center/keybindings/50-mutter-wayland.xml
%{_datadir}/GConf/gsettings/mutter-schemas.convert
%{_datadir}/glib-2.0/schemas/org.gnome.mutter.gschema.xml
%{_datadir}/glib-2.0/schemas/org.gnome.mutter.wayland.gschema.xml
%files devel
%{_includedir}/mutter/
%{_libdir}/libmutter-%{api_major}.so
%{_libdir}/mutter/Meta-%{api_major}.gir
%{_libdir}/mutter/Cally-%{api_major}.gir
%{_libdir}/mutter/Clutter-%{api_major}.gir
%{_libdir}/mutter/ClutterX11-%{api_major}.gir
%{_libdir}/mutter/Cogl-%{api_major}.gir
%{_libdir}/mutter/CoglPango-%{api_major}.gir
%{_libdir}/pkgconfig/libmutter-%{api_major}.pc
%{_libdir}/pkgconfig/mutter-clutter-%{api_major}.pc
%{_libdir}/pkgconfig/mutter-clutter-x11-%{api_major}.pc
%{_libdir}/pkgconfig/mutter-cogl-%{api_major}.pc
%{_libdir}/pkgconfig/mutter-cogl-gles2-%{api_major}.pc
%{_libdir}/pkgconfig/mutter-cogl-pango-%{api_major}.pc
%{_libdir}/pkgconfig/mutter-cogl-path-%{api_major}.pc
%files lang -f %{name}.lang
%changelog