No subject
Sun Dec 8 17:39:16 PST 2013
<h3>Modified Paths</h3>
<ul>
<li><a href=3D"#trunkbasesrcpackage10portarchivefetchtcl">trunk/base/src/=
package1.0/portarchivefetch.tcl</a></li>
<li><a href=3D"#trunkbasesrcpackage10portdmgtcl">trunk/base/src/package1.=
0/portdmg.tcl</a></li>
<li><a href=3D"#trunkbasesrcpackage10portdpkgtcl">trunk/base/src/package1=
.0/portdpkg.tcl</a></li>
<li><a href=3D"#trunkbasesrcpackage10portmdmgtcl">trunk/base/src/package1=
.0/portmdmg.tcl</a></li>
<li><a href=3D"#trunkbasesrcpackage10portmpkgtcl">trunk/base/src/package1=
.0/portmpkg.tcl</a></li>
<li><a href=3D"#trunkbasesrcpackage10portpkgtcl">trunk/base/src/package1.=
0/portpkg.tcl</a></li>
<li><a href=3D"#trunkbasesrcpackage10portrpmtcl">trunk/base/src/package1.=
0/portrpm.tcl</a></li>
<li><a href=3D"#trunkbasesrcpackage10portsrpmtcl">trunk/base/src/package1=
.0/portsrpm.tcl</a></li>
<li><a href=3D"#trunkbasesrcpackage10portunarchivetcl">trunk/base/src/pac=
kage1.0/portunarchive.tcl</a></li>
<li><a href=3D"#trunkbasesrcpackage10teststesttcl">trunk/base/src/package=
1.0/tests/test.tcl</a></li>
</ul>
</div>
<div id=3D"patch">
<h3>Diff</h3>
<a id=3D"trunkbasesrcpackage10portarchivefetchtcl"></a>
<div class=3D"modfile"><h4>Modified: trunk/base/src/package1.0/portarchiv=
efetch.tcl (116445 =3D> 116446)</h4>
<pre class=3D"diff"><span>
<span class=3D"info">--- trunk/base/src/package1.0/portarchivefetch.tcl 2=
014-01-25 16:46:33 UTC (rev 116445)
+++ trunk/base/src/package1.0/portarchivefetch.tcl 2014-01-25 16:48:01 UT=
C (rev 116446)
</span><span class=3D"lines">@@ -104,7 +104,7 @@
</span><span class=3D"cx"> }
</span><span class=3D"cx">=20
</span><span class=3D"cx"> # check if porturl itself points to an arc=
hive
</span><del>- if {[file rootname [file tail $porturl]] =3D=3D [file ro=
otname [get_portimage_name]] && [file extension $porturl] !=3D &q=
uot;"} {
</del><ins>+ if {[file rootname [file tail $porturl]] eq [file rootnam=
e [get_portimage_name]] && [file extension $porturl] ne "&qu=
ot;} {
</ins><span class=3D"cx"> lappend ret [string range $porturl 0 en=
d-[string length [file tail $porturl]]]:[string range [file extension $po=
rturl] 1 end]
</span><span class=3D"cx"> archive.subdir
</span><span class=3D"cx"> }
</span><span class=3D"lines">@@ -186,7 +186,7 @@
</span><span class=3D"cx"> if {${archivefetch.ignore_sslcert} !=3D &q=
uot;no"} {
</span><span class=3D"cx"> lappend fetch_options "--ignore-s=
sl-cert"
</span><span class=3D"cx"> }
</span><del>- if {$portverbose =3D=3D "yes"} {
</del><ins>+ if {$portverbose eq "yes"} {
</ins><span class=3D"cx"> lappend fetch_options "-v"
</span><span class=3D"cx"> }
</span><span class=3D"cx"> set sorted no
</span><span class=3D"lines">@@ -194,7 +194,7 @@
</span><span class=3D"cx"> set existing_archive [find_portarchive_pat=
h]
</span><span class=3D"cx">=20
</span><span class=3D"cx"> foreach {url_var archive} $archivefetch_ur=
ls {
</span><del>- if {![file isfile ${archivefetch.fulldestpath}/${arc=
hive}] && $existing_archive =3D=3D ""} {
</del><ins>+ if {![file isfile ${archivefetch.fulldestpath}/${arch=
ive}] && $existing_archive eq ""} {
</ins><span class=3D"cx"> ui_info "$UI_PREFIX [format [m=
sgcat::mc "%s doesn't seem to exist in %s"] $archive ${archivef=
etch.fulldestpath}]"
</span><span class=3D"cx"> if {![file writable ${archivefetch=
.fulldestpath}]} {
</span><span class=3D"cx"> return -code error [format [ms=
gcat::mc "%s must be writable"] ${archivefetch.fulldestpath}]
</span><span class=3D"lines">@@ -213,7 +213,7 @@
</span><span class=3D"cx"> set failed_sites 0
</span><span class=3D"cx"> unset -nocomplain fetched
</span><span class=3D"cx"> foreach site $urlmap($url_var) {
</span><del>- if {[string index $site end] !=3D "/&qu=
ot;} {
</del><ins>+ if {[string index $site end] ne "/"=
} {
</ins><span class=3D"cx"> append site "/[option =
archive.subdir]"
</span><span class=3D"cx"> } else {
</span><span class=3D"cx"> append site [option archiv=
e.subdir]
</span><span class=3D"lines">@@ -280,7 +280,7 @@
</span><span class=3D"cx"> }
</span><span class=3D"cx"> return 0
</span><span class=3D"cx"> }
</span><del>- if {[info exists ports_binary_only] && $ports_bi=
nary_only =3D=3D "yes"} {
</del><ins>+ if {[info exists ports_binary_only] && $ports_bin=
ary_only eq "yes"} {
</ins><span class=3D"cx"> return -code error "archivefetch f=
ailed for [option subport] @[option version]_[option revision][option por=
tvariants]"
</span><span class=3D"cx"> } else {
</span><span class=3D"cx"> return 0
</span></span></pre></div>
<a id=3D"trunkbasesrcpackage10portdmgtcl"></a>
<div class=3D"modfile"><h4>Modified: trunk/base/src/package1.0/portdmg.tc=
l (116445 =3D> 116446)</h4>
<pre class=3D"diff"><span>
<span class=3D"info">--- trunk/base/src/package1.0/portdmg.tcl 2014-01-25=
16:46:33 UTC (rev 116445)
+++ trunk/base/src/package1.0/portdmg.tcl 2014-01-25 16:48:01 UTC (rev 11=
6446)
</span><span class=3D"lines">@@ -91,13 +91,13 @@
</span><span class=3D"cx"> }
</span><span class=3D"cx">=20
</span><span class=3D"cx"> set hdiutil [findBinary hdiutil $portutil:=
:autoconf::hdiutil_path]
</span><del>- if {[system "$hdiutil create -quiet -fs HFS+ -volna=
me ${imagename} -srcfolder ${pkgpath} ${tmp_image}"] !=3D "&quo=
t;} {
</del><ins>+ if {[system "$hdiutil create -quiet -fs HFS+ -volnam=
e ${imagename} -srcfolder ${pkgpath} ${tmp_image}"] ne ""}=
{
</ins><span class=3D"cx"> return -code error [format [msgcat::mc =
"Failed to create temporary image: %s"] ${imagename}]
</span><span class=3D"cx"> }
</span><del>- if {[system "$hdiutil convert ${tmp_image} -format =
UDCO -o ${final_image} -quiet"] !=3D ""} {
</del><ins>+ if {[system "$hdiutil convert ${tmp_image} -format U=
DCO -o ${final_image} -quiet"] ne ""} {
</ins><span class=3D"cx"> return -code error [format [msgcat::mc =
"Failed to convert to final image: %s"] ${final_image}]
</span><span class=3D"cx"> }
</span><del>- if {[system "$hdiutil internet-enable -quiet -yes $=
{final_image}"] !=3D ""} {
</del><ins>+ if {[system "$hdiutil internet-enable -quiet -yes ${=
final_image}"] ne ""} {
</ins><span class=3D"cx"> return -code error [format [msgcat::mc =
"Failed to internet-enable: %s"] ${final_image}]
</span><span class=3D"cx"> }
</span><span class=3D"cx"> file delete -force "${tmp_image}"=
;
</span></span></pre></div>
<a id=3D"trunkbasesrcpackage10portdpkgtcl"></a>
<div class=3D"modfile"><h4>Modified: trunk/base/src/package1.0/portdpkg.t=
cl (116445 =3D> 116446)</h4>
<pre class=3D"diff"><span>
<span class=3D"info">--- trunk/base/src/package1.0/portdpkg.tcl 2014-01-2=
5 16:46:33 UTC (rev 116445)
+++ trunk/base/src/package1.0/portdpkg.tcl 2014-01-25 16:48:01 UTC (rev 1=
16446)
</span><span class=3D"lines">@@ -87,7 +87,7 @@
</span><span class=3D"cx"> set controlfd [open [file join ${controlpath}=
control] w+]
</span><span class=3D"cx">=20
</span><span class=3D"cx"> # Size, in kilobytes, of ${destpath}
</span><del>- set pkg_installed-size [expr [dirSize ${destpath}] / 102=
4]
</del><ins>+ set pkg_installed-size [expr {[dirSize ${destpath}] / 102=
4}]
</ins><span class=3D"cx">=20
</span><span class=3D"cx"> # Create debian dependency list
</span><span class=3D"cx"> if {[info exists dependencies]} {
</span><span class=3D"lines">@@ -97,12 +97,12 @@
</span><span class=3D"cx"> }
</span><span class=3D"cx">=20
</span><span class=3D"cx"> # Create dpkg version number
</span><del>- if {[expr [option epoch] !=3D 0]} {
</del><ins>+ if {[expr {[option epoch] !=3D 0}]} {
</ins><span class=3D"cx"> set pkg_version "[option epoch]:[option =
version]"
</span><span class=3D"cx"> } else {
</span><span class=3D"cx"> set pkg_version "[option version]"
</span><span class=3D"cx"> }
</span><del>- if {[expr [option revision] !=3D 0]} {
</del><ins>+ if {[expr {[option revision] !=3D 0}]} {
</ins><span class=3D"cx"> append pkg_version "-[option revision]&q=
uot;
</span><span class=3D"cx"> }
</span><span class=3D"cx">=20
</span><span class=3D"lines">@@ -146,7 +146,7 @@
</span><span class=3D"cx"> }
</span><span class=3D"cx">=20
</span><span class=3D"cx"> # An architecture-independent package
</span><del>- if {$supported_archs =3D=3D "noarch"} {
</del><ins>+ if {$supported_archs eq "noarch"} {
</ins><span class=3D"cx"> set pkg_arch "all"
</span><span class=3D"cx"> }
</span><span class=3D"cx">=20
</span></span></pre></div>
<a id=3D"trunkbasesrcpackage10portmdmgtcl"></a>
<div class=3D"modfile"><h4>Modified: trunk/base/src/package1.0/portmdmg.t=
cl (116445 =3D> 116446)</h4>
<pre class=3D"diff"><span>
<span class=3D"info">--- trunk/base/src/package1.0/portmdmg.tcl 2014-01-2=
5 16:46:33 UTC (rev 116445)
+++ trunk/base/src/package1.0/portmdmg.tcl 2014-01-25 16:48:01 UTC (rev 1=
16446)
</span><span class=3D"lines">@@ -91,13 +91,13 @@
</span><span class=3D"cx"> }
</span><span class=3D"cx">=20
</span><span class=3D"cx"> set hdiutil [findBinary hdiutil $portutil:=
:autoconf::hdiutil_path]
</span><del>- if {[system "$hdiutil create -quiet -fs HFS+ -volna=
me ${imagename} -srcfolder ${mpkgpath} ${tmp_image}"] !=3D "&qu=
ot;} {
</del><ins>+ if {[system "$hdiutil create -quiet -fs HFS+ -volnam=
e ${imagename} -srcfolder ${mpkgpath} ${tmp_image}"] ne ""=
} {
</ins><span class=3D"cx"> return -code error [format [msgcat::mc =
"Failed to create temporary image: %s"] ${imagename}]
</span><span class=3D"cx"> }
</span><del>- if {[system "$hdiutil convert ${tmp_image} -format =
UDCO -o ${final_image} -quiet"] !=3D ""} {
</del><ins>+ if {[system "$hdiutil convert ${tmp_image} -format U=
DCO -o ${final_image} -quiet"] ne ""} {
</ins><span class=3D"cx"> return -code error [format [msgcat::mc =
"Failed to convert to final image: %s"] ${final_image}]
</span><span class=3D"cx"> }
</span><del>- if {[system "$hdiutil internet-enable -quiet -yes $=
{final_image}"] !=3D ""} {
</del><ins>+ if {[system "$hdiutil internet-enable -quiet -yes ${=
final_image}"] ne ""} {
</ins><span class=3D"cx"> return -code error [format [msgcat::mc =
"Failed to internet-enable: %s"] ${final_image}]
</span><span class=3D"cx"> }
</span><span class=3D"cx"> file delete -force "${tmp_image}"=
;
</span></span></pre></div>
<a id=3D"trunkbasesrcpackage10portmpkgtcl"></a>
<div class=3D"modfile"><h4>Modified: trunk/base/src/package1.0/portmpkg.t=
cl (116445 =3D> 116446)</h4>
<pre class=3D"diff"><span>
<span class=3D"info">--- trunk/base/src/package1.0/portmpkg.tcl 2014-01-2=
5 16:46:33 UTC (rev 116445)
+++ trunk/base/src/package1.0/portmpkg.tcl 2014-01-25 16:48:01 UTC (rev 1=
16446)
</span><span class=3D"lines">@@ -91,7 +91,7 @@
</span><span class=3D"cx">=20
</span><span class=3D"cx"> foreach depspec $depends {
</span><span class=3D"cx"> set dep [_get_dep_port $depspec]
</span><del>- if {$dep !=3D ""} {
</del><ins>+ if {$dep ne ""} {
</ins><span class=3D"cx"> eval "lappend result [make_dep=
endency_list $dep $destination]"
</span><span class=3D"cx"> }
</span><span class=3D"cx"> }
</span><span class=3D"lines">@@ -272,7 +272,7 @@
</span><span class=3D"cx"> proc portmpkg::mpkg_write_info_plist {infofile=
portname portversion portrevision destination dependencies} {
</span><span class=3D"cx"> set vers [split $portversion "."=
]
</span><span class=3D"cx">=20
</span><del>- if {[string index $destination end] !=3D "/"} =
{
</del><ins>+ if {[string index $destination end] ne "/"} {
</ins><span class=3D"cx"> append destination /
</span><span class=3D"cx"> }
</span><span class=3D"cx">=20
</span></span></pre></div>
<a id=3D"trunkbasesrcpackage10portpkgtcl"></a>
<div class=3D"modfile"><h4>Modified: trunk/base/src/package1.0/portpkg.tc=
l (116445 =3D> 116446)</h4>
<pre class=3D"diff"><span>
<span class=3D"info">--- trunk/base/src/package1.0/portpkg.tcl 2014-01-25=
16:46:33 UTC (rev 116445)
+++ trunk/base/src/package1.0/portpkg.tcl 2014-01-25 16:48:01 UTC (rev 11=
6446)
</span><span class=3D"lines">@@ -51,7 +51,7 @@
</span><span class=3D"cx"> default package.resources {${workpath}/pkg_res=
ources}
</span><span class=3D"cx"> default package.scripts {${workpath}/pkg_scri=
pts}
</span><span class=3D"cx"> # Need productbuild to make flat packages real=
ly work
</span><del>-default package.flat {[expr [vercmp $macosx_deployment_t=
arget 10.6] >=3D 0]}
</del><ins>+default package.flat {[expr {[vercmp $macosx_deployment_t=
arget 10.6] >=3D 0}]}
</ins><span class=3D"cx">=20
</span><span class=3D"cx"> set_ui_prefix
</span><span class=3D"cx">=20
</span><span class=3D"lines">@@ -314,7 +314,7 @@
</span><span class=3D"cx">=20
</span><span class=3D"cx"> proc portpkg::write_welcome_html {filename por=
tname portepoch portversion portrevision long_description description hom=
epage} {
</span><span class=3D"cx"> set fd [open ${filename} w+]
</span><del>- if {$long_description =3D=3D ""} {
</del><ins>+ if {$long_description eq ""} {
</ins><span class=3D"cx"> set long_description $description
</span><span class=3D"cx"> }
</span><span class=3D"cx">=20
</span><span class=3D"lines">@@ -350,7 +350,7 @@
</span><span class=3D"cx"> <font face=3D\"Helvetica\">${l=
ong_description}</font>
</span><span class=3D"cx"> <p>"
</span><span class=3D"cx">=20
</span><del>- if {$homepage !=3D ""} {
</del><ins>+ if {$homepage ne ""} {
</ins><span class=3D"cx"> puts $fd "<font face=3D\"H=
elvetica\"><a href=3D\"${homepage}\">${homepage}&=
lt;/a></font><p>"
</span><span class=3D"cx"> }
</span><span class=3D"cx">=20
</span><span class=3D"lines">@@ -366,10 +366,10 @@
</span><span class=3D"cx"> if {[catch {set numFiles [llength [split [=
exec [findBinary lsbom $portutil::autoconf::lsbom_path] -s ${pkgpath}/Con=
tents/Archive.bom] "\n"]]} result]} {
</span><span class=3D"cx"> return -code error [format [msgcat::mc=
"Reading package bom failed: %s"] $result]
</span><span class=3D"cx"> }
</span><del>- if {[catch {set compressedSize [expr [dirSize ${pkgpath}=
] / 1024]} result]} {
</del><ins>+ if {[catch {set compressedSize [expr {[dirSize ${pkgpath}=
] / 1024}]} result]} {
</ins><span class=3D"cx"> return -code error [format [msgcat::mc =
"Error determining compressed size: %s"] $result]
</span><span class=3D"cx"> }
</span><del>- if {[catch {set installedSize [expr [dirSize ${destpath}=
] / 1024]} result]} {
</del><ins>+ if {[catch {set installedSize [expr {[dirSize ${destpath}=
] / 1024}]} result]} {
</ins><span class=3D"cx"> return -code error [format [msgcat::mc =
"Error determining installed size: %s"] $result]
</span><span class=3D"cx"> }
</span><span class=3D"cx"> if {[catch {set infoSize [file size ${pkgp=
ath}/Contents/Info.plist]} result]} {
</span><span class=3D"lines">@@ -503,11 +503,11 @@
</span><span class=3D"cx"> # subtracted, otherwise subtract '=
a'. Add 1 to the value
</span><span class=3D"cx"> # so that 'a' and 'A' are mapped t=
o 1, not 0.
</span><span class=3D"cx"> if {$ord < $ord_a} {
</span><del>- set j [expr $ord - $ord_A + 1]
</del><ins>+ set j [expr {$ord - $ord_A + 1}]
</ins><span class=3D"cx"> } else {
</span><del>- set j [expr $ord - $ord_a + 1]
</del><ins>+ set j [expr {$ord - $ord_a + 1}]
</ins><span class=3D"cx"> }
</span><del>- set i [expr 26*$i + $j]
</del><ins>+ set i [expr {26*$i + $j}]
</ins><span class=3D"cx"> }
</span><span class=3D"cx"> lappend vs $i
</span><span class=3D"cx"> }
</span></span></pre></div>
<a id=3D"trunkbasesrcpackage10portrpmtcl"></a>
<div class=3D"modfile"><h4>Modified: trunk/base/src/package1.0/portrpm.tc=
l (116445 =3D> 116446)</h4>
<pre class=3D"diff"><span>
<span class=3D"info">--- trunk/base/src/package1.0/portrpm.tcl 2014-01-25=
16:46:33 UTC (rev 116445)
+++ trunk/base/src/package1.0/portrpm.tcl 2014-01-25 16:48:01 UTC (rev 11=
6446)
</span><span class=3D"lines">@@ -81,7 +81,7 @@
</span><span class=3D"cx"> }
</span><span class=3D"cx">=20
</span><span class=3D"cx"> set rpmbuildarch ""
</span><del>- if {$supported_archs =3D=3D "noarch"} {
</del><ins>+ if {$supported_archs eq "noarch"} {
</ins><span class=3D"cx"> set rpmbuildarch "--target noarch&=
quot;
</span><span class=3D"cx"> } elseif {[variant_exists universal] &=
& [variant_isset universal]} {
</span><span class=3D"cx"> set rpmbuildarch "--target fat&qu=
ot;
</span><span class=3D"lines">@@ -227,7 +227,7 @@
</span><span class=3D"cx"> URL: ${homepage}
</span><span class=3D"cx"> BuildRoot: ${destroot}
</span><span class=3D"cx"> AutoReq: no"
</span><del>- if {[expr ${epoch} !=3D 0]} {
</del><ins>+ if {[expr {${epoch} !=3D 0}]} {
</ins><span class=3D"cx"> puts $specfd "Epoch: ${epoch}"
</span><span class=3D"cx"> }
</span><span class=3D"cx"> if {[llength ${dependencies}] !=3D 0} {
</span></span></pre></div>
<a id=3D"trunkbasesrcpackage10portsrpmtcl"></a>
<div class=3D"modfile"><h4>Modified: trunk/base/src/package1.0/portsrpm.t=
cl (116445 =3D> 116446)</h4>
<pre class=3D"diff"><span>
<span class=3D"info">--- trunk/base/src/package1.0/portsrpm.tcl 2014-01-2=
5 16:46:33 UTC (rev 116445)
+++ trunk/base/src/package1.0/portsrpm.tcl 2014-01-25 16:48:01 UTC (rev 1=
16446)
</span><span class=3D"lines">@@ -224,10 +224,10 @@
</span><span class=3D"cx"> URL: ${homepage}
</span><span class=3D"cx"> BuildRoot: %{_tmppath}/%{name}-%{version}-root
</span><span class=3D"cx"> Source0: ${portname}-Portfile"
</span><del>- if {$zip !=3D ""} {
</del><ins>+ if {$zip ne ""} {
</ins><span class=3D"cx"> puts $specfd "Source1: $zip"
</span><span class=3D"cx"> }
</span><del>- if {[expr ${epoch} !=3D 0]} {
</del><ins>+ if {[expr {${epoch} !=3D 0}]} {
</ins><span class=3D"cx"> puts $specfd "Epoch: ${epoch}"
</span><span class=3D"cx"> }
</span><span class=3D"cx"> set first 2
</span><span class=3D"lines">@@ -238,7 +238,7 @@
</span><span class=3D"cx"> puts -nonewline $specfd "Source${=
count}: "
</span><span class=3D"cx"> if {![info exists $fetch_urls]} {
</span><span class=3D"cx"> foreach {url_var distfile} ${fetch_ur=
ls} {
</span><del>- if {[string equal $distfile $file]} {
</del><ins>+ if {$distfile eq $file} {
</ins><span class=3D"cx"> global portfetch::$url_var mas=
ter_sites
</span><span class=3D"cx"> set site [lindex [set $url_va=
r] 0]
</span><span class=3D"cx"> set file [portfetch::assemble=
_url $site $distfile]
</span><span class=3D"lines">@@ -259,7 +259,7 @@
</span><span class=3D"cx"> }
</span><span class=3D"cx"> }
</span><span class=3D"cx"> set wrap_description [word_wrap ${long_des=
cription} 72]
</span><del>- if {$zip !=3D ""} {
</del><ins>+ if {$zip ne ""} {
</ins><span class=3D"cx"> set and "-a 1"
</span><span class=3D"cx"> } else {
</span><span class=3D"cx"> set and ""
</span></span></pre></div>
<a id=3D"trunkbasesrcpackage10portunarchivetcl"></a>
<div class=3D"modfile"><h4>Modified: trunk/base/src/package1.0/portunarch=
ive.tcl (116445 =3D> 116446)</h4>
<pre class=3D"diff"><span>
<span class=3D"info">--- trunk/base/src/package1.0/portunarchive.tcl 2014=
-01-25 16:46:33 UTC (rev 116445)
+++ trunk/base/src/package1.0/portunarchive.tcl 2014-01-25 16:48:01 UTC (=
rev 116446)
</span><span class=3D"lines">@@ -71,14 +71,14 @@
</span><span class=3D"cx"> set skipped 0
</span><span class=3D"cx"> if {[check_statefile target org.macports.u=
narchive $target_state_fd]} {
</span><span class=3D"cx"> return 0
</span><del>- } elseif {[info exists ports_source_only] && $po=
rts_source_only =3D=3D "yes"} {
</del><ins>+ } elseif {[info exists ports_source_only] && $por=
ts_source_only eq "yes"} {
</ins><span class=3D"cx"> ui_debug "Skipping unarchive ($sub=
port) since source-only is set"
</span><span class=3D"cx"> set skipped 1
</span><span class=3D"cx"> } elseif {[check_statefile target org.macp=
orts.destroot $target_state_fd]
</span><span class=3D"cx"> && [file isdirectory $de=
stroot]} {
</span><span class=3D"cx"> ui_debug "Skipping unarchive ($su=
bport) since destroot completed"
</span><span class=3D"cx"> set skipped 1
</span><del>- } elseif {[info exists ports_force] && $ports_fo=
rce =3D=3D "yes"} {
</del><ins>+ } elseif {[info exists ports_force] && $ports_for=
ce eq "yes"} {
</ins><span class=3D"cx"> ui_debug "Skipping unarchive ($sub=
port) since force is set"
</span><span class=3D"cx"> set skipped 1
</span><span class=3D"cx"> } else {
</span><span class=3D"lines">@@ -88,7 +88,7 @@
</span><span class=3D"cx"> if {${unarchive.path} !=3D ""=
;} {
</span><span class=3D"cx"> ui_debug "Found [string toupp=
er ${unarchive.type}] archive: ${unarchive.path}"
</span><span class=3D"cx"> } else {
</span><del>- if {[info exists ports_binary_only] && $=
ports_binary_only =3D=3D "yes"} {
</del><ins>+ if {[info exists ports_binary_only] && $p=
orts_binary_only eq "yes"} {
</ins><span class=3D"cx"> return -code error "Archiv=
e for ${subport} ${version}_${revision}${portvariants} not found, require=
d when binary-only is set!"
</span><span class=3D"cx"> } else {
</span><span class=3D"cx"> ui_debug "Skipping unarch=
ive ($subport) since no suitable archive found"
</span></span></pre></div>
<a id=3D"trunkbasesrcpackage10teststesttcl"></a>
<div class=3D"modfile"><h4>Modified: trunk/base/src/package1.0/tests/test=
.tcl (116445 =3D> 116446)</h4>
<pre class=3D"diff"><span>
<span class=3D"info">--- trunk/base/src/package1.0/tests/test.tcl 2014-01=
-25 16:46:33 UTC (rev 116445)
+++ trunk/base/src/package1.0/tests/test.tcl 2014-01-25 16:48:01 UTC (rev=
116446)
</span><span class=3D"lines">@@ -15,7 +15,7 @@
</span><span class=3D"cx"> }
</span><span class=3D"cx">=20
</span><span class=3D"cx"> proc print_help {arg} {
</span><del>- if { $arg =3D=3D "tests" } {
</del><ins>+ if { $arg eq "tests" } {
</ins><span class=3D"cx"> puts "The list of available tests =
is:"
</span><span class=3D"cx"> cd tests
</span><span class=3D"cx"> set test_suite [glob *.test]
</span><span class=3D"lines">@@ -34,11 +34,11 @@
</span><span class=3D"cx">=20
</span><span class=3D"cx"> # Process args
</span><span class=3D"cx"> foreach arg $argv {
</span><del>- if { $arg =3D=3D "-h" || $arg =3D=3D "-he=
lp" } {
</del><ins>+ if { $arg eq "-h" || $arg eq "-help" =
} {
</ins><span class=3D"cx"> print_help ""
</span><span class=3D"cx"> exit 0
</span><del>- } elseif { $arg =3D=3D "-debug" } {
- set index [expr [lsearch $argv $arg] + 1]
</del><ins>+ } elseif { $arg eq "-debug" } {
+ set index [expr {[lsearch $argv $arg] + 1}]
</ins><span class=3D"cx"> set level [lindex $argv $index]
</span><span class=3D"cx"> if { $level >=3D 0 && $leve=
l <=3D 3 } {
</span><span class=3D"cx"> append arguments "-debug &quo=
t; $level
</span><span class=3D"lines">@@ -46,32 +46,32 @@
</span><span class=3D"cx"> puts "Invalid debug level.&qu=
ot;
</span><span class=3D"cx"> exit 1
</span><span class=3D"cx"> }
</span><del>- } elseif { $arg =3D=3D "-t" } {
- set index [expr [lsearch $argv $arg] + 1]
</del><ins>+ } elseif { $arg eq "-t" } {
+ set index [expr {[lsearch $argv $arg] + 1}]
</ins><span class=3D"cx"> set test_name [lindex $argv $index]
</span><span class=3D"cx"> set no 0
</span><span class=3D"cx"> cd tests
</span><span class=3D"cx"> set test_suite [glob *.test]
</span><span class=3D"cx"> foreach test $test_suite {
</span><span class=3D"cx"> if { $test_name !=3D $test } {
</span><del>- set no [expr $no + 1]
</del><ins>+ set no [expr {$no + 1}]
</ins><span class=3D"cx"> }
</span><span class=3D"cx"> }
</span><span class=3D"cx"> if { $no =3D=3D [llength $test_suite] =
} {
</span><span class=3D"cx"> print_help tests
</span><span class=3D"cx"> exit 1
</span><span class=3D"cx"> }
</span><del>- } elseif { $arg =3D=3D "-l" } {
</del><ins>+ } elseif { $arg eq "-l" } {
</ins><span class=3D"cx"> print_help tests
</span><span class=3D"cx"> exit 0
</span><del>- } elseif { $arg =3D=3D "-nocolor" } {
</del><ins>+ } elseif { $arg eq "-nocolor" } {
</ins><span class=3D"cx"> set color_out "no"
</span><span class=3D"cx"> }
</span><span class=3D"cx"> }
</span><span class=3D"cx">=20
</span><span class=3D"cx">=20
</span><span class=3D"cx"> # Run tests
</span><del>-if { $test_name !=3D ""} {
</del><ins>+if { $test_name ne ""} {
</ins><span class=3D"cx"> set result [eval exec $tcl $test_name $argu=
ments 2>@stderr]
</span><span class=3D"cx"> puts $result
</span><span class=3D"cx">=20
</span><span class=3D"lines">@@ -109,7 +109,7 @@
</span><span class=3D"cx"> if { $fail !=3D 0 } { set err "ye=
s" }
</span><span class=3D"cx">=20
</span><span class=3D"cx"> set out ""
</span><del>- if { ($fail !=3D 0 || $skip !=3D 0) && $colo=
r_out =3D=3D "" } {
</del><ins>+ if { ($fail !=3D 0 || $skip !=3D 0) && $color=
_out eq "" } {
</ins><span class=3D"cx"> # Color failed tests.
</span><span class=3D"cx"> append out "\x1b\[1;31mTotal:=
" $total " Passed:" $pass " Failed:" $fail "=
; Skipped:" $skip " \x1b\[0m" $test
</span><span class=3D"cx"> } else {
</span><span class=3D"lines">@@ -124,13 +124,13 @@
</span><span class=3D"cx"> puts $out
</span><span class=3D"cx"> }
</span><span class=3D"cx"> if { $fail !=3D 0 } {
</span><del>- set end [expr [string first $test $result 0] - 1]
</del><ins>+ set end [expr {[string first $test $result 0] - 1}]
</ins><span class=3D"cx"> puts [string range $result 0 $end]
</span><span class=3D"cx"> }
</span><span class=3D"cx"> }
</span><span class=3D"cx"> }
</span><span class=3D"cx">=20
</span><span class=3D"cx"> # Return 1 if errors were found.
</span><del>-if {$err !=3D ""} { exit 1 }
</del><ins>+if {$err ne ""} { exit 1 }
</ins><span class=3D"cx">=20
</span><span class=3D"cx"> return 0
</span></span></pre>
</div>
</div>
</body>
</html>
--XTy5n1g1ehK--
More information about the macports-changes
mailing list