All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] matchbox-desktop: sync with gio for the inotify-sub
@ 2015-12-01  5:47 jackie.huang
  2015-12-01  8:56 ` Burton, Ross
  0 siblings, 1 reply; 5+ messages in thread
From: jackie.huang @ 2015-12-01  5:47 UTC (permalink / raw)
  To: openembedded-core

From: Jackie Huang <jackie.huang@windriver.com>

matchbox-desktop builds with included libinotify which
is very old (last sync was in 2008), if we compile glib-2.0
with -fvisibility=default (the default is hidden for libglib
and libgio), it will crash because of inconsistency of
inotify-sub, so port the related parts to fix the issue.

Signed-off-by: Jackie Huang <jackie.huang@windriver.com>
---
 .../files/gio-sync-for-the-inotify-sub.patch       | 112 +++++++++++++++++++++
 .../matchbox-desktop/matchbox-desktop_git.bb       |   4 +-
 2 files changed, 115 insertions(+), 1 deletion(-)
 create mode 100644 meta/recipes-sato/matchbox-desktop/files/gio-sync-for-the-inotify-sub.patch

diff --git a/meta/recipes-sato/matchbox-desktop/files/gio-sync-for-the-inotify-sub.patch b/meta/recipes-sato/matchbox-desktop/files/gio-sync-for-the-inotify-sub.patch
new file mode 100644
index 0000000..a9367e9
--- /dev/null
+++ b/meta/recipes-sato/matchbox-desktop/files/gio-sync-for-the-inotify-sub.patch
@@ -0,0 +1,112 @@
+From 84b7272c446cea5c6ae185548de0c6cad3a42355 Mon Sep 17 00:00:00 2001
+From: Jackie Huang <jackie.huang@windriver.com>
+Date: Sat, 28 Nov 2015 07:53:38 +0000
+Subject: [PATCH] gio: sync for the inotify-sub
+
+This only sync for the inotify-sub with glib-2.44
+to keep _ih_sub_new consistent.
+
+Upstream-Status: Pending
+
+Signed-off-by: Jackie Huang <jackie.huang@windriver.com>
+---
+ libtaku/inotify/inotify-sub.c | 15 +++++++++------
+ libtaku/inotify/inotify-sub.h | 13 +++++++++----
+ libtaku/taku-menu-desktop.c   |  2 +-
+ 3 files changed, 19 insertions(+), 11 deletions(-)
+
+diff --git a/libtaku/inotify/inotify-sub.c b/libtaku/inotify/inotify-sub.c
+index 404dc20..85b3411 100644
+--- a/libtaku/inotify/inotify-sub.c
++++ b/libtaku/inotify/inotify-sub.c
+@@ -16,8 +16,7 @@
+ 
+    You should have received a copy of the GNU Library General Public
+    License along with the Gnome Library; see the file COPYING.LIB.  If not,
+-   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+-   Boston, MA 02111-1307, USA.
++   see <http://www.gnu.org/licenses/>.
+ 
+    Authors: 
+ 		 John McCutchan <john@johnmccutchan.com>
+@@ -38,15 +37,17 @@ dup_dirname (const gchar *dirname)
+   gchar *d_dirname = g_strdup (dirname);
+   size_t len = strlen (d_dirname);
+   
+-  if (d_dirname[len] == '/')
+-    d_dirname[len] = '\0';
++  if (len && d_dirname[len - 1] == '/')
++    d_dirname[len - 1] = '\0';
+   
+   return d_dirname;
+ }
+ 
+ inotify_sub*
+ _ih_sub_new (const gchar *dirname, 
+-             const gchar *filename, 
++             const gchar *filename,
++             gboolean     pair_moves,
++             gboolean     watch_hardlinks,
+              gpointer     user_data)
+ {
+   inotify_sub *sub = NULL;
+@@ -54,8 +55,10 @@ _ih_sub_new (const gchar *dirname,
+   sub = g_new0 (inotify_sub, 1);
+   sub->dirname = dup_dirname (dirname);
+   sub->filename = g_strdup (filename);
++  sub->pair_moves = pair_moves;
++  sub->hardlinks = watch_hardlinks;
+   sub->user_data = user_data;
+-  
++
+   IS_W ("new subscription for %s being setup\n", sub->dirname);
+   
+   return sub;
+diff --git a/libtaku/inotify/inotify-sub.h b/libtaku/inotify/inotify-sub.h
+index 36561e7..ff37567 100644
+--- a/libtaku/inotify/inotify-sub.h
++++ b/libtaku/inotify/inotify-sub.h
+@@ -14,8 +14,7 @@
+ 
+    You should have received a copy of the GNU Library General Public
+    License along with the Gnome Library; see the file COPYING.LIB.  If not,
+-   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+-   Boston, MA 02111-1307, USA.
++   see <http://www.gnu.org/licenses/>.
+ 
+    Author: John McCutchan <john@johnmccutchan.com>
+ */
+@@ -30,9 +29,15 @@ typedef struct
+ 	gchar*   filename;
+ 	gboolean cancelled;
+ 	gpointer user_data;
++	gboolean pair_moves;
++	gboolean hardlinks;
+ } inotify_sub;
+ 
+-inotify_sub* _ih_sub_new (const gchar* dirname, const gchar* filename, gpointer user_data);
+-void         _ih_sub_free (inotify_sub* sub);
++inotify_sub *_ih_sub_new (const gchar  *dirname,
++			  const gchar  *filename,
++			  gboolean      pair_moves,
++			  gboolean      watch_hardlinks,
++			  gpointer      user_data);
++void         _ih_sub_free (inotify_sub *sub);
+ 
+ #endif /* __INOTIFY_SUB_H */
+diff --git a/libtaku/taku-menu-desktop.c b/libtaku/taku-menu-desktop.c
+index 34b10d9..ef88421 100644
+--- a/libtaku/taku-menu-desktop.c
++++ b/libtaku/taku-menu-desktop.c
+@@ -415,7 +415,7 @@ monitor (const char *directory)
+   if (!with_inotify)
+     return;
+ 
+-  sub = _ih_sub_new (directory, NULL, NULL);
++  sub = _ih_sub_new (directory, NULL, FALSE, FALSE, NULL);
+   _ip_start_watching (sub);
+ }
+ 
+-- 
+2.5.0
+
diff --git a/meta/recipes-sato/matchbox-desktop/matchbox-desktop_git.bb b/meta/recipes-sato/matchbox-desktop/matchbox-desktop_git.bb
index 318d2e0..4fcc69e 100644
--- a/meta/recipes-sato/matchbox-desktop/matchbox-desktop_git.bb
+++ b/meta/recipes-sato/matchbox-desktop/matchbox-desktop_git.bb
@@ -13,7 +13,9 @@ SECTION = "x11/wm"
 SRCREV = "71e3e6e04271e9d5a14f1c231ef100c7f320134d"
 PV = "2.0+git${SRCPV}"
 
-SRC_URI = "git://git.yoctoproject.org/${BPN}-2"
+SRC_URI = "git://git.yoctoproject.org/${BPN}-2 \
+           file://gio-sync-for-the-inotify-sub.patch \
+"
 
 EXTRA_OECONF = "--enable-startup-notification --with-dbus"
 
-- 
1.9.1



^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [PATCH] matchbox-desktop: sync with gio for the inotify-sub
  2015-12-01  5:47 [PATCH] matchbox-desktop: sync with gio for the inotify-sub jackie.huang
@ 2015-12-01  8:56 ` Burton, Ross
  2015-12-03  9:11   ` Huang, Jie (Jackie)
  0 siblings, 1 reply; 5+ messages in thread
From: Burton, Ross @ 2015-12-01  8:56 UTC (permalink / raw)
  To: jackie.huang; +Cc: OE-core

[-- Attachment #1: Type: text/plain, Size: 669 bytes --]

On 1 December 2015 at 05:47, <jackie.huang@windriver.com> wrote:

> matchbox-desktop builds with included libinotify which
> is very old (last sync was in 2008), if we compile glib-2.0
> with -fvisibility=default (the default is hidden for libglib
> and libgio), it will crash because of inconsistency of
> inotify-sub, so port the related parts to fix the issue.
>

matchbox-desktop is maintained by the Yocto Project, so this patch should
be applied there and then the recipe updated to the latest git revision.

There's a big rewrite of matchbox-desktop going on, so dropping that code
entirely is probably the best idea: just use GIO instead.

Ross

[-- Attachment #2: Type: text/html, Size: 1154 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] matchbox-desktop: sync with gio for the inotify-sub
  2015-12-01  8:56 ` Burton, Ross
