2
0
mirror of https://github.com/m-labs/artiq.git synced 2024-12-22 18:04:03 +08:00
artiq/nix
2019-02-09 14:23:36 +08:00
..
pkgs nix: use nixpkgs cargo 2019-02-09 14:19:34 +08:00
artiq-board.nix nix/artiq-board: build tester variant 2019-02-09 14:23:36 +08:00
artiq-dev.nix nix: use nixpkgs cargo 2019-02-09 14:19:34 +08:00
conda-build.nix nix: cleanup 2019-02-09 10:24:22 +08:00
default.nix nix: use nixpkgs cargo 2019-02-09 14:19:34 +08:00
fetch-llvm-clang.nix nix: add Clang back 2018-08-16 13:03:55 +08:00
README.rst nix: support reusing dev environment in build scripts 2019-01-23 21:59:39 +08:00
release.nix nix: cleanup 2019-02-09 10:24:22 +08:00
shell-dev.nix nix: cleanup 2019-02-09 10:24:22 +08:00
shell.nix nix: do not install development packages in user environment 2019-01-01 23:35:55 +08:00

Use ARTIQ via the Nix Package Manager
=====================================

These instructions provide an alternative route to install ARTIQ for people who do not wish to use conda.

This sets up an environment suitable for using ARTIQ, including the ARTIQ-Python compiler, device drivers, and the graphical user interfaces. This works correctly on Linux, and partially works (but not to a level that we would consider usable) with WSL introduced in Windows 10.

* Install the Nix package manager

  * many Linux distros already have a package for the `Nix package manager <http://nixos.org/nix/>`_

    * for example: ``$ apt-get install nix``

  * if you would like to install via sh

    * $ ``wget https://nixos.org/nix/install``

    * $ ``sh install``

    * $ ``source ~/.nix-profile/etc/profile.d/nix.sh``

* $ ``git clone github.com/m-labs/artiq``
* $ ``cd artiq/nix``
* $ ``nix-env -i -f default.nix``

The above command will setup your entire environment. Note that it will compile LLVM, which uses a lot of CPU time and disk space.

ARTIQ development environment with Nix
======================================

Run ``nix-shell shell-dev.nix`` to obtain an environment containing Migen, MiSoC, Microscope, jesd204b, Clang, Rust, Cargo, and OpenOCD in addition to the user environment above.

This creates a FHS chroot environment in order to simplify the installation and patching of Xilinx Vivado (it needs to be installed manually e.g. in your home folder).

You can then build the firmware and gateware with a command such as ``python -m artiq.gateware.targets.kasli --gateware-toolchain-path ~/Xilinx/Vivado``.