Skip to content
Snippets Groups Projects
Commit f451acf1 authored by Recolic Keghart's avatar Recolic Keghart
Browse files

remove another junk dir

parents c99d34c0 e894e179
No related branches found
No related tags found
No related merge requests found
......@@ -60,6 +60,17 @@ elif [[ $1 == gui ]]; then
echo "open_project ${xpr}
`find ${proj_dir}/*.srcs -regex '^.*\.s?vh?$' -exec echo add_files \{\} \;`
start_gui"
elif [[ $1 == init-project ]]; then
proj_name="$2"
proj_dir="$3"
part_name="$4" # xc7a100tcsg324-1
echo "# Generated by Vivado wrapper, licensed under GPL 3.0
# Copyright (C) Recolic Keghart <root@recolic.net>
create_project ${proj_name} ${proj_dir} -part ${part_name}
file mkdir ${proj_dir}/${proj_name}.srcs/constrs_1/new
close [ open ${proj_dir}/${proj_name}.srcs/constrs_1/new/constraint.xdc w ]
add_files -fileset constrs_1 ${proj_dir}/${proj_name}.srcs/constrs_1/new/constraint.xdc"
rm -f ${proj_dir}/${proj_name}.srcs/constrs_1/new/constraint.xdc
else
echo "Usage: $0 build <xpr path> <run_name_synth> <run_name_impl> <to_step> <top module name> <threads_num>
$0 burn <xpr path> <run_name_impl> <top_module_name> <dev_name(Ex:xc7a100t_0)>"
......
......@@ -22,6 +22,9 @@ top_modules=(
# top_module=test_main
top_module=
# Name of your board in vivado
board="xc7a100tcsg324-1"
#
# Optional options
#
......
......@@ -132,12 +132,13 @@ function get_constraint_of_module () {
function generate_real_project () {
[[ "$constr_path" == '' ]] && constr_path="$(pwd)/$(get_constraint_of_module $top_module)"
cp -r "$my_path/template/project" "$temp_dir/"
# todo: use new init-project to generate if template not exist
_real_proj_src="$temp_dir/project/temp_project.srcs"
for src in `echo ${sources[@]}`; do
mkdir -p "$_real_proj_src/sources_1/new/$(dirname "$src")"
ln -s "$(pwd)/$src" "$_real_proj_src/sources_1/new/$src"
done
rm "$_real_proj_src/constrs_1/new/constraint.xdc"
rm -f "$_real_proj_src/constrs_1/new/constraint.xdc"
ln -s "$constr_path" "$_real_proj_src/constrs_1/new/constraint.xdc"
echo "real_project generated at $temp_dir"
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment