diff mbox series

[meta-gnome,06/10] xdg-desktop-portal: add recipe

Message ID 20221219131041.452949-6-f_l_k@t-online.de
State Under Review
Headers show
Series [meta-gnome,01/10] pipewire: update 0.3.62 -> 0.3.63 | expand

Commit Message

Markus Volk Dec. 19, 2022, 1:10 p.m. UTC
Signed-off-by: Markus Volk <f_l_k@t-online.de>
---
 ...p-portal-pc-in-add-pc_sysrootdir-dir.patch | 25 ++++++++++++
 .../xdg-desktop-portal_1.16.0.bb              | 40 +++++++++++++++++++
 2 files changed, 65 insertions(+)
 create mode 100644 meta-oe/recipes-support/xdg-desktop-portal/xdg-desktop-portal/0001-xdg-desktop-portal-pc-in-add-pc_sysrootdir-dir.patch
 create mode 100644 meta-oe/recipes-support/xdg-desktop-portal/xdg-desktop-portal_1.16.0.bb

Comments

Khem Raj Dec. 19, 2022, 7:25 p.m. UTC | #1
I am seeing this issue

10:01:37 ERROR: Nothing PROVIDES 'python3-dbusmock-native' (but
/mnt/jenkins/workspace/yocto-world-glibc/sources/meta-openembedded/meta-oe/recipes-support/xdg-desktop-portal/xdg-desktop-portal_1.16.0.bb
DEPENDS on or otherwise requires it). Close matches:
10:01:37   python3-dbus-native
10:01:37   python3-dbussy-native
10:01:37   python3-pysocks-native
10:01:38 ERROR: Nothing PROVIDES 'bubblewrap-native' (but
/mnt/jenkins/workspace/yocto-world-glibc/sources/meta-openembedded/meta-oe/recipes-support/xdg-desktop-portal/xdg-desktop-portal_1.16.0.bb
DEPENDS on or otherwise requires it). Close matches:
10:01:38   babl-native
10:01:38 ERROR: Nothing PROVIDES 'flatpak' (but
/mnt/jenkins/workspace/yocto-world-glibc/sources/meta-openembedded/meta-oe/recipes-support/xdg-desktop-portal/xdg-desktop-portal_1.16.0.bb
DEPENDS on or otherwise requires it)
10:01:38 flatpak was skipped: missing required distro feature 'polkit'
(not in DISTRO_FEATURES)
10:01:39 ERROR: Nothing RPROVIDES 'xdg-desktop-portal-dev' (but
/mnt/jenkins/workspace/yocto-world-glibc/sources/meta-openembedded/meta-oe/recipes-support/xdg-desktop-portal/xdg-desktop-portal_1.16.0.bb
RDEPENDS on or otherwise requires it)
10:01:39 No eligible RPROVIDERs exist for 'xdg-desktop-portal-dev'
10:01:39 NOTE: Runtime target 'xdg-desktop-portal-dev' is unbuildable,
removing...
10:01:39 Missing or unbuildable dependency chain was: ['xdg-desktop-portal-dev']
10:01:39 ERROR: Nothing RPROVIDES 'bubblewrap' (but
/mnt/jenkins/workspace/yocto-world-glibc/sources/meta-openembedded/meta-oe/recipes-support/xdg-desktop-portal/xdg-desktop-portal_1.16.0.bb
RDEPENDS on or otherwise requires it)
10:01:39 NOTE: Runtime target 'bubblewrap' is unbuildable, removing...
10:01:39 Missing or unbuildable dependency chain was: ['bubblewrap']
10:01:39 ERROR: Nothing RPROVIDES 'xdg-desktop-portal' (but
/mnt/jenkins/workspace/yocto-world-glibc/sources/meta-openembedded/meta-oe/recipes-support/xdg-desktop-portal/xdg-desktop-portal_1.16.0.bb
RDEPENDS on or otherwise requires it)
10:01:39 No eligible RPROVIDERs exist for 'xdg-desktop-portal'
10:01:39 NOTE: Runtime target 'xdg-desktop-portal' is unbuildable, removing...
10:01:39 Missing or unbuildable dependency chain was: ['xdg-desktop-portal']
10:01:40 ERROR: Nothing RPROVIDES 'xdg-desktop-portal-gnome-dev' (but
/mnt/jenkins/workspace/yocto-world-glibc/sources/meta-openembedded/meta-gnome/recipes-support/xdg-desktop-portal/xdg-desktop-portal-gnome_43.1.bb
RDEPENDS on or otherwise requires it)
10:01:40 No eligible RPROVIDERs exist for 'xdg-desktop-portal-gnome-dev'
10:01:40 NOTE: Runtime target 'xdg-desktop-portal-gnome-dev' is
unbuildable, removing...
10:01:40 Missing or unbuildable dependency chain was:
['xdg-desktop-portal-gnome-dev']
10:01:40 ERROR: Nothing RPROVIDES 'xdg-desktop-portal-gnome' (but
/mnt/jenkins/workspace/yocto-world-glibc/sources/meta-openembedded/meta-gnome/recipes-support/xdg-desktop-portal/xdg-desktop-portal-gnome_43.1.bb
RDEPENDS on or otherwise requires it)
10:01:40 No eligible RPROVIDERs exist for 'xdg-desktop-portal-gnome'
10:01:40 NOTE: Runtime target 'xdg-desktop-portal-gnome' is
unbuildable, removing...
10:01:40 Missing or unbuildable dependency chain was:
['xdg-desktop-portal-gnome']

