Merge pull request #24 from antmicro/add-env

Add conda environment file
This commit is contained in:
Karol Gugala 2020-06-22 16:57:05 +02:00 committed by GitHub
commit d2d8451102
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 53 additions and 18 deletions

View File

@ -35,14 +35,9 @@ For the Artix-7 devices:
INSTALL_DIR="/opt/symbiflow/xc7" INSTALL_DIR="/opt/symbiflow/xc7"
bash conda_installer.sh -b -p $INSTALL_DIR/conda && rm conda_installer.sh bash conda_installer.sh -b -p $INSTALL_DIR/conda && rm conda_installer.sh
source "$INSTALL_DIR/conda/etc/profile.d/conda.sh" source "$INSTALL_DIR/conda/etc/profile.d/conda.sh"
conda update -y -q conda conda env create -f examples/xc7/environment.yml
conda activate xc7
wget -qO- https://storage.googleapis.com/symbiflow-arch-defs/artifacts/prod/foss-fpga-tools/symbiflow-arch-defs/continuous/install/4/20200416-002215/symbiflow-arch-defs-install-a321d9d9.tar.xz | tar -xJ -C $INSTALL_DIR wget -qO- https://storage.googleapis.com/symbiflow-arch-defs/artifacts/prod/foss-fpga-tools/symbiflow-arch-defs/continuous/install/4/20200416-002215/symbiflow-arch-defs-install-a321d9d9.tar.xz | tar -xJ -C $INSTALL_DIR
conda install -y -c symbiflow yosys yosys-plugins vtr-no-gui
conda install -y make lxml simplejson intervaltree git pip
conda activate
pip install python-constraint
pip install git+https://github.com/symbiflow/fasm
conda deactivate conda deactivate
``` ```
@ -52,16 +47,9 @@ For the EOS S3 devices:
INSTALL_DIR="/opt/symbiflow/eos-s3" INSTALL_DIR="/opt/symbiflow/eos-s3"
bash conda_installer.sh -b -p $INSTALL_DIR/conda && rm conda_installer.sh bash conda_installer.sh -b -p $INSTALL_DIR/conda && rm conda_installer.sh
source "$INSTALL_DIR/conda/etc/profile.d/conda.sh" source "$INSTALL_DIR/conda/etc/profile.d/conda.sh"
conda update -y -q conda conda env create -f examples/eos-s3/environment.yml
conda activate eos-s3
wget -qO- https://storage.googleapis.com/symbiflow-arch-defs-install/quicklogic/arch-defs-install-eos-s3-f7880e1f.tar.xz | tar -xJ -C $INSTALL_DIR wget -qO- https://storage.googleapis.com/symbiflow-arch-defs-install/quicklogic/arch-defs-install-eos-s3-f7880e1f.tar.xz | tar -xJ -C $INSTALL_DIR
conda install -y -c antmicro/label/ql yosys yosys-plugins vtr-no-gui
conda install -y make lxml simplejson intervaltree git pip
conda activate
pip install python-constraint
pip install git+https://github.com/symbiflow/fasm
pip install git+https://github.com/antmicro/quicklogic-fasm
pip install git+https://github.com/antmicro/quicklogic-fasm-utils
conda deactivate conda deactivate
``` ```
@ -89,7 +77,7 @@ export INSTALL_DIR="/opt/symbiflow/xc7"
# adding symbiflow toolchain binaries to PATH # adding symbiflow toolchain binaries to PATH
export PATH="$INSTALL_DIR/install/bin:$PATH" export PATH="$INSTALL_DIR/install/bin:$PATH"
source "$INSTALL_DIR/conda/etc/profile.d/conda.sh" source "$INSTALL_DIR/conda/etc/profile.d/conda.sh"
conda activate conda activate xc7
git clone https://github.com/SymbiFlow/symbiflow-examples && cd symbiflow-examples git clone https://github.com/SymbiFlow/symbiflow-examples && cd symbiflow-examples
# counter example # counter example
pushd examples/xc7/counter_test && TARGET="arty" make && popd pushd examples/xc7/counter_test && TARGET="arty" make && popd
@ -97,6 +85,15 @@ pushd examples/xc7/counter_test && make clean && TARGET="basys3" make && popd
# picosoc example # picosoc example
pushd examples/xc7/picosoc_demo && make && popd pushd examples/xc7/picosoc_demo && make && popd
# litex example # litex example
wget https://raw.githubusercontent.com/enjoy-digital/litex/master/litex_setup.py
chmod +x litex_setup.py
./litex_setup.py init
./litex_setup.py install
wget https://static.dev.sifive.com/dev-tools/riscv64-unknown-elf-gcc-8.1.0-2019.01.0-x86_64-linux-ubuntu14.tar.gz
tar -xf riscv64-unknown-elf-gcc-8.1.0-2019.01.0-x86_64-linux-ubuntu14.tar.gz
export PATH=$PATH:$PWD/riscv64-unknown-elf-gcc-8.1.0-2019.01.0-x86_64-linux-ubuntu14/bin/
pushd litex/litex/boards/targets && ./arty.py --toolchain symbiflow --cpu-type vexriscv --build && popd
# linux litex example
pushd examples/xc7/linux_litex_demo && make && popd pushd examples/xc7/linux_litex_demo && make && popd
``` ```
@ -111,7 +108,7 @@ export INSTALL_DIR="/opt/symbiflow/eos-s3"
# adding symbiflow toolchain binaries to PATH # adding symbiflow toolchain binaries to PATH
export PATH="$INSTALL_DIR/install/bin:$PATH" export PATH="$INSTALL_DIR/install/bin:$PATH"
source "$INSTALL_DIR/conda/etc/profile.d/conda.sh" source "$INSTALL_DIR/conda/etc/profile.d/conda.sh"
conda activate conda activate eos-s3
git clone https://github.com/SymbiFlow/symbiflow-examples && cd symbiflow-examples git clone https://github.com/SymbiFlow/symbiflow-examples && cd symbiflow-examples
pushd examples/eos-s3 && make && popd pushd examples/eos-s3 && make && popd
``` ```

16
examples/eos-s3/environment.yml vendored Normal file
View File

@ -0,0 +1,16 @@
name: eos-s3
channels:
- antmicro/label/ql
dependencies:
- antmicro/label/ql::yosys
- antmicro/label/ql::yosys-plugins
- antmicro/label/ql::vtr
- make
- lxml
- simplejson
- intervaltree
- git
- pip
# Packages installed from PyPI
- pip:
- -r file:requirements.txt

4
examples/eos-s3/requirements.txt vendored Normal file
View File

@ -0,0 +1,4 @@
python-constraint
git+https://github.com/symbiflow/fasm
git+https://github.com/antmicro/quicklogic-fasm
git+https://github.com/antmicro/quicklogic-fasm-utils

16
examples/xc7/environment.yml vendored Normal file
View File

@ -0,0 +1,16 @@
name: xc7
channels:
- symbiflow
dependencies:
- symbiflow::symbiflow-yosys
- symbiflow::symbiflow-yosys-plugins=1.0.0.7_0032_g104f4fc
- symbiflow::symbiflow-vtr=8.0.0.rc2_3575_g253f75b6d
- make
- lxml
- simplejson
- intervaltree
- git
- pip
# Packages installed from PyPI
- pip:
- -r file:requirements.txt

2
examples/xc7/requirements.txt vendored Normal file
View File

@ -0,0 +1,2 @@
python-constraint
git+https://github.com/symbiflow/fasm