diff options
-rw-r--r-- | Makefile.am | 7 | ||||
-rw-r--r-- | configure.in | 26 | ||||
-rw-r--r-- | etc/Makefile.am | 2 | ||||
-rw-r--r-- | ohmd/ohm-conf.c | 27 | ||||
-rw-r--r-- | ohmd/ohm-module.c | 13 | ||||
-rw-r--r-- | ohmd/ohm-plugin.c | 6 | ||||
-rwxr-xr-x | ohmd/run-ohm.sh | 14 | ||||
-rw-r--r-- | plugins/glue/acadapter/Makefile.am | 19 | ||||
-rw-r--r-- | plugins/glue/backlight/Makefile.am | 21 | ||||
-rw-r--r-- | plugins/glue/battery/Makefile.am | 19 | ||||
-rw-r--r-- | plugins/glue/buttons/Makefile.am | 19 | ||||
-rw-r--r-- | plugins/glue/dpms/Makefile.am | 21 | ||||
-rw-r--r-- | plugins/glue/idle/Makefile.am | 26 | ||||
-rw-r--r-- | plugins/glue/powerstatus/Makefile.am | 20 | ||||
-rw-r--r-- | plugins/glue/timeremaining/Makefile.am | 20 | ||||
-rw-r--r-- | plugins/glue/xorg/Makefile.am | 21 | ||||
-rw-r--r-- | plugins/glue/xrandr/Makefile.am | 19 | ||||
-rw-r--r-- | plugins/policy/display/Makefile.am | 21 | ||||
-rw-r--r-- | plugins/policy/suspend/Makefile.am | 21 |
19 files changed, 109 insertions, 233 deletions
diff --git a/Makefile.am b/Makefile.am index 8cd791a..03b9ad1 100644 --- a/Makefile.am +++ b/Makefile.am @@ -9,13 +9,10 @@ SUBDIRS = \ etc \ plugins -dbusconfdir = $(sysconfdir)/dbus-1/system.d -dbusconf_DATA = ohm.conf - -pkgconfigdir = $(libdir)/pkgconfig +pkgconfigdir = ${libdir}/pkgconfig pkgconfig_DATA = ohm.pc -dbusdir = $(DBUS_SYS_DIR) +dbusdir = @DBUS_SYS_DIR@ dist_dbus_DATA = ohm.conf EXTRA_DIST = \ diff --git a/configure.in b/configure.in index ef53f64..5409e22 100644 --- a/configure.in +++ b/configure.in @@ -100,14 +100,25 @@ PKG_CHECK_MODULES(GDK, gdk-2.0 >= 2.10.0 gdk-x11-2.0 >= 2.10.0) AC_SUBST(GDK_CFLAGS) AC_SUBST(GDK_LIBS) +AC_SUBST(OHM_CONF_DIR, "\$(sysconfdir)/ohm") + +AC_SUBST(OHM_PLUGIN_CONF_DIR, "\$(OHM_CONF_DIR)/plugins.d") +AC_SUBST(OHM_PLUGIN_DIR, "\$(libdir)/ohm") +AC_SUBST(OHM_PLUGIN_CFLAGS, "-I\$(top_srcdir)/ohmd $GLIB_CFLAGS $DBUS_CFLAGS $GMODULE_CFLAGS") +AC_SUBST(OHM_PLUGIN_LIBS, "$GLIB_LIBS $DBUS_LIBS $GMODULE_LIBS") + dnl --------------------------------------------------------------------------- -dnl - Make paths available for source files +dnl - Where should we put documentation ? dnl --------------------------------------------------------------------------- -AC_SUBST(SYSCONFDIR, $sysconfdir) -AC_SUBST(DATADIR, $datadir) -AC_SUBST(BINDIR, $bindir) -AC_SUBST(LIBDIR, $bindir) -AC_SUBST(SBINDIR, $sbindir) +AC_ARG_WITH(doc-dir, + [AC_HELP_STRING([--with-doc-dir=<dir>], + [directory to install documentation])]) +if ! test -z "$with_doc_dir"; then + DOCDIR="$with_doc_dir/ohm-$VERSION" +else + DOCDIR="\$(docdir\)" +fi +AC_SUBST(DOCDIR) dnl --------------------------------------------------------------------------- dnl - DocBook Documentation @@ -140,11 +151,12 @@ AC_ARG_WITH(dbus-sys, [ --with-dbus-sys=<dir> where D-BUS system.d directory if ! test -z "$with_dbus_sys" ; then DBUS_SYS_DIR="$with_dbus_sys" else - DBUS_SYS_DIR="$SYSCONFDIR/dbus-1/system.d" + DBUS_SYS_DIR="\${sysconfdir}/dbus-1/system.d" fi AC_SUBST(DBUS_SYS_DIR) AC_DEFINE_UNQUOTED(DBUS_SYSTEMD_DIR, "$DBUS_SYS_DIR", [Where system.d dir for DBUS is]) + dnl --------------------------------------------------------------------------- dnl - Some utility functions to make checking for X things easier. dnl --------------------------------------------------------------------------- diff --git a/etc/Makefile.am b/etc/Makefile.am index df0dc88..970fcb6 100644 --- a/etc/Makefile.am +++ b/etc/Makefile.am @@ -1,7 +1,7 @@ EXTRA_DIST = \ $(Data_DATA) -Datadir = $(sysconfdir)/ohm +Datadir = $(OHM_CONF_DIR) Data_DATA = \ modules.ini diff --git a/ohmd/ohm-conf.c b/ohmd/ohm-conf.c index d9ec7e7..ecd2f15 100644 --- a/ohmd/ohm-conf.c +++ b/ohmd/ohm-conf.c @@ -439,7 +439,11 @@ ohm_conf_load_defaults (OhmConf *conf, inifile = g_strdup_printf ("%s.ini", plugin_name); /* generate path for each module */ - filename = g_build_path (G_DIR_SEPARATOR_S, SYSCONFDIR, "ohm", "plugins", inifile, NULL); + filename = getenv ("OHM_CONF_DIR"); + if (!filename) + filename = g_build_path (G_DIR_SEPARATOR_S, SYSCONFDIR, "ohm", "plugins.d", NULL); + + filename = g_build_path (G_DIR_SEPARATOR_S, filename, "plugins.d", inifile, NULL); g_free (inifile); ohm_debug ("Loading %s defaults from %s", plugin_name, filename); @@ -468,20 +472,6 @@ ohm_conf_load_defaults (OhmConf *conf, } /** - * ohm_hash_remove_return: - * FIXME: there must be a better way to do this - **/ -static gboolean -ohm_hash_remove_return (gpointer key, - gpointer value, - gpointer user_data) -{ - OhmConfObj *confobj = (OhmConfObj *) value; - g_object_unref (confobj); - return TRUE; -} - -/** * ohm_conf_finalize: **/ static void @@ -493,9 +483,7 @@ ohm_conf_finalize (GObject *object) conf = OHM_CONF (object); ohm_debug ("freeing conf"); - g_hash_table_foreach_remove (conf->priv->keys, - ohm_hash_remove_return, NULL); - g_hash_table_destroy (conf->priv->keys); + g_hash_table_unref (conf->priv->keys); conf->priv->keys = NULL; g_return_if_fail (conf->priv != NULL); @@ -538,7 +526,8 @@ static void ohm_conf_init (OhmConf *conf) { conf->priv = OHM_CONF_GET_PRIVATE (conf); - conf->priv->keys = g_hash_table_new (g_str_hash, g_str_equal); + conf->priv->keys = g_hash_table_new_full (g_str_hash, g_str_equal, + g_free, g_object_unref); } /** diff --git a/ohmd/ohm-module.c b/ohmd/ohm-module.c index 11dc999..cc75407 100644 --- a/ohmd/ohm-module.c +++ b/ohmd/ohm-module.c @@ -290,13 +290,22 @@ ohm_module_read_defaults (OhmModule *module) keyfile = g_key_file_new (); /* generate path for conf file */ - filename = g_build_path (G_DIR_SEPARATOR_S, SYSCONFDIR, "ohm", "modules.ini", NULL); + filename = getenv ("OHM_CONF_DIR"); + + g_warning ("OHM_CONF_DIR=%s", filename); + + if (!filename) + filename = g_build_path (G_DIR_SEPARATOR_S, SYSCONFDIR, "ohm", "modules.ini", NULL); + else + filename = g_build_path (G_DIR_SEPARATOR_S, filename, "modules.ini", NULL); + + g_warning ("keyfile = %s", filename); /* we can never save the file back unless we remove G_KEY_FILE_NONE */ error = NULL; ret = g_key_file_load_from_file (keyfile, filename, G_KEY_FILE_NONE, &error); if (ret == FALSE) { - g_error ("cannot load keyfile %s", filename); + g_error ("cannot load goddammded keyfile %s", filename); } g_free (filename); diff --git a/ohmd/ohm-plugin.c b/ohmd/ohm-plugin.c index 3a9fda7..e292264 100644 --- a/ohmd/ohm-plugin.c +++ b/ohmd/ohm-plugin.c @@ -124,7 +124,11 @@ ohm_plugin_preload (OhmPlugin *plugin, const gchar *name) ohm_debug ("Trying to load : %s", name); filename = g_strdup_printf ("libohm_%s.so", name); - path = g_build_filename (LIBDIR, "ohm", filename, NULL); + path = getenv ("OHM_PLUGIN_DIR"); + if (path) + path = g_build_filename (path, filename, NULL); + else + path = g_build_filename (LIBDIR, "ohm", filename, NULL); g_free (filename); handle = g_module_open (path, 0); if (!handle) { diff --git a/ohmd/run-ohm.sh b/ohmd/run-ohm.sh index f548cea..c906553 100755 --- a/ohmd/run-ohm.sh +++ b/ohmd/run-ohm.sh @@ -1,3 +1,15 @@ #!/bin/sh -./ohmd --no-daemon --verbose +OHM_TMPDIR=/tmp/run-ohmd-$USER + +if [ "$1" = "--skip-plugin-install" ] ; then + shift +else + make -C ../etc install DESTDIR=$OHM_TMPDIR prefix=/ + make -C ../plugins install DESTDIR=$OHM_TMPDIR prefix=/ +fi + +export OHM_CONF_DIR=$OHM_TMPDIR/etc/ohm +export OHM_PLUGIN_DIR=$OHM_TMPDIR/lib/ohm + +sudo ./ohmd --no-daemon --verbose $@ diff --git a/plugins/glue/acadapter/Makefile.am b/plugins/glue/acadapter/Makefile.am index bdd3a83..d5c669a 100644 --- a/plugins/glue/acadapter/Makefile.am +++ b/plugins/glue/acadapter/Makefile.am @@ -1,21 +1,10 @@ -INCLUDES = \ - -I$(top_srcdir)/ohmd \ - $(GLIB_CFLAGS) \ - $(GMODULE_CFLAGS) \ - -DPACKAGE_DATA_DIR=\""$(datadir)"\" \ - -DPACKAGE_LOCALE_DIR=\""$(prefix)/$(DATADIRNAME)/locale"\" - EXTRA_DIST = $(Data_DATA) -Datadir = $(sysconfdir)/ohm/plugins +Datadir = @OHM_PLUGIN_CONF_DIR@ Data_DATA = acadapter.ini -plugindir = $(libdir)/ohm +plugindir = @OHM_PLUGIN_DIR@ plugin_LTLIBRARIES = libohm_acadapter.la -libohm_acadapterincludedir = $(includedir)/ohm libohm_acadapter_la_SOURCES = ohm-plugin-acadapter.c -libohm_acadapter_la_LIBADD = $(INTLLIBS) +libohm_acadapter_la_LIBADD = @OHM_PLUGIN_LIBS@ libohm_acadapter_la_LDFLAGS = -module -avoid-version - -clean-local: - rm -f *.la - rm -f *~ +libohm_acadapter_la_CFLAGS = @OHM_PLUGIN_CFLAGS@ diff --git a/plugins/glue/backlight/Makefile.am b/plugins/glue/backlight/Makefile.am index 1a506bf..006c6a3 100644 --- a/plugins/glue/backlight/Makefile.am +++ b/plugins/glue/backlight/Makefile.am @@ -1,23 +1,10 @@ -INCLUDES = \ - -I$(top_srcdir)/ohmd \ - $(HAL_CFLAGS) \ - $(GLIB_CFLAGS) \ - $(DBUS_CFLAGS) \ - $(GMODULE_CFLAGS) \ - -DPACKAGE_DATA_DIR=\""$(datadir)"\" \ - -DPACKAGE_LOCALE_DIR=\""$(prefix)/$(DATADIRNAME)/locale"\" - EXTRA_DIST = $(Data_DATA) -Datadir = $(sysconfdir)/ohm/plugins +Datadir = @OHM_PLUGIN_CONF_DIR@ Data_DATA = backlight.ini -plugindir = $(libdir)/ohm +plugindir = @OHM_PLUGIN_DIR@ plugin_LTLIBRARIES = libohm_backlight.la -libohm_backlightincludedir = $(includedir)/ohm libohm_backlight_la_SOURCES = ohm-plugin-backlight.c -libohm_backlight_la_LIBADD = @HAL_LIBS@ @DBUS_LIBS@ $(INTLLIBS) +libohm_backlight_la_LIBADD = @HAL_LIBS@ @OHM_PLUGIN_LIBS@ libohm_backlight_la_LDFLAGS = -module -avoid-version - -clean-local: - rm -f *.la - rm -f *~ +libohm_backlight_CFLAGS = @HAL_CFLAGS@ @OHM_PLUGIN_CFLAGS@ diff --git a/plugins/glue/battery/Makefile.am b/plugins/glue/battery/Makefile.am index 0452857..6d11741 100644 --- a/plugins/glue/battery/Makefile.am +++ b/plugins/glue/battery/Makefile.am @@ -1,21 +1,10 @@ -INCLUDES = \ - -I$(top_srcdir)/ohmd \ - $(GLIB_CFLAGS) \ - $(GMODULE_CFLAGS) \ - -DPACKAGE_DATA_DIR=\""$(datadir)"\" \ - -DPACKAGE_LOCALE_DIR=\""$(prefix)/$(DATADIRNAME)/locale"\" - EXTRA_DIST = $(Data_DATA) -Datadir = $(sysconfdir)/ohm/plugins +Datadir = @OHM_PLUGIN_CONF_DIR@ Data_DATA = battery.ini -plugindir = $(libdir)/ohm +plugindir = @OHM_PLUGIN_DIR@ plugin_LTLIBRARIES = libohm_battery.la -libohm_batteryincludedir = $(includedir)/ohm libohm_battery_la_SOURCES = ohm-plugin-battery.c -libohm_battery_la_LIBADD = $(INTLLIBS) +libohm_battery_la_LIBADD = @OHM_PLUGIN_LIBS@ libohm_battery_la_LDFLAGS = -module -avoid-version - -clean-local: - rm -f *.la - rm -f *~ +libohm_battery_la_CFLAGS = @OHM_PLUGIN_CFLAGS@ diff --git a/plugins/glue/buttons/Makefile.am b/plugins/glue/buttons/Makefile.am index 336f8b2..cca5d63 100644 --- a/plugins/glue/buttons/Makefile.am +++ b/plugins/glue/buttons/Makefile.am @@ -1,21 +1,10 @@ -INCLUDES = \ - -I$(top_srcdir)/ohmd \ - $(GLIB_CFLAGS) \ - $(GMODULE_CFLAGS) \ - -DPACKAGE_DATA_DIR=\""$(datadir)"\" \ - -DPACKAGE_LOCALE_DIR=\""$(prefix)/$(DATADIRNAME)/locale"\" - EXTRA_DIST = $(Data_DATA) -Datadir = $(sysconfdir)/ohm/plugins +Datadir = @OHM_PLUGIN_CONF_DIR@ Data_DATA = buttons.ini -plugindir = $(libdir)/ohm +plugindir = @OHM_PLUGIN_DIR@ plugin_LTLIBRARIES = libohm_buttons.la -libohm_buttonsincludedir = $(includedir)/ohm libohm_buttons_la_SOURCES = ohm-plugin-buttons.c -libohm_buttons_la_LIBADD = $(INTLLIBS) +libohm_buttons_la_LIBADD = @OHM_PLUGIN_LIBS@ libohm_buttons_la_LDFLAGS = -module -avoid-version - -clean-local: - rm -f *.la - rm -f *~ +libohm_buttons_la_CFLAGS = @OHM_PLUGIN_CFLAGS@ diff --git a/plugins/glue/dpms/Makefile.am b/plugins/glue/dpms/Makefile.am index cdff7c1..1deb0c3 100644 --- a/plugins/glue/dpms/Makefile.am +++ b/plugins/glue/dpms/Makefile.am @@ -1,23 +1,10 @@ -INCLUDES = \ - -I$(top_srcdir)/ohmd \ - $(GLIB_CFLAGS) \ - $(DBUS_CFLAGS) \ - $(GMODULE_CFLAGS) \ - -DPACKAGE_DATA_DIR=\""$(datadir)"\" \ - -DPACKAGE_LOCALE_DIR=\""$(prefix)/$(DATADIRNAME)/locale"\" - EXTRA_DIST = $(Data_DATA) -Datadir = $(sysconfdir)/ohm/plugins +Datadir = @OHM_PLUGIN_CONF_DIR@ Data_DATA = dpms.ini -plugindir = $(libdir)/ohm +plugindir = @OHM_PLUGIN_DIR@ plugin_LTLIBRARIES = libohm_dpms.la -libohm_dpmsincludedir = $(includedir)/ohm libohm_dpms_la_SOURCES = ohm-plugin-dpms.c -libohm_dpms_la_LIBADD = @DBUS_LIBS@ $(INTLLIBS) $(OHM_X11_LIBS) - +libohm_dpms_la_LIBADD = @OHM_PLUGIN_LIBS@ @OHM_X11_LIBS@ libohm_dpms_la_LDFLAGS = -module -avoid-version - -clean-local: - rm -f *.la - rm -f *~ +libohm_dpms_la_CFLAGS = @OHM_PLUGIN_CFLAGS@ diff --git a/plugins/glue/idle/Makefile.am b/plugins/glue/idle/Makefile.am index aa090ac..c5d332d 100644 --- a/plugins/glue/idle/Makefile.am +++ b/plugins/glue/idle/Makefile.am @@ -1,27 +1,13 @@ -INCLUDES = \ - -I$(top_srcdir)/ohmd \ - $(GLIB_CFLAGS) \ - $(GDK_CFLAGS) \ - $(DBUS_CFLAGS) \ - $(GMODULE_CFLAGS) \ - -I$(top_srcdir)/libidletime \ - -DPACKAGE_DATA_DIR=\""$(datadir)"\" \ - -DPACKAGE_LOCALE_DIR=\""$(prefix)/$(DATADIRNAME)/locale"\" - -LOCAL_LIBIDLETIME_LIBS = \ - $(top_builddir)/libidletime/libidletime.la +LOCAL_LIBIDLETIME_LIBS = $(top_builddir)/libidletime/libidletime.la +LOCAL_LIBIDLETIME_CFLAGS = -I$(top_srcdir)/libidletime EXTRA_DIST = $(Data_DATA) -Datadir = $(sysconfdir)/ohm/plugins +Datadir = @OHM_PLUGIN_CONF_DIR@ Data_DATA = idle.ini -plugindir = $(libdir)/ohm +plugindir = @OHM_PLUGIN_DIR@ plugin_LTLIBRARIES = libohm_idle.la -libohm_idleincludedir = $(includedir)/ohm libohm_idle_la_SOURCES = ohm-plugin-idle.c -libohm_idle_la_LIBADD = @DBUS_LIBS@ $(INTLLIBS) $(LOCAL_LIBIDLETIME_LIBS) +libohm_idle_la_LIBADD = @OHM_PLUGIN_LIBS@ $(LOCAL_LIBIDLETIME_LIBS) libohm_idle_la_LDFLAGS = -module -avoid-version - -clean-local: - rm -f *.la - rm -f *~ +libohm_idle_la_CFLAGS = @OHM_PLUGIN_CFLAGS@ $(LOCAL_LIBIDLETIME_CFLAGS) diff --git a/plugins/glue/powerstatus/Makefile.am b/plugins/glue/powerstatus/Makefile.am index c544813..538aa98 100644 --- a/plugins/glue/powerstatus/Makefile.am +++ b/plugins/glue/powerstatus/Makefile.am @@ -1,22 +1,10 @@ -INCLUDES = \ - -I$(top_srcdir)/ohmd \ - $(GLIB_CFLAGS) \ - $(DBUS_CFLAGS) \ - $(GMODULE_CFLAGS) \ - -DPACKAGE_DATA_DIR=\""$(datadir)"\" \ - -DPACKAGE_LOCALE_DIR=\""$(prefix)/$(DATADIRNAME)/locale"\" - EXTRA_DIST = $(Data_DATA) -Datadir = $(sysconfdir)/ohm/plugins +Datadir = @OHM_PLUGIN_CONF_DIR@ Data_DATA = powerstatus.ini -plugindir = $(libdir)/ohm +plugindir = @OHM_PLUGIN_DIR@ plugin_LTLIBRARIES = libohm_powerstatus.la -libohm_powerstatusincludedir = $(includedir)/ohm libohm_powerstatus_la_SOURCES = ohm-plugin-powerstatus.c -libohm_powerstatus_la_LIBADD = @DBUS_LIBS@ $(INTLLIBS) +libohm_powerstatus_la_LIBADD = @OHM_PLUGIN_LIBS@ libohm_powerstatus_la_LDFLAGS = -module -avoid-version - -clean-local: - rm -f *.la - rm -f *~ +libohm_powerstatus_la_CFLAGS = @OHM_PLUGIN_CFLAGS@ diff --git a/plugins/glue/timeremaining/Makefile.am b/plugins/glue/timeremaining/Makefile.am index 1d5c9ad..56a4106 100644 --- a/plugins/glue/timeremaining/Makefile.am +++ b/plugins/glue/timeremaining/Makefile.am @@ -1,22 +1,10 @@ -INCLUDES = \ - -I$(top_srcdir)/ohmd \ - $(GLIB_CFLAGS) \ - $(DBUS_CFLAGS) \ - $(GMODULE_CFLAGS) \ - -DPACKAGE_DATA_DIR=\""$(datadir)"\" \ - -DPACKAGE_LOCALE_DIR=\""$(prefix)/$(DATADIRNAME)/locale"\" - EXTRA_DIST = $(Data_DATA) -Datadir = $(sysconfdir)/ohm/plugins +Datadir = @OHM_PLUGIN_CONF_DIR@ Data_DATA = timeremaining.ini -plugindir = $(libdir)/ohm +plugindir = @OHM_PLUGIN_DIR@ plugin_LTLIBRARIES = libohm_timeremaining.la -libohm_timeremainingincludedir = $(includedir)/ohm libohm_timeremaining_la_SOURCES = ohm-plugin-timeremaining.c -libohm_timeremaining_la_LIBADD = @DBUS_LIBS@ $(INTLLIBS) +libohm_timeremaining_la_LIBADD = @OHM_PLUGIN_LIBS@ libohm_timeremaining_la_LDFLAGS = -module -avoid-version - -clean-local: - rm -f *.la - rm -f *~ +libohm_timeremaining_la_CFLAGS= @OHM_PLUGIN_CFLAGS@ diff --git a/plugins/glue/xorg/Makefile.am b/plugins/glue/xorg/Makefile.am index cd30f3f..d314d37 100644 --- a/plugins/glue/xorg/Makefile.am +++ b/plugins/glue/xorg/Makefile.am @@ -1,23 +1,10 @@ -INCLUDES = \ - -I$(top_srcdir)/ohmd \ - $(GLIB_CFLAGS) \ - $(DBUS_CFLAGS) \ - $(GMODULE_CFLAGS) \ - -DPACKAGE_DATA_DIR=\""$(datadir)"\" \ - -DPACKAGE_LOCALE_DIR=\""$(prefix)/$(DATADIRNAME)/locale"\" - EXTRA_DIST = $(Data_DATA) -Datadir = $(sysconfdir)/ohm/plugins +Datadir = @OHM_PLUGIN_CONF_DIR@ Data_DATA = xorg.ini -plugindir = $(libdir)/ohm +plugindir = @OHM_PLUGIN_DIR@ plugin_LTLIBRARIES = libohm_xorg.la -libohm_xorgincludedir = $(includedir)/ohm libohm_xorg_la_SOURCES = ohm-plugin-xorg.c -libohm_xorg_la_LIBADD = @DBUS_LIBS@ $(INTLLIBS) $(OHM_X11_LIBS) - +libohm_xorg_la_LIBADD = @OHM_PLUGIN_LIBS@ @OHM_X11_LIBS@ libohm_xorg_la_LDFLAGS = -module -avoid-version - -clean-local: - rm -f *.la - rm -f *~ +libohm_xorg_la_CFLAGS = @OHM_PLUGIN_CFLAGS@ diff --git a/plugins/glue/xrandr/Makefile.am b/plugins/glue/xrandr/Makefile.am index 685de30..d854c22 100644 --- a/plugins/glue/xrandr/Makefile.am +++ b/plugins/glue/xrandr/Makefile.am @@ -1,21 +1,10 @@ -INCLUDES = \ - -I$(top_srcdir)/ohmd \ - $(GLIB_CFLAGS) \ - $(GMODULE_CFLAGS) \ - -DPACKAGE_DATA_DIR=\""$(datadir)"\" \ - -DPACKAGE_LOCALE_DIR=\""$(prefix)/$(DATADIRNAME)/locale"\" - EXTRA_DIST = $(Data_DATA) -Datadir = $(sysconfdir)/ohm/plugins +Datadir = @OHM_PLUGIN_CONF_DIR@ Data_DATA = xrandr.ini -plugindir = $(libdir)/ohm +plugindir = @OHM_PLUGIN_DIR@ plugin_LTLIBRARIES = libohm_xrandr.la -libohm_xrandrincludedir = $(includedir)/ohm libohm_xrandr_la_SOURCES = ohm-plugin-xrandr.c -libohm_xrandr_la_LIBADD = $(INTLLIBS) +libohm_xrandr_la_LIBADD = @OHM_PLUGIN_LIBS@ libohm_xrandr_la_LDFLAGS = -module -avoid-version - -clean-local: - rm -f *.la - rm -f *~ +libohm_xrandr_la_CFLAGS = @OHM_PLUGIN_CFLAGS@ diff --git a/plugins/policy/display/Makefile.am b/plugins/policy/display/Makefile.am index c4f5319..426eb0a 100644 --- a/plugins/policy/display/Makefile.am +++ b/plugins/policy/display/Makefile.am @@ -1,23 +1,10 @@ -INCLUDES = \ - -I$(top_srcdir)/ohmd \ - $(HAL_CFLAGS) \ - $(GLIB_CFLAGS) \ - $(DBUS_CFLAGS) \ - $(GMODULE_CFLAGS) \ - -DPACKAGE_DATA_DIR=\""$(datadir)"\" \ - -DPACKAGE_LOCALE_DIR=\""$(prefix)/$(DATADIRNAME)/locale"\" - EXTRA_DIST = $(Data_DATA) -Datadir = $(sysconfdir)/ohm/plugins +Datadir = $(OHM_PLUGIN_CONF_DIR) Data_DATA = display.ini -plugindir = $(libdir)/ohm +plugindir = $(OHM_PLUGIN_DIR) plugin_LTLIBRARIES = libohm_display.la -libohm_displayincludedir = $(includedir)/ohm libohm_display_la_SOURCES = ohm-plugin-display.c -libohm_display_la_LIBADD = @HAL_LIBS@ @DBUS_LIBS@ $(INTLLIBS) +libohm_display_la_LIBADD = @HAL_LIBS@ @OHM_PLUGIN_LIBS@ libohm_display_la_LDFLAGS = -module -avoid-version - -clean-local: - rm -f *.la - rm -f *~ +libohm_display_la_CFLAGS = @HAL_CFLAGS@ @OHM_PLUGIN_CFLAGS@ diff --git a/plugins/policy/suspend/Makefile.am b/plugins/policy/suspend/Makefile.am index 891199b..ecf1159 100644 --- a/plugins/policy/suspend/Makefile.am +++ b/plugins/policy/suspend/Makefile.am @@ -1,23 +1,10 @@ -INCLUDES = \ - -I$(top_srcdir)/ohmd \ - $(HAL_CFLAGS) \ - $(GLIB_CFLAGS) \ - $(DBUS_CFLAGS) \ - $(GMODULE_CFLAGS) \ - -DPACKAGE_DATA_DIR=\""$(datadir)"\" \ - -DPACKAGE_LOCALE_DIR=\""$(prefix)/$(DATADIRNAME)/locale"\" - EXTRA_DIST = $(Data_DATA) -Datadir = $(sysconfdir)/ohm/plugins +Datadir = @OHM_PLUGIN_CONF_DIR@ Data_DATA = suspend.ini -plugindir = $(libdir)/ohm +plugindir = @OHM_PLUGIN_DIR@ plugin_LTLIBRARIES = libohm_suspend.la -libohm_suspendincludedir = $(includedir)/ohm libohm_suspend_la_SOURCES = ohm-plugin-suspend.c -libohm_suspend_la_LIBADD = @HAL_LIBS@ @DBUS_LIBS@ $(INTLLIBS) +libohm_suspend_la_LIBADD = @HAL_LIBS@ @OHM_PLUGIN_LIBS@ libohm_suspend_la_LDFLAGS = -module -avoid-version - -clean-local: - rm -f *.la - rm -f *~ +libohm_suspend_la_CFLAGS = @HAL_CFLAGS@ @OHM_PLUGIN_CFLAGS@ |