--- /dev/null
+# If the .gconf directory already exists, merge it in a single tree.
+# Otherwise, create %gconf-tree.xml so that a single tree is always
+# used.
+
+if [ -x /usr/bin/gconf-merge-tree ]; then
+ GCONF_DIR="$HOME/.gconf"
+ GCONF_TREE="$GCONF_DIR/%gconf-tree.xml"
+ GCONF_DONT="$GCONF_DIR/DONT-MIGRATE"
+
+ if [ -d "$GCONF_DIR" ]
+ then
+ if [ ! -f "$GCONF_TREE" ] && [ ! -f "$GCONF_DONT" ]
+ then
+ /usr/bin/gconf-merge-tree "$GCONF_DIR"
+ killall -q -u "$USER" -s HUP gconfd-2 >/dev/null 2>&1 || true
+ fi
+ else
+ mkdir -p -m 700 "$GCONF_DIR"
+ touch "$GCONF_TREE"
+ chmod 600 "$GCONF_TREE"
+ fi
+fi
Group: X11/Applications
Source0: http://ftp.gnome.org/pub/gnome/sources/GConf/2.12/GConf-%{version}.tar.bz2
# Source0-md5: 247110de013ed24b17cf4191eb6daec5
+Source1: %{name}-merge-tree.xinit
Patch0: %{name}-NO_MAJOR_VERSION.patch
Patch1: %{name}-path.patch
URL: http://www.gnome.org/
%install
rm -rf $RPM_BUILD_ROOT
-install -d $RPM_BUILD_ROOT%{_sysconfdir}/gconf/schemas
+install -d $RPM_BUILD_ROOT%{_sysconfdir}{/gconf/schemas,/X11/xinit/xinitrc.d}
%{__make} install \
DESTDIR=$RPM_BUILD_ROOT
+install %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/X11/xinit/xinitrc.d/GConf2-merge-tree
+
rm -r $RPM_BUILD_ROOT%{_datadir}/locale/no
%find_lang %{name}
%dir %{_libdir}/GConf2
%attr(755,root,root) %{_libdir}/GConf2/lib*.so
%{_sysconfdir}/gconf
+%attr(755,root,root) %{_sysconfdir}/X11/xinit/xinitrc.d/*
%{_datadir}/sgml/gconf
%{_mandir}/man1/*