Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions scripts/git_wrapper.tcl
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ namespace eval ::git_wrapper {
set proj_file [current_project].tcl

# Generate project and add it
write_project_tcl_git -no_copy_sources -force $proj_file
write_project_tcl_git -no_copy_sources -force -no_layout $proj_file
puts $proj_file
exec git add $proj_file

Expand All @@ -76,6 +76,6 @@ namespace eval ::git_wrapper {
# Generate project
set proj_file [current_project].tcl
puts $proj_file
write_project_tcl_git -no_copy_sources -force $proj_file
write_project_tcl_git -no_copy_sources -force -no_layout $proj_file
}
}
20 changes: 17 additions & 3 deletions scripts/write_project_tcl_git.tcl
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,8 @@ proc write_project_tcl_git {args} {
"-use_bd_files" { set a_global_vars(b_arg_use_bd_files) 1 }
"-internal" { set a_global_vars(b_internal) 1 }
"-quiet" { set a_global_vars(b_arg_quiet) 1}
"-exclude_external_ips" { set a_global_vars(exclude_external_ips) 1}
"-no_layout" { set a_global_vars(b_no_layout) 1}
default {
# is incorrect switch specified?
if { [regexp {^-} $option] } {
Expand Down Expand Up @@ -241,6 +243,8 @@ proc reset_global_vars {} {
set a_global_vars(def_val_fh) 0
set a_global_vars(script_file) ""
set a_global_vars(b_arg_quiet) 0
set a_global_vars(exclude_external_ips) 0
set a_global_vars(b_no_layout) 0

if { [get_param project.enableMergedProjTcl] } {
set a_global_vars(b_arg_use_bd_files) 0
Expand Down Expand Up @@ -599,9 +603,17 @@ proc write_bd_as_proc { bd_file } {
}
set temp_bd_file [file join $temp_dir "temp_$temp_offset.tcl"]
if { $a_global_vars(b_arg_no_ip_version) } {
write_bd_tcl -no_project_wrapper -no_ip_version -make_local -include_layout $temp_bd_file
if { $a_global_vars(b_no_layout) } {
write_bd_tcl -no_project_wrapper -no_ip_version -make_local $temp_bd_file
} else {
write_bd_tcl -no_project_wrapper -no_ip_version -make_local -include_layout $temp_bd_file
}
} else {
write_bd_tcl -no_project_wrapper -make_local -include_layout $temp_bd_file
if { $a_global_vars(b_no_layout) } {
write_bd_tcl -no_project_wrapper -make_local $temp_bd_file
} else {
write_bd_tcl -no_project_wrapper -make_local -include_layout $temp_bd_file
}
}

# Set non default properties for the BD
Expand Down Expand Up @@ -843,7 +855,9 @@ proc write_specified_fileset { proj_dir proj_name filesets } {
} else {
set rel_file_path "[get_relative_file_path_for_source $path [get_script_execution_dir]]"
# Filter out IP repositories outside of the project directory
if { [string first .. $rel_file_path] == 0 } { continue }
if { $a_global_vars(exclude_external_ips) } {
if { [string first .. $rel_file_path] == 0 } { continue }
}
set path "\[file normalize \"\$origin_dir/$rel_file_path\"\]"
lappend path_list $path
}
Expand Down