@ 2015-12-03  9:11   ` Huang, Jie (Jackie)
  2015-12-03 11:58     ` Jussi Kukkonen
  0 siblings, 1 reply; 5+ messages in thread
From: Huang, Jie (Jackie) @ 2015-12-03  9:11 UTC (permalink / raw)
  To: BURTON, ROSS; +Cc: OE-core

[-- Attachment #1: Type: text/plain, Size: 1262 bytes --]

So I should send the patch to yocto@yoctoproject.org<mailto:yocto@yoctoproject.org>, right?

I agree to drop those codes, and it should already be part of the rewrite,
where I can find info about the rewrite, I don’t see any actives in:
git.yoctoproject.org/cgit/cgit.cgi/matchbox-desktop-2

The latest commit is 3 years ago.

Thanks,
Jackie

From: Burton, Ross [mailto:ross.burton@intel.com]
Sent: Tuesday, December 01, 2015 4:56 PM
To: Huang, Jie (Jackie)
Cc: OE-core
Subject: Re: [OE-core] [PATCH] matchbox-desktop: sync with gio for the inotify-sub


On 1 December 2015 at 05:47, <jackie.huang@windriver.com<mailto:jackie.huang@windriver.com>> wrote:
matchbox-desktop builds with included libinotify which
is very old (last sync was in 2008), if we compile glib-2.0
with -fvisibility=default (the default is hidden for libglib
and libgio), it will crash because of inconsistency of
inotify-sub, so port the related parts to fix the issue.

matchbox-desktop is maintained by the Yocto Project, so this patch should be applied there and then the recipe updated to the latest git revision.

There's a big rewrite of matchbox-desktop going on, so dropping that code entirely is probably the best idea: just use GIO instead.

Ross

[-- Attachment #2: Type: text/html, Size: 5685 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] matchbox-desktop: sync with gio for the inotify-sub
  2015-12-03  9:11   ` Huang, Jie (Jackie)
@ 2015-12-03 11:58     ` Jussi Kukkonen
  2015-12-09  7:11       ` Huang, Jie (Jackie)
  0 siblings, 1 reply; 5+ messages in thread
From: Jussi Kukkonen @ 2015-12-03 11:58 UTC (permalink / raw)
  To: Huang, Jie (Jackie); +Cc: OE-core

[-- Attachment #1: Type: text/plain, Size: 872 bytes --]

On 3 December 2015 at 11:11, Huang, Jie (Jackie) <Jackie.Huang@windriver.com>
wrote:
>
> I agree to drop those codes, and it should already be part of the rewrite,
>
> where I can find info about the rewrite, I don’t see any actives in:
>
> git.yoctoproject.org/cgit/cgit.cgi/matchbox-desktop-2
>
> The latest commit is 3 years ago.


They're not very recent either but most of the matchbox-* repos have a
branch 'gtk3' that contains the most up to date work. I've just started
looking at the code with the intention of finishing this gtk3 transition:
an up-to-date poky branch with these changes is 'jku/shuku' in git://
git.yoctoproject.org/poky-contrib. Be warned that it's currently quite
broken: I hope I have something that runs in a week or two.

I agree with ross about preferably getting rid of things like custom
inotify code.

 - Jussi

[-- Attachment #2: Type: text/html, Size: 1187 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] matchbox-desktop: sync with gio for the inotify-sub
  2015-12-03 11:58     ` Jussi Kukkonen
@ 2015-12-09  7:11       ` Huang, Jie (Jackie)
  0 siblings, 0 replies; 5+ messages in thread
From: Huang, Jie (Jackie) @ 2015-12-09  7:11 UTC (permalink / raw)
  To: KUKKONEN, JUSSI; +Cc: OE-core

[-- Attachment #1: Type: text/plain, Size: 1352 bytes --]

Thanks, so we can ignore this patch and should get rid of the inotify codes in the rewrite.

Thanks,
Jackie

From: Jussi Kukkonen [mailto:jussi.kukkonen@intel.com]
Sent: Thursday, December 03, 2015 7:58 PM
To: Huang, Jie (Jackie)
Cc: BURTON, ROSS; OE-core
Subject: Re: [OE-core] [PATCH] matchbox-desktop: sync with gio for the inotify-sub

On 3 December 2015 at 11:11, Huang, Jie (Jackie) <Jackie.Huang@windriver.com<mailto:Jackie.Huang@windriver.com>> wrote:
>
> I agree to drop those codes, and it should already be part of the rewrite,
>
> where I can find info about the rewrite, I don’t see any actives in:
>
> git.yoctoproject.org/cgit/cgit.cgi/matchbox-desktop-2<http://git.yoctoproject.org/cgit/cgit.cgi/matchbox-desktop-2>
>
> The latest commit is 3 years ago.


They're not very recent either but most of the matchbox-* repos have a branch 'gtk3' that contains the most up to date work. I've just started looking at the code with the intention of finishing this gtk3 transition: an up-to-date poky branch with these changes is 'jku/shuku' in git://git.yoctoproject.org/poky-contrib<http://git.yoctoproject.org/poky-contrib>. Be warned that it's currently quite broken: I hope I have something that runs in a week or two.

I agree with ross about preferably getting rid of things like custom inotify code.
 - Jussi

[-- Attachment #2: Type: text/html, Size: 4766 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2015-12-09  7:11 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-12-01  5:47 [PATCH] matchbox-desktop: sync with gio for the inotify-sub jackie.huang
2015-12-01  8:56 ` Burton, Ross
2015-12-03  9:11   ` Huang, Jie (Jackie)
2015-12-03 11:58     ` Jussi Kukkonen
2015-12-09  7:11       ` Huang, Jie (Jackie)

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.