svn commit: r344586 - in head/devel/glib20: . files

Koop Mast kwm at FreeBSD.org
Sun Feb 16 15:40:35 UTC 2014


Author: kwm
Date: Sun Feb 16 15:40:34 2014
New Revision: 344586
URL: http://svnweb.freebsd.org/changeset/ports/344586
QAT: https://qat.redports.org/buildarchive/r344586/

Log:
  Add patch from upstream to fix crasher in open-vm-tools [1]
  Add back depend on libiconv. This is needed because our base iconv
  doesn't do utf-8 -> wchar_t apparently. [2] wchar_t is used by glibmm.
  
  While here:
  Use new lib_depend syntax, strip libraries, stagify [3]
  
  Submitted by:	swills@ [1]
  		mandree@ [2]
  Discussion at:	http://lists.freebsd.org/pipermail/freebsd-ports/2014-February/089603.html [2]
  Obtained from:	gnome devel-repo [3]

Added:
  head/devel/glib20/files/patch-glib_gmain.c   (contents, props changed)
Modified:
  head/devel/glib20/Makefile

Modified: head/devel/glib20/Makefile
==============================================================================
--- head/devel/glib20/Makefile	Sun Feb 16 15:25:59 2014	(r344585)
+++ head/devel/glib20/Makefile	Sun Feb 16 15:40:34 2014	(r344586)
@@ -4,7 +4,7 @@
 
 PORTNAME=	glib
 PORTVERSION=	2.36.3
-PORTREVISION=	1
+PORTREVISION=	2
 CATEGORIES=	devel
 MASTER_SITES=	GNOME
 DIST_SUBDIR=	gnome2
@@ -19,12 +19,14 @@ PORTSCOUT=	limitw:1,even
 
 .if !defined(REFERENCE_PORT)
 
-LIB_DEPENDS+=	pcre:${PORTSDIR}/devel/pcre \
-		ffi:${PORTSDIR}/devel/libffi
+LIB_DEPENDS+=	libpcre.so:${PORTSDIR}/devel/pcre \
+		libffi.so:${PORTSDIR}/devel/libffi
 
 USE_AUTOTOOLS=	libtool
 USE_LDCONFIG=	yes
-USES=		gettext gmake iconv pathfix pkgconfig shebangfix perl5
+# iconv:wchar_t - our iconv in base doesn't support utf-8 -> wchar_t (boooo)
+# (wchar_t is used by glibmm, rawtherapee triggered this)
+USES=		gettext gmake iconv:wchar_t pathfix pkgconfig shebangfix perl5
 USE_GNOME=	ltverhack
 USE_PYTHON=	yes
 CONFIGURE_ARGS=	--enable-static \
@@ -35,13 +37,13 @@ CONFIGURE_ARGS=	--enable-static \
 CONFIGURE_ENV=	ac_cv_header_sys_inotify_h=
 CPPFLAGS+=	-I${LOCALBASE}/include
 LDFLAGS+=	-L${LOCALBASE}/lib
+INSTALL_TARGET=	install-strip
 
 SHEBANG_FILES=	*/*.pl glib/gen-iswide-table.py
 
 OPTIONS_DEFINE=	COLLATION_FIX DEBUG
 COLLATION_FIX_DESC=	fix string collation
 
-NO_STAGE=	yes
 .include <bsd.port.pre.mk>
 
 # doesn't build yet
@@ -74,7 +76,7 @@ GLIB_ARCH=	${ARCH}
 CONFIGURE_TARGET=${GLIB_ARCH}-portbld-freebsd${OSREL}
 
 .if ${PORT_OPTIONS:MCOLLATION_FIX}
-LIB_DEPENDS+=	icui18n:${PORTSDIR}/devel/icu
+LIB_DEPENDS+=	libicui18n.so:${PORTSDIR}/devel/icu
 EXTRA_PATCHES+=	${FILESDIR}/extra-patch-glib_Makefile.in \
 		${FILESDIR}/extra-patch-glib_gunicollate.c
 # Disable it until someone can figure why it causes net-im/pidgin crashed.
@@ -101,8 +103,7 @@ post-patch:
 		s|#define HAVE_SYS_INOTIFY_H 1||' ${WRKSRC}/configure
 
 post-install:
-	@${MKDIR} ${PREFIX}/share/GConf/gsettings
-	-${PREFIX}/bin/gio-querymodules ${PREFIX}/lib/gio/modules
+	@${MKDIR} ${STAGEDIR}${PREFIX}/share/GConf/gsettings
 
 .include <bsd.port.post.mk>
 

Added: head/devel/glib20/files/patch-glib_gmain.c
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/devel/glib20/files/patch-glib_gmain.c	Sun Feb 16 15:40:34 2014	(r344586)
@@ -0,0 +1,38 @@
+From 0513c855cba69b96e4c9d2200719249a8a0c586e Mon Sep 17 00:00:00 2001
+From: Dan Winship <danw at gnome.org>
+Date: Wed, 10 Apr 2013 11:39:12 -0400
+Subject: [PATCH] gmain: fix double-unlock in g_main_context_unref()
+
+When unreffing a context with sources still attached, it would end up
+unlocking an already-unlocked context, causing crashes on platforms
+that (unlike Linux) actually check for that.
+
+https://bugzilla.gnome.org/show_bug.cgi?id=697595
+---
+ glib/gmain.c | 6 +++++-
+ 1 file changed, 5 insertions(+), 1 deletion(-)
+
+diff --git a/glib/gmain.c b/glib/gmain.c
+index 68a7f8e..d6037ba 100644
+--- glib/gmain.c
++++ glib/gmain.c
+@@ -520,12 +520,16 @@ g_main_context_unref (GMainContext *context)
+   main_context_list = g_slist_remove (main_context_list, context);
+   G_UNLOCK (main_context_list);
+ 
++  /* g_source_iter_next() assumes the context is locked. */
++  LOCK_CONTEXT (context);
+   g_source_iter_init (&iter, context, TRUE);
+   while (g_source_iter_next (&iter, &source))
+     {
+       source->context = NULL;
+-      g_source_destroy_internal (source, context, FALSE);
++      g_source_destroy_internal (source, context, TRUE);
+     }
++  UNLOCK_CONTEXT (context);
++
+   for (sl_iter = context->source_lists; sl_iter; sl_iter = sl_iter->next)
+     {
+       list = sl_iter->data;
+-- 
+1.8.1.4


More information about the svn-ports-all mailing list