<pre style='margin:0'>
Joshua Root (jmroot) pushed a commit to branch master
in repository macports-base.
</pre>
<p><a href="https://github.com/macports/macports-base/commit/ed3e39b69cae00af70938cd114e43ea65fc67be9">https://github.com/macports/macports-base/commit/ed3e39b69cae00af70938cd114e43ea65fc67be9</a></p>
<pre style="white-space: pre; background: #F8F8F8"><span style='display:block; white-space:pre;color:#808000;'>commit ed3e39b69cae00af70938cd114e43ea65fc67be9
</span>Author: Joshua Root <jmr@macports.org>
AuthorDate: Mon Oct 30 05:59:51 2023 +1100
<span style='display:block; white-space:pre;color:#404040;'> macports.tcl: use list constructor
</span>---
src/macports1.0/macports.tcl | 52 ++++++++++++++++++++++----------------------
1 file changed, 26 insertions(+), 26 deletions(-)
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/src/macports1.0/macports.tcl b/src/macports1.0/macports.tcl
</span><span style='display:block; white-space:pre;color:#808080;'>index e22443fd5..133ca83a6 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/src/macports1.0/macports.tcl
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/src/macports1.0/macports.tcl
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -521,7 +521,7 @@ proc macports::set_developer_dir {name1 name2 op} {
</span>
# Ask mdfind where Xcode is and make some suggestions for the user,
# searching by bundle identifier for various Xcode versions (3.x and 4.x)
<span style='display:block; white-space:pre;background:#ffe0e0;'>- set installed_xcodes {}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set installed_xcodes [list]
</span>
macports_try -pass_signal {
set mdfind [findBinary mdfind $macports::autoconf::mdfind_path]
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -820,7 +820,7 @@ proc mportinit {{up_ui_options {}} {up_options {}} {up_variations {}}} {
</span> }
# Configure the search path for configuration files
<span style='display:block; white-space:pre;background:#ffe0e0;'>- set conf_files {}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set conf_files [list]
</span> lappend conf_files ${macports_conf_path}/macports.conf
if {[file isdirectory $macports_user_dir]} {
lappend conf_files ${macports_user_dir}/macports.conf
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -941,7 +941,7 @@ Please edit sources.conf and change '$url' to '[string range $url 0 end-6]tarbal
</span> array set macports::global_variations [array get variations]
# pubkeys.conf
<span style='display:block; white-space:pre;background:#ffe0e0;'>- set macports::archivefetch_pubkeys {}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set macports::archivefetch_pubkeys [list]
</span> if {[file isfile [file join $macports_conf_path pubkeys.conf]]} {
set fd [open [file join $macports_conf_path pubkeys.conf] r]
while {[gets $fd line] >= 0} {
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -2032,7 +2032,7 @@ proc mportopen_installed {name version revision variants options} {
</span> set regref [lindex [registry::entry imaged $name $version $revision $variants] 0]
set portfile_dir [file join ${registry.path} registry portfiles ${name}-${version}_${revision} [$regref portfile]]
<span style='display:block; white-space:pre;background:#ffe0e0;'>- set variations {}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set variations [list]
</span> # Relies on all negated variants being at the end of requested_variants
set minusvariant [lrange [split [$regref requested_variants] -] 1 end]
set plusvariant [lrange [split [$regref variants] +] 1 end]
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -2231,7 +2231,7 @@ proc _mportispresent {mport depspec} {
</span> #
# mport the port to check for conflicts
proc _mporterrorifconflictsinstalled {mport} {
<span style='display:block; white-space:pre;background:#ffe0e0;'>- set conflictlist {}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set conflictlist [list]
</span> array set portinfo [mportinfo $mport]
if {[info exists portinfo(conflicts)] &&
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -2395,7 +2395,7 @@ proc mportexec {mport target} {
</span> # User Interaction Question
# Asking before installing dependencies
if {[info exists macports::ui_options(questions_yesno)]} {
<span style='display:block; white-space:pre;background:#ffe0e0;'>- set deplist {}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set deplist [list]
</span> foreach ditem $dlist {
lappend deplist [ditem_key $ditem provides]
}
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -2516,13 +2516,13 @@ proc macports::_upgrade_mport_deps {mport target} {
</span> foreach depspec $portinfo($deptype) {
set dep_portname [$workername eval "_get_dep_port $depspec"]
if {$dep_portname ne "" && ![info exists depscache(port:$dep_portname)] && [$test $dep_portname]} {
<span style='display:block; white-space:pre;background:#ffe0e0;'>- set variants {}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set variants [list]
</span>
# check that the dep has the required archs
set active_archs [_active_archs $dep_portname]
if {$deptype ni {depends_fetch depends_extract} && $active_archs ni {{} noarch}
&& $required_archs ne "noarch" && $dep_portname ni $depends_skip_archcheck} {
<span style='display:block; white-space:pre;background:#ffe0e0;'>- set missing {}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set missing [list]
</span> foreach arch $required_archs {
if {$arch ni $active_archs} {
lappend missing $arch
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -2533,7 +2533,7 @@ proc macports::_upgrade_mport_deps {mport target} {
</span> array unset dep_portinfo
array set dep_portinfo [lindex $res 1]
if {[info exists dep_portinfo(installs_libs)] && !$dep_portinfo(installs_libs)} {
<span style='display:block; white-space:pre;background:#ffe0e0;'>- set missing {}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set missing [list]
</span> }
}
if {[llength $missing] > 0} {
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -2541,7 +2541,7 @@ proc macports::_upgrade_mport_deps {mport target} {
</span> # dep offers a universal variant
if {[llength $active_archs] == 1} {
# not installed universal
<span style='display:block; white-space:pre;background:#ffe0e0;'>- set missing {}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set missing [list]
</span> foreach arch $required_archs {
if {$arch ni $macports::universal_archs} {
lappend missing $arch
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -3582,7 +3582,7 @@ proc mportdepends {mport {target {}} {recurseDeps 1} {skipSatisfied 1} {accDeps
</span> set workername [ditem_key $mport workername]
set deptypes [macports::_deptypes_for_target $target $workername]
<span style='display:block; white-space:pre;background:#ffe0e0;'>- set depPorts {}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set depPorts [list]
</span> if {[llength $deptypes] > 0} {
# avoid propagating requested flag from parent
unset -nocomplain optionsarray(ports_requested)
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -3806,7 +3806,7 @@ proc macports::_active_archs {portname} {
</span> set ilist [registry::entry installed $portname]
set i [lindex $ilist 0]
if {[catch {$i archs} archs]} {
<span style='display:block; white-space:pre;background:#ffe0e0;'>- set archs {}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set archs [list]
</span> }
#catch {registry::entry close $i}
return $archs
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -4435,7 +4435,7 @@ proc macports::_upgrade {portname dspec variationslist optionslist {depscachenam
</span>
# check if the startupitem is loaded, so we can load again it after upgrading
# (deactivating the old version will unload the startupitem)
<span style='display:block; white-space:pre;background:#ffe0e0;'>- set loaded_startupitems {}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set loaded_startupitems [list]
</span> if {$portname eq $newname} {
set loaded_startupitems [$workername eval {portstartupitem::loaded}]
}
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -4687,7 +4687,7 @@ proc mportselect {command {group ""} {version {}}} {
</span> }
# Return the sorted list of versions (excluding base and current).
<span style='display:block; white-space:pre;background:#ffe0e0;'>- set lversions {}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set lversions [list]
</span> foreach v $versions {
# Only the file name corresponds to the version name.
set v [file tail $v]
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -5055,7 +5055,7 @@ proc macports::revupgrade_update_cxx_stdlib {fancy_output {revupgrade_progress "
</span> $revupgrade_progress update $i $maybe_cxx_len
}
incr i
<span style='display:block; white-space:pre;background:#ffe0e0;'>- set binary_files {}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set binary_files [list]
</span> foreach filehandle [registry::file search id [$maybe_port id] binary 1] {
lappend binary_files [$filehandle actual_path]
}
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -5104,7 +5104,7 @@ proc macports::revupgrade_scanandrebuild {broken_port_counts_name opts} {
</span>
revupgrade_update_cxx_stdlib $fancy_output $revupgrade_progress
<span style='display:block; white-space:pre;background:#ffe0e0;'>- set broken_files {}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set broken_files [list]
</span> set binaries [registry::file search active 1 binary 1]
set binary_count [llength $binaries]
if {$binary_count > 0} {
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -5324,7 +5324,7 @@ proc macports::revupgrade_scanandrebuild {broken_port_counts_name opts} {
</span> set num_broken_files [llength $broken_files]
set s [expr {$num_broken_files == 1 ? "" : "s"}]
<span style='display:block; white-space:pre;background:#ffe0e0;'>- set broken_ports {}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set broken_ports [list]
</span> if {$num_broken_files == 0} {
ui_msg "$macports::ui_prefix No broken files found."
} else {
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -5360,7 +5360,7 @@ proc macports::revupgrade_scanandrebuild {broken_port_counts_name opts} {
</span>
if {$macports::revupgrade_mode eq "rebuild"} {
# don't try to rebuild ports that don't exist in the tree
<span style='display:block; white-space:pre;background:#ffe0e0;'>- set temp_broken_ports {}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set temp_broken_ports [list]
</span> foreach port $broken_ports {
set portname [$port name]
if {[catch {mportlookup $portname} result]} {
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -5383,7 +5383,7 @@ proc macports::revupgrade_scanandrebuild {broken_port_counts_name opts} {
</span> set temp_broken_ports $broken_ports
}
<span style='display:block; white-space:pre;background:#ffe0e0;'>- set broken_ports {}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set broken_ports [list]
</span>
foreach port $temp_broken_ports {
set portname [$port name]
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -5435,8 +5435,8 @@ proc macports::revupgrade_scanandrebuild {broken_port_counts_name opts} {
</span> # now we need adjacents
foreach port $broken_ports {
# initialize with empty list
<span style='display:block; white-space:pre;background:#ffe0e0;'>- set adjlist($port) {}
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- set revadjlist($port) {}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set adjlist($port) [list]
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set revadjlist($port) [list]
</span> ui_debug "Broken: [$port name]"
}
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -5453,7 +5453,7 @@ proc macports::revupgrade_scanandrebuild {broken_port_counts_name opts} {
</span> }
set unsorted_ports $broken_ports
<span style='display:block; white-space:pre;background:#ffe0e0;'>- set topsort_ports {}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set topsort_ports [list]
</span> while {[llength $unsorted_ports] > 0} {
set lowest_adj_number [llength $adjlist([lindex $unsorted_ports 0])]
set lowest_adj_port [lindex $unsorted_ports 0]
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -5498,7 +5498,7 @@ proc macports::revupgrade_scanandrebuild {broken_port_counts_name opts} {
</span> }
}
<span style='display:block; white-space:pre;background:#ffe0e0;'>- set broken_portnames {}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set broken_portnames [list]
</span> if {![info exists macports::ui_options(questions_yesno)]} {
ui_msg "$macports::ui_prefix Rebuilding in order"
}
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -5747,8 +5747,8 @@ proc macports::get_tool_path {tool} {
</span> proc macports::get_archive_sites_conf_values {} {
global macports::archive_sites_conf_values macports::autoconf::macports_conf_path
if {![info exists archive_sites_conf_values]} {
<span style='display:block; white-space:pre;background:#ffe0e0;'>- set archive_sites_conf_values {}
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- set all_names {}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set archive_sites_conf_values [list]
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set all_names [list]
</span> set defaults_list {applications_dir /Applications/MacPorts prefix /opt/local type tbz2}
if {$macports::os_platform eq "darwin" && $macports::os_major <= 12} {
lappend defaults_list cxx_stdlib libstdc++ delete_la_files no
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -5770,7 +5770,7 @@ proc macports::get_archive_sites_conf_values {} {
</span> } elseif {[info exists cur_name]} {
set trimmedval [string trim $val]
if {$option eq "urls"} {
<span style='display:block; white-space:pre;background:#ffe0e0;'>- set processed_urls {}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set processed_urls [list]
</span> foreach url $trimmedval {
lappend processed_urls ${url}:nosubdir
}
</pre><pre style='margin:0'>
</pre>