about summary refs log tree commit diff
path: root/pkgs/tools/networking/vde2
diff options
context:
space:
mode:
authorMaximilian Bosch <maximilian@mbosch.me>2019-08-25 18:06:33 +0200
committerFrederik Rietdijk <freddyrietdijk@fridh.nl>2019-08-27 18:19:24 +0200
commitb4a4d98c5297e8d9bfe7b1794e9a875bcb4e339f (patch)
tree0120ebf93b33d8ac334256e65a88f4ba18da4788 /pkgs/tools/networking/vde2
parent1296b10c31b2205990ed7751dd01f103a2b06f70 (diff)
downloadnixlib-b4a4d98c5297e8d9bfe7b1794e9a875bcb4e339f.tar
nixlib-b4a4d98c5297e8d9bfe7b1794e9a875bcb4e339f.tar.gz
nixlib-b4a4d98c5297e8d9bfe7b1794e9a875bcb4e339f.tar.bz2
nixlib-b4a4d98c5297e8d9bfe7b1794e9a875bcb4e339f.tar.lz
nixlib-b4a4d98c5297e8d9bfe7b1794e9a875bcb4e339f.tar.xz
nixlib-b4a4d98c5297e8d9bfe7b1794e9a875bcb4e339f.tar.zst
nixlib-b4a4d98c5297e8d9bfe7b1794e9a875bcb4e339f.zip
vde2: build with `--disable-python` by default
This package explicitly depends on `python2` which will be EOLed at the
end of the year[1]. This package provides python bindings for `python2`,
however the latest release (also used by other distros) is from 2011[2]
and doesn't support v3. For instance, debian ships `vde2` without
`python2` support since Debian Jessie[3].

KVM and QEMU appear to build fine, also NixOS tests and ISO builds are
still functional.

By running `nix-review` against this change, only `xen` packages failed,
but those were already broken on master[4].

Finally it's also worth mentioning that the closure size of `vde2` drops
from 99.5M to 33.5M without `python2` according to `nix path-info -S -h`.

[1] https://pythonclock.org/
[2] https://github.com/virtualsquare/vde-2/releases/tag/vde-2
    (vde.sourceforge.net redirects to this github page)
[3] https://packages.debian.org/en/jessie/vde2
[4] https://hydra.nixos.org/build/99185451, https://hydra.nixos.org/build/99187262
Diffstat (limited to 'pkgs/tools/networking/vde2')
-rw-r--r--pkgs/tools/networking/vde2/default.nix6
1 files changed, 4 insertions, 2 deletions
diff --git a/pkgs/tools/networking/vde2/default.nix b/pkgs/tools/networking/vde2/default.nix
index ac87a5c10e9f..4ea09cd7f006 100644
--- a/pkgs/tools/networking/vde2/default.nix
+++ b/pkgs/tools/networking/vde2/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, openssl, libpcap, python2 }:
+{ stdenv, fetchurl, fetchpatch, openssl, libpcap, python2, withPython ? false }:
 
 stdenv.mkDerivation rec {
   name = "vde2-2.3.2";
@@ -15,8 +15,10 @@ stdenv.mkDerivation rec {
     }
   );
 
+  configureFlags = stdenv.lib.optional (!withPython) [ "--disable-python" ];
 
-  buildInputs = [ openssl libpcap python2 ];
+  buildInputs = [ openssl libpcap ]
+    ++ stdenv.lib.optional withPython python2;
 
   hardeningDisable = [ "format" ];