From 2bc0f7b701a41aaf2e2f4615ab3dbe66e38573c8 Mon Sep 17 00:00:00 2001 From: Luca Bruno Date: Tue, 8 Apr 2014 13:23:12 +0200 Subject: [PATCH] evolution-data-server: fix gsettings schemas and add dbus service --- nixos/modules/module-list.nix | 1 + .../desktops/gnome3/evolution-data-server.nix | 39 +++++++++++++++++++ .../services/x11/desktop-managers/gnome3.nix | 1 + .../core/evolution-data-server/default.nix | 10 ++++- 4 files changed, 49 insertions(+), 2 deletions(-) create mode 100644 nixos/modules/services/desktops/gnome3/evolution-data-server.nix diff --git a/nixos/modules/module-list.nix b/nixos/modules/module-list.nix index ecf1901d500d..7e69eabdeacf 100644 --- a/nixos/modules/module-list.nix +++ b/nixos/modules/module-list.nix @@ -97,6 +97,7 @@ ./services/databases/virtuoso.nix ./services/databases/monetdb.nix ./services/desktops/accountservice.nix + ./services/desktops/gnome3/evolution-data-server.nix ./services/desktops/gnome3/sushi.nix ./services/games/ghost-one.nix ./services/games/minecraft-server.nix diff --git a/nixos/modules/services/desktops/gnome3/evolution-data-server.nix b/nixos/modules/services/desktops/gnome3/evolution-data-server.nix new file mode 100644 index 000000000000..645921336669 --- /dev/null +++ b/nixos/modules/services/desktops/gnome3/evolution-data-server.nix @@ -0,0 +1,39 @@ +# Evolution Data Server daemon. + +{ config, pkgs, ... }: + +with pkgs.lib; + +{ + + ###### interface + + options = { + + services.gnome3.evolution-data-server = { + + enable = mkOption { + type = types.bool; + default = false; + description = '' + Whether to enable Evolution Data Server, a collection of services for + storing addressbooks and calendars. + ''; + }; + + }; + + }; + + + ###### implementation + + config = mkIf config.services.gnome3.evolution-data-server.enable { + + environment.systemPackages = [ pkgs.evolution_data_server ]; + + services.dbus.packages = [ pkgs.evolution_data_server ]; + + }; + +} diff --git a/nixos/modules/services/x11/desktop-managers/gnome3.nix b/nixos/modules/services/x11/desktop-managers/gnome3.nix index 985884595ab6..626c683f9dc6 100644 --- a/nixos/modules/services/x11/desktop-managers/gnome3.nix +++ b/nixos/modules/services/x11/desktop-managers/gnome3.nix @@ -23,6 +23,7 @@ in { security.polkit.enable = true; services.udisks2.enable = true; services.accounts-daemon.enable = true; + services.gnome3.evolution-data-server.enable = true; services.gnome3.sushi.enable = true; networking.networkmanager.enable = true; services.upower.enable = config.powerManagement.enable; diff --git a/pkgs/desktops/gnome-3/core/evolution-data-server/default.nix b/pkgs/desktops/gnome-3/core/evolution-data-server/default.nix index 0ded30b11abb..9e7d0cb3da0a 100644 --- a/pkgs/desktops/gnome-3/core/evolution-data-server/default.nix +++ b/pkgs/desktops/gnome-3/core/evolution-data-server/default.nix @@ -1,5 +1,5 @@ { fetchurl, stdenv, pkgconfig, gnome3, python, intltool, libsoup, libxml2, libsecret -, p11_kit, db, nspr, nss, libical, gperf, valaSupport ? true, vala }: +, p11_kit, db, nspr, nss, libical, gperf, makeWrapper, valaSupport ? true, vala }: stdenv.mkDerivation rec { @@ -12,13 +12,19 @@ stdenv.mkDerivation rec { buildInputs = with gnome3; [ pkgconfig glib python intltool libsoup libxml2 gtk gnome_online_accounts libsecret - gcr p11_kit db nspr nss libgweather libical libgdata gperf ] + gcr p11_kit db nspr nss libgweather libical libgdata gperf makeWrapper ] ++ stdenv.lib.optional valaSupport vala; # uoa irrelevant for now configureFlags = ["--disable-uoa" "--with-nspr-includes=${nspr}/include/nspr" "--with-nss-includes=${nss}/include/nss"] ++ stdenv.lib.optional valaSupport "--enable-vala-bindings"; + preFixup = '' + for f in "$out/libexec/evolution-addressbook-factory" "$out/libexec/evolution-calendar-factory"; do + wrapProgram $f --prefix XDG_DATA_DIRS : "$GSETTINGS_SCHEMAS_PATH" + done + ''; + meta = with stdenv.lib; { platforms = platforms.linux; };