b450903751
GitOrigin-RevId: 74a1793c659d09d7cf738005308b1f86c90cb59b
25 lines
559 B
Nix
25 lines
559 B
Nix
{ stdenv, python }:
|
|
|
|
stdenv.mkDerivation {
|
|
pname = "python-recursive-pth-loader";
|
|
version = "1.0";
|
|
|
|
dontUnpack = true;
|
|
|
|
buildInputs = [ python ];
|
|
|
|
patchPhase = "cat ${./sitecustomize.py} > sitecustomize.py";
|
|
|
|
buildPhase = "${python.pythonForBuild}/bin/${python.pythonForBuild.executable} -m compileall .";
|
|
|
|
installPhase =
|
|
''
|
|
dst=$out/lib/${python.libPrefix}/site-packages
|
|
mkdir -p $dst
|
|
cp sitecustomize.* $dst/
|
|
'';
|
|
|
|
meta = {
|
|
description = "Enable recursive processing of pth files anywhere in sys.path";
|
|
};
|
|
}
|