diff options
author | kwm <kwm@df743ca5-7f9a-e211-a948-0013205c9059> | 2013-05-06 19:04:38 +0800 |
---|---|---|
committer | kwm <kwm@df743ca5-7f9a-e211-a948-0013205c9059> | 2013-05-06 19:04:38 +0800 |
commit | 0a1f795c69afbeaf1a67180eaf88b06f50bef4e8 (patch) | |
tree | 54a74676833ae2689271965c69a48b8d9596a5a5 /devel/dconf | |
parent | 0aaa2a884f269e3b7926fa78176e3dc4c634a1b9 (diff) | |
download | marcuscom-ports-0a1f795c69afbeaf1a67180eaf88b06f50bef4e8.tar marcuscom-ports-0a1f795c69afbeaf1a67180eaf88b06f50bef4e8.tar.gz marcuscom-ports-0a1f795c69afbeaf1a67180eaf88b06f50bef4e8.tar.bz2 marcuscom-ports-0a1f795c69afbeaf1a67180eaf88b06f50bef4e8.tar.lz marcuscom-ports-0a1f795c69afbeaf1a67180eaf88b06f50bef4e8.tar.xz marcuscom-ports-0a1f795c69afbeaf1a67180eaf88b06f50bef4e8.tar.zst marcuscom-ports-0a1f795c69afbeaf1a67180eaf88b06f50bef4e8.zip |
Part two of the GNOME 3.6 update.
Submitted by: Gustau Perez
git-svn-id: svn://creme-brulee.marcuscom.com/ports/trunk@18422 df743ca5-7f9a-e211-a948-0013205c9059
Diffstat (limited to 'devel/dconf')
-rw-r--r-- | devel/dconf/Makefile | 69 | ||||
-rw-r--r-- | devel/dconf/distinfo | 2 | ||||
-rw-r--r-- | devel/dconf/files/patch-client_Makefile.in | 40 | ||||
-rw-r--r-- | devel/dconf/files/patch-dbus-1_Makefile.in | 51 | ||||
-rw-r--r-- | devel/dconf/files/patch-editor_Makefile.in | 20 | ||||
-rw-r--r-- | devel/dconf/files/patch-editor_dconf-editor.vala | 157 | ||||
-rw-r--r-- | devel/dconf/files/patch-editor_dconf-model.vala | 212 | ||||
-rw-r--r-- | devel/dconf/files/patch-editor_dconf-schema.vala | 129 | ||||
-rw-r--r-- | devel/dconf/files/patch-editors_dconf-view.vala | 11 | ||||
-rw-r--r-- | devel/dconf/files/patch-test_Makefile.am | 21 | ||||
-rw-r--r-- | devel/dconf/files/patch-test_Makefile.in | 21 | ||||
-rw-r--r-- | devel/dconf/pkg-descr | 18 | ||||
-rw-r--r-- | devel/dconf/pkg-plist | 97 |
13 files changed, 848 insertions, 0 deletions
diff --git a/devel/dconf/Makefile b/devel/dconf/Makefile new file mode 100644 index 000000000..3846fef22 --- /dev/null +++ b/devel/dconf/Makefile @@ -0,0 +1,69 @@ +# Created by: Koop Mast <kwm@FreeBSD.org> +# $FreeBSD: devel/dconf/Makefile 313956 2013-03-12 09:45:07Z kwm $ +# $MCom$ + +PORTNAME?= dconf +PORTVERSION= 0.14.1 +PORTREVISION= 0 +CATEGORIES= devel gnome +MASTER_SITES= GNOME +DISTNAME= dconf-${PORTVERSION} +DIST_SUBDIR= gnome3 + +MAINTAINER= gnome@FreeBSD.org +COMMENT= A configuration database system for GNOME + +BUILD_DEPENDS= vala>=0.18.1:${PORTSDIR}/lang/vala \ + docbook-xsl>=0:${PORTSDIR}/textproc/docbook-xsl + +LIB_DEPENDS= dbus-1:${PORTSDIR}/devel/dbus + +USE_XZ= yes +USE_GMAKE= yes +USES= gettext pathfix pkgconfig +USE_GNOME= glib20 gnomehier intltool +USE_LDCONFIG= yes +GNU_CONFIGURE= yes +MAKE_JOBS_UNSAFE= yes +CPPFLAGS+= -I${LOCALBASE}/include +LDFLAGS+= -L${LOCALBASE}/lib + +DCONF_SLAVE?= no + +.if ${DCONF_SLAVE} == "editor" +USE_GNOME+= gtk30 +INSTALLS_ICONS= yes +GLIB_SCHEMAS= ca.desrt.dconf-editor.gschema.xml +LIB_DEPENDS+= dconf:${PORTSDIR}/devel/dconf +.else +CONFIGURE_ARGS+=--disable-editor +.endif + +.if ${DCONF_SLAVE} == "no" +MAN1= dconf.1 +MAN7= dconf.7 +.endif + +post-patch: + @${REINPLACE_CMD} -e 's|/etc/|${PREFIX}/etc/|g' \ + ${WRKSRC}/engine/dconf-engine.c \ + ${WRKSRC}/bin/dconf-update.c + @${REINPLACE_CMD} -e 's|/usr/local/|${LOCALBASE}/|g' \ + ${WRKSRC}/editor/dconf-model.c + @${REINPLACE_CMD} -e 's|/usr/share|${LOCALBASE}/share|g' \ + ${WRKSRC}/editor/dconf-model.vala + @${REINPLACE_CMD} -e 's|-Wno-unused-but-set-variable||g' \ + ${WRKSRC}/bin/Makefile.in \ + ${WRKSRC}/client/Makefile.in \ + ${WRKSRC}/editor/Makefile.in + +pre-build: +# ${GMAKE} -C ${WRKSRC}/client dconf-client.c libdconf.so.0 +# ${GMAKE} -C ${WRKSRC}/dbus-1 dconf-dbus-1.c libdconf-dbus-1.so.0 + +post-install: + -${LOCALBASE}/bin/gio-querymodules ${PREFIX}/lib/gio/modules + @${MKDIR} ${PREFIX}/etc/dconf/db + @${MKDIR} ${PREFIX}/etc/dconf/profile + +.include <bsd.port.mk> diff --git a/devel/dconf/distinfo b/devel/dconf/distinfo new file mode 100644 index 000000000..e1afb761d --- /dev/null +++ b/devel/dconf/distinfo @@ -0,0 +1,2 @@ +SHA256 (gnome3/dconf-0.14.1.tar.xz) = 59c58c5eafa0ebd616287d078f4441d5342870a44634445d324e88fc0287f0b8 +SIZE (gnome3/dconf-0.14.1.tar.xz) = 291300 diff --git a/devel/dconf/files/patch-client_Makefile.in b/devel/dconf/files/patch-client_Makefile.in new file mode 100644 index 000000000..c53b723b7 --- /dev/null +++ b/devel/dconf/files/patch-client_Makefile.in @@ -0,0 +1,40 @@ +--- client/Makefile.orig.in 2013-03-26 19:40:26.085263743 +0000 ++++ client/Makefile.in 2013-03-26 19:40:33.384265230 +0000 +@@ -55,7 +55,7 @@ + DIST_COMMON = $(dconfclientinclude_HEADERS) $(dconfinclude_HEADERS) \ + $(srcdir)/Makefile.am $(srcdir)/Makefile.in \ + $(srcdir)/dconf.pc.in $(top_srcdir)/Makefile.gtester +-shlib_PROGRAMS = libdconf.so.1.0.0$(EXEEXT) ++shlib_PROGRAMS = libdconf.so.1$(EXEEXT) + subdir = client + ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 + am__aclocal_m4_deps = $(top_srcdir)/configure.ac +@@ -416,12 +416,12 @@ + + clean-shlibPROGRAMS: + -test -z "$(shlib_PROGRAMS)" || rm -f $(shlib_PROGRAMS) +-libdconf.so.1.0.0$(EXEEXT): $(libdconf_so_1_0_0_OBJECTS) $(libdconf_so_1_0_0_DEPENDENCIES) $(EXTRA_libdconf_so_1_0_0_DEPENDENCIES) ++libdconf.so.1$(EXEEXT): $(libdconf_so_1_0_0_OBJECTS) $(libdconf_so_1_0_0_DEPENDENCIES) $(EXTRA_libdconf_so_1_0_0_DEPENDENCIES) + @rm -f libdconf.so.1.0.0$(EXEEXT) + $(AM_V_CCLD)$(libdconf_so_1_0_0_LINK) $(libdconf_so_1_0_0_OBJECTS) $(libdconf_so_1_0_0_LDADD) $(LIBS) ++ $(AM_V_GEN) ln -fs libdconf.so.1 libdconf.so + + mostlyclean-compile: +- -rm -f *.$(OBJEXT) + + distclean-compile: + -rm -f *.tab.c +@@ -838,12 +838,8 @@ + # run tests in cwd as part of make check + check-local: test-nonrecursive + +-libdconf.so.1 libdconf.so: libdconf.so.1.0.0 +- $(AM_V_GEN) ln -fs libdconf.so.1.0.0 $@ +- + install-data-hook: +- ln -fs libdconf.so.1.0.0 $(DESTDIR)$(shlibdir)/libdconf.so.1 +- ln -fs libdconf.so.1.0.0 $(DESTDIR)$(shlibdir)/libdconf.so ++ ln -fs libdconf.so.1 $(DESTDIR)$(shlibdir)/libdconf.so + + uninstall-hook: + rm -f $(DESTDIR)$(shlibdir)/libdconf.so.1 diff --git a/devel/dconf/files/patch-dbus-1_Makefile.in b/devel/dconf/files/patch-dbus-1_Makefile.in new file mode 100644 index 000000000..2cabd14fb --- /dev/null +++ b/devel/dconf/files/patch-dbus-1_Makefile.in @@ -0,0 +1,51 @@ +--- dbus-1/Makefile.orig.in 2013-03-26 19:18:48.870352031 +0000 ++++ dbus-1/Makefile.in 2013-03-26 19:18:57.583352154 +0000 +@@ -55,7 +55,7 @@ + DIST_COMMON = $(dconf_dbus_1include_HEADERS) $(srcdir)/Makefile.am \ + $(srcdir)/Makefile.in $(srcdir)/dconf-dbus-1.pc.in \ + $(top_srcdir)/Makefile.gtester +-shlib_PROGRAMS = libdconf-dbus-1.so.0.0.0$(EXEEXT) ++shlib_PROGRAMS = libdconf-dbus-1.so.0$(EXEEXT) + subdir = dbus-1 + ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 + am__aclocal_m4_deps = $(top_srcdir)/configure.ac +@@ -341,7 +341,7 @@ + + libdconf_dbus_1_so_0_0_0_LDFLAGS = -shared -Wl,-soname=libdconf-dbus-1.so.0 + libdconf_dbus_1_so_0_0_0_SOURCES = dconf-dbus-1.c +-nodist_noinst_DATA = libdconf-dbus-1.so libdconf-dbus-1.so.0 ++nodist_noinst_DATA = libdconf-dbus-1.so.0 + CLEANFILES = libdconf-dbus-1.so.0 libdconf-dbus-1.so + all: all-am + +@@ -430,13 +430,12 @@ + cd "$(DESTDIR)$(shlibdir)" && rm -f $$files + + clean-shlibPROGRAMS: +- -test -z "$(shlib_PROGRAMS)" || rm -f $(shlib_PROGRAMS) +-libdconf-dbus-1.so.0.0.0$(EXEEXT): $(libdconf_dbus_1_so_0_0_0_OBJECTS) $(libdconf_dbus_1_so_0_0_0_DEPENDENCIES) $(EXTRA_libdconf_dbus_1_so_0_0_0_DEPENDENCIES) +- @rm -f libdconf-dbus-1.so.0.0.0$(EXEEXT) ++libdconf-dbus-1.so.0$(EXEEXT): $(libdconf_dbus_1_so_0_0_0_OBJECTS) $(libdconf_dbus_1_so_0_0_0_DEPENDENCIES) $(EXTRA_libdconf_dbus_1_so_0_0_0_DEPENDENCIES) ++ @rm -f libdconf-dbus-1.so.0$(EXEEXT) + $(AM_V_CCLD)$(libdconf_dbus_1_so_0_0_0_LINK) $(libdconf_dbus_1_so_0_0_0_OBJECTS) $(libdconf_dbus_1_so_0_0_0_LDADD) $(LIBS) ++ $(AM_V_GEN) ln -fs libdconf-dbus-1.so.0 libdconf-dbus-1.so + + mostlyclean-compile: +- -rm -f *.$(OBJEXT) + + distclean-compile: + -rm -f *.tab.c +@@ -821,12 +820,8 @@ + # run tests in cwd as part of make check + check-local: test-nonrecursive + +-libdconf-dbus-1.so.0 libdconf-dbus-1.so: libdconf-dbus-1.so.0.0.0 +- $(AM_V_GEN) ln -fs libdconf-dbus-1.so.0.0.0 $@ +- + install-data-hook: +- ln -fs libdconf-dbus-1.so.0.0.0 $(DESTDIR)$(shlibdir)/libdconf-dbus-1.so.0 +- ln -fs libdconf-dbus-1.so.0.0.0 $(DESTDIR)$(shlibdir)/libdconf-dbus-1.so ++ ln -fs libdconf-dbus-1.so.0 $(DESTDIR)$(shlibdir)/libdconf-dbus-1.so + + uninstall-hook: + rm -f $(DESTDIR)$(shlibdir)/libdconf-dbus-1.so.0 diff --git a/devel/dconf/files/patch-editor_Makefile.in b/devel/dconf/files/patch-editor_Makefile.in new file mode 100644 index 000000000..f9935dd33 --- /dev/null +++ b/devel/dconf/files/patch-editor_Makefile.in @@ -0,0 +1,20 @@ +--- editor/Makefile.orig.in 2013-03-26 19:20:12.623348896 +0000 ++++ editor/Makefile.in 2013-03-26 19:21:40.077341977 +0000 +@@ -72,7 +72,7 @@ + dconf_editor-dconf-view.$(OBJEXT) + dconf_editor_OBJECTS = $(am_dconf_editor_OBJECTS) + am__DEPENDENCIES_1 = +-dconf_editor_DEPENDENCIES = ../client/libdconf.so.1 \ ++dconf_editor_DEPENDENCIES = -ldconf \ + $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \ + $(am__DEPENDENCIES_1) + dconf_editor_LINK = $(CCLD) $(dconf_editor_CFLAGS) $(CFLAGS) \ +@@ -297,7 +297,7 @@ + INCLUDES = -I$(top_srcdir) -I$(top_srcdir)/client + dconf_editor_VALAFLAGS = --vapidir ../client --pkg gtk+-3.0 --pkg gmodule-2.0 --pkg libxml-2.0 --pkg dconf + dconf_editor_LDADD = \ +- ../client/libdconf.so.1 \ ++ -ldconf \ + $(gtk_LIBS) \ + $(gee_LIBS) \ + $(gmodule_LIBS) \ diff --git a/devel/dconf/files/patch-editor_dconf-editor.vala b/devel/dconf/files/patch-editor_dconf-editor.vala new file mode 100644 index 000000000..3c03fa220 --- /dev/null +++ b/devel/dconf/files/patch-editor_dconf-editor.vala @@ -0,0 +1,157 @@ +--- editor/dconf-editor.vala.orig 2013-05-01 21:48:10.000000000 +0000 ++++ editor/dconf-editor.vala 2013-05-01 21:50:26.000000000 +0000 +@@ -5,6 +5,10 @@ + private Settings settings; + private Gtk.Builder ui; + private Gtk.ApplicationWindow window; ++ private int window_width = 0; ++ private int window_height = 0; ++ private bool window_is_maximized = false; ++ private bool window_is_fullscreen = false; + private Gtk.TreeView dir_tree_view; + private Gtk.TreeView key_tree_view; + private Gtk.Grid key_info_grid; +@@ -72,8 +76,10 @@ + } + set_app_menu((MenuModel)menu_ui.get_object("menu")); + +- window.set_default_size (settings.get_int ("width"), settings.get_int ("height")); +- if (settings.get_boolean ("maximized")) ++ window.set_default_size (settings.get_int ("window-width"), settings.get_int ("window-height")); ++ if (settings.get_boolean ("window-is-fullscreen")) ++ window.fullscreen (); ++ else if (settings.get_boolean ("window-is-maximized")) + window.maximize (); + + dir_tree_view = new DConfDirView(); +@@ -124,6 +130,15 @@ + window.present(); + } + ++ protected override void shutdown () ++ { ++ base.shutdown(); ++ settings.set_int ("window-width", window_width); ++ settings.set_int ("window-height", window_height); ++ settings.set_boolean ("window-is-maximized", window_is_maximized); ++ settings.set_boolean ("window-is-fullscreen", window_is_fullscreen); ++ } ++ + private void dir_selected_cb() + { + KeyModel? key_model = null; +@@ -201,11 +216,16 @@ + { + if (selected_key.schema != null) + { ++ var gettext_domain = selected_key.schema.gettext_domain; + schema_name = selected_key.schema.schema.id; + if (selected_key.schema.summary != null) + summary = selected_key.schema.summary; ++ if (gettext_domain != null && summary != "") ++ summary = dgettext(gettext_domain, summary); + if (selected_key.schema.description != null) + description = selected_key.schema.description; ++ if (gettext_domain != null && description != "") ++ description = dgettext(gettext_domain, description); + type = key_to_description(selected_key); + default_value = selected_key.schema.default_value.print(false); + } +@@ -236,10 +256,10 @@ + + private bool main_window_configure_event_cb (Gtk.Widget widget, Gdk.EventConfigure event) + { +- if (!settings.get_boolean ("maximized")) ++ if (!window_is_maximized && !window_is_fullscreen) + { +- settings.set_int ("width", event.width); +- settings.set_int ("height", event.height); ++ window_width = event.width; ++ window_height = event.height; + } + + return false; +@@ -248,10 +268,9 @@ + private bool main_window_window_state_event_cb (Gtk.Widget widget, Gdk.EventWindowState event) + { + if ((event.changed_mask & Gdk.WindowState.MAXIMIZED) != 0) +- { +- var is_maximized = (event.new_window_state & Gdk.WindowState.MAXIMIZED) != 0; +- settings.set_boolean ("maximized", is_maximized); +- } ++ window_is_maximized = (event.new_window_state & Gdk.WindowState.MAXIMIZED) != 0; ++ if ((event.changed_mask & Gdk.WindowState.FULLSCREEN) != 0) ++ window_is_fullscreen = (event.new_window_state & Gdk.WindowState.FULLSCREEN) != 0; + + return false; + } +@@ -266,6 +285,7 @@ + { + search_label.set_text(""); + ++ /* Get the current position in the tree */ + Gtk.TreeIter iter; + var key_iter = Gtk.TreeIter(); + var have_key_iter = false; +@@ -283,17 +303,31 @@ + else if (!model.get_iter_first(out iter)) + return; + ++ var on_first_directory = true; + do + { ++ /* Select next directory that matches */ + var dir = model.get_directory(iter); + if (!have_key_iter) ++ { + have_key_iter = dir.key_model.get_iter_first(out key_iter); ++ if (!on_first_directory && dir.name.index_of(search_entry.text) >= 0) ++ { ++ dir_tree_view.expand_to_path(model.get_path(iter)); ++ dir_tree_view.get_selection().select_iter(iter); ++ dir_tree_view.scroll_to_cell(model.get_path(iter), null, false, 0, 0); ++ return; ++ } ++ } ++ on_first_directory = false; ++ ++ /* Select next key that matches */ + if (have_key_iter) + { + do + { + var key = dir.key_model.get_key(key_iter); +- if (key.name.index_of (search_entry.text) >= 0) ++ if (key_matches(key, search_entry.text)) + { + dir_tree_view.expand_to_path(model.get_path(iter)); + dir_tree_view.get_selection().select_iter(iter); +@@ -310,6 +344,28 @@ + search_label.set_text(_("Not found")); + } + ++ private bool key_matches (Key key, string text) ++ { ++ /* Check key name */ ++ if (key.name.index_of(text) >= 0) ++ return true; ++ ++ /* Check key schema (description) */ ++ if (key.schema != null) ++ { ++ if (key.schema.summary != null && key.schema.summary.index_of(text) >= 0) ++ return true; ++ if (key.schema.description != null && key.schema.description.index_of(text) >= 0) ++ return true; ++ } ++ ++ /* Check key value */ ++ if (key.value.is_of_type(VariantType.STRING) && key.value.get_string().index_of(text) >= 0) ++ return true; ++ ++ return false; ++ } ++ + private bool get_next_iter(ref Gtk.TreeIter iter) + { + /* Search children next */ diff --git a/devel/dconf/files/patch-editor_dconf-model.vala b/devel/dconf/files/patch-editor_dconf-model.vala new file mode 100644 index 000000000..58077d674 --- /dev/null +++ b/devel/dconf/files/patch-editor_dconf-model.vala @@ -0,0 +1,212 @@ +--- editor/dconf-model.vala.orig 2013-05-01 21:47:59.000000000 +0000 ++++ editor/dconf-model.vala 2013-05-01 21:50:26.000000000 +0000 +@@ -254,7 +254,7 @@ + string[] tokens = path.split("/", 2); + string name = tokens[0]; + +- Directory directory = get_child(name); ++ var directory = get_child(name); + directory.load_schema(schema, tokens[1]); + } + } +@@ -341,8 +341,10 @@ + return (Key)iter.user_data; + } + +- public bool get_iter(ref Gtk.TreeIter iter, Gtk.TreePath path) ++ public bool get_iter(out Gtk.TreeIter iter, Gtk.TreePath path) + { ++ iter = Gtk.TreeIter(); ++ + if (path.get_depth() != 1) + return false; + +@@ -391,11 +393,14 @@ + return true; + } + +- public bool iter_children(ref Gtk.TreeIter iter, Gtk.TreeIter? parent) ++ public bool iter_children(out Gtk.TreeIter iter, Gtk.TreeIter? parent) + { ++ iter = Gtk.TreeIter(); ++ + if (parent != null || directory.keys.length() == 0) + return false; + set_iter(ref iter, directory.keys.nth_data(0)); ++ + return true; + } + +@@ -412,8 +417,10 @@ + return 0; + } + +- public bool iter_nth_child(ref Gtk.TreeIter iter, Gtk.TreeIter? parent, int n) ++ public bool iter_nth_child(out Gtk.TreeIter iter, Gtk.TreeIter? parent, int n) + { ++ iter = Gtk.TreeIter(); ++ + if (parent != null) + return false; + +@@ -423,8 +430,9 @@ + return true; + } + +- public bool iter_parent(ref Gtk.TreeIter iter, Gtk.TreeIter child) ++ public bool iter_parent(out Gtk.TreeIter iter, Gtk.TreeIter child) + { ++ iter = Gtk.TreeIter(); + return false; + } + +@@ -479,8 +487,10 @@ + return (SchemaValue)iter.user_data; + } + +- public bool get_iter(ref Gtk.TreeIter iter, Gtk.TreePath path) ++ public bool get_iter(out Gtk.TreeIter iter, Gtk.TreePath path) + { ++ iter = Gtk.TreeIter(); ++ + if (path.get_depth() != 1) + return false; + +@@ -513,11 +523,15 @@ + return true; + } + +- public bool iter_children(ref Gtk.TreeIter iter, Gtk.TreeIter? parent) ++ public bool iter_children(out Gtk.TreeIter iter, Gtk.TreeIter? parent) + { ++ iter = Gtk.TreeIter(); ++ + if (parent != null || schema_enum.values.length() == 0) + return false; ++ + set_iter(ref iter, schema_enum.values.nth_data(0)); ++ + return true; + } + +@@ -534,8 +548,10 @@ + return 0; + } + +- public bool iter_nth_child(ref Gtk.TreeIter iter, Gtk.TreeIter? parent, int n) ++ public bool iter_nth_child(out Gtk.TreeIter iter, Gtk.TreeIter? parent, int n) + { ++ iter = Gtk.TreeIter(); ++ + if (parent != null) + return false; + +@@ -545,8 +561,9 @@ + return true; + } + +- public bool iter_parent(ref Gtk.TreeIter iter, Gtk.TreeIter child) ++ public bool iter_parent(out Gtk.TreeIter iter, Gtk.TreeIter child) + { ++ iter = Gtk.TreeIter(); + return false; + } + +@@ -586,9 +603,14 @@ + schemas = new SchemaList(); + try + { +- foreach (var dir in GLib.Environment.get_system_data_dirs()) ++ var dirs = GLib.Environment.get_system_data_dirs(); ++ ++ /* Walk directories in reverse so the schemas in the ++ * directory which appears first in the XDG_DATA_DIRS are ++ * not overridden. */ ++ for (int i = dirs.length - 1; i >= 0; i--) + { +- var path = Path.build_filename (dir, "glib-2.0", "schemas", null); ++ var path = Path.build_filename (dirs[i], "glib-2.0", "schemas"); + if (File.new_for_path (path).query_exists ()) + schemas.load_directory (path); + } +@@ -601,7 +623,7 @@ + } + + /* Add keys for the values in the schemas */ +- foreach (var schema in schemas.schemas) ++ foreach (var schema in schemas.schemas.get_values()) + root.load_schema(schema, schema.path[1:schema.path.length]); + } + +@@ -639,8 +661,10 @@ + return (Directory)iter.user_data; + } + +- public bool get_iter(ref Gtk.TreeIter iter, Gtk.TreePath path) ++ public bool get_iter(out Gtk.TreeIter iter, Gtk.TreePath path) + { ++ iter = Gtk.TreeIter(); ++ + if (!iter_nth_child(out iter, null, path.get_indices()[0])) + return false; + +@@ -672,19 +696,23 @@ + + public bool iter_next(ref Gtk.TreeIter iter) + { +- Directory directory = get_directory(iter); ++ var directory = get_directory(iter); + if (directory.index >= directory.parent.children.length() - 1) + return false; + set_iter(ref iter, directory.parent.children.nth_data(directory.index+1)); ++ + return true; + } + +- public bool iter_children(ref Gtk.TreeIter iter, Gtk.TreeIter? parent) ++ public bool iter_children(out Gtk.TreeIter iter, Gtk.TreeIter? parent) + { +- Directory directory = get_directory(parent); ++ iter = Gtk.TreeIter(); ++ ++ var directory = get_directory(parent); + if (directory.children.length() == 0) + return false; + set_iter(ref iter, directory.children.nth_data(0)); ++ + return true; + } + +@@ -698,21 +726,28 @@ + return (int) get_directory(iter).children.length(); + } + +- public bool iter_nth_child(ref Gtk.TreeIter iter, Gtk.TreeIter? parent, int n) ++ public bool iter_nth_child(out Gtk.TreeIter iter, Gtk.TreeIter? parent, int n) + { +- Directory directory = get_directory(parent); ++ iter = Gtk.TreeIter(); ++ ++ var directory = get_directory(parent); + if (n >= directory.children.length()) + return false; + set_iter(ref iter, directory.children.nth_data(n)); ++ + return true; + } + +- public bool iter_parent(ref Gtk.TreeIter iter, Gtk.TreeIter child) ++ public bool iter_parent(out Gtk.TreeIter iter, Gtk.TreeIter child) + { +- Directory directory = get_directory(child); ++ iter = Gtk.TreeIter(); ++ ++ var directory = get_directory(child); + if (directory.parent == root) + return false; ++ + set_iter(ref iter, directory.parent); ++ + return true; + } + diff --git a/devel/dconf/files/patch-editor_dconf-schema.vala b/devel/dconf/files/patch-editor_dconf-schema.vala new file mode 100644 index 000000000..2c624560c --- /dev/null +++ b/devel/dconf/files/patch-editor_dconf-schema.vala @@ -0,0 +1,129 @@ +--- editor/dconf-schema.vala.orig 2013-05-01 21:48:04.000000000 +0000 ++++ editor/dconf-schema.vala 2013-05-01 21:50:26.000000000 +0000 +@@ -44,7 +44,7 @@ + { + try + { +- default_value = Variant.parse(new VariantType(type), child->children->content); ++ default_value = Variant.parse(new VariantType(type), child->get_content()); + } + catch (VariantParseError e) + { +@@ -52,9 +52,9 @@ + } + } + else if (child->name == "summary") +- summary = child->children == null ? "" : child->children->content; ++ summary = child->get_content(); + else if (child->name == "description") +- description = child->children == null ? "" : child->children->content; ++ description = child->get_content(); + else if (child->name == "range") + range = new SchemaValueRange.from_xml(type, child); + else if (child->name == "choices") +@@ -345,7 +345,7 @@ + + public class SchemaList + { +- public GLib.List<Schema> schemas = new GLib.List<Schema>(); ++ public GLib.HashTable<string, Schema> schemas = new GLib.HashTable<string, Schema>(str_hash, str_equal); + public GLib.HashTable<string, SchemaKey> keys = new GLib.HashTable<string, SchemaKey>(str_hash, str_equal); + public GLib.HashTable<string, SchemaEnum> enums = new GLib.HashTable<string, SchemaEnum>(str_hash, str_equal); + public GLib.HashTable<string, SchemaFlags> flags = new GLib.HashTable<string, SchemaFlags>(str_hash, str_equal); +@@ -385,7 +385,7 @@ + string full_name = schema.path + key.name; + keys.insert(full_name, key); + } +- schemas.append(schema); ++ schemas.insert(schema.id, schema); + } + else if (node->name == "enum") + { +@@ -407,19 +407,79 @@ + delete doc; + } + ++ public void parse_override(string path) ++ { ++ var keyfile = new KeyFile(); ++ try ++ { ++ keyfile.load_from_file(path, KeyFileFlags.NONE); ++ } ++ catch (Error e) ++ { ++ warning("Failed to load override file %s: %s", path, e.message); ++ return; ++ } ++ ++ foreach (var group in keyfile.get_groups()) ++ { ++ var schema = schemas.lookup(group); ++ if (schema == null) ++ continue; ++ ++ string[] keys; ++ try { keys = keyfile.get_keys(group); } catch (Error e) { continue; } ++ ++ foreach (var key_name in keys) ++ { ++ string value; ++ try { value = keyfile.get_value(group, key_name); } catch (Error e) { continue; } ++ ++ var key = schema.keys.lookup (key_name); ++ if (key == null) ++ continue; ++ ++ Variant default_value; ++ try ++ { ++ default_value = Variant.parse(new VariantType(key.type), value); ++ } ++ catch (VariantParseError e) ++ { ++ // ... ++ continue; ++ } ++ ++ key.default_value = default_value; ++ } ++ } ++ } ++ + public void load_directory(string dir) throws Error + { +- File directory = File.new_for_path(dir); ++ var directory = File.new_for_path(dir); ++ + var i = directory.enumerate_children (FileAttribute.STANDARD_NAME, 0, null); +- FileInfo info; +- while ((info = i.next_file (null)) != null) { +- string name = info.get_name(); ++ while (true) ++ { ++ var info = i.next_file (null); ++ if (info == null) ++ break; ++ var name = info.get_name(); + +- if (!name.has_suffix(".gschema.xml") && !name.has_suffix(".enums.xml")) +- continue; ++ if (name.has_suffix(".gschema.xml") || name.has_suffix(".enums.xml")) ++ parse_file(Path.build_filename(dir, name, null)); ++ } ++ ++ i = directory.enumerate_children (FileAttribute.STANDARD_NAME, 0, null); ++ while (true) ++ { ++ var info = i.next_file (null); ++ if (info == null) ++ break; ++ var name = info.get_name(); + +- string path = Path.build_filename(dir, name, null); +- parse_file(path); ++ if (name.has_suffix(".override")) ++ parse_override(Path.build_filename(dir, name, null)); + } + } + } diff --git a/devel/dconf/files/patch-editors_dconf-view.vala b/devel/dconf/files/patch-editors_dconf-view.vala new file mode 100644 index 000000000..70998f181 --- /dev/null +++ b/devel/dconf/files/patch-editors_dconf-view.vala @@ -0,0 +1,11 @@ +--- editor/dconf-view.vala.orig 2013-05-01 21:48:19.000000000 +0000 ++++ editor/dconf-view.vala 2013-05-01 21:50:26.000000000 +0000 +@@ -270,7 +270,7 @@ + + private void spin_edited_cb(Gtk.CellRendererText renderer, string path, string text) + { +- Key key = get_key_from_path(path); ++ var key = get_key_from_path(path); + switch (key.type_string) + { + case "y": diff --git a/devel/dconf/files/patch-test_Makefile.am b/devel/dconf/files/patch-test_Makefile.am new file mode 100644 index 000000000..a3288f9e6 --- /dev/null +++ b/devel/dconf/files/patch-test_Makefile.am @@ -0,0 +1,21 @@ +--- tests/Makefile.orig.am 2013-03-26 21:34:03.467621533 +0100 ++++ tests/Makefile.am 2013-03-26 21:34:43.396618710 +0100 +@@ -28,8 +28,7 @@ + shm_CFLAGS = $(glib_CFLAGS) + shm_LDADD = \ + ../shm/libdconf-shm.a \ +- $(glib_LIBS) \ +- -ldl ++ $(glib_LIBS) + shm_SOURCES = \ + shm.c \ + tmpdir.h \ +@@ -79,7 +78,7 @@ + ../common/libdconf-common.a \ + libdconf-mock.a \ + $(glib_LIBS) \ +- -ldl -lm ++ -lm + engine_SOURCES = engine.c + EXTRA_DIST += \ + profile/broken-profile \ diff --git a/devel/dconf/files/patch-test_Makefile.in b/devel/dconf/files/patch-test_Makefile.in new file mode 100644 index 000000000..cdd5f47a0 --- /dev/null +++ b/devel/dconf/files/patch-test_Makefile.in @@ -0,0 +1,21 @@ +--- tests/Makefile.orig.in 2013-03-26 21:34:10.705623412 +0100 ++++ tests/Makefile.in 2013-03-26 21:34:54.686617478 +0100 +@@ -349,8 +349,7 @@ + shm_CFLAGS = $(glib_CFLAGS) + shm_LDADD = \ + ../shm/libdconf-shm.a \ +- $(glib_LIBS) \ +- -ldl ++ $(glib_LIBS) + + shm_SOURCES = \ + shm.c \ +@@ -395,7 +394,7 @@ + ../common/libdconf-common.a \ + libdconf-mock.a \ + $(glib_LIBS) \ +- -ldl -lm ++ -lm + + engine_SOURCES = engine.c + client_CFLAGS = $(gio_CFLAGS) -DSRCDIR=\"$(abs_srcdir)\" diff --git a/devel/dconf/pkg-descr b/devel/dconf/pkg-descr new file mode 100644 index 000000000..1688899d3 --- /dev/null +++ b/devel/dconf/pkg-descr @@ -0,0 +1,18 @@ +GConf extends the concept of a configuration registry. It provides +a simple way for applications and administrators to store data; +often GConf is used to store preferences for applications. + +Some of the features of GConf are: +GConf provides: + + * Documentation for each configuration key, so that administrators + can better modify the value. + + * Notifications to interested applications when configuration data + is changed. The notification service works across networks, + affecting all login sessions for a single user. + + * Proper locking so that configuration data doesn't get corrupted + when accessed by multiple applications at the same time. + +WWW: http://live.gnome.org/dconf diff --git a/devel/dconf/pkg-plist b/devel/dconf/pkg-plist new file mode 100644 index 000000000..27b0e51a1 --- /dev/null +++ b/devel/dconf/pkg-plist @@ -0,0 +1,97 @@ +bin/dconf +include/dconf/client/dconf-client.h +include/dconf/common/dconf-changeset.h +include/dconf-dbus-1/dconf-dbus-1.h +include/dconf/common/dconf-paths.h +include/dconf/dconf.h +lib/gio/modules/libdconfsettings.so +lib/gio/modules/giomodule.cache +lib/libdconf.so +lib/libdconf.so.1 +lib/libdconf-dbus-1.so +lib/libdconf-dbus-1.so.0 +libdata/pkgconfig/dconf.pc +libdata/pkgconfig/dconf-dbus-1.pc +libexec/dconf-service +man/man1/dconf-editor.1 +man/man1/dconf-service.1 +share/bash-completion/completions/dconf +share/dbus-1/services/ca.desrt.dconf.service +share/gtk-doc/html/dconf/dconf-DConfChangeset.html +share/gtk-doc/html/dconf/dconf-editor.html +share/gtk-doc/html/dconf/dconf-overview.html +share/gtk-doc/html/dconf/dconf-service.html +share/gtk-doc/html/dconf/dconf-tool.html +share/gtk-doc/html/dconf/programs.html +share/gtk-doc/html/dconf/DConfClient.html +share/gtk-doc/html/dconf/dconf-DConf-Paths.html +share/gtk-doc/html/dconf/annotation-glossary.html +share/gtk-doc/html/dconf/api-index-full.html +share/gtk-doc/html/dconf/ch01.html +share/gtk-doc/html/dconf/dconf.devhelp2 +share/gtk-doc/html/dconf/home.png +share/gtk-doc/html/dconf/index.html +share/gtk-doc/html/dconf/index.sgml +share/gtk-doc/html/dconf/left.png +share/gtk-doc/html/dconf/object-tree.html +share/gtk-doc/html/dconf/right.png +share/gtk-doc/html/dconf/style.css +share/gtk-doc/html/dconf/up.png +share/locale/ar/LC_MESSAGES/dconf.mo +share/locale/as/LC_MESSAGES/dconf.mo +share/locale/be/LC_MESSAGES/dconf.mo +share/locale/bg/LC_MESSAGES/dconf.mo +share/locale/bn_IN/LC_MESSAGES/dconf.mo +share/locale/ca/LC_MESSAGES/dconf.mo +share/locale/ca@valencia/LC_MESSAGES/dconf.mo +share/locale/cs/LC_MESSAGES/dconf.mo +share/locale/da/LC_MESSAGES/dconf.mo +share/locale/de/LC_MESSAGES/dconf.mo +share/locale/el/LC_MESSAGES/dconf.mo +share/locale/en_GB/LC_MESSAGES/dconf.mo +share/locale/eo/LC_MESSAGES/dconf.mo +share/locale/es/LC_MESSAGES/dconf.mo +share/locale/et/LC_MESSAGES/dconf.mo +share/locale/fa/LC_MESSAGES/dconf.mo +share/locale/fi/LC_MESSAGES/dconf.mo +share/locale/fr/LC_MESSAGES/dconf.mo +share/locale/gl/LC_MESSAGES/dconf.mo +share/locale/he/LC_MESSAGES/dconf.mo +share/locale/hi/LC_MESSAGES/dconf.mo +share/locale/hu/LC_MESSAGES/dconf.mo +share/locale/id/LC_MESSAGES/dconf.mo +share/locale/it/LC_MESSAGES/dconf.mo +share/locale/ja/LC_MESSAGES/dconf.mo +share/locale/ko/LC_MESSAGES/dconf.mo +share/locale/lt/LC_MESSAGES/dconf.mo +share/locale/lv/LC_MESSAGES/dconf.mo +share/locale/ml/LC_MESSAGES/dconf.mo +share/locale/mr/LC_MESSAGES/dconf.mo +share/locale/nb/LC_MESSAGES/dconf.mo +share/locale/pa/LC_MESSAGES/dconf.mo +share/locale/pl/LC_MESSAGES/dconf.mo +share/locale/pt/LC_MESSAGES/dconf.mo +share/locale/pt_BR/LC_MESSAGES/dconf.mo +share/locale/ru/LC_MESSAGES/dconf.mo +share/locale/sk/LC_MESSAGES/dconf.mo +share/locale/sl/LC_MESSAGES/dconf.mo +share/locale/sr/LC_MESSAGES/dconf.mo +share/locale/sr@latin/LC_MESSAGES/dconf.mo +share/locale/sv/LC_MESSAGES/dconf.mo +share/locale/ta/LC_MESSAGES/dconf.mo +share/locale/te/LC_MESSAGES/dconf.mo +share/locale/th/LC_MESSAGES/dconf.mo +share/locale/uk/LC_MESSAGES/dconf.mo +share/locale/vi/LC_MESSAGES/dconf.mo +share/locale/zh_CN/LC_MESSAGES/dconf.mo +share/locale/zh_HK/LC_MESSAGES/dconf.mo +share/locale/zh_TW/LC_MESSAGES/dconf.mo +share/vala/vapi/dconf.deps +share/vala/vapi/dconf.vapi +@dirrm share/gtk-doc/html/dconf +@dirrmtry share/gtk-doc/html +@dirrmtry share/gtk-doc +@dirrm include/dconf-dbus-1 +@dirrm include/dconf +@exec %D/bin/gio-querymodules %D/lib/gio/modules 2>/dev/null || /usr/bin/true +@unexec %D/bin/gio-querymodules %D/lib/gio/modules 2>/dev/null || /usr/bin/true |