27 lines
409 B
Bash
Executable File
27 lines
409 B
Bash
Executable File
#!/bin/bash
|
|
|
|
if [[ -z $1 ]]; then
|
|
echo "Specify object directory"
|
|
exit -1
|
|
fi
|
|
|
|
if [[ -z $2 ]]; then
|
|
echo "Specify source folder to scan"
|
|
exit -1
|
|
fi
|
|
|
|
|
|
if [[ -z $3 ]]; then
|
|
echo "Specify target library"
|
|
exit -1
|
|
fi
|
|
|
|
echo "Scanning \"$2\" for lib \"$3\" to obj dir \"$1\""
|
|
|
|
files=`find "$2" -name "*.vhd"`
|
|
|
|
for file in $files; do
|
|
echo "Importing file $file"
|
|
ghdl -i --workdir="$1" --work="$3" "$file"
|
|
done
|