summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthias Clasen <mclasen@redhat.com>2008-09-26 00:52:00 +0200
committerLennart Poettering <lennart@poettering.net>2008-09-26 00:54:12 +0200
commit6c0ffa3f480ff1d97d897128545c275f167263e8 (patch)
tree097a992e19fdc94bfc4715cf85e08058d3d0c8ee
parentf855a098f537fd8d4cb381f07ea5badc9646515c (diff)
Enable canberra-gtk-module via GConf
The most recent version of gnome-settings-daemon now supports activating Gtk+ modules via a GConf setting. We should be using this to activate our Gtk+ module automatically on install. Signed-off-by: Lennart Poettering <lennart@poettering.net>
-rw-r--r--Makefile.am14
-rw-r--r--configure.ac5
-rw-r--r--libcanberra.schemas16
3 files changed, 35 insertions, 0 deletions
diff --git a/Makefile.am b/Makefile.am
index 3c01de2..27c382d 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -31,6 +31,20 @@ if HAVE_GTK
pkgconfig_DATA += libcanberra-gtk.pc
endif
+schemasdir = $(GCONF_SCHEMA_FILE_DIR)
+schemas_DATA = libcanberra.schemas
+
+if GCONF_SCHEMAS_INSTALL
+install-data-local:
+ if test -z "$(DESTDIR)" ; then \
+ for p in $(schemas_DATA) ; do \
+ GCONF_CONFIG_SOURCE=$(GCONF_SCHEMA_CONFIG_SOURCE) $(GCONFTOOL) --makefile-install-rule $(top_builddir)/data/$$p ; \
+ done \
+ fi
+else
+install-data-local:
+endif
+
DISTCHECK_CONFIGURE_FLAGS=--enable-gtk-doc
ACLOCAL_AMFLAGS = -I m4
diff --git a/configure.ac b/configure.ac
index 1a90942..6bfac1e 100644
--- a/configure.ac
+++ b/configure.ac
@@ -72,6 +72,11 @@ AC_SUBST(LTDLINCL)
AC_SUBST(LIBLTDL)
AC_CONFIG_SUBDIRS(libltdl)
+### gconf stuff ###
+
+AC_PATH_PROG(GCONFTOOL, gconftool-2)
+AM_GCONF_SOURCE_2
+
#### Determine build environment ####
os_is_win32=0
diff --git a/libcanberra.schemas b/libcanberra.schemas
new file mode 100644
index 0000000..7002844
--- /dev/null
+++ b/libcanberra.schemas
@@ -0,0 +1,16 @@
+<?xml version="1.0"?>
+<gconfschemafile>
+ <schemalist>
+ <schema>
+ <key>/schemas/apps/gnome_settings_daemon/gtk-modules/canberra-gtk-module</key>
+ <applyto>/apps/gnome_settings_daemon/gtk-modules/canberra-gtk-module</applyto>
+ <owner>libcanberra</owner>
+ <type>bool</type>
+ <default>true</default>
+ <locale name="C">
+ <short>GTK+ module for event sounds</short>
+ <long>This key determines the GTK+ module to load for event sound support.</long>
+ </locale>
+ </schema>
+ </schemalist>
+</gconfschemafile>