Nix (Flakes) based Zynqmp Qemu Development Environment
Prerequisites
- You’ll need a working Nix Flakes setup. If you are using NixOS, you can enable Nix Flakes feature by following this link. You can also setup Nix Flakes on non-NixOS distro such as Ubuntu by following this link.
- Next you’ll need to download Zynq UltraScale+ MPSoC Board Support Packages - 2020.1 from Xilinx website. Here is the link. Please download the file called
ZCU102 BSP
. The downloaded file should have the following checksum.$ sha256sum xilinx-zcu102-v2020.1-final.bsp 2045c3b6421ec34d7e943f2227c40e42beb83b65ec67b0128e81c3ac19d000f0 xilinx-zcu102-v2020.1-final.bsp
Getting Started
- Rename the downloaded BSP file and add it to the Nix store.
mv xilinx-zcu102-v2020.1-final.bsp xilinx-zcu102-v2020.1-final.tar.gz nix-store --add-fixed sha256 ./xilinx-zcu102-v2020.1-final.tar.gz
- Enable ViryaOS Cachix repository.
nix shell nixpkgs#cachix -c cachix use viryaos
This will update
~/.config/nix/nix.conf
. - You are all set. You can now
cd
into this directory and start your development shell usingnix develop
.cd zynqmp-qemu-devenv/ nix develop which qemu-system-aarch64
Inside your development shell, you can access the BSP binary blobs using the
XILINX_ZCU102_BINARY_BLOB_PATH
environment variable.echo $XILINX_ZCU102_BINARY_BLOB_PATH