blob: 28129fd66abedeb39f15f9072d6ab9f0a0bdc8c6 [file] [log] [blame]
Andrew Geisslereff27472021-10-29 15:35:00 -05001SUMMARY = "Python GObject bindings"
2HOMEPAGE = "https://gitlab.gnome.org/GNOME/pygobject"
3DESCRIPTION = "PyGObject is a Python package which provides bindings for GObject based libraries such as GTK, GStreamer, WebKitGTK, GLib, GIO and many more."
4SECTION = "devel/python"
Andrew Geissler7e0e3c02022-02-25 20:34:39 +00005LICENSE = "LGPL-2.1-only"
Andrew Geisslereff27472021-10-29 15:35:00 -05006LIC_FILES_CHKSUM = "file://COPYING;md5=a916467b91076e631dd8edb7424769c7"
7
8GNOMEBASEBUILDCLASS = "meson"
Andrew Geissler595f6302022-01-24 19:11:47 +00009GIR_MESON_OPTION = ""
10
Andrew Geissler5082cc72023-09-11 08:41:39 -040011inherit gnomebase setuptools3-base gobject-introspection upstream-version-is-even
Andrew Geisslereff27472021-10-29 15:35:00 -050012
Andrew Geissler5082cc72023-09-11 08:41:39 -040013python() {
14 if d.getVar('CLASSOVERRIDE') == "class-target" and not bb.utils.to_boolean(d.getVar("GI_DATA_ENABLED")):
15 raise bb.parse.SkipRecipe("GI not available")
16}
Patrick Williamse760df82023-05-26 11:10:49 -050017
18DEPENDS += "python3 glib-2.0"
Andrew Geisslereff27472021-10-29 15:35:00 -050019
Andrew Geisslereff27472021-10-29 15:35:00 -050020SRCNAME="pygobject"
21
Andrew Geissler220dafd2023-10-04 10:18:08 -050022SRC_URI = "http://ftp.gnome.org/pub/GNOME/sources/${SRCNAME}/${@gnome_verdir("${PV}")}/${SRCNAME}-${PV}.tar.xz"
23SRC_URI[sha256sum] = "426008b2dad548c9af1c7b03b59df0440fde5c33f38fb5406b103a43d653cafc"
Andrew Geisslereff27472021-10-29 15:35:00 -050024
25S = "${WORKDIR}/${SRCNAME}-${PV}"
26
27PACKAGECONFIG ??= "${@bb.utils.contains_any('DISTRO_FEATURES', [ 'directfb', 'wayland', 'x11' ], 'cairo', '', d)}"
28
Patrick Williamse760df82023-05-26 11:10:49 -050029RDEPENDS:${PN} += " \
30 python3-io \
31 python3-pkgutil \
32"
Andrew Geisslereff27472021-10-29 15:35:00 -050033
34# python3-pycairo is checked on configuration -> DEPENDS
35# we don't link against python3-pycairo -> RDEPENDS
36PACKAGECONFIG[cairo] = "-Dpycairo=enabled,-Dpycairo=disabled, cairo python3-pycairo, python3-pycairo"
Andrew Geissler220dafd2023-10-04 10:18:08 -050037PACKAGECONFIG[tests] = "-Dtests=true,-Dtests=false,"
Andrew Geisslereff27472021-10-29 15:35:00 -050038
39BBCLASSEXTEND = "native"
40PACKAGECONFIG:class-native = ""