f4pga-examples/xc7/linux_litex_demo/Makefile
Tim Callahan 94e7544cfd Really remove the LOC; try to get 100T linux demo to run.
Restore output redirect for synth step (deleted by accident).
Checking status w/ EOS-S3 updates .. DNM!
Change instructions around INSTALL_DIR.
Update formatting to rst not md.
More formatting fixes, mostly for ..code.
Now use $INSTALL_DIR/xc7 and $INSTALL_DIR/eos-s3.
Formatting & instructions update.

Signed-off-by: Tim Callahan <tcal@google.com>
2020-09-23 14:53:43 -07:00

51 lines
1.7 KiB
Makefile

mkfile_path := $(abspath $(lastword $(MAKEFILE_LIST)))
current_dir := $(patsubst %/,%,$(dir $(mkfile_path)))
TOP := top
VERILOG := ${current_dir}/baselitex_arty.v \
${current_dir}/VexRiscv_Linux.v
MEM_INIT := ${current_dir}/mem.init \
${current_dir}/mem_1.init \
${current_dir}/mem_2.init
BITSTREAM_DEVICE := artix7
PCF := ${current_dir}/arty.pcf
SDC := ${current_dir}/arty.sdc
XDC := ${current_dir}/arty.xdc
BUILDDIR_35 := build
BUILDDIR_100 := build_100
ifeq ($(TARGET),arty_100)
PARTNAME := xc7a100tcsg324-1
DEVICE := xc7a100t_test
BUILDDIR := ${BUILDDIR_100}
else
PARTNAME := xc7a35tcsg324-1
DEVICE := xc7a50t_test
BUILDDIR := ${BUILDDIR_35}
endif
all: ${BUILDDIR}/${TOP}.bit
${BUILDDIR}:
mkdir ${BUILDDIR}
ln -s ${MEM_INIT} ${BUILDDIR}
${BUILDDIR}/${TOP}.eblif: | ${BUILDDIR}
cd ${BUILDDIR} && symbiflow_synth -t ${TOP} -v ${VERILOG} -d ${BITSTREAM_DEVICE} -p ${PARTNAME} -x ${XDC} 2>&1 > /dev/null
${BUILDDIR}/${TOP}.net: ${BUILDDIR}/${TOP}.eblif
cd ${BUILDDIR} && symbiflow_pack -e ${TOP}.eblif -d ${DEVICE} -s ${SDC} 2>&1 > /dev/null
${BUILDDIR}/${TOP}.place: ${BUILDDIR}/${TOP}.net
cd ${BUILDDIR} && symbiflow_place -e ${TOP}.eblif -d ${DEVICE} -p ${PCF} -n ${TOP}.net -P ${PARTNAME} -s ${SDC} 2>&1 > /dev/null
${BUILDDIR}/${TOP}.route: ${BUILDDIR}/${TOP}.place
cd ${BUILDDIR} && symbiflow_route -e ${TOP}.eblif -d ${DEVICE} -s ${SDC} 2>&1 > /dev/null
${BUILDDIR}/${TOP}.fasm: ${BUILDDIR}/${TOP}.route
cd ${BUILDDIR} && symbiflow_write_fasm -e ${TOP}.eblif -d ${DEVICE}
${BUILDDIR}/${TOP}.bit: ${BUILDDIR}/${TOP}.fasm
cd ${BUILDDIR} && symbiflow_write_bitstream -d ${BITSTREAM_DEVICE} -f ${TOP}.fasm -p ${PARTNAME} -b ${TOP}.bit
clean:
rm -rf ${BUILDDIR_35} ${BUILDDIR_100}