Skip to contentSkip to conversation

gdk-pixbuf: fix run query-loaders fail

PATCH In review [email protected] 4 participants 6 messages Mar 29, 2019 – Apr 17, 2019

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 gdk-pixbuf: fix run query-loaders fail

From: Changqing Li <[email protected]>

Reproduce steps:
1. add below config into local.conf IMAGE_INSTALL_append = " packagegroup-xfce-base" DISTRO_FEATURES_append = " polkit"
2. bitbake core-image-minimal

do_rootfs failed with below error:

qemu-i386 -r 3.2.0 -E LD_LIBRARY_PATH=/tmp/work/qemux86-poky-linux/core-image-minimal/1.0-r0/rootfs/usr/lib:/tmp/work/qemux86-poky-linux/core-image-minimal/1.0-r0/rootfs/lib -L /tmp/work/qemux86-poky-linux/core-image-minimal/1.0-r0/rootfs /tmp/work/qemux86-poky-linux/core-image-minimal/1.0-r0/rootfs/usr/lib/gdk-pixbuf-2.0/gdk-pixbuf-query-loaders

** (process:162531): CRITICAL **: 02:10:12.174: Failed to get connection to xfconfd: Cannot autolaunch D-Bus without X11 $DISPLAY

---
 ...001-gdk-pixbuf-fix-run-query-loaders-fail.patch | 59 ++++++++++++++++++++++
 meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf_2.38.0.bb |  1 +
 2 files changed, 60 insertions(+)
 create mode 100644 meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf/0001-gdk-pixbuf-fix-run-query-loaders-fail.patch
meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf/0001-gdk-pixbuf-fix-run-query-loaders-fail.patch new file +59 -0
new file mode 100644
index 0000000..836dcae
@@ -0,0 +1,59 @@
+From fa0d2ba51f1ccc848da9ff708c23a76b22c6e764 Mon Sep 17 00:00:00 2001
+From: Changqing Li <[email protected]>
+Date: Thu, 28 Mar 2019 17:27:45 +0800
+Subject: [PATCH] gdk-pixbuf: fix run query-loaders fail
+
+run query-loaders fail with error:
+
+** (process:417595): CRITICAL **: 09:21:35.330: Failed to
+get connection to xfconfd: Cannot autolaunch D-Bus without X11 $DISPLAY
+
+Commit https://github.com/GNOME/gdk-pixbuf/commit/49d4becc33ca6bc99199dc845f3413e16eeb7f53
+change method of getting pixbuf_libdir, but call of function g_file_new_for_path 
+make this error happen, fix by only use g_file_new_for_path for WIN32, 
+for other platform, still use g_strdup.
+
+Maybe this fix just like a workaround, and have send upstream for review.
+
+Upstream-Status: Submitted [https://gitlab.gnome.org/GNOME/gdk-pixbuf/merge_requests/44]
+
+Signed-off-by: Changqing Li <[email protected]>
+---
+ gdk-pixbuf/queryloaders.c | 7 +++++--
+ 1 file changed, 5 insertions(+), 2 deletions(-)
+
+diff --git a/gdk-pixbuf/queryloaders.c b/gdk-pixbuf/queryloaders.c
+index b813d99..59d62f7 100644
+--- a/gdk-pixbuf/queryloaders.c
++++ b/gdk-pixbuf/queryloaders.c
+@@ -316,15 +316,14 @@ int main (int argc, char **argv)
+         GString *contents;
+         gchar *cache_file = NULL;
+         gint first_file = 1;
+-        GFile *pixbuf_libdir_file;
+         gchar *pixbuf_libdir;
+         gboolean success = TRUE;
+ 
+ #ifdef G_OS_WIN32
++        GFile *pixbuf_libdir_file;
+         gchar *libdir;
+         GFile *pixbuf_prefix_file;
+         gchar *pixbuf_prefix;
+-#endif
+ 
+         /* An intermediate GFile here will convert all the path separators
+          * to the right one used by the platform
+@@ -332,6 +331,10 @@ int main (int argc, char **argv)
+         pixbuf_libdir_file = g_file_new_for_path (PIXBUF_LIBDIR);
+         pixbuf_libdir = g_file_get_path (pixbuf_libdir_file);
+         g_object_unref (pixbuf_libdir_file);
++#else
++        pixbuf_libdir = g_strdup (PIXBUF_LIBDIR);
++#endif
++
+ 
+ #ifdef G_OS_WIN32
+         pixbuf_prefix_file = g_file_new_for_path (GDK_PIXBUF_PREFIX);
+-- 
+2.7.4
+
meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf_2.38.0.bb +1 -0
index c5de7a9..6435473 100644
@@ -20,6 +20,7 @@ SRC_URI = "${GNOME_MIRROR}/${BPN}/${MAJ_VER}/${BPN}-${PV}.tar.xz \
            file://0001-Fix-a-couple-of-decisions-around-cross-compilation.patch \
            file://0001-loaders.cache-depend-on-loaders-being-fully-build.patch \
            file://0004-Do-not-run-tests-when-building.patch \
+           file://0001-gdk-pixbuf-fix-run-query-loaders-fail.patch \
            "
 
 SRC_URI_append_class-target = " \
Signature · 1 line
2.7.4
#1 lore raw
Quoted 35 lines · On 3/29/19 2:41 PM, [email protected] wrote:

From: Changqing Li <[email protected]>

Reproduce steps:
1. add below config into local.conf IMAGE_INSTALL_append = " packagegroup-xfce-base" DISTRO_FEATURES_append = " polkit"
2. bitbake core-image-minimal

do_rootfs failed with below error:

qemu-i386 -r 3.2.0 -E LD_LIBRARY_PATH=/tmp/work/qemux86-poky-linux/core-image-minimal/1.0-r0/rootfs/usr/lib:/tmp/work/qemux86-poky-linux/core-image-minimal/1.0-r0/rootfs/lib -L /tmp/work/qemux86-poky-linux/core-image-minimal/1.0-r0/rootfs /tmp/work/qemux86-poky-linux/core-image-minimal/1.0-r0/rootfs/usr/lib/gdk-pixbuf-2.0/gdk-pixbuf-query-loaders

** (process:162531): CRITICAL **: 02:10:12.174: Failed to get connection to xfconfd: Cannot autolaunch D-Bus without X11 $DISPLAY

---
  ...001-gdk-pixbuf-fix-run-query-loaders-fail.patch | 59 ++++++++++++++++++++++
  meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf_2.38.0.bb |  1 +
  2 files changed, 60 insertions(+)

create mode 100644 meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf/0001-gdk-pixbuf-fix-run-query-loaders-fail.patch

meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf/0001-gdk-pixbuf-fix-run-query-loaders-fail.patch new file +8 -0
new file mode 100644
index 0000000..836dcae
@@ -0,0 +1,59 @@
+From fa0d2ba51f1ccc848da9ff708c23a76b22c6e764 Mon Sep 17 00:00:00 2001
+From: Changqing Li <[email protected]>
+Date: Thu, 28 Mar 2019 17:27:45 +0800
+Subject: [PATCH] gdk-pixbuf: fix run query-loaders fail
+
+run query-loaders fail with error:
+
+** (process:417595): CRITICAL **: 09:21:35.330: Failed to

meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf/0001-gdk-pixbuf-fix-run-query-loaders-fail.patch line 18

Quoted 10 lines
meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf/0001-gdk-pixbuf-fix-run-query-loaders-fail.patch new file +10 -0
+get connection to xfconfd: Cannot autolaunch D-Bus without X11 $DISPLAY
+
+Commit https://github.com/GNOME/gdk-pixbuf/commit/49d4becc33ca6bc99199dc845f3413e16eeb7f53
+change method of getting pixbuf_libdir, but call of function g_file_new_for_path
+make this error happen, fix by only use g_file_new_for_path for WIN32,
+for other platform, still use g_strdup.
+
+Maybe this fix just like a workaround, and have send upstream for review.
+
+Upstream-Status: Submitted [https://gitlab.gnome.org/GNOME/gdk-pixbuf/merge_requests/44]

Upstream replied that:  should be xfconf upsteam bug. So this is a workaround,

and we need to follow the upsteam bug and backport after it is fixed.

Quoted 53 lines
meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf/0001-gdk-pixbuf-fix-run-query-loaders-fail.patch new file +41 -0
+
+Signed-off-by: Changqing Li <[email protected]>
+---
+ gdk-pixbuf/queryloaders.c | 7 +++++--
+ 1 file changed, 5 insertions(+), 2 deletions(-)
+
+diff --git a/gdk-pixbuf/queryloaders.c b/gdk-pixbuf/queryloaders.c
+index b813d99..59d62f7 100644
+--- a/gdk-pixbuf/queryloaders.c
++++ b/gdk-pixbuf/queryloaders.c
+@@ -316,15 +316,14 @@ int main (int argc, char **argv)
+         GString *contents;
+         gchar *cache_file = NULL;
+         gint first_file = 1;
+-        GFile *pixbuf_libdir_file;
+         gchar *pixbuf_libdir;
+         gboolean success = TRUE;
+
+ #ifdef G_OS_WIN32
++        GFile *pixbuf_libdir_file;
+         gchar *libdir;
+         GFile *pixbuf_prefix_file;
+         gchar *pixbuf_prefix;
+-#endif
+
+         /* An intermediate GFile here will convert all the path separators
+          * to the right one used by the platform
+@@ -332,6 +331,10 @@ int main (int argc, char **argv)
+         pixbuf_libdir_file = g_file_new_for_path (PIXBUF_LIBDIR);
+         pixbuf_libdir = g_file_get_path (pixbuf_libdir_file);
+         g_object_unref (pixbuf_libdir_file);
++#else
++        pixbuf_libdir = g_strdup (PIXBUF_LIBDIR);
++#endif
++
+
+ #ifdef G_OS_WIN32
+         pixbuf_prefix_file = g_file_new_for_path (GDK_PIXBUF_PREFIX);
+--
+2.7.4
+
meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf_2.38.0.bb +1 -0
index c5de7a9..6435473 100644
@@ -20,6 +20,7 @@ SRC_URI = "${GNOME_MIRROR}/${BPN}/${MAJ_VER}/${BPN}-${PV}.tar.xz \
             file://0001-Fix-a-couple-of-decisions-around-cross-compilation.patch \
             file://0001-loaders.cache-depend-on-loaders-being-fully-build.patch \
             file://0004-Do-not-run-tests-when-building.patch \
+           file://0001-gdk-pixbuf-fix-run-query-loaders-fail.patch \
             "
 
  SRC_URI_append_class-target = " \
Signature · 3 lines
BRs

Sandy(Li Changqing)
#2 lore raw
Quoted 2 lines · Changqing Li

Upstream replied that: should be xfconf upsteam bug. So this is a workaround,

Yes, that's definitely a xfconf bug. Let's fix it there.

Ross

#3 lore raw

PATCH 1/1 xfconf: fix 'Failed to get connection to xfconfd' during do_rootfs

Packages such as gdk-pixbuf can result in the following error during
the rootfs construction:
CRITICAL **: 16:51:57.223: Failed to get connection to xfconfd: Cannot autolaunch D-Bus without X11 $DISPLAY

This is hit during the postinst-intercepts/update_pixbuf_cache.

Based on discussions upstream this appears to be an issue for xfconf and has an upstream update

https://git.xfce.org/xfce/xfconf/commit?id=6f11cc65a2213f424728b5a0d25b1b63c19e773e

Drawing from this change we can go ahead and use PACKAGECONFIG to emulate it.

---

Guys,

This is still broken in Yocto and I would like to see it fixed. I haven't dug into the issue as much as you two so I wanted to float this fix out there but hold back from calling it a proper fix. Please let me know what you think or feel free to take this, evaluate it and modify it into a full fledged fix.

MarkA

 meta-xfce/recipes-xfce/xfconf/xfconf_4.13.6.bb | 2 ++
 1 file changed, 2 insertions(+)
meta-xfce/recipes-xfce/xfconf/xfconf_4.13.6.bb +2 -0
index 2667ff9..22a7bc1 100644
@@ -16,3 +16,5 @@ FILES_${PN} += "${libdir}/xfce4/xfconf/xfconfd \
                 ${datadir}/dbus-1/services/org.xfce.Xfconf.service"
 
 FILES_${PN}-dev += "${libdir}/gio/modules/libxfconfgsettingsbackend.la"
+
+PACKAGECONFIG[gsettings-backend] = ",--disable-gsettings-backend,"
Signature · 1 line
2.7.4
#4 lore raw

Re: [PATCH] xfconf: fix 'Failed to get connection to xfconfd' during do_rootfs

On Wed, Apr 17, 2019 at 8:22 PM Mark Asselstine <[email protected]> wrote:
Seems that there are configurations where it xfconf causes trouble even at runtime (not only at headless builds) [1]

So adding a PACKAGECONFIG disabled by default is OK.

Could you please send this to meta-oe with

PACKAGECONFIG[gsettings-backend] = "--enable-gsettings-backend,--disable-gsettings-backend,"

Thanks

Andreas

Quoted 50 lines

Packages such as gdk-pixbuf can result in the following error during
the rootfs construction:
CRITICAL **: 16:51:57.223: Failed to get connection to xfconfd: Cannot autolaunch D-Bus without X11 $DISPLAY

This is hit during the postinst-intercepts/update_pixbuf_cache.

Based on discussions upstream this appears to be an issue for xfconf and has an upstream update

https://git.xfce.org/xfce/xfconf/commit?id=6f11cc65a2213f424728b5a0d25b1b63c19e773e

Drawing from this change we can go ahead and use PACKAGECONFIG to emulate it.

---

Guys,

This is still broken in Yocto and I would like to see it fixed. I haven't dug into the issue as much as you two so I wanted to float this fix out there but hold back from calling it a proper fix. Please let me know what you think or feel free to take this, evaluate it and modify it into a full fledged fix.

MarkA

 meta-xfce/recipes-xfce/xfconf/xfconf_4.13.6.bb | 2 ++
 1 file changed, 2 insertions(+)
meta-xfce/recipes-xfce/xfconf/xfconf_4.13.6.bb +2 -1
index 2667ff9..22a7bc1 100644
@@ -16,3 +16,5 @@ FILES_${PN} += "${libdir}/xfce4/xfconf/xfconfd \
                 ${datadir}/dbus-1/services/org.xfce.Xfconf.service"
 
 FILES_${PN}-dev += "${libdir}/gio/modules/libxfconfgsettingsbackend.la"
+
+PACKAGECONFIG[gsettings-backend] = ",--disable-gsettings-backend,"
--

2.7.4

--
_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core

#5 lore raw

Re: [PATCH] xfconf: fix 'Failed to get connection to xfconfd' during do_rootfs

Forgot the link

[1] https://bugzilla.xfce.org/show_bug.cgi?id=14789

Quoted 66 lines · Andreas Müller

On Wed, Apr 17, 2019 at 8:22 PM Mark Asselstine <[email protected]> wrote:
Seems that there are configurations where it xfconf causes trouble even at runtime (not only at headless builds) [1]

So adding a PACKAGECONFIG disabled by default is OK.

Could you please send this to meta-oe with

PACKAGECONFIG[gsettings-backend] = "--enable-gsettings-backend,--disable-gsettings-backend,"

Thanks

Andreas

Quoted 50 lines

Packages such as gdk-pixbuf can result in the following error during
the rootfs construction:
CRITICAL **: 16:51:57.223: Failed to get connection to xfconfd: Cannot autolaunch D-Bus without X11 $DISPLAY

This is hit during the postinst-intercepts/update_pixbuf_cache.

Based on discussions upstream this appears to be an issue for xfconf and has an upstream update

https://git.xfce.org/xfce/xfconf/commit?id=6f11cc65a2213f424728b5a0d25b1b63c19e773e

Drawing from this change we can go ahead and use PACKAGECONFIG to emulate it.

---

Guys,

This is still broken in Yocto and I would like to see it fixed. I haven't dug into the issue as much as you two so I wanted to float this fix out there but hold back from calling it a proper fix. Please let me know what you think or feel free to take this, evaluate it and modify it into a full fledged fix.

MarkA

 meta-xfce/recipes-xfce/xfconf/xfconf_4.13.6.bb | 2 ++
 1 file changed, 2 insertions(+)
meta-xfce/recipes-xfce/xfconf/xfconf_4.13.6.bb +2 -1
index 2667ff9..22a7bc1 100644
@@ -16,3 +16,5 @@ FILES_${PN} += "${libdir}/xfce4/xfconf/xfconfd \
                 ${datadir}/dbus-1/services/org.xfce.Xfconf.service"
 
 FILES_${PN}-dev += "${libdir}/gio/modules/libxfconfgsettingsbackend.la"
+
+PACKAGECONFIG[gsettings-backend] = ",--disable-gsettings-backend,"
--

2.7.4

--
_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core