summaryrefslogtreecommitdiff
path: root/devel/gio-fam-backend/files
diff options
context:
space:
mode:
Diffstat (limited to 'devel/gio-fam-backend/files')
-rw-r--r--devel/gio-fam-backend/files/patch-fam52
-rw-r--r--devel/gio-fam-backend/files/patch-gio_fam_Makefile.in27
2 files changed, 79 insertions, 0 deletions
diff --git a/devel/gio-fam-backend/files/patch-fam b/devel/gio-fam-backend/files/patch-fam
new file mode 100644
index 000000000000..a3b5fe4aa716
--- /dev/null
+++ b/devel/gio-fam-backend/files/patch-fam
@@ -0,0 +1,52 @@
+--- gio/fam/fam-helper.h.orig 2008-03-10 13:50:12.000000000 -0400
++++ gio/fam/fam-helper.h 2008-03-10 13:50:29.000000000 -0400
+@@ -28,6 +28,7 @@
+ typedef struct _fam_sub fam_sub;
+
+ gboolean _fam_sub_startup (void);
++void _fam_sub_shutdown (void);
+ fam_sub* _fam_sub_add (const gchar* pathname,
+ gboolean directory,
+ gpointer user_data);
+--- gio/fam/fam-helper.c.orig 2008-03-10 20:31:58.000000000 -0400
++++ gio/fam/fam-helper.c 2008-03-10 23:06:32.000000000 -0400
+@@ -181,6 +181,22 @@ _fam_sub_startup (void)
+ return TRUE;
+ }
+
++void
++_fam_sub_shutdown (void)
++{
++ G_LOCK (fam_connection);
++
++ if (fam_connection != NULL) {
++ FAMClose (fam_connection);
++ g_free (fam_connection);
++ g_source_remove (fam_watch_id);
++ fam_watch_id = 0;
++ fam_connection = NULL;
++ }
++
++ G_UNLOCK (fam_connection);
++}
++
+ fam_sub*
+ _fam_sub_add (const gchar* pathname,
+ gboolean directory,
+--- gio/fam/fam-module.c.orig 2008-03-12 13:38:54.000000000 -0400
++++ gio/fam/fam-module.c 2008-03-12 13:39:31.000000000 -0400
+@@ -26,6 +26,7 @@
+ #include "giomodule.h"
+ #include "gfamdirectorymonitor.h"
+ #include "gfamfilemonitor.h"
++#include "fam-helper.h"
+
+ void
+ g_io_module_load (GIOModule *module)
+@@ -37,5 +38,6 @@ g_io_module_load (GIOModule *module)
+ void
+ g_io_module_unload (GIOModule *module)
+ {
++ _fam_sub_shutdown ();
+ }
+
diff --git a/devel/gio-fam-backend/files/patch-gio_fam_Makefile.in b/devel/gio-fam-backend/files/patch-gio_fam_Makefile.in
new file mode 100644
index 000000000000..0f6a9e25ead1
--- /dev/null
+++ b/devel/gio-fam-backend/files/patch-gio_fam_Makefile.in
@@ -0,0 +1,27 @@
+--- gio/fam/Makefile.in.orig 2008-01-07 19:40:38.000000000 -0500
++++ gio/fam/Makefile.in 2008-01-07 19:41:53.000000000 -0500
+@@ -59,9 +59,8 @@ am__installdirs = "$(DESTDIR)$(giomodule
+ giomoduleLTLIBRARIES_INSTALL = $(INSTALL)
+ LTLIBRARIES = $(giomodule_LTLIBRARIES)
+ am__DEPENDENCIES_1 =
+-libgiofam_la_DEPENDENCIES = $(top_builddir)/gio/libgio-2.0.la \
+- $(top_builddir)/gobject/libgobject-2.0.la \
+- $(top_builddir)/glib/libglib-2.0.la $(am__DEPENDENCIES_1) \
++libgiofam_la_DEPENDENCIES = \
++ $(am__DEPENDENCIES_1) \
+ $(am__DEPENDENCIES_1)
+ am__objects_1 =
+ am_libgiofam_la_OBJECTS = libgiofam_la-fam-helper.lo \
+@@ -321,9 +320,9 @@ libgiofam_la_CFLAGS = \
+
+ libgiofam_la_LDFLAGS = $(module_flags)
+ libgiofam_la_LIBADD = \
+- $(top_builddir)/gio/libgio-2.0.la \
+- $(top_builddir)/gobject/libgobject-2.0.la \
+- $(top_builddir)/glib/libglib-2.0.la \
++ -lgio-2.0 \
++ -lgobject-2.0 \
++ -lglib-2.0 \
+ $(GLIB_LIBS) \
+ $(FAM_LIBS) \
+ $(NULL)