From owner-svn-ports-all@FreeBSD.ORG Wed Jul 3 12:38:32 2013 Return-Path: Delivered-To: svn-ports-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 24B35A29; Wed, 3 Jul 2013 12:38:32 +0000 (UTC) (envelope-from wg@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id F224D1924; Wed, 3 Jul 2013 12:38:31 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r63CcVqp062997; Wed, 3 Jul 2013 12:38:31 GMT (envelope-from wg@svn.freebsd.org) Received: (from wg@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r63CcVGB062995; Wed, 3 Jul 2013 12:38:31 GMT (envelope-from wg@svn.freebsd.org) Message-Id: <201307031238.r63CcVGB062995@svn.freebsd.org> From: William Grzybowski Date: Wed, 3 Jul 2013 12:38:31 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r322225 - in head/x11/menu-cache: . files X-SVN-Group: ports-head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-ports-all@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the ports tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 03 Jul 2013 12:38:32 -0000 Author: wg Date: Wed Jul 3 12:38:31 2013 New Revision: 322225 URL: http://svnweb.freebsd.org/changeset/ports/322225 Log: x11/menu-cache: fix LXDE menu bug - Fix LXDE menu bug (from upstream) - Change depenency to glib20 PR: ports/180132 Submitted by: nemysis (maintainer) Added: head/x11/menu-cache/files/ head/x11/menu-cache/files/patch-menu-cache-daemon-menu-cached.c (contents, props changed) Modified: head/x11/menu-cache/Makefile Modified: head/x11/menu-cache/Makefile ============================================================================== --- head/x11/menu-cache/Makefile Wed Jul 3 12:34:05 2013 (r322224) +++ head/x11/menu-cache/Makefile Wed Jul 3 12:38:31 2013 (r322225) @@ -3,6 +3,7 @@ PORTNAME= menu-cache PORTVERSION= 0.4.1 +PORTREVISION= 1 CATEGORIES= x11 MASTER_SITES= SF/lxde/menu-cache/menu-cache%20${PORTVERSION}/ @@ -10,7 +11,7 @@ MAINTAINER= nemysis@gmx.ch COMMENT= The menu-cache portion of LXDE USES= pkgconfig -USE_GNOME= gnomehack gtk20 +USE_GNOME= gnomehack glib20 USE_AUTOTOOLS= libtool USE_GMAKE= yes USE_LDCONFIG= yes Added: head/x11/menu-cache/files/patch-menu-cache-daemon-menu-cached.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/x11/menu-cache/files/patch-menu-cache-daemon-menu-cached.c Wed Jul 3 12:38:31 2013 (r322225) @@ -0,0 +1,46 @@ +--- menu-cache-daemon/menu-cached.c.orig 2012-11-14 09:07:36.000000000 +0100 ++++ menu-cache-daemon/menu-cached.c 2013-07-01 00:02:26.000000000 +0200 +@@ -121,7 +121,7 @@ + static gboolean read_all_used_files( FILE* f, int* n_files, char*** used_files ) + { + char line[ 4096 ]; +- int i, n; ++ int i, n, x; + char** files; + int ver_maj, ver_min; + +@@ -141,20 +141,31 @@ + if( ! fgets( line, G_N_ELEMENTS(line), f ) ) + return FALSE; + +- *n_files = n = atoi( line ); ++ n = atoi( line ); + files = g_new0( char*, n + 1 ); + +- for( i = 0; i < n; ++i ) ++ for( i = 0, x = 0; i < n; ++i ) + { + int len; ++ GFile *gfile; + if( ! fgets( line, G_N_ELEMENTS(line), f ) ) + return FALSE; + + len = strlen( line ); + if( len <= 1 ) + return FALSE; +- files[ i ] = g_strndup( line, len - 1 ); /* don't include \n */ ++ files[ x ] = g_strndup( line, len - 1 ); /* don't include \n */ ++ gfile = g_file_new_for_path(files[x]+1); ++ if (g_file_query_exists(gfile, NULL)) ++ x++; ++ else ++ { ++ DEBUG("ignoring not existant file from menu-cache-gen: %s", files[x]); ++ g_free(files[x]); ++ } ++ g_object_unref(gfile); + } ++ *n_files = x; + *used_files = files; + return TRUE; + }