I created a nix development shell using the procedure from the manual:
sh <(curl -L https://nixos.org/nix/install) --no-daemon
source ~/.nix-profile/etc/profile.d/nix.sh
nix-channel --add https://nixbld.m-labs.hk/channel/custom/artiq/full/artiq-full
nix-channel --remove nixpkgs
nix-channel --add https://nixos.org/channels/nixos-21.05 nixpkgs
nix-channel --update
nix-env -u '*'
git clone https://git.m-labs.hk/M-Labs/nix-scripts.git
git clone https://github.com/m-labs/artiq.git
nix develop git+https://github.com/m-labs/artiq.git
Then I tried these steps to build the firmware:
sudo sysctl -w kernel.unprivileged_userns_clone=1
python -m artiq.gateware.targets.kasli
However, that failed with the following errors in the step "Start Loading Part and Timing Information".
rdiArgs.sh: line 312: 36468 Killed "$RDI_PROG" "$@"
The Vivado version is 2021.1 (according to artiq/flake.nix). Is it correct?
Thanks a lot. Here's the traceback:
Finished Constraint Validation : Time (s): cpu = 00:00:33 ; elapsed = 00:00:34 . Memory (MB): peak = 3074.512 ; gain = 376.254 ; free physical = 775 ; free virtual = 1737
-----------------------------------------
Start Loading Part and Timing Information
-----------------------------------------
Loading part: xc7a100tfgg484-3
/home/jcsz/xilinx/Vivado/2021.1/bin/rdiArgs.sh: line 312: 36468 Killed "$RDI_PROG" "$@"
Parent process (pid 36468) has died. This helper process will now exit
/home/jcsz/xilinx/Vivado/2021.1/bin/rdiArgs.sh: line 312: 36675 Killed "$RDI_PROG" "$@"
/home/jcsz/xilinx/Vivado/2021.1/bin/rdiArgs.sh: line 312: 36510 Segmentation fault (core dumped) "$RDI_PROG" "$@"
segfault in /home/jcsz/xilinx/Vivado/2021.1/bin/unwrapped/lnx64.o/parallel_synth_helper -exec vivado -exec parallel_synth_helper --key LaunchHelperProcessKey_36468_1647787066 --partid xc7a100tfgg484-3 --parent_pid 36468, exiting...
Traceback (most recent call last):
File "/nix/store/hrq2jcbjdwkj39xzahvnnjk93ccrz1pr-python3-3.9.6/lib/python3.9/runpy.py", line 197, in _run_module_as_main
return _run_code(code, main_globals, None,
File "/nix/store/hrq2jcbjdwkj39xzahvnnjk93ccrz1pr-python3-3.9.6/lib/python3.9/runpy.py", line 87, in _run_code
exec(code, run_globals)
File "/nix/store/iwld7h8i95l9jr5dbrlys641ap7qr42n-python3-3.9.6-env/lib/python3.9/site-packages/artiq/gateware/targets/kasli.py", line 701, in <module>
main()
File "/nix/store/iwld7h8i95l9jr5dbrlys641ap7qr42n-python3-3.9.6-env/lib/python3.9/site-packages/artiq/gateware/targets/kasli.py", line 697, in main
build_artiq_soc(soc, builder_argdict(args))
File "/nix/store/iwld7h8i95l9jr5dbrlys641ap7qr42n-python3-3.9.6-env/lib/python3.9/site-packages/artiq/build_soc.py", line 77, in build_artiq_soc
builder.build()
File "/nix/store/iwld7h8i95l9jr5dbrlys641ap7qr42n-python3-3.9.6-env/lib/python3.9/site-packages/misoc/integration/builder.py", line 201, in build
self.soc.build(build_dir=os.path.join(self.output_dir, "gateware"),
File "/nix/store/iwld7h8i95l9jr5dbrlys641ap7qr42n-python3-3.9.6-env/lib/python3.9/site-packages/misoc/integration/soc_core.py", line 222, in build
self.platform.build(self, *args, **kwargs)
File "/nix/store/iwld7h8i95l9jr5dbrlys641ap7qr42n-python3-3.9.6-env/lib/python3.9/site-packages/migen/build/xilinx/platform.py", line 59, in build
return self.toolchain.build(self, *args, **kwargs)
File "/nix/store/iwld7h8i95l9jr5dbrlys641ap7qr42n-python3-3.9.6-env/lib/python3.9/site-packages/migen/build/xilinx/vivado.py", line 222, in build
_run_vivado(build_name)
File "/nix/store/iwld7h8i95l9jr5dbrlys641ap7qr42n-python3-3.9.6-env/lib/python3.9/site-packages/migen/build/xilinx/vivado.py", line 69, in _run_vivado
raise OSError("Subprocess failed")
OSError: Subprocess failed```