diff options
author | Sandro <sandro.jaeckel@gmail.com> | 2021-01-13 08:49:29 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-01-13 08:49:29 +0100 |
commit | c7a1cbf5cf17abf9fb9804bdfa14acfb0ebce4c5 (patch) | |
tree | d9cf3c2e28d2e0809973996a11bf86eebb6733da /pkgs/applications/networking | |
parent | 8922b5df79b70057c7b0dea467076271e6207e3f (diff) | |
parent | 1eae217a5ff2fb9738d56d5769a518e0086ff7ec (diff) |
Merge pull request #100642 from oxzi/astroid-plugin-fix
astroid: fix python plugin usage
Diffstat (limited to 'pkgs/applications/networking')
-rw-r--r-- | pkgs/applications/networking/mailreaders/astroid/default.nix | 34 |
1 files changed, 21 insertions, 13 deletions
diff --git a/pkgs/applications/networking/mailreaders/astroid/default.nix b/pkgs/applications/networking/mailreaders/astroid/default.nix index c49866ed9c6c8..570b2d13be14f 100644 --- a/pkgs/applications/networking/mailreaders/astroid/default.nix +++ b/pkgs/applications/networking/mailreaders/astroid/default.nix @@ -1,12 +1,12 @@ -{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig, gnome3, gmime3, webkitgtk +{ lib, stdenv, fetchFromGitHub, cmake, pkg-config, gnome3, gmime3, webkitgtk, ronn , libsass, notmuch, boost, wrapGAppsHook, glib-networking, protobuf, vim_configurable -, gtkmm3, libpeas, gsettings-desktop-schemas -, python3, python3Packages -, vim ? vim_configurable.override { - features = "normal"; - gui = "auto"; - } -, ronn +, gtkmm3, libpeas, gsettings-desktop-schemas, gobject-introspection, python3 + +# vim to be used, should support the GUI mode. +, vim ? vim_configurable.override { features = "normal"; gui = "auto"; } + +# additional python3 packages to be available within plugins +, extraPythonPackages ? [] }: stdenv.mkDerivation rec { @@ -20,22 +20,30 @@ stdenv.mkDerivation rec { sha256 = "11cxbva9ni98gii59xmbxh4c6idcg3mg0pgdsp1c3j0yg7ix0lj3"; }; - nativeBuildInputs = [ cmake ronn pkgconfig wrapGAppsHook ]; + nativeBuildInputs = [ + cmake ronn pkg-config wrapGAppsHook gobject-introspection + python3 python3.pkgs.wrapPython + ]; buildInputs = [ gtkmm3 gmime3 webkitgtk libsass libpeas - python3 python3Packages.pygobject3 + python3 notmuch boost gsettings-desktop-schemas gnome3.adwaita-icon-theme glib-networking protobuf - ] ++ (if vim == null then [] else [ vim ]); + vim + ]; postPatch = '' sed -i "s~gvim ~${vim}/bin/vim -g ~g" src/config.cc sed -i "s~ -geom 10x10~~g" src/config.cc ''; - postInstall = '' - wrapProgram "$out/bin/astroid" --set CHARSET=en_us.UTF-8 + pythonPath = with python3.pkgs; requiredPythonModules [ pygobject3 ] ++ extraPythonPackages; + preFixup = '' + buildPythonPath "$out $pythonPath" + gappsWrapperArgs+=( + --prefix PYTHONPATH : "$program_PYTHONPATH" + ) ''; meta = with lib; { |