1 |
%global glib_version 2.75.1 |
2 |
%global gtk3_version 3.19.8 |
3 |
%global gtk4_version 4.0.0 |
4 |
%global gsettings_desktop_schemas_version 40~alpha |
5 |
%global json_glib_version 0.12.0 |
6 |
%global libinput_version 1.19.0 |
7 |
%global pipewire_version 0.3.33 |
8 |
%global lcms2_version 2.6 |
9 |
%global colord_version 1.4.5 |
10 |
%global libei_version 1.0.0 |
11 |
|
12 |
%define url_ver %{lua: ver = rpm.expand("%{version}"); majmin, count1 = string.gsub(ver, "^([0123456789]+%.[0123456789]+).*", "%1", 1); if count1 == 0 then print(ver); return; end; maj, count2 = string.gsub(majmin, "^([0123456789]+).*", "%1", 1); if count2 == 0 then print(majmin) elseif tonumber(majmin) < 40 then print(majmin) else print(maj) end} |
13 |
|
14 |
%define lib_major 0 |
15 |
%define api 14 |
16 |
%define libname %mklibname %{name} %{api} %{lib_major} |
17 |
%define libnamedev %mklibname -d %{name} %{api} |
18 |
|
19 |
%define privatelib %mklibname %{name}-private %{api} |
20 |
%define privategir %mklibname %{name}-private-gir %{api} |
21 |
|
22 |
# (wally) building tests causes ninja to loop forever |
23 |
%bcond_without tests |
24 |
|
25 |
# (tmb) disble underlinking for now |
26 |
%define _disable_ld_no_undefined 1 |
27 |
|
28 |
# ovitters remove this autoreq; this is a hack |
29 |
%global __requires_exclude %{?__requires_exclude:%__requires_exclude|}^devel\\(libmutter- |
30 |
|
31 |
%global libinput_version 1.4 |
32 |
%global json_glib_version 0.12.0 |
33 |
|
34 |
Name: mutter |
35 |
Version: 46.0 |
36 |
Release: %mkrel 1 |
37 |
Summary: Window and compositing manager based on Clutter |
38 |
License: GPLv2+ |
39 |
Group: Graphical desktop/GNOME |
40 |
URL: https://download.gnome.org/sources/mutter/ |
41 |
Source0: https://download.gnome.org/sources/%{name}/%{url_ver}/%{name}-%{version}.tar.xz |
42 |
# upstream git |
43 |
|
44 |
# From Fedora |
45 |
# Work-around for OpenJDK's compliance test |
46 |
Patch50: 0001-window-actor-Special-case-shaped-Java-windows.patch |
47 |
|
48 |
# https://bugzilla.redhat.com/show_bug.cgi?id=1936991 |
49 |
Patch51: mutter-42.alpha-disable-tegra.patch |
50 |
|
51 |
# |
52 |
# From Deb |
53 |
# |
54 |
Source117: wayland-data-device-Allow-any-drag-timestamp-as-drag-star.patch |
55 |
# |
56 |
Patch121: tests-Disable-restore-size-test.patch |
57 |
|
58 |
# From ubuntu |
59 |
# https://bugs.launchpad.net/ubuntu/+source/mutter/+bug/1820850 |
60 |
# (https://gitlab.gnome.org/3v1n0/mutter/-/commits/xrandr-scaling) |
61 |
Source150: x11-Add-support-for-fractional-scaling-using-Randr.patch |
62 |
# |
63 |
|
64 |
# From opensuse |
65 |
Patch201: mutter-SLE-bell.patch |
66 |
|
67 |
# Fix libmutter-test-12.so's soversion |
68 |
Patch500: 0001-Add-soversion-to-libmutter-test-12.so.patch |
69 |
|
70 |
BuildRequires: cvt |
71 |
BuildRequires: git |
72 |
BuildRequires: meson |
73 |
BuildRequires: mesaegl-devel |
74 |
BuildRequires: pkgconfig(gnome-settings-daemon) |
75 |
BuildRequires: pkgconfig(glesv2) |
76 |
BuildRequires: pkgconfig(glib-2.0) >= %{glib_version} |
77 |
BuildRequires: pkgconfig(gio-2.0) >= 2.25.10 |
78 |
BuildRequires: pkgconfig(graphene-gobject-1.0) |
79 |
BuildRequires: pkgconfig(gsettings-desktop-schemas) >= 3.7.3 |
80 |
BuildRequires: pkgconfig(gnome-settings-daemon) |
81 |
BuildRequires: pkgconfig(gnome-desktop-4) |
82 |
BuildRequires: pkgconfig(gtk+-3.0) >= 3.3.3 |
83 |
BuildRequires: pkgconfig(gbm) |
84 |
BuildRequires: pkgconfig(sm) |
85 |
BuildRequires: pkgconfig(libwacom) |
86 |
BuildRequires: pkgconfig(x11) |
87 |
BuildRequires: pkgconfig(libstartup-notification-1.0) >= 0.7 |
88 |
BuildRequires: pkgconfig(libcanberra) |
89 |
BuildRequires: pkgconfig(libcanberra-gtk3) >= 0.26 |
90 |
BuildRequires: pkgconfig(libdisplay-info) |
91 |
BuildRequires: pkgconfig(libpipewire-0.3) >= 0.2.5 |
92 |
BuildRequires: pkgconfig(xcomposite) >= 0.2 |
93 |
BuildRequires: pkgconfig(xcursor) |
94 |
BuildRequires: pkgconfig(pango) >= 1.2.0 |
95 |
BuildRequires: pkgconfig(cairo) >= 1.10.0 |
96 |
BuildRequires: pkgconfig(xfixes) |
97 |
BuildRequires: pkgconfig(xext) |
98 |
BuildRequires: pkgconfig(xdamage) |
99 |
BuildRequires: pkgconfig(xi) >= 1.6.99.1 |
100 |
BuildRequires: pkgconfig(xrandr) |
101 |
BuildRequires: pkgconfig(xrender) |
102 |
BuildRequires: pkgconfig(xdamage) |
103 |
BuildRequires: pkgconfig(gobject-introspection-1.0) >= 0.9.5 |
104 |
BuildRequires: pkgconfig(clutter-1.0) >= 1.19.5 |
105 |
BuildRequires: pkgconfig(upower-glib) >= 0.99.0 |
106 |
BuildRequires: pkgconfig(gnome-desktop-3.0) |
107 |
BuildRequires: pkgconfig(libdrm) |
108 |
BuildRequires: pkgconfig(wayland-server) >= 1.13.0 |
109 |
BuildRequires: pkgconfig(wayland-protocols) >= 1.19 |
110 |
BuildRequires: pkgconfig(lcms2) >= %{lcms2_version} |
111 |
BuildRequires: pkgconfig(colord) >= %{colord_version} |
112 |
# (tv) temp cauldron fix: |
113 |
BuildRequires: %{mklibname ei 1} |
114 |
BuildRequires: pkgconfig(libei-1.0) >= %{libei_version} |
115 |
BuildRequires: pkgconfig(libeis-1.0) >= %{libei_version} |
116 |
BuildRequires: pkgconfig(clutter-wayland-1.0) |
117 |
BuildRequires: pkgconfig(clutter-wayland-compositor-1.0) |
118 |
BuildRequires: pkgconfig(clutter-egl-1.0) |
119 |
BuildRequires: pkgconfig(cogl-1.0) >= 1.17.1 |
120 |
BuildRequires: x11-server-xvfb |
121 |
# for wayland: |
122 |
BuildRequires: x11-server-xwayland |
123 |
BuildRequires: pkgconfig(json-glib-1.0) >= %{json_glib_version} |
124 |
BuildRequires: pkgconfig(libinput) >= %{libinput_version} |
125 |
BuildRequires: pkgconfig(xwayland) |
126 |
BuildRequires: pkgconfig(libsystemd) |
127 |
# Nvidia eglstream: |
128 |
BuildRequires: pkgconfig(wayland-eglstream) |
129 |
BuildRequires: pkgconfig(wayland-eglstream-protocols) |
130 |
BuildRequires: pkgconfig(sysprof-capture-4) |
131 |
BuildRequires: pkgconfig(xtst) |
132 |
BuildRequires: pkgconfig(glu) |
133 |
BuildRequires: pkgconfig(glesv2) |
134 |
BuildRequires: pkgconfig(xkbfile) |
135 |
BuildRequires: pkgconfig(xkbcommon) >= 0.4.3 |
136 |
BuildRequires: pkgconfig(xkbcommon-x11) |
137 |
BuildRequires: pkgconfig(xtst) |
138 |
BuildRequires: pkgconfig(x11-xcb) |
139 |
BuildRequires: pkgconfig(xkeyboard-config) |
140 |
BuildRequires: pkgconfig(gudev-1.0) |
141 |
BuildRequires: gettext |
142 |
BuildRequires: gnome-doc-utils |
143 |
BuildRequires: python3-dbusmock |
144 |
Requires: %{privategir} = %{version}-%{release} |
145 |
%if ! %{with tests} |
146 |
Obsoletes: %{name}-tests < %{version}-%{release} |
147 |
%endif |
148 |
|
149 |
# Need common |
150 |
Requires: %{name}-common = %{version}-%{release} |
151 |
|
152 |
%description |
153 |
Mutter is a window and compositing manager that displays and manages |
154 |
your desktop via OpenGL. Mutter combines a sophisticated display engine |
155 |
using the Clutter toolkit with solid window-management logic inherited |
156 |
from the Metacity window manager. |
157 |
|
158 |
While Mutter can be used stand-alone, it is primarily intended to be |
159 |
used as the display core of a larger system such as GNOME Shell. For |
160 |
this reason, Mutter is very extensible via plugins, which are used both |
161 |
to add fancy visual effects and to rework the window management |
162 |
behaviors to meet the needs of the environment. |
163 |
|
164 |
%package common |
165 |
Summary: Common files used by %{name} and forks of %{name} |
166 |
Group: Graphical desktop/GNOME |
167 |
BuildArch: noarch |
168 |
|
169 |
%description common |
170 |
Common files used by Mutter and soft forks of Mutter. |
171 |
|
172 |
%package -n %{libname} |
173 |
Summary: Libraries for Mutter |
174 |
Group: System/Libraries |
175 |
|
176 |
%description -n %{libname} |
177 |
This package contains libraries used by Mutter. |
178 |
|
179 |
%package -n %{privatelib} |
180 |
Summary: Private libraries for Mutter |
181 |
Group: System/Libraries |
182 |
|
183 |
%description -n %{privatelib} |
184 |
This package contains private libraries used by Mutter. |
185 |
|
186 |
%package -n %{privategir} |
187 |
Summary: GObject Introspection interface description for Mutter |
188 |
Group: System/Libraries |
189 |
Requires: %{libname} = %{version}-%{release} |
190 |
Requires: %{privatelib} = %{version}-%{release} |
191 |
|
192 |
%description -n %{privategir} |
193 |
GObject Introspection interface description for Mutter. |
194 |
|
195 |
%package -n %{libnamedev} |
196 |
Summary: Development package for %{name} |
197 |
Group: Development/GNOME and GTK+ |
198 |
Requires: %{name} = %{version}-%{release} |
199 |
Requires: %{libname} = %{version}-%{release} |
200 |
Requires: %{privatelib} = %{version}-%{release} |
201 |
Requires: %{privategir} = %{version}-%{release} |
202 |
# for EGL/eglmesaext.h that's included from public cogl-egl-defines.h header |
203 |
Requires: %{_lib}mesaegl-devel |
204 |
Provides: %{name}-devel = %{version}-%{release} |
205 |
Provides: lib%{name}-devel = %{version}-%{release} |
206 |
|
207 |
%description -n %{libnamedev} |
208 |
Header files and libraries for developing Mutter plugins. Also includes |
209 |
utilities for testing Metacity/Mutter themes. |
210 |
|
211 |
%package tests |
212 |
Summary: Tests for the %{name} package |
213 |
Group: Development/GNOME and GTK+ |
214 |
Requires: %{name}-devel = %{version}-%{release} |
215 |
Requires: %{name} = %{version}-%{release} |
216 |
|
217 |
%description tests |
218 |
The %{name}-tests package contains tests that can be used to verify |
219 |
the functionality of the installed %{name} package. |
220 |
|
221 |
%prep |
222 |
%autosetup -S git -p1 |
223 |
|
224 |
%build |
225 |
%meson \ |
226 |
-Dtests=%{?with_tests:true}%{!?with_tests:false} \ |
227 |
-Dintrospection=true \ |
228 |
-Dwayland=true \ |
229 |
-Degl_device=true \ |
230 |
-Dwayland_eglstream=true \ |
231 |
-Dxwayland_initfd=enabled \ |
232 |
-Dremote_desktop=true \ |
233 |
-Dnative_backend=true |
234 |
%meson_build |
235 |
|
236 |
%install |
237 |
%meson_install |
238 |
|
239 |
%find_lang %{name} |
240 |
|
241 |
%files -f %{name}.lang |
242 |
%doc NEWS |
243 |
%{_bindir}/mutter |
244 |
%{_libexecdir}/mutter-restart-helper |
245 |
%{_libexecdir}/mutter-x11-frames |
246 |
%{_mandir}/man1/mutter.1* |
247 |
|
248 |
%files common |
249 |
%{_datadir}/GConf/gsettings/mutter-schemas.convert |
250 |
%{_datadir}/glib-2.0/schemas/org.gnome.mutter.gschema.xml |
251 |
%{_datadir}/glib-2.0/schemas/org.gnome.mutter.wayland.gschema.xml |
252 |
%{_datadir}/gnome-control-center/keybindings/50-mutter-*.xml |
253 |
%{_udevrulesdir}/61-mutter.rules |
254 |
|
255 |
%files -n %{libname} |
256 |
%dir %{_libdir}/%{name}-%{api} |
257 |
%dir %{_libdir}/%{name}-%{api}/plugins |
258 |
%{_libdir}/%{name}-%{api}/plugins/libdefault.so |
259 |
%{_libdir}/lib%{name}-%{api}.so.%{lib_major}{,.*} |
260 |
%{_libdir}/%{name}-%{api}/lib%{name}-*-%{api}.so.%{lib_major}{,.*} |
261 |
%{_libdir}/lib%{name}-test-%{api}.so.%{lib_major}{,.*} |
262 |
|
263 |
%files -n %{privategir} |
264 |
%{_libdir}/%{name}-%{api}/*-%{api}.typelib |
265 |
|
266 |
%files -n %{privatelib} |
267 |
%{_libdir}/%{name}-%{api}/libmutter-*-%{api}.so |
268 |
|
269 |
%files -n %{libnamedev} |
270 |
%{_includedir}/* |
271 |
%{_libdir}/lib%{name}*-%{api}.so |
272 |
%{_libdir}/pkgconfig/* |
273 |
%{_libdir}/%{name}-%{api}/*.gir |
274 |
|
275 |
%if %{with tests} |
276 |
%files tests |
277 |
%{_libexecdir}/installed-tests/%{name}-%{api} |
278 |
%{_datadir}/installed-tests/%{name}-%{api} |
279 |
%{_datadir}/%{name}-%{api}/tests |
280 |
%endif |