Commit d79fa6cf authored by Stefan Walter's avatar Stefan Walter

Add DBUS activation

    * acinclude.m4 (added):
    * configure.in:
    * daemon/Makefile.am:
    * daemon/org.gnome.seahorse.service.in: Add DBUS activation
parent 29081090
2006-04-12 Nate Nielsen <nielsen@memberwebs.com>
* acinclude.m4 (added):
* configure.in:
* daemon/Makefile.am:
* daemon/org.gnome.seahorse.service.in: Add DBUS activation
2006-04-12 Nate Nielsen <nielsen@memberwebs.com>
* Makefile.am:
......
dnl AS_AC_EXPAND(VAR, CONFIGURE_VAR)
dnl
dnl example
dnl AS_AC_EXPAND(SYSCONFDIR, $sysconfdir)
dnl will set SYSCONFDIR to /usr/local/etc if prefix=/usr/local
AC_DEFUN([AS_AC_EXPAND],
[
EXP_VAR=[$1]
FROM_VAR=[$2]
dnl first expand prefix and exec_prefix if necessary
prefix_save=$prefix
exec_prefix_save=$exec_prefix
dnl if no prefix given, then use /usr/local, the default prefix
if test "x$prefix" = "xNONE"; then
prefix=$ac_default_prefix
fi
dnl if no exec_prefix given, then use prefix
if test "x$exec_prefix" = "xNONE"; then
exec_prefix=$prefix
fi
full_var="$FROM_VAR"
dnl loop until it doesn't change anymore
while true; do
new_full_var="`eval echo $full_var`"
if test "x$new_full_var"="x$full_var"; then break; fi
full_var=$new_full_var
done
dnl clean up
full_var=$new_full_var
AC_SUBST([$1], "$full_var")
dnl restore prefix and exec_prefix
prefix=$prefix_save
exec_prefix=$exec_prefix_save
])
......@@ -444,6 +444,12 @@ else
AC_SUBST(LIBCRYPTUI_CFLAGS)
AC_SUBST(LIBCRYPTUI_LIBS)
AS_AC_EXPAND(DATADIR, $datadir)
DBUS_SERVICES_DIR="$DATADIR/dbus-1/services"
AC_SUBST(DBUS_SERVICES_DIR)
AC_DEFINE_UNQUOTED(DBUS_SERVICES_DIR, "$DBUS_SERVICES_DIR", [Where services dir for DBUS is])
fi
fi
......
......@@ -8,4 +8,4 @@ seahorse-daemon
seahorse-service-bindings.h
seahorse-service-keyset-bindings.h
seahorse-service-crypto-bindings.h
*.service
......@@ -61,6 +61,7 @@ EXTRA_DIST = \
CLEANFILES = *.gladep* *.bak
# DBUS binding files
seahorse-service-bindings.h: seahorse-service.xml
dbus-binding-tool --prefix=seahorse_service --mode=glib-server --output=$@ $(srcdir)/$<
seahorse-service-keyset-bindings.h: seahorse-service-keyset.xml
......@@ -68,5 +69,15 @@ seahorse-service-keyset-bindings.h: seahorse-service-keyset.xml
seahorse-service-crypto-bindings.h: seahorse-service-crypto.xml
dbus-binding-tool --prefix=seahorse_service_crypto --mode=glib-server --output=$@ $(srcdir)/$<
# Dbus service file
servicedir = $(DBUS_SERVICES_DIR)
service_in_files = org.gnome.seahorse.service.in
service_DATA = $(service_in_files:.service.in=.service)
# Rule to make the service file with bindir expanded
$(service_DATA): $(service_in_files) Makefile
@sed -e "s|\@bindir\@|$(bindir)|" $< > $@
# Make the daemon setuid
install-exec-hook:
chmod u+s $(DESTDIR)$(bindir)/seahorse-daemon
[D-BUS Service]
Name=org.gnome.seahorse
Exec=@bindir@/seahorse-daemon
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment