1 # TODO: switch to gtk4-update-icon-cache
4 %bcond_without sysprofd # daemon to run UI without root permissions
6 Summary: Sampling CPU profiler for Linux
7 Summary(pl.UTF-8): Próbkujący profiler procesora dla Linuksa
12 Group: Applications/System
13 Source0: https://download.gnome.org/sources/sysprof/3.48/%{name}-%{version}.tar.xz
14 # Source0-md5: ee1556063c7b8d9abd414f451b04c33a
15 URL: http://www.sysprof.com/
16 BuildRequires: cairo-devel
17 # -std=gnu11 + C11 atomics
18 BuildRequires: gcc >= 6:4.9
19 BuildRequires: gettext-tools >= 0.19.6
20 BuildRequires: glib2-devel >= 1:2.73.0
21 BuildRequires: gtk4-devel >= 4.6
22 BuildRequires: json-glib-devel
23 BuildRequires: libstdc++-devel >= 6:4.7
24 BuildRequires: libunwind-devel
25 BuildRequires: meson >= 0.59.0
26 BuildRequires: ninja >= 1.5
27 BuildRequires: pango-devel
28 BuildRequires: pkgconfig >= 1:0.22
29 %{?with_sysprofd:BuildRequires: polkit-devel >= 0.114}
30 BuildRequires: rpmbuild(macros) >= 1.736
31 %{?with_sysprofd:BuildRequires: systemd-devel >= 1:222}
32 BuildRequires: tar >= 1:1.22
34 BuildRequires: yelp-tools
35 Requires: %{name}-libs = %{version}-%{release}
36 %{?with_sysprofd:Requires: polkit >= 0.114}
37 %{?with_sysprofd:Requires: systemd-units >= 1:222}
38 Requires: uname(release) >= 2.6.31
39 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
42 Sysprof is a sampling CPU profiler for Linux that uses a kernel module
43 to profile the entire system, not just a single application. Sysprof
44 handles shared libraries and applications do not need to be
45 recompiled. In fact they don't even have to be restarted.
47 Just insert the kernel module and start sysprof.
49 %description -l pl.UTF-8
50 Sysprof to próbkujący profiler procesora dla Linuksa wykorzystujący
51 moduł jądra do profilowania całego systemu, nie tylko pojedynczej
52 aplikacji. Sysprof obsługuje biblioteki współdzielone, a aplikacje nie
53 wymagają rekompilacji. Właściwie nawet nie trzeba ich restartować.
55 Wystarczy załadować moduł jądra i uruchomić sysprof.
58 Summary: The sysprof profiler library
59 Summary(pl.UTF-8): Biblioteka profilera sysprof
61 Requires: glib2 >= 1:2.73.0
64 The sysprof profiler library.
66 %description libs -l pl.UTF-8
67 Biblioteka profilera sysprof.
70 Summary: Header files for sysprof library
71 Summary(pl.UTF-8): Pliki nagłówkowe biblioteki sysprof
72 Group: Development/Libraries
73 Requires: %{name}-libs = %{version}-%{release}
74 Requires: glib2-devel >= 1:2.73.0
75 Obsoletes: sysprof-static < 3.28.0
78 Header files for sysprof library.
80 %description devel -l pl.UTF-8
81 Pliki nagłówkowe biblioteki sysprof.
84 Summary: The sysprof graphical user interface
85 Summary(pl.UTF-8): Graficzny interfejs użytkownika profilera sysprof
86 Group: Applications/System
87 Requires(post,postun): desktop-file-utils
88 Requires(post,postun): glib2 >= 1:2.73.0
89 Requires(post,postun): gtk-update-icon-cache
90 Requires: %{name} = %{version}-%{release}
91 Requires: %{name}-ui-libs = %{version}-%{release}
92 Requires: hicolor-icon-theme
93 Requires: shared-mime-info
96 The sysprof graphical user interface.
98 %description ui -l pl.UTF-8
99 Graficzny interfejs użytkownika profilera sysprof.
102 Summary: The sysprof library containing reusable GTK+ widgets
103 Summary(pl.UTF-8): Biblioteka sysprofa zawierająca widgety GTK+ wielokrotnego użytku
105 Requires: %{name}-libs = %{version}-%{release}
106 Requires: gtk4 >= 4.6
109 The sysprof library containing reusable GTK+ widgets.
111 %description ui-libs -l pl.UTF-8
112 Biblioteka sysprofa zawierająca widgety GTK+ wielokrotnego użytku.
115 Summary: Header files for sysprof-ui library
116 Summary(pl.UTF-8): Pliki nagłówkowe biblioteki sysprof-ui
117 Group: X11/Development/Libraries
118 Requires: %{name}-devel = %{version}-%{release}
119 Requires: %{name}-ui-libs = %{version}-%{release}
120 Requires: gtk4-devel >= 4.6
121 Obsoletes: sysprof-ui-static < 3.28.0
123 %description ui-devel
124 Header files for sysprof-ui library.
126 %description ui-devel -l pl.UTF-8
127 Pliki nagłówkowe biblioteki sysprof-ui.
134 %{!?with_sysprofd:-Dwith_sysprofd=host}
136 %ninja_build -C build
139 rm -rf $RPM_BUILD_ROOT
141 %ninja_install -C build
143 %find_lang %{name} -o %{name}-ui.lang --with-gnome --without-mo
147 rm -rf $RPM_BUILD_ROOT
151 %systemd_post sysprof2.service
154 %systemd_preun sysprof2.service
160 %post libs -p /sbin/ldconfig
161 %postun libs -p /sbin/ldconfig
164 %update_icon_cache hicolor
165 %update_mime_database
166 %update_desktop_database
169 %update_icon_cache hicolor
170 %update_mime_database
171 %update_desktop_database
173 %post ui-libs -p /sbin/ldconfig
174 %postun ui-libs -p /sbin/ldconfig
176 %files -f %{name}.lang
177 %defattr(644,root,root,755)
178 %doc AUTHORS DESIGN.md NEWS README.md
179 %attr(755,root,root) %{_bindir}/sysprof-agent
180 %attr(755,root,root) %{_bindir}/sysprof-cli
182 %attr(755,root,root) %{_libexecdir}/sysprofd
183 %{systemdunitdir}/sysprof2.service
184 %{systemdunitdir}/sysprof3.service
185 %{_datadir}/dbus-1/system-services/org.gnome.Sysprof2.service
186 %{_datadir}/dbus-1/system-services/org.gnome.Sysprof3.service
187 %{_datadir}/dbus-1/system.d/org.gnome.Sysprof2.conf
188 %{_datadir}/dbus-1/system.d/org.gnome.Sysprof3.conf
189 %{_datadir}/polkit-1/actions/org.gnome.sysprof3.policy
193 %defattr(644,root,root,755)
194 %attr(755,root,root) %{_libdir}/libsysprof-4.so
195 %attr(755,root,root) %{_libdir}/libsysprof-memory-4.so
196 %attr(755,root,root) %{_libdir}/libsysprof-speedtrack-4.so
199 %defattr(644,root,root,755)
200 %{_libdir}/libsysprof-capture-4.a
201 %{_includedir}/sysprof-4
202 %{_pkgconfigdir}/sysprof-4.pc
203 %{_pkgconfigdir}/sysprof-capture-4.pc
204 %{_datadir}/dbus-1/interfaces/org.gnome.Sysprof.Agent.xml
205 %{_datadir}/dbus-1/interfaces/org.gnome.Sysprof2.xml
206 %{_datadir}/dbus-1/interfaces/org.gnome.Sysprof3.Profiler.xml
207 %{_datadir}/dbus-1/interfaces/org.gnome.Sysprof3.Service.xml
209 %files ui -f %{name}-ui.lang
210 %defattr(644,root,root,755)
211 %attr(755,root,root) %{_bindir}/sysprof
212 %{_datadir}/metainfo/org.gnome.Sysprof.appdata.xml
213 %{_datadir}/mime/packages/sysprof-mime.xml
214 %{_desktopdir}/org.gnome.Sysprof.desktop
215 %{_iconsdir}/hicolor/scalable/actions/sysprof-*.svg
216 %{_iconsdir}/hicolor/scalable/apps/org.gnome.Sysprof.svg
217 %{_iconsdir}/hicolor/symbolic/apps/org.gnome.Sysprof-symbolic.svg
220 %defattr(644,root,root,755)
221 %attr(755,root,root) %{_libdir}/libsysprof-ui-5.so
224 %defattr(644,root,root,755)
225 %{_includedir}/sysprof-ui-5
226 %{_pkgconfigdir}/sysprof-ui-5.pc