diff --git a/pkgs/applications/virtualization/xen/default.nix b/pkgs/applications/virtualization/xen/default.nix index 4c93a277e98..b688bf1e310 100644 --- a/pkgs/applications/virtualization/xen/default.nix +++ b/pkgs/applications/virtualization/xen/default.nix @@ -1,6 +1,6 @@ { stdenv, fetchurl, which, zlib, pkgconfig, SDL, openssl, python , libuuid, gettext, ncurses, dev86, iasl, pciutils, bzip2, xz -, lvm2, utillinux, procps, texinfo, perl }: +, lvm2, utillinux, procps, texinfo, perl, wrapPython, pythonPackages }: with stdenv.lib; @@ -51,9 +51,11 @@ stdenv.mkDerivation { buildInputs = [ which zlib pkgconfig SDL openssl python libuuid gettext ncurses - dev86 iasl pciutils bzip2 xz texinfo perl + dev86 iasl pciutils bzip2 xz texinfo perl wrapPython ]; + pythonPath = [ pythonPackages.curses ]; + makeFlags = "PREFIX=$(out) CONFIG_DIR=/etc"; buildFlags = "xen tools stubdom"; @@ -121,19 +123,7 @@ stdenv.mkDerivation { cp -prvd dist/install/boot $out/boot cp -prvd dist/install/etc $out/etc cp -dR docs/man1 docs/man5 $out/share/man/ - ''; # */ - - postFixup = - '' - # Set the Python search path in all Python scripts. - for fn in $(grep -l '#!.*python' $out/bin/* $out/sbin/*); do - sed -i "$fn" -e "1 a import sys\nsys.path = ['$out/lib/python2.6/site-packages'] + sys.path" - done - - # Remove calls to `env'. - for fn in $(grep -l '#!.*/env.*python' $out/bin/* $out/sbin/*); do - sed -i "$fn" -e "1 s^/nix/store/.*/env.*python^${python}/bin/python^" - done + wrapPythonPrograms ''; # */ meta = { diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index e13a998c35a..27098cca708 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -6714,9 +6714,7 @@ let xdg_utils = callPackage ../tools/X11/xdg-utils { }; - xen = callPackage ../applications/virtualization/xen { - python = pythonFull; - }; + xen = callPackage ../applications/virtualization/xen { }; xfig = callPackage ../applications/graphics/xfig { stdenv = overrideGCC stdenv gcc34;