X-Git-Url: https://git.libre-soc.org/?a=blobdiff_plain;f=hdl-dev-repos;h=a549da6da1bfba45b5d0de3f80255ba892bbf7cb;hb=HEAD;hp=f570b2a747124f7ddaaca802594424c48c01d9a7;hpb=5a7b8def9453c86c38ccaf3ae897fbc6666954ad;p=dev-env-setup.git diff --git a/hdl-dev-repos b/hdl-dev-repos index f570b2a..032182f 100755 --- a/hdl-dev-repos +++ b/hdl-dev-repos @@ -1,30 +1,106 @@ #!/bin/bash if [ "$EUID" -ne 0 ] - then echo "Please run as root" + then echo "Please run as root using 'sudo bash'" exit fi -export MYNAME=`id 1000 | awk '{print $1}' | sed 's/.*(\(.*\))/\1/'` -export MYHOME=/home/$MYNAME - -runuser $MYNAME --preserve-environment -c ' -cd /home/$MYNAME -mkdir src +runuser $SUDO_USER --preserve-environment -c ' +cd /home/$SUDO_USER +mkdir -p src cd src -git clone https://github.com/nmigen/nmigen.git -git clone https://git.libre-riscv.org/git/nmutil.git -git clone https://git.libre-riscv.org/git/ieee754fpu.git -git clone https://git.libre-riscv.org/git/soc.git +git clone https://github.com/westerndigitalcorporation/pyvcd.git +git clone https://gitlab.com/nmigen/nmigen-boards.git +git clone https://gitlab.com/nmigen/nmigen.git +git clone https://git.libre-soc.org/git/c4m-jtag.git +git clone https://git.libre-soc.org/git/nmutil.git +git clone https://git.libre-soc.org/git/openpower-isa.git +git clone https://git.libre-soc.org/git/ieee754fpu.git +git clone https://gitlab.com/nmigen/nmigen-soc.git +git clone https://gitlab.com/nmigen/nmigen-stdio.git +git clone https://git.libre-soc.org/git/soc.git +git clone https://git.libre-soc.org/git/pytest-output-to-files.git +git clone https://git.libre-soc.org/git/mdis.git +git clone git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git --depth=1 --branch v6.5.8 ' -cd /home/$MYNAME/src/nmigen + +# pytest +python3 -m pip install pytest-xdist==3.3.1 pytest==7.3.1 \ + pytest-subtests==0.11.0 + +# pytest-output-to-files +cd /home/$SUDO_USER/src/pytest-output-to-files +python3 setup.py develop + +# pyvcd - needed for nmigen +cd /home/$SUDO_USER/src/pyvcd +git checkout 0.2.4 +python3 setup.py develop --no-deps + +# nmigen +cd /home/$SUDO_USER/src/nmigen +git tag | xargs git tag -d # very annoying +python3 setup.py develop + +# nmigen-boards +cd /home/$SUDO_USER/src/nmigen-boards +git tag | xargs git tag -d # very annoying +python3 setup.py develop --no-deps + +# nmigen-soc +cd ../nmigen-soc +git tag | xargs git tag -d # very annoying +python3 setup.py develop + +# nmigen-stdio +cd ../nmigen-stdio +git tag | xargs git tag -d # very annoying +python3 setup.py develop + +# XXX GRRR run this again: TODO, resolve dependencies +# nmigen +cd /home/$SUDO_USER/src/nmigen +git tag | xargs git tag -d # very annoying +python3 setup.py develop + +# c4m-jtag +cd ../c4m-jtag +git tag | xargs git tag -d # very annoying python3 setup.py develop -python3 setup.py test + +# nmutil cd ../nmutil python3 setup.py develop + +# mdis +cd ../mdis +python3 setup.py develop + +# openpower-isa +cd ../openpower-isa +python3 setup.py develop +make svanalysis +make pywriter +make pyfnwriter +python3 -m openpower.syscalls json ../linux > src/openpower/syscalls/syscalls.json + +# ieee754fpy cd ../ieee754fpu git submodule update --init --recursive python3 setup.py develop + +# soc cd ../soc -git submodule update --init --recursive +make gitupdate python3 setup.py develop +# sigh sort out pinmux +cd pinmux +git checkout d96f737c0a53dde983 +cd .. +make mkpinmux + cd ../ +chown -R $SUDO_USER . +chgrp -R $SUDO_USER . +echo -e " +\e[1;91mAll Libre-SOC dev dependenices should now be installed.\e[0m +"