From aa2371eafe7527a9c09187227117d8bab043da03 Mon Sep 17 00:00:00 2001 From: Joshua Fife Date: Tue, 17 Aug 2021 15:34:49 -0600 Subject: [PATCH] Modified Makefiles to call common/Makefile Signed-off-by: Joshua Fife --- xc7/pulse_width_led/Makefile | 44 ++++-------------------------------- xc7/timer/Makefile | 43 ++++------------------------------- 2 files changed, 10 insertions(+), 77 deletions(-) diff --git a/xc7/pulse_width_led/Makefile b/xc7/pulse_width_led/Makefile index b3e9b7d..d4069df 100644 --- a/xc7/pulse_width_led/Makefile +++ b/xc7/pulse_width_led/Makefile @@ -1,43 +1,9 @@ -mkfile_path := $(abspath $(lastword $(MAKEFILE_LIST))) -current_dir := $(patsubst %/,%,$(dir $(mkfile_path))) +current_dir := ${CURDIR} +TARGET := arty_35 TOP := top -VERILOG := ${current_dir}/PWM.v -VERILOG += ${current_dir}/pulse_led.v -DEVICE := xc7a50t_test -BITSTREAM_DEVICE := artix7 -BUILDDIR := build +SOURCES := ${current_dir}/PWM.v +SOURCES += ${current_dir}/pulse_led.v - -PARTNAME := xc7a35tcsg324-1 XDC := ${current_dir}/arty_35.xdc -BOARD_BUILDDIR := ${BUILDDIR}/arty_35 - -.DELETE_ON_ERROR: - - -all: ${BOARD_BUILDDIR}/${TOP}.bit - -${BOARD_BUILDDIR}: - mkdir -p ${BOARD_BUILDDIR} - -${BOARD_BUILDDIR}/${TOP}.eblif: | ${BOARD_BUILDDIR} - cd ${BOARD_BUILDDIR} && symbiflow_synth -t ${TOP} -v ${VERILOG} -d ${BITSTREAM_DEVICE} -p ${PARTNAME} -x ${XDC} 2>&1 > /dev/null - -${BOARD_BUILDDIR}/${TOP}.net: ${BOARD_BUILDDIR}/${TOP}.eblif - cd ${BOARD_BUILDDIR} && symbiflow_pack -e ${TOP}.eblif -d ${DEVICE} 2>&1 > /dev/null - -${BOARD_BUILDDIR}/${TOP}.place: ${BOARD_BUILDDIR}/${TOP}.net - cd ${BOARD_BUILDDIR} && symbiflow_place -e ${TOP}.eblif -d ${DEVICE} -n ${TOP}.net -P ${PARTNAME} 2>&1 > /dev/null - -${BOARD_BUILDDIR}/${TOP}.route: ${BOARD_BUILDDIR}/${TOP}.place - cd ${BOARD_BUILDDIR} && symbiflow_route -e ${TOP}.eblif -d ${DEVICE} 2>&1 > /dev/null - -${BOARD_BUILDDIR}/${TOP}.fasm: ${BOARD_BUILDDIR}/${TOP}.route - cd ${BOARD_BUILDDIR} && symbiflow_write_fasm -e ${TOP}.eblif -d ${DEVICE} - -${BOARD_BUILDDIR}/${TOP}.bit: ${BOARD_BUILDDIR}/${TOP}.fasm - cd ${BOARD_BUILDDIR} && symbiflow_write_bitstream -d ${BITSTREAM_DEVICE} -f ${TOP}.fasm -p ${PARTNAME} -b ${TOP}.bit - -clean: - rm -rf ${BUILDDIR} +include ${current_dir}/../../common/Makefile \ No newline at end of file diff --git a/xc7/timer/Makefile b/xc7/timer/Makefile index 052e42c..e022307 100644 --- a/xc7/timer/Makefile +++ b/xc7/timer/Makefile @@ -1,41 +1,8 @@ -mkfile_path := $(abspath $(lastword $(MAKEFILE_LIST))) -current_dir := $(patsubst %/,%,$(dir $(mkfile_path))) +current_dir := ${CURDIR} +TARGET := basys3 TOP := top -SYSTEM_VERILOG := ${current_dir}/*.sv -DEVICE := xc7a50t_test -BITSTREAM_DEVICE := artix7 -BUILDDIR := build +SOURCES := ${current_dir}/*.sv - PARTNAME := xc7a35tcpg236-1 - BOARD_BUILDDIR := ${BUILDDIR}/basys3 +XDC := ${current_dir}/basys3.xdc - XDC := ${current_dir}/basys3.xdc - -.DELETE_ON_ERROR: - - -all: ${BOARD_BUILDDIR}/${TOP}.bit - -${BOARD_BUILDDIR}: - mkdir -p ${BOARD_BUILDDIR} - -${BOARD_BUILDDIR}/${TOP}.eblif: | ${BOARD_BUILDDIR} - cd ${BOARD_BUILDDIR} && symbiflow_synth -t ${TOP} -v ${SYSTEM_VERILOG} -d ${BITSTREAM_DEVICE} -p ${PARTNAME} -x ${XDC} 2>&1 > /dev/null - -${BOARD_BUILDDIR}/${TOP}.net: ${BOARD_BUILDDIR}/${TOP}.eblif - cd ${BOARD_BUILDDIR} && symbiflow_pack -e ${TOP}.eblif -d ${DEVICE} 2>&1 > /dev/null - -${BOARD_BUILDDIR}/${TOP}.place: ${BOARD_BUILDDIR}/${TOP}.net - cd ${BOARD_BUILDDIR} && symbiflow_place -e ${TOP}.eblif -d ${DEVICE} -n ${TOP}.net -P ${PARTNAME} 2>&1 > /dev/null - -${BOARD_BUILDDIR}/${TOP}.route: ${BOARD_BUILDDIR}/${TOP}.place - cd ${BOARD_BUILDDIR} && symbiflow_route -e ${TOP}.eblif -d ${DEVICE} 2>&1 > /dev/null - -${BOARD_BUILDDIR}/${TOP}.fasm: ${BOARD_BUILDDIR}/${TOP}.route - cd ${BOARD_BUILDDIR} && symbiflow_write_fasm -e ${TOP}.eblif -d ${DEVICE} - -${BOARD_BUILDDIR}/${TOP}.bit: ${BOARD_BUILDDIR}/${TOP}.fasm - cd ${BOARD_BUILDDIR} && symbiflow_write_bitstream -d ${BITSTREAM_DEVICE} -f ${TOP}.fasm -p ${PARTNAME} -b ${TOP}.bit - -clean: - rm -rf ${BUILDDIR} +include ${current_dir}/../../common/Makefile \ No newline at end of file