From 26db63c809798d53ccb2bee265ec36f0291b9af8 Mon Sep 17 00:00:00 2001 From: John-Mark Gurney Date: Mon, 18 May 2020 12:29:03 -0700 Subject: [PATCH] Set of scripts to automatically install Xilinx Vivado into a VM, and provide a way to launch it from the command line. This is tested on MacOSX w/ VirtualBox. It also installs the Xilinx drivers and has been tested in programming a Digilent Cora Z7 board. --- .gitignore | 6 ++++++ Makefile | 29 +++++++++++++++++++++++++++++ README.md | 14 ++++++++++++++ Vagrantfile | 13 +++++++++++++ bootstrap.sh | 3 +++ install_config.txt | 33 +++++++++++++++++++++++++++++++++ 6 files changed, 98 insertions(+) create mode 100644 .gitignore create mode 100644 Makefile create mode 100644 README.md create mode 100644 Vagrantfile create mode 100644 bootstrap.sh create mode 100644 install_config.txt diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..1f60ed8 --- /dev/null +++ b/.gitignore @@ -0,0 +1,6 @@ +Xilinx_Unified_2019.2_1106_2127_Lin64.bin +.extract +.token +.install +.vagrant +.DS_Store diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..f591d78 --- /dev/null +++ b/Makefile @@ -0,0 +1,29 @@ +# Installation instructions: +# https://www.xilinx.com/content/dam/xilinx/support/documentation/sw_manuals/xilinx2019_2/ug973-vivado-release-notes-install-license.pdf +# +# See Chapt 4: Installing the Vivado Design Suite Tools -> Batch Mode Installation Flow + +Xilinx_Unified_2019.2_1106_2127_Lin64.bin: + echo 'Must d/l manually' + exit 1 + +.extract: Xilinx_Unified_2019.2_1106_2127_Lin64.bin + chmod 755 $< && vagrant up && vagrant ssh -c '/vagrant/Xilinx_Unified_2019.2_1106_2127_Lin64.bin --keep --noexec --target vivado' && touch $@ || (echo failed to extract; rm -f $@) + +.token: .extract + vagrant up && vagrant ssh -c 'vivado/xsetup -b AuthTokenGen' && touch $@ || (echo failed to generate auth token; rm -f $@) + +.PHONY: confgen +confgen: .extract + vagrant ssh -c 'vivado/xsetup -b ConfigGen && cp .Xilinx/install_config.txt /vagrant' + +.install: .token + vagrant up && vagrant ssh -c 'sudo mkdir -p /tools/Xilinx && sudo chown vagrant /tools/Xilinx && vivado/xsetup -b Install -a XilinxEULA,3rdPartyEULA,WebTalkTerms -c /vagrant/install_config.txt && cd /tools/Xilinx/Vivado/2019.2/data/xicom/cable_drivers/lin64/install_script/install_drivers && sudo ./install_drivers' && touch $@ || (echo failed to install software; rm -f $@) + +.PHONY: vivado +vivado: .install + vagrant up && vagrant ssh -c /tools/Xilinx/Vivado/2019.2/bin/vivado + +.PHONY: shell +shell: .install + vagrant up && vagrant ssh diff --git a/README.md b/README.md new file mode 100644 index 0000000..bf9bcb1 --- /dev/null +++ b/README.md @@ -0,0 +1,14 @@ +Vivado Vagrant +============== + +This automatically installs Vivado into a VM for development. + + +Steps +----- + +Note: by running these commands, it will execute a step that has you agree to Xilinux's EULA, their 3rd Party EULA and their Web Talk Terms. If you do not agree to these terms, do not run the commands. + +1) Make sure that vagrant is installed and functional. +2) Download and put the file `Xilinx_Unified_2019.2_1106_2127_Lin64.bin` in this directory. +3) Run: `make vivado` diff --git a/Vagrantfile b/Vagrantfile new file mode 100644 index 0000000..fc1dad2 --- /dev/null +++ b/Vagrantfile @@ -0,0 +1,13 @@ +Vagrant.configure("2") do |config| + config.vm.box = "hashicorp/bionic64" + config.ssh.forward_x11 = true + + config.vm.provider 'virtualbox' do |v| + v.customize ['modifyvm', :id, '--usb', 'on'] + v.customize ['modifyvm', :id, '--usbehci', 'on'] + v.memory = 2048 + v.cpus = 2 + end + + config.vm.provision :shell, path: "bootstrap.sh" +end diff --git a/bootstrap.sh b/bootstrap.sh new file mode 100644 index 0000000..6721232 --- /dev/null +++ b/bootstrap.sh @@ -0,0 +1,3 @@ +#!/bin/sh - + +apt-get install -y xauth libxrender1 libxtst6 libxi6 diff --git a/install_config.txt b/install_config.txt new file mode 100644 index 0000000..3f9fe42 --- /dev/null +++ b/install_config.txt @@ -0,0 +1,33 @@ +#### Vivado HL WebPACK Install Configuration #### +Edition=Vivado HL WebPACK + +Product=Vivado + +# Path where Xilinx software will be installed. +Destination=/tools/Xilinx + +# Choose the Products/Devices the you would like to install. +Modules=Virtex UltraScale+ HBM:1,Zynq UltraScale+ MPSoC:1,DocNav:1,Kintex UltraScale:1,Zynq-7000:1,System Generator for DSP:0,Virtex UltraScale+:1,Kintex UltraScale+:1,Model Composer:0 + +# Choose the post install scripts you'd like to run as part of the finalization step. Please note that some of these scripts may require user interaction during runtime. +InstallOptions= + +## Shortcuts and File associations ## +# Choose whether Start menu/Application menu shortcuts will be created or not. +CreateProgramGroupShortcuts=1 + +# Choose the name of the Start menu/Application menu shortcut. This setting will be ignored if you choose NOT to create shortcuts. +ProgramGroupFolder=Xilinx Design Tools + +# Choose whether shortcuts will be created for All users or just the Current user. Shortcuts can be created for all users only if you run the installer as administrator. +CreateShortcutsForAllUsers=0 + +# Choose whether shortcuts will be created on the desktop or not. +CreateDesktopShortcuts=1 + +# Choose whether file associations will be created or not. +CreateFileAssociation=1 + +# Choose whether disk usage will be optimized (reduced) after installation +EnableDiskUsageOptimization=1 +