#!/bin/bash if [ "$EUID" -ne 0 ] then echo "Please run as root using 'sudo bash'" exit fi runuser $SUDO_USER --preserve-environment -c ' cd /home/$SUDO_USER mkdir -p src cd src git clone https://git.libre-soc.org/git/ls2.git git clone https://git.libre-soc.org/git/gram.git git clone https://git.libre-soc.org/git/lambdasoc.git git clone https://git.libre-soc.org/git/microwatt.git tercel-qspi git clone https://github.com/freecores/uart16550 git clone https://github.com/freecores/ethmac git clone https://github.com/alexforencich/verilog-wishbone ' # verilog-wishbone checkout at specific tag cd /home/$SUDO_USER/src/verilog-wishbone git checkout d1fa24a0 # lambdasoc cd /home/$SUDO_USER/src/lambdasoc git tag | xargs git tag -d # very annoying python3 setup.py develop # gram cd ../gram git tag | xargs git tag -d # very annoying python3 setup.py develop # ls2 # does not need an "install"... yet. cd ../ chown -R $SUDO_USER . chgrp -R $SUDO_USER . echo -e " \e[1;91mAll Libre-SOC dev dependencies should now be installed.\e[0m "