On Mon, Dec 19, 2022 at 5:12 AM Markus Volk <f_l_k@t-online.de> wrote:
>
> Signed-off-by: Markus Volk <f_l_k@t-online.de>
> ---
>  ...p-portal-pc-in-add-pc_sysrootdir-dir.patch | 25 ++++++++++++
>  .../xdg-desktop-portal_1.16.0.bb              | 40 +++++++++++++++++++
>  2 files changed, 65 insertions(+)
>  create mode 100644 meta-oe/recipes-support/xdg-desktop-portal/xdg-desktop-portal/0001-xdg-desktop-portal-pc-in-add-pc_sysrootdir-dir.patch
>  create mode 100644 meta-oe/recipes-support/xdg-desktop-portal/xdg-desktop-portal_1.16.0.bb
>
> diff --git a/meta-oe/recipes-support/xdg-desktop-portal/xdg-desktop-portal/0001-xdg-desktop-portal-pc-in-add-pc_sysrootdir-dir.patch b/meta-oe/recipes-support/xdg-desktop-portal/xdg-desktop-portal/0001-xdg-desktop-portal-pc-in-add-pc_sysrootdir-dir.patch
> new file mode 100644
> index 000000000..4b80c6e9f
> --- /dev/null
> +++ b/meta-oe/recipes-support/xdg-desktop-portal/xdg-desktop-portal/0001-xdg-desktop-portal-pc-in-add-pc_sysrootdir-dir.patch
> @@ -0,0 +1,25 @@
> +From 7727dbfef4dd7ced3958ae9ada59a8899976b12d Mon Sep 17 00:00:00 2001
> +From: Markus Volk <f_l_k@t-online.de>
> +Date: Mon, 12 Dec 2022 18:40:31 +0100
> +Subject: [PATCH] xdg-desktop-portal.pc.in: add pc_sysrootdir dir
> +
> +---
> + xdg-desktop-portal.pc.in | 2 +-
> + 1 file changed, 1 insertion(+), 1 deletion(-)
> +
> +diff --git a/xdg-desktop-portal.pc.in b/xdg-desktop-portal.pc.in
> +index 585c0c8..15b5817 100644
> +--- a/xdg-desktop-portal.pc.in
> ++++ b/xdg-desktop-portal.pc.in
> +@@ -2,7 +2,7 @@ prefix=@prefix@
> + datarootdir=@datarootdir@
> + datadir=@datadir@
> +
> +-interfaces_dir=${datadir}/dbus-1/interfaces/
> ++interfaces_dir=${pc_sysrootdir}${datadir}/dbus-1/interfaces
> +
> + Name: xdg-desktop-portal
> + Description: Desktop integration portal
> +--
> +2.34.1
> +
> diff --git a/meta-oe/recipes-support/xdg-desktop-portal/xdg-desktop-portal_1.16.0.bb b/meta-oe/recipes-support/xdg-desktop-portal/xdg-desktop-portal_1.16.0.bb
> new file mode 100644
> index 000000000..d026f3b61
> --- /dev/null
> +++ b/meta-oe/recipes-support/xdg-desktop-portal/xdg-desktop-portal_1.16.0.bb
> @@ -0,0 +1,40 @@
> +SUMMARY = "A portal frontend service for Flatpak and possibly other desktop containment frameworks."
> +HOMEPAGE = "https://github.com/flatpak/xdg-desktop-portal"
> +LICENSE = "LGPL-2.1-only"
> +LIC_FILES_CHKSUM = "file://COPYING;md5=4fbd65380cdd255951079008b364516c"
> +
> +DEPENDS = " \
> +    json-glib \
> +    glib-2.0 \
> +    libportal \
> +    geoclue \
> +    pipewire \
> +    dbus-native \
> +    fuse3 \
> +    bubblewrap-native \
> +    xmlto-native \
> +    flatpak \
> +    python3-dbus-native \
> +    python3-dbusmock-native \
> +"
> +
> +PORTAL_BACKENDS ?= " \
> +       ${@bb.utils.contains('DISTRO_FEATURES', 'wayland', 'xdg-desktop-portal-wlr', '', d)} \
> +       ${@bb.utils.contains('DISTRO_FEATURES', 'gtk', 'xdg-desktop-portal-gnome', '', d)} \
> +       ${@bb.utils.contains('DISTRO_FEATURES', 'gtk+3', 'xdg-desktop-portal-gnome', '', d)} \
> +       ${@bb.utils.contains('DISTRO_FEATURES', 'gtk4', 'xdg-desktop-portal-gnome', '', d)} \
> +"
> +
> +RDEPENDS:${PN} = "bubblewrap ${PORTAL_BACKENDS}"
> +
> +inherit meson pkgconfig python3native
> +
> +SRC_URI = " \
> +       git://github.com/flatpak/xdg-desktop-portal.git;protocol=https;branch=main \
> +       file://0001-xdg-desktop-portal-pc-in-add-pc_sysrootdir-dir.patch \
> +"
> +
> +S = "${WORKDIR}/git"
> +SRCREV = "88af6c8ca4106fcf70925355350a669848e9fd5a"
> +
> +FILES:${PN} += "${libdir}/systemd ${datadir}/dbus-1"
> --
> 2.34.1
>
>
> -=-=-=-=-=-=-=-=-=-=-=-
> Links: You receive all messages sent to this group.
> View/Reply Online (#100104): https://lists.openembedded.org/g/openembedded-devel/message/100104
> Mute This Topic: https://lists.openembedded.org/mt/95764279/1997914
> Group Owner: openembedded-devel+owner@lists.openembedded.org
> Unsubscribe: https://lists.openembedded.org/g/openembedded-devel/unsub [raj.khem@gmail.com]
> -=-=-=-=-=-=-=-=-=-=-=-
>
Markus Volk Dec. 19, 2022, 7:43 p.m. UTC | #2
Am Mo, 19. Dez 2022 um 11:25:16 -0800 schrieb Khem Raj 
<raj.khem@gmail.com>:
> 10:01:37 ERROR: Nothing PROVIDES 'python3-dbusmock-native' (but
> /mnt/jenkins/workspace/yocto-world-glibc/sources/meta-openembedded/meta-oe/recipes-support/xdg-desktop-portal/xdg-desktop-portal_1.16.0.bb

Sorry, I forgot that I allowed to build python3-dbusmock-native in 
oe-core. What would be the right way to fix it? I ask because I sent a 
patch for it some time ago when python3-dbusmock-native was needed for 
evolution-data-server tests and was rejected in oe-core. I don't 
remember what the problem was.
I think removing the dependency of python3-dbusmock-native would also 
work as long as it is installed on the host system. But it's not by 
default, at least for ubuntu 22.04
Markus Volk Dec. 19, 2022, 8:09 p.m. UTC | #3
Am Mo, 19. Dez 2022 um 11:25:16 -0800 schrieb Khem Raj 
<raj.khem@gmail.com>:
> 10:01:38 ERROR: Nothing PROVIDES 'bubblewrap-native' (but
> /mnt/jenkins/workspace/yocto-world-glibc/sources/meta-openembedded/meta-oe/recipes-support/xdg-desktop-portal/xdg-desktop-portal_1.16.0.bb

I'll try to send a patch for meta-security
Khem Raj Dec. 19, 2022, 8:15 p.m. UTC | #4
On Mon, Dec 19, 2022 at 11:43 AM Markus Volk <f_l_k@t-online.de> wrote:
>
> Am Mo, 19. Dez 2022 um 11:25:16 -0800 schrieb Khem Raj <raj.khem@gmail.com>:
>
> 10:01:37 ERROR: Nothing PROVIDES 'python3-dbusmock-native' (but /mnt/jenkins/workspace/yocto-world-glibc/sources/meta-openembedded/meta-oe/recipes-support/xdg-desktop-portal/xdg-desktop-portal_1.16.0.bb
>
>
> Sorry, I forgot that I allowed to build python3-dbusmock-native in oe-core. What would be the right way to fix it? I ask because I sent a patch for it some time ago when python3-dbusmock-native was needed for evolution-data-server tests and was rejected in oe-core. I don't remember what the problem was.
> I think removing the dependency of python3-dbusmock-native would also work as long as it is installed on the host system. But it's not by default, at least for ubuntu 22.04

Well I see python3-dbusmock is in core layer, it should be simple to
bbclassextend it to provide native variant as well. What objections
did you see ?
Khem Raj Dec. 19, 2022, 8:16 p.m. UTC | #5
On Mon, Dec 19, 2022 at 12:10 PM Markus Volk <f_l_k@t-online.de> wrote:
>
> Am Mo, 19. Dez 2022 um 11:25:16 -0800 schrieb Khem Raj <raj.khem@gmail.com>:
>
> 10:01:38 ERROR: Nothing PROVIDES 'bubblewrap-native' (but /mnt/jenkins/workspace/yocto-world-glibc/sources/meta-openembedded/meta-oe/recipes-support/xdg-desktop-portal/xdg-desktop-portal_1.16.0.bb
>
>
> I'll try to send a patch for meta-security

Adding bubblewrap recipe to meta-oe might be better perhaps, I see it
being needed in webkit as well.
Markus Volk Dec. 19, 2022, 8:26 p.m. UTC | #6
Am Mo, 19. Dez 2022 um 12:15:26 -0800 schrieb Khem Raj 
<raj.khem@gmail.com>:
> Well I see python3-dbusmock is in core layer, it should be simple to
> bbclassextend it to provide native variant as well. What objections
> did you see ?

I see no objections besides that i already sent that patch and it was 
rejected in oe-core. The need for dbusmock was disabled in 
evolution-data-server back then by not building the tests.
Now for xdg-desktop-portal we cant disable the build of tests. There's 
only an option to not install them. I'll try to send this native expand 
to oe-core again.
Khem Raj Dec. 20, 2022, 5:59 a.m. UTC | #7
On Mon, Dec 19, 2022 at 12:26 PM Markus Volk <f_l_k@t-online.de> wrote:

> Am Mo, 19. Dez 2022 um 12:15:26 -0800 schrieb Khem Raj <raj.khem@gmail.com
> >:
>
> Well I see python3-dbusmock is in core layer, it should be simple to
> bbclassextend it to provide native variant as well. What objections did you
> see ?
>
>
> I see no objections besides that i already sent that patch and it was
> rejected in oe-core. The need for dbusmock was disabled in
> evolution-data-server back then by not building the tests.
> Now for xdg-desktop-portal we cant disable the build of tests. There's
> only an option to not install them. I'll try to send this native expand to
> oe-core again.
>
Maybe resend it again now ?
Markus Volk Dec. 23, 2022, 3:15 a.m. UTC | #8
Am Mo, 19. Dez 2022 um 11:25:16 -0800 schrieb Khem Raj 
<raj.khem@gmail.com>:
> 10:01:40 No eligible RPROVIDERs exist for 'xdg-desktop-portal-gnome'

I removed the circular dependency between xdg-desktop-portal and 
xdg-desktop-portal-gnome and resent the remaining 3 patches for flatpak 
support. Let me know if it still causes problems.
diff mbox series

Patch

diff --git a/meta-oe/recipes-support/xdg-desktop-portal/xdg-desktop-portal/0001-xdg-desktop-portal-pc-in-add-pc_sysrootdir-dir.patch b/meta-oe/recipes-support/xdg-desktop-portal/xdg-desktop-portal/0001-xdg-desktop-portal-pc-in-add-pc_sysrootdir-dir.patch
new file mode 100644
index 000000000..4b80c6e9f
--- /dev/null
+++ b/meta-oe/recipes-support/xdg-desktop-portal/xdg-desktop-portal/0001-xdg-desktop-portal-pc-in-add-pc_sysrootdir-dir.patch
@@ -0,0 +1,25 @@ 
+From 7727dbfef4dd7ced3958ae9ada59a8899976b12d Mon Sep 17 00:00:00 2001
+From: Markus Volk <f_l_k@t-online.de>
+Date: Mon, 12 Dec 2022 18:40:31 +0100
+Subject: [PATCH] xdg-desktop-portal.pc.in: add pc_sysrootdir dir
+
+---
+ xdg-desktop-portal.pc.in | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/xdg-desktop-portal.pc.in b/xdg-desktop-portal.pc.in
+index 585c0c8..15b5817 100644
+--- a/xdg-desktop-portal.pc.in
++++ b/xdg-desktop-portal.pc.in
+@@ -2,7 +2,7 @@ prefix=@prefix@
+ datarootdir=@datarootdir@
+ datadir=@datadir@
+ 
+-interfaces_dir=${datadir}/dbus-1/interfaces/
++interfaces_dir=${pc_sysrootdir}${datadir}/dbus-1/interfaces
+ 
+ Name: xdg-desktop-portal
+ Description: Desktop integration portal
+-- 
+2.34.1
+
diff --git a/meta-oe/recipes-support/xdg-desktop-portal/xdg-desktop-portal_1.16.0.bb b/meta-oe/recipes-support/xdg-desktop-portal/xdg-desktop-portal_1.16.0.bb
new file mode 100644
index 000000000..d026f3b61
--- /dev/null
+++ b/meta-oe/recipes-support/xdg-desktop-portal/xdg-desktop-portal_1.16.0.bb
@@ -0,0 +1,40 @@ 
+SUMMARY = "A portal frontend service for Flatpak and possibly other desktop containment frameworks."
+HOMEPAGE = "https://github.com/flatpak/xdg-desktop-portal"
+LICENSE = "LGPL-2.1-only"
+LIC_FILES_CHKSUM = "file://COPYING;md5=4fbd65380cdd255951079008b364516c"
+
+DEPENDS = " \
+    json-glib \
+    glib-2.0 \
+    libportal \
+    geoclue \
+    pipewire \
+    dbus-native \
+    fuse3 \
+    bubblewrap-native \
+    xmlto-native \
+    flatpak \
+    python3-dbus-native \
+    python3-dbusmock-native \
+"
+
+PORTAL_BACKENDS ?= " \
+	${@bb.utils.contains('DISTRO_FEATURES', 'wayland', 'xdg-desktop-portal-wlr', '', d)} \
+	${@bb.utils.contains('DISTRO_FEATURES', 'gtk', 'xdg-desktop-portal-gnome', '', d)} \
+	${@bb.utils.contains('DISTRO_FEATURES', 'gtk+3', 'xdg-desktop-portal-gnome', '', d)} \
+	${@bb.utils.contains('DISTRO_FEATURES', 'gtk4', 'xdg-desktop-portal-gnome', '', d)} \
+"
+
+RDEPENDS:${PN} = "bubblewrap ${PORTAL_BACKENDS}"
+
+inherit meson pkgconfig python3native
+
+SRC_URI = " \
+	git://github.com/flatpak/xdg-desktop-portal.git;protocol=https;branch=main \
+	file://0001-xdg-desktop-portal-pc-in-add-pc_sysrootdir-dir.patch \
+"
+
+S = "${WORKDIR}/git"
+SRCREV = "88af6c8ca4106fcf70925355350a669848e9fd5a"
+
+FILES:${PN} += "${libdir}/systemd ${datadir}/dbus-1"