!2 sysprof: importing for gjs updating.

From: @chengguipeng_xian
Reviewed-by: @orange-snn
Signed-off-by: @orange-snn
This commit is contained in:
openeuler-ci-bot 2020-09-19 17:56:47 +08:00 committed by Gitee
commit 77a3932fe5
4 changed files with 140 additions and 0 deletions

BIN
sysprof-3.36.0.tar.xz Normal file

Binary file not shown.

104
sysprof.spec Normal file
View File

@ -0,0 +1,104 @@
Name: sysprof
Version: 3.36.0
Release: 1
Summary: A system-wide Linux profiler
License: GPLv3+
URL: http://www.sysprof.com
Source0: https://download.gnome.org/sources/sysprof/3.36/sysprof-%{version}.tar.xz
# Fix the build on 32 bit hosts
# https://gitlab.gnome.org/GNOME/sysprof/-/merge_requests/24
Patch0: use-G_GSIZE_FORMAT-instead-of-G_GUINT64_FORMAT-for-gsize.patch
BuildRequires: gcc gcc-c++ gettext itstool meson glib2-devel >= 2.61.3
BuildRequires: libdazzle-devel systemd-devel polkit-devel libappstream-glib desktop-file-utils
Requires: glib2 >= 2.61.3 hicolor-icon-theme %{name}-cli = %{version}-%{release}
Requires: libsysprof-ui = %{version}-%{release}
%description
Sysprof is a sampling CPU profiler for Linux that collects accurate.
%package cli
Summary: Sysprof command line utility
# sysprofd needs turbostat
Requires: kernel-tools
%description cli
The %{name}-cli package contains the sysprof-cli command line utility.
%package -n libsysprof-ui
Summary: Sysprof UI library
BuildRequires: gtk3-devel >= 3.22.0
%description -n libsysprof-ui
The libsysprof-ui package contains the Sysprof UI library.
%package devel
Summary: Development files for %{name}
Requires: %{name} = %{version}-%{release}
%description devel
The %{name}-devel package contains libraries and header files for
developing applications that use %{name}.
%package_help
%prep
%autosetup -p1
%build
%meson
%meson_build
%install
%meson_install
%find_lang %{name} --with-gnome
%check
appstream-util validate-relax --nonet %{buildroot}%{_datadir}/metainfo/*.appdata.xml
desktop-file-validate %{buildroot}%{_datadir}/applications/*.desktop
%files
%license COPYING
%doc NEWS AUTHORS
%{_bindir}/sysprof
%{_datadir}/applications/org.gnome.Sysprof3.desktop
%{_datadir}/glib-2.0/schemas/org.gnome.sysprof3.gschema.xml
%{_datadir}/icons/hicolor/*/*/*
%{_datadir}/metainfo/org.gnome.Sysprof3.appdata.xml
%{_datadir}/mime/packages/sysprof-mime.xml
%files cli -f %{name}.lang
%license COPYING
%{_bindir}/sysprof-cli
%{_libdir}/libsysprof-3.so
%{_libdir}/libsysprof-memory-3.so
%{_libexecdir}/sysprofd
%{_datadir}/dbus-1/interfaces/org.gnome.Sysprof2.xml
%{_datadir}/dbus-1/interfaces/org.gnome.Sysprof3.Profiler.xml
%{_datadir}/dbus-1/interfaces/org.gnome.Sysprof3.Service.xml
%{_datadir}/dbus-1/system.d/org.gnome.Sysprof2.conf
%{_datadir}/dbus-1/system.d/org.gnome.Sysprof3.conf
%{_datadir}/dbus-1/system-services/org.gnome.Sysprof2.service
%{_datadir}/dbus-1/system-services/org.gnome.Sysprof3.service
%{_datadir}/polkit-1/actions/org.gnome.sysprof3.policy
%{_unitdir}/sysprof2.service
%{_unitdir}/sysprof3.service
%files -n libsysprof-ui
%license COPYING
%{_libdir}/libsysprof-ui-3.so
%files devel
%{_includedir}/sysprof-3/
%{_libdir}/pkgconfig/sysprof-3.pc
%{_libdir}/pkgconfig/sysprof-capture-3.pc
%{_libdir}/pkgconfig/sysprof-ui-3.pc
%{_libdir}/libsysprof-capture-3.a
%files help
%doc README.md
%changelog
* Sat Sep 19 2020 chengguipeng<chengguipeng1@huawei.com> - 3.36.0-1
- Package init

5
sysprof.yaml Normal file
View File

@ -0,0 +1,5 @@
git_url: https://gitlab.gnome.org/GNOME/sysprof
version_control: gitlab.gnome
src_repo: sysprof
tag_prefix: ^sysprof-
seperator: "."

View File

@ -0,0 +1,31 @@
From 5dea152c7728f5a37370ad8a229115833e36b4f6 Mon Sep 17 00:00:00 2001
From: Rasmus Thomsen <oss@cogitri.dev>
Date: Sat, 7 Mar 2020 10:44:16 +0100
Subject: [PATCH] tests: use G_GSIZE_FORMAT instead of G_GUINT64_FORMAT for
gsize
This fixes the build on 32-bit platforms with -Werror-format
https://gitlab.gnome.org/GNOME/sysprof/-/commit/5dea152c7728f5a37370ad8a229115833e36b4f6
fixes #32
---
src/tests/allocs-by-size.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/tests/allocs-by-size.c b/src/tests/allocs-by-size.c
index 666113a..6260d4b 100644
--- a/src/tests/allocs-by-size.c
+++ b/src/tests/allocs-by-size.c
@@ -109,7 +109,7 @@ allocs_by_size (SysprofCaptureReader *reader)
{
const Item *item = &g_array_index (ar, Item, i);
- g_print ("%"G_GUINT64_FORMAT",%"G_GUINT64_FORMAT",%"G_GUINT64_FORMAT"\n",
+ g_print ("%"G_GSIZE_FORMAT",%"G_GSIZE_FORMAT",%"G_GSIZE_FORMAT"\n",
item->size, item->cmp, item->count);
}
}
--
2.24.1