@@ -25,15 +25,15 @@ set device_part [lindex $::argv 1]
2525set vcs_file [lindex $::argv 2]
2626set xdc_file [lindex $::argv 3]
2727
28- set script_dir $::env(SCRIPT_DIR )
29- set source_dir [ file dirname [info script] ]
28+ set tool_dir $::env(TOOL_DIR )
29+ set script_dir [ file dirname [ file normalize [ info script ] ] ]
3030
3131puts " Using top_module=$top_module "
3232puts " Using device_part=$device_part "
3333puts " Using vcs_file=$vcs_file "
3434puts " Using xdc_file=$xdc_file "
35+ puts " Using tool_dir=$tool_dir "
3536puts " Using script_dir=$script_dir "
36- puts " Using source_dir=$source_dir "
3737
3838# Set the number of jobs based on MAX_JOBS environment variable
3939if {[info exists ::env(MAX_JOBS)]} {
@@ -46,7 +46,7 @@ if {[info exists ::env(MAX_JOBS)]} {
4646proc run_setup {} {
4747 global project_name
4848 global top_module device_part vcs_file xdc_file
49- global script_dir source_dir
49+ global script_dir tool_dir
5050 global num_jobs
5151 global argv argc ;# Using global system variables: argv and argc
5252
@@ -55,10 +55,10 @@ proc run_setup {} {
5555 set ip_dir $::env(FPU_IP)
5656 set argv [list $ip_dir $device_part ]
5757 set argc 2
58- source ${script_dir } /xilinx_ip_gen.tcl
58+ source ${tool_dir } /xilinx_ip_gen.tcl
5959 }
6060
61- source " ${script_dir } /parse_vcs_list.tcl"
61+ source " ${tool_dir } /parse_vcs_list.tcl"
6262 set vlist [parse_vcs_list " ${vcs_file} " ]
6363
6464 set vsources_list [lindex $vlist 0]
@@ -96,12 +96,22 @@ proc run_setup {} {
9696 -objects [get_runs synth_1]
9797
9898 # register compilation hooks
99- # set_property STEPS.SYNTH_DESIGN.TCL.PRE ${source_dir}/pre_synth_hook.tcl [get_runs synth_1]
100- # set_property STEPS.SYNTH_DESIGN.TCL.POST ${source_dir}/post_synth_hook.tcl [get_runs synth_1]
101- set_property STEPS.OPT_DESIGN.TCL.PRE ${script_dir} /xilinx_async_bram_patch.tcl [get_runs impl_1]
102- # set_property STEPS.OPT_DESIGN.TCL.POST ${source_dir}/post_opt_hook.tcl [get_runs impl_1]
103- # set_property STEPS.ROUTE_DESIGN.TCL.PRE ${source_dir}/pre_route_hook.tcl [get_runs impl_1]
104- # set_property STEPS.ROUTE_DESIGN.TCL.POST ${source_dir}/post_route_hook.tcl [get_runs impl_1]
99+ # set_property STEPS.SYNTH_DESIGN.TCL.PRE ${script_dir}/pre_synth_hook.tcl [get_runs synth_1]
100+ # set_property STEPS.SYNTH_DESIGN.TCL.POST ${script_dir}/post_synth_hook.tcl [get_runs synth_1]
101+ set_property STEPS.OPT_DESIGN.TCL.PRE ${script_dir} /pre_opt_hook.tcl [get_runs impl_1]
102+ # set_property STEPS.OPT_DESIGN.TCL.POST ${script_dir}/post_opt_hook.tcl [get_runs impl_1]
103+ # set_property STEPS.POWER_OPT_DESIGN.TCL.PRE ${script_dir}/pre_power_opt_hook.tcl [get_runs impl_1]
104+ # set_property STEPS.POWER_OPT_DESIGN.TCL.POST ${script_dir}/post_power_opt_hook.tcl [get_runs impl_1]
105+ # set_property STEPS.PLACE_DESIGN.TCL.PRE ${script_dir}/pre_place_hook.tcl [get_runs impl_1]
106+ # set_property STEPS.PLACE_DESIGN.TCL.POST ${script_dir}/post_place_hook.tcl [get_runs impl_1]
107+ # set_property STEPS.POST_PLACE_POWER_OPT_DESIGN.TCL.PRE ${script_dir}/pre_place_power_opt_hook.tcl [get_runs impl_1]
108+ # set_property STEPS.POST_PLACE_POWER_OPT_DESIGN.TCL.POST ${script_dir}/post_place_power_opt_hook.tcl [get_runs impl_1]
109+ # set_property STEPS.PHYS_OPT_DESIGN.TCL.PRE ${script_dir}/pre_phys_opt_hook.tcl [get_runs impl_1]
110+ # set_property STEPS.PHYS_OPT_DESIGN.TCL.POST ${script_dir}/post_phys_opt_hook.tcl [get_runs impl_1]
111+ # set_property STEPS.ROUTE_DESIGN.TCL.PRE ${script_dir}/pre_route_hook.tcl [get_runs impl_1]
112+ # set_property STEPS.ROUTE_DESIGN.TCL.POST ${script_dir}/post_route_hook.tcl [get_runs impl_1]
113+ # set_property STEPS.WRITE_BITSTREAM.TCL.PRE ${script_dir}/pre_bitstream_hook.tcl [get_runs impl_1]
114+ # set_property STEPS.WRITE_BITSTREAM.TCL.POST ${script_dir}/post_bitstream_hook.tcl [get_runs impl_1]
105115
106116 update_compile_order -fileset sources_1
107117}
0 commit comments