From 343f11b73bbd61addbbe71c6e03ee71301ccd202 Mon Sep 17 00:00:00 2001 From: Stephan Maka Date: Sat, 13 Apr 2019 20:32:06 +0200 Subject: [PATCH] move list of conda dependencies to artiq/conda-artiq-deps.nix --- artiq/conda-artiq-deps.nix | 19 +++++++++++++++++++ artiq/conda-artiq.nix | 18 +----------------- artiq/windows/install.nix | 26 ++++---------------------- 3 files changed, 24 insertions(+), 39 deletions(-) create mode 100644 artiq/conda-artiq-deps.nix diff --git a/artiq/conda-artiq-deps.nix b/artiq/conda-artiq-deps.nix new file mode 100644 index 0000000..e1371e3 --- /dev/null +++ b/artiq/conda-artiq-deps.nix @@ -0,0 +1,19 @@ +[ + "python >=3.5.3,<3.6" + "llvmlite-artiq 0.23.0.dev py35_5" + "binutils-or1k-linux >=2.27" + "pythonparser >=1.1" + "openocd 0.10.0 6" + "scipy" + "numpy" + "prettytable" + "asyncserial" + "h5py 2.8" + "python-dateutil" + "pyqt >=5.5" + "quamash" + "pyqtgraph 0.10.0" + "pygit2" + "aiohttp >=3" + "levenshtein" +] diff --git a/artiq/conda-artiq.nix b/artiq/conda-artiq.nix index 2948f7d..b419376 100644 --- a/artiq/conda-artiq.nix +++ b/artiq/conda-artiq.nix @@ -39,23 +39,7 @@ let requirements: run: - - python >=3.5.3,<3.6 - - llvmlite-artiq 0.23.0.dev py35_5 - - binutils-or1k-linux >=2.27 - - pythonparser >=1.1 - - openocd 0.10.0 6 - - scipy - - numpy - - prettytable - - asyncserial - - h5py 2.8 - - python-dateutil - - pyqt >=5.5 - - quamash - - pyqtgraph 0.10.0 - - pygit2 - - aiohttp >=3 - - levenshtein + ${lib.concatStringsSep "\n" (map (s: " - ${s}") (import ./conda-artiq-deps.nix))} about: home: https://m-labs.hk/artiq diff --git a/artiq/windows/install.nix b/artiq/windows/install.nix index e0b4ae2..f885bef 100644 --- a/artiq/windows/install.nix +++ b/artiq/windows/install.nix @@ -45,28 +45,10 @@ let "${src}" "${sshUser}@localhost:${target}" ''; condaEnv = "artiq-env"; - condaDependencies = [ - "python >=3.5.3,<3.6" - "llvmlite-artiq 0.23.0.dev py35_5" - "binutils-or1k-linux >=2.27" - "pythonparser >=1.1" - "openocd 0.10.0 6" - "scipy" - "numpy" - "prettytable" - "asyncserial" - "h5py 2.8" - "python-dateutil" - "pyqt >=5.5" - "quamash" - "pyqtgraph 0.10.0" - "pygit2" - "aiohttp >=3" - "levenshtein" - ]; - condaPkgSpecs = + condaDepSpecs = builtins.concatStringsSep " " - (map (s: "\"${s}\"") condaDependencies); + (map (s: "\"${s}\"") + (import ../conda-artiq-deps.nix)); in stdenv.mkDerivation { name = "windows-installer"; @@ -127,7 +109,7 @@ stdenv.mkDerivation { ${ssh "miniconda\\Scripts\\conda update -y conda"} ${ssh "miniconda\\Scripts\\conda update -y --all"} ${ssh "miniconda\\Scripts\\conda create -y -n ${condaEnv}"} - ${ssh "miniconda\\Scripts\\conda install -y -n ${condaEnv} ${condaPkgSpecs}"} + ${ssh "miniconda\\Scripts\\conda install -y -n ${condaEnv} ${condaDepSpecs}"} ${ssh "shutdown /p /f"} echo "Waiting for qemu exit"