mirror of
git://projects.qi-hardware.com/nn-usb-fpga.git
synced 2025-04-21 12:27:27 +03:00
Fixing some examples, adding scripts for compiling xilinx libs with ghdl
This commit is contained in:
52
xilinx_lib/xilinx_ghdl_unisim
Executable file
52
xilinx_lib/xilinx_ghdl_unisim
Executable file
@@ -0,0 +1,52 @@
|
||||
#!/bin/sh
|
||||
# $Id: xilinx_ghdl_unisim 88 2007-10-12 20:37:45Z mueller $
|
||||
#
|
||||
if [ -z "$XILINX" ]
|
||||
then
|
||||
echo "XILINX not defined"
|
||||
exit 1
|
||||
fi
|
||||
#
|
||||
cd $XILINX
|
||||
echo "============================================================"
|
||||
echo "* Build ghdl UNISIM libs for $XILINX"
|
||||
echo "============================================================"
|
||||
#
|
||||
if [ ! -d ghdl ]
|
||||
then
|
||||
mkdir ghdl
|
||||
fi
|
||||
#
|
||||
cd $XILINX/ghdl
|
||||
if [ ! -d unisim ]
|
||||
then
|
||||
mkdir unisim
|
||||
fi
|
||||
#
|
||||
cd $XILINX/ghdl/unisim
|
||||
cp $XILINX/vhdl/src/unisims/unisim_VCOMP.vhd .
|
||||
cp $XILINX/vhdl/src/unisims/unisim_VPKG.vhd .
|
||||
#
|
||||
if [ ! -d unisim_vital_chop ]
|
||||
then
|
||||
mkdir unisim_vital_chop
|
||||
fi
|
||||
cd unisim_vital_chop
|
||||
xilinx_vhdl_chop $XILINX/vhdl/src/unisims/unisim_VITAL.vhd
|
||||
#
|
||||
cd ..
|
||||
echo "# ghdl ... unisim_VCOMP.vhd"
|
||||
ghdl -a --ieee=synopsys --work=unisim unisim_VCOMP.vhd
|
||||
echo "# ghdl ... unisim_VPKG.vhd"
|
||||
ghdl -a --ieee=synopsys --work=unisim unisim_VPKG.vhd
|
||||
|
||||
for file in `find unisim_vital_chop -name "*.vhd"`
|
||||
do
|
||||
echo "# ghdl ... $file"
|
||||
ghdl -a -fexplicit --ieee=synopsys --work=unisim 2>&1 $file |\
|
||||
tee $file.ghdl.log
|
||||
done
|
||||
#
|
||||
echo "--- scan for compilation errors:"
|
||||
find unisim_vital_chop -name "*.ghdl.log" | xargs grep error
|
||||
#
|
||||
Reference in New Issue
Block a user