View | Details | Raw Unified | Return to bug 199872 | Differences between
and this patch

Collapse All | Expand All

(-)Makefile (-5 / +18 lines)
Lines 3-9 Link Here
3
3
4
PORTNAME=	glib
4
PORTNAME=	glib
5
PORTVERSION=	2.50.2
5
PORTVERSION=	2.50.2
6
PORTREVISION=	7
6
PORTREVISION=	8
7
PORTEPOCH=	1
7
PORTEPOCH=	1
8
CATEGORIES=	devel
8
CATEGORIES=	devel
9
MASTER_SITES=	GNOME
9
MASTER_SITES=	GNOME
Lines 34-40 Link Here
34
		--enable-static=yes \
34
		--enable-static=yes \
35
		--with-pcre=system \
35
		--with-pcre=system \
36
		--disable-fam
36
		--disable-fam
37
CONFIGURE_ENV=	ac_cv_header_sys_inotify_h=
38
INSTALL_TARGET=	install-strip
37
INSTALL_TARGET=	install-strip
39
38
40
SHEBANG_FILES=	*/*.pl
39
SHEBANG_FILES=	*/*.pl
Lines 49-54 Link Here
49
gobject_MAN=	glib-genmarshal.1 glib-mkenums.1 gobject-query.1
48
gobject_MAN=	glib-genmarshal.1 glib-mkenums.1 gobject-query.1
50
49
51
OPTIONS_DEFINE=	COLLATION_FIX DEBUG NLS
50
OPTIONS_DEFINE=	COLLATION_FIX DEBUG NLS
51
OPTIONS_SINGLE=	GIO_BACKEND
52
OPTIONS_SINGLE_GIO_BACKEND=	INOTIFY KQUEUE
53
OPTIONS_DEFAULT=	INOTIFY
52
OPTIONS_SUB=	yes
54
OPTIONS_SUB=	yes
53
# libc collation was fixed by https://svnweb.freebsd.org/changeset/base/290494
55
# libc collation was fixed by https://svnweb.freebsd.org/changeset/base/290494
54
COLLATION_FIX_DESC=	Use ICU for UTF-8 string collation (if libc is broken)
56
COLLATION_FIX_DESC=	Use ICU for UTF-8 string collation (if libc is broken)
Lines 65-70 Link Here
65
# http://www.freebsd.org/cgi/query-pr.cgi?pr=175930 see comment by ed@
67
# http://www.freebsd.org/cgi/query-pr.cgi?pr=175930 see comment by ed@
66
#COLLATION_FIX_CONFIGURE_ENV+=	CFLAGS="-D__STDC_ISO_10646__"
68
#COLLATION_FIX_CONFIGURE_ENV+=	CFLAGS="-D__STDC_ISO_10646__"
67
69
70
GIO_BACKEND_DESC=	Gio backend
71
INOTIFY_DESC=		Use gio/inotify backend
72
INOTIFY_CONFIGURE_ENV=	ac_cv_header_sys_event_h=
73
INOTIFY_LDFLAGS=	-linotify
74
INOTIFY_LIB_DEPENDS=	libinotify.so:devel/libinotify
75
KQUEUE_DESC=		Use gio/kqueue backend
76
KQUEUE_CONFIGURE_ENV=	ac_cv_header_sys_inotify_h=
77
68
.include <bsd.port.pre.mk>
78
.include <bsd.port.pre.mk>
69
79
70
# doesn't build yet
80
# doesn't build yet
Lines 71-77 Link Here
71
CONFIGURE_ARGS+=--disable-dtrace
81
CONFIGURE_ARGS+=--disable-dtrace
72
82
73
.if empty(ICONV_LIB)
83
.if empty(ICONV_LIB)
74
CONFIGURE_ARGS+=	--with-libiconv=no
84
CONFIGURE_ARGS+=	--with-libiconv=maybe
75
.else
85
.else
76
CONFIGURE_ARGS+=	--with-libiconv=gnu
86
CONFIGURE_ARGS+=	--with-libiconv=gnu
77
.endif
87
.endif
Lines 94-101 Link Here
94
	@${REINPLACE_CMD} -e 's|/usr/local|${LOCALBASE}|g ; \
104
	@${REINPLACE_CMD} -e 's|/usr/local|${LOCALBASE}|g ; \
95
		s|/usr/share/locale/locale|${LOCALBASE}/share/locale/locale|g' \
105
		s|/usr/share/locale/locale|${LOCALBASE}/share/locale/locale|g' \
96
			${WRKSRC}/glib/gutils.c
106
			${WRKSRC}/glib/gutils.c
97
	@${REINPLACE_CMD} -e 's|inotify_support=yes|inotify_support=no| ; \
107
	@${REINPLACE_CMD} -e 's|-Werror||' ${WRKSRC}/configure
98
		s|-Werror|| ; \
108
109
post-patch-KQUEUE-on:
110
	@${REINPLACE_CMD} -i '.kqueue' -e \
111
		's|inotify_support=yes|inotify_support=no| ; \
99
		s|#define HAVE_SYS_INOTIFY_H 1||' ${WRKSRC}/configure
112
		s|#define HAVE_SYS_INOTIFY_H 1||' ${WRKSRC}/configure
100
113
101
post-install:
114
post-install:
(-)files/patch-gio_inotify_inotify-path.c (+16 lines)
Line 0 Link Here
1
--- gio/inotify/inotify-path.c.orig	2016-10-22 05:18:16 UTC
2
+++ gio/inotify/inotify-path.c
3
@@ -36,7 +36,13 @@
4
 #include "inotify-path.h"
5
 #include "inotify-missing.h"
6
 
7
+#ifdef __linux__
8
 #define IP_INOTIFY_DIR_MASK (IN_MODIFY|IN_ATTRIB|IN_MOVED_FROM|IN_MOVED_TO|IN_DELETE|IN_CREATE|IN_DELETE_SELF|IN_UNMOUNT|IN_MOVE_SELF|IN_CLOSE_WRITE)
9
+#else
10
+/* libinotify-kqueue opens each file in watched directory if one of IN_MODIFY,
11
+ * IN_ATTRIB or IN_CLOSE_WRITE flags specified. Exclude them from mask */
12
+#define IP_INOTIFY_DIR_MASK (IN_MOVED_FROM|IN_MOVED_TO|IN_DELETE|IN_CREATE|IN_DELETE_SELF|IN_UNMOUNT|IN_MOVE_SELF)
13
+#endif
14
 
15
 #define IP_INOTIFY_FILE_MASK (IN_MODIFY|IN_ATTRIB|IN_CLOSE_WRITE)
16
 

Return to bug 199872