Skip to content

Instantly share code, notes, and snippets.

@polynomialspace
Last active December 10, 2018 09:08
Show Gist options
  • Save polynomialspace/4de7201642da0adb00c1021bf65267d8 to your computer and use it in GitHub Desktop.
Save polynomialspace/4de7201642da0adb00c1021bf65267d8 to your computer and use it in GitHub Desktop.
Quick and dirty makefile to build migen or yosys and dependencies on fedora (Why isnt this just a shell script?)
all: migen
deps:
sudo yum install git make gcc gcc-c++
icestorm: deps
sudo yum install -y python3 libftdi-devel \
&& git clone https://github.com/cliffordwolf/icestorm \
&& cd icestorm \
&& make -j $(nproc) \
&& sudo make install
nextpnr: icestorm
sudo yum install -y python3-devel cmake boost-devel boost-python3-devel qt5-devel \
&& git clone https://github.com/YosysHQ/nextpnr \
&& cd nextpnr \
&& cmake -DARCH=ice40 . \
&& make -j $(nproc) \
&& sudo make install
yosys: nextpnr
sudo yum -y install clang bison flex readline-devel gawk tcl-devel libffi-devel graphviz python-xdot \
&& git clone https://github.com/YosysHQ/yosys \
&& cd yosys \
&& make -j $(nproc) \
&& sudo make install
migen: yosys
git clone https://github.com/m-labs/migen \
&& cd migen \
&& python3 setup.py build \
&& sudo python3 setup.py install
.PHONY: deps icestorm nextpnr yosys migen all
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment