Commit e777e95b authored by Paul Boven's avatar Paul Boven
Browse files

Automatically including the Xilinx Environment in the Makefile

parent 84744fa8
......@@ -3,48 +3,52 @@
# and sends it out over the 1Gb/s ethernet
# $Id: Makefile,v 1.1 2012/01/03 21:00:36 paul Exp paul $
# This writes the Xilin Environment to file, then includes it in Make
# Change the value of SETTINGS as appropriate
SETTINGS=/opt/Xilinx/14.7/ISE_DS/settings64.sh
IGNORE := $(shell bash -c "source $(SETTINGS); env |grep -e ^XILINX -e ^PATH -e ^LD_LIBRARY_PATH |sed 's/=/:=/' |sed 's/^/export /' > makeenv")
include makeenv
all: main.twr main.bit SDR-5M.bit
clean:
rm -rf raw.bit main.bit main.twr main.bgn main.bld main.cgc main.cgp main.drc main.ncd main.ngc main.ngd main.ngr main.pad main.par main.pcf man.twx main.syr main.twr main.twx main.unroutes main.xpi .lso main.ptwx main_bitgen.xwbt main_map.map main_map.mrp main_map.ncd main_map.ngm main_map.xrpt main_ngdbuild.xrpt main_pad.csv main_pad.txt main_par.xrpt main_summary.xml main_usage.xml main_xst.xrpt tmp/ _nog/ _xmsgs/ usage_statistics_webtalk.html webtalk.log xlnx_auto_0_xdb coregen.log fir_A.asy fir_B.asy fir_Afilt_decode_rom.mif fir_Bfilt_decode_rom.mif fir_A_flist.txt fir_B_flist.txt fir_A.gise fir_B.gise fir_A.mif fir_B.mif fir_A.ngc fir_B.ngc fir_A_readme.txt fir_B_readme.txt fir_A.vhd fir_B.vhd fir_A.vho fir_B.vho fir_A.xise fir_B.xise fir_A_xmdf.tcl fir_B_xmdf.tcl xst/ fir_ACOEFF* fir_BCOEFF* SDR-5M.bit
rm -rf raw.bit main.bit main.twr main.bgn main.bld main.cgc main.cgp main.drc main.ncd main.ngc main.ngd main.ngr main.pad main.par main.pcf man.twx main.syr main.twr main.twx main.unroutes main.xpi .lso main.ptwx main_bitgen.xwbt main_map.map main_map.mrp main_map.ncd main_map.ngm main_map.xrpt main_ngdbuild.xrpt main_pad.csv main_pad.txt main_par.xrpt main_summary.xml main_usage.xml main_xst.xrpt tmp/ _nog/ _xmsgs/ usage_statistics_webtalk.html webtalk.log xlnx_auto_0_xdb coregen.log fir_A.asy fir_B.asy fir_Afilt_decode_rom.mif fir_Bfilt_decode_rom.mif fir_A_flist.txt fir_B_flist.txt fir_A.gise fir_B.gise fir_A.mif fir_B.mif fir_A.ngc fir_B.ngc fir_A_readme.txt fir_B_readme.txt fir_A.vhd fir_B.vhd fir_A.vho fir_B.vho fir_A.xise fir_B.xise fir_A_xmdf.tcl fir_B_xmdf.tcl xst/ fir_ACOEFF* fir_BCOEFF* SDR-5M.bit makeenv
xst/projnav.tmp:
mkdir -p xst/projnav.tmp
fir_A.ngc: fir_A.xco fir_A.coe
bash -c ". $(SETTINGS) >/dev/null; coregen -b fir_A.xco -p main.prj"
coregen -b fir_A.xco -p main.prj
fir_B.ngc: fir_B.xco fir_B.coe
bash -c ". ${SETTINGS} >/dev/null; coregen -b fir_B.xco -p main.prj"
coregen -b fir_B.xco -p main.prj
lo.vhdl: lo.vhdl.templ lo.pl
./lo.pl lo.vhdl.templ > lo.vhdl
# XST
main.ngc: main.xst main.prj main.vhd LCD_Driver.vhd LCD_Controller.vhd fir_A.ngc fir_B.ngc xst/projnav.tmp
bash -c ". ${SETTINGS} >/dev/null; xst -ifn main.xst -ofn main.syr"
xst -ifn main.xst -ofn main.syr
# Ngdbuild
main.ngd: main.ngc main.ucf
bash -c ". ${SETTINGS} >/dev/null; ngdbuild -dd _nog -nt timestamp -p xc3sd1800a-fg676-4 -uc main.ucf main.ngc main.ngd"
ngdbuild -dd _nog -nt timestamp -p xc3sd1800a-fg676-4 -uc main.ucf main.ngc main.ngd
# Map
main.pcf: main.ngd
bash -c ". ${SETTINGS} >/dev/null; map -p xc3sd1800a-fg676-4 -cm area -ir off -pr off -c 100 -o main_map.ncd main.ngd main.pcf"
map -p xc3sd1800a-fg676-4 -cm area -ir off -pr off -c 100 -o main_map.ncd main.ngd main.pcf
# PAR
main.ncd: main.pcf
bash -c ". ${SETTINGS} >/dev/null; par -w -ol std -t 1 main_map.ncd main.ncd main.pcf"
par -w -ol std -t 1 main_map.ncd main.ncd main.pcf
# Timing Report
main.twr: main.ucf main.ncd
bash -c ". ${SETTINGS} >/dev/null; trce -v 3 -s 4 main.ncd -o main.twr main.pcf -ucf main.ucf"
trce -v 3 -s 4 main.ncd -o main.twr main.pcf -ucf main.ucf
# Bitgen
main.bit: main.ut main.ncd
bash -c ". ${SETTINGS} >/dev/null; bitgen -f main.ut main.ncd"
bitgen -f main.ut main.ncd
# Public name
SDR-5M.bit: main.bit
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment