1SUMMARY = "System-wide Performance Profiler for Linux"
2HOMEPAGE = "http://www.sysprof.com"
3LICENSE = "GPL-3.0-or-later"
4LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504 \
5                    file://src/sysprof/sysprof-application.c;endline=17;md5=a3de8df3b0f8876dd01e1388d2d4b607"
6
7inherit gnomebase gnome-help gettext systemd gsettings gtk-icon-cache mime mime-xdg features_check
8
9DEPENDS += " \
10    desktop-file-utils-native \
11    glib-2.0 \
12    glib-2.0-native \
13    json-glib \
14    libdex \
15    libunwind \
16    libxml2-native \
17    yelp-tools-native \
18"
19
20SRC_URI += "file://0001-meson-Check-for-libunwind-instead-of-libunwind-gener.patch \
21            file://0002-meson-Do-not-invoke-the-commands-to-update-the-icon-.patch \
22            file://0003-libsysprof-Check-for-unw_set_caching_policy-before-u.patch \
23           "
24SRC_URI[archive.sha256sum] = "e4b5ede9fd978ec3f0d5a0d44d0429a6d201c362bf6cb4527319031ae462c54f"
25
26# reason: gtk4 requires opengl distro feature
27REQUIRED_DISTRO_FEATURES = "${@bb.utils.contains('PACKAGECONFIG', 'gtk', 'opengl', '', d)}"
28
29PACKAGECONFIG ?= "${@bb.utils.contains('DISTRO_FEATURES', 'polkit', 'sysprofd libsysprof', '', d)} \
30                  ${@bb.utils.contains_any('DISTRO_FEATURES', '${GTK3DISTROFEATURES}', 'gtk', '', d)} \
31                 "
32
33PACKAGECONFIG[gtk] = "-Dgtk=true,-Dgtk=false,gtk4 libpanel"
34PACKAGECONFIG[sysprofd] = "-Dsysprofd=bundled,-Dsysprofd=none,polkit"
35PACKAGECONFIG[libsysprof] = "-Dlibsysprof=true,-Dlibsysprof=false,polkit"
36
37EXTRA_OEMESON += "-Dsystemdunitdir=${systemd_unitdir}/system"
38
39SOLIBS = ".so"
40FILES_SOLIBSDEV = "${libdir}/libsysprof-6.so"
41
42SYSTEMD_SERVICE:${PN} = "${@bb.utils.contains('PACKAGECONFIG', 'sysprofd', 'sysprof3.service', '', d)}"
43
44FILES:${PN} += " \
45    ${datadir}/dbus-1/system-services \
46    ${datadir}/dbus-1/system.d \
47    ${datadir}/dbus-1/interfaces \
48    ${datadir}/metainfo \
49    ${libdir}/libsysprof-6*.so.* \
50"
51