From 85961441eea85b37b53fcbc35d83dd5989d9db70 Mon Sep 17 00:00:00 2001 From: Bruce Toll <4109762+tollb@users.noreply.github.com> Date: Sat, 26 Jan 2019 10:23:23 -0500 Subject: gnumeric: fix wrapping Incorporate wrapGAppsHook so that all gnumeric binaries are wrapped, following the convention used by many gnome applications. This addresses two issues: 1. The packaged ssconvert, ssdiff, ssgrep, and ssindex executables in bin are not currently wrapped so some expected environment variables including XDG_DATA_DIRS and GIO_EXTRA_MODULES are not set. The result is many warnings on stderr when running these commands, e.g. ================================================================== CRITICAL **:...go_conf_add_monitor: assertion 'node || key' failed CRITICAL **:...go_conf_get_node: assertion 'parent || key' failed WARNING **:...unknown GOConfMonitor id. ================================================================== 2. None of the binaries, including gnumeric, currently wrap the environment variable GDK_PIXBUF_MODULE_FILE. This can cause segfaults if an incompatible GDK_PIXBUF_MODULE_FILE is already set in the environment (e.g. by plasma5). This could be encountered running a nixos pre-19.03 gnumeric binary from a nixos 18.09 KDE session. --- pkgs/applications/office/gnumeric/default.nix | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) (limited to 'pkgs/applications/office/gnumeric') diff --git a/pkgs/applications/office/gnumeric/default.nix b/pkgs/applications/office/gnumeric/default.nix index 5d0985b0ba2e..e42777bdd006 100644 --- a/pkgs/applications/office/gnumeric/default.nix +++ b/pkgs/applications/office/gnumeric/default.nix @@ -1,5 +1,5 @@ { stdenv, fetchurl, pkgconfig, intltool, perlPackages -, goffice, gnome3, makeWrapper, gtk3, bison, pythonPackages +, goffice, gnome3, wrapGAppsHook, gtk3, bison, pythonPackages , itstool }: @@ -16,7 +16,7 @@ in stdenv.mkDerivation rec { configureFlags = [ "--disable-component" ]; - nativeBuildInputs = [ pkgconfig intltool bison itstool makeWrapper ]; + nativeBuildInputs = [ pkgconfig intltool bison itstool wrapGAppsHook ]; # ToDo: optional libgda, introspection? buildInputs = [ @@ -26,14 +26,6 @@ in stdenv.mkDerivation rec { enableParallelBuilding = true; - preFixup = '' - for f in "$out"/bin/gnumeric-*; do - wrapProgram $f \ - --prefix XDG_DATA_DIRS : "$XDG_ICON_DIRS:$GSETTINGS_SCHEMAS_PATH" \ - ${stdenv.lib.optionalString (!stdenv.isDarwin) "--prefix GIO_EXTRA_MODULES : '${stdenv.lib.getLib gnome3.dconf}/lib/gio/modules'"} - done - ''; - passthru = { updateScript = gnome3.updateScript { packageName = pname; -- cgit 1.4.1