diff --git a/artiq-fast/pkgs/artiq.nix b/artiq-fast/pkgs/artiq.nix index f2a89c2..78be5a0 100644 --- a/artiq-fast/pkgs/artiq.nix +++ b/artiq-fast/pkgs/artiq.nix @@ -21,6 +21,10 @@ python3Packages.buildPythonPackage rec { wrapQtApp "$out/bin/artiq_session" ''; + # Modifies PATH to pass the wrapped python environment (i.e. python3.withPackages(...) to subprocesses. + # Allows subprocesses using python to find all packages you have installed + makeWrapperArgs = [ ''--run 'if [ ! -z "$NIX_PYTHONPREFIX" ]; then export PATH=$NIX_PYTHONPREFIX/bin:$PATH;fi' '' ]; + checkInputs = [ binutils-or1k outputcheck ]; checkPhase = '' diff --git a/artiq-full/extras.nix b/artiq-full/extras.nix index 9f51628..bc55fc8 100644 --- a/artiq-full/extras.nix +++ b/artiq-full/extras.nix @@ -195,6 +195,9 @@ in sha256 = "165j12k9nnrkf2pv0idcv6xhnp1hnsllna4rps2dssnqgjfaw1ss"; }; propagatedBuildInputs = [ sipyco pkgs.python3Packages.numpy pkgs.python3Packages.aiohttp ]; + # Modifies PATH to pass the wrapped python environment (i.e. python3.withPackages(...) to subprocesses. + # Allows subprocesses using python to find all packages you have installed + makeWrapperArgs = [ ''--run 'if [ ! -z "$NIX_PYTHONPREFIX" ]; then export PATH=$NIX_PYTHONPREFIX/bin:$PATH;fi' '' ]; }; conda-artiq-comtools = condaBuild { name = "conda-artiq-comtools";