[129506] trunk/dports
ionic at macports.org
ionic at macports.org
Sun Dec 14 16:11:38 PST 2014
Revision: 129506
https://trac.macports.org/changeset/129506
Author: ionic at macports.org
Date: 2014-12-14 16:11:38 -0800 (Sun, 14 Dec 2014)
Log Message:
-----------
PortGroup/{github,bitbucket}: rename source archives containing a top level dir of project-name-hash instead of name-version.
This patch enables this post-extract hook for all ports appending some
distfile location to master_sites, as long as the original github source
is left intact within the ${master_files} list.
Remove workarounds needed in a few ports to achieve exactly this.
Modified Paths:
--------------
trunk/dports/_resources/port1.0/group/bitbucket-1.0.tcl
trunk/dports/_resources/port1.0/group/github-1.0.tcl
trunk/dports/graphics/MyPaint/Portfile
trunk/dports/sysutils/peco/Portfile
Modified: trunk/dports/_resources/port1.0/group/bitbucket-1.0.tcl
===================================================================
--- trunk/dports/_resources/port1.0/group/bitbucket-1.0.tcl 2014-12-14 23:02:33 UTC (rev 129505)
+++ trunk/dports/_resources/port1.0/group/bitbucket-1.0.tcl 2014-12-15 00:11:38 UTC (rev 129506)
@@ -42,6 +42,8 @@
options bitbucket.livecheck_branch
default bitbucket.homepage {https://bitbucket.org/${bitbucket.author}/${bitbucket.project}}
+
+# Later code assumes that bitbucket.master_sites is a simple string, not a list.
default bitbucket.master_sites {${bitbucket.homepage}/get}
default bitbucket.tarball_from {tags}
@@ -90,9 +92,11 @@
fetch.ignore_sslcert yes
post-extract {
+ # It is assumed that bitbucket.master_sites is a simple string, not a list.
+ # Here be dragons.
if {![file exists ${worksrcpath}] && \
${fetch.type} eq "standard" && \
- ${master_sites} eq ${bitbucket.master_sites} && \
+ [lsearch -exact ${master_sites} ${bitbucket.master_sites}] != -1 && \
[llength ${distfiles}] > 0 && \
[llength [glob -nocomplain ${workpath}/*]] > 0} {
move [glob ${workpath}/*] ${worksrcpath}
Modified: trunk/dports/_resources/port1.0/group/github-1.0.tcl
===================================================================
--- trunk/dports/_resources/port1.0/group/github-1.0.tcl 2014-12-14 23:02:33 UTC (rev 129505)
+++ trunk/dports/_resources/port1.0/group/github-1.0.tcl 2014-12-15 00:11:38 UTC (rev 129506)
@@ -113,6 +113,8 @@
default github.homepage {https://github.com/${github.author}/${github.project}}
default github.raw {https://raw.githubusercontent.com/${github.author}/${github.project}}
+
+# Later code assumes that github.master_sites is a simple string, not a list.
default github.master_sites {${github.homepage}/tarball/[join ${github.tag_prefix} ""]${github.version}}
default master_sites {${github.master_sites}}
@@ -166,9 +168,11 @@
# that hash is every time the version number changes, rename the
# directory to the value of distname (not worksrcdir: ports may want to
# set worksrcdir to a subdirectory of the extracted directory).
+ # It is assumed that github.master_sites is a simple string, not a list.
+ # Here be dragons.
if {![file exists ${worksrcpath}] && \
${fetch.type} eq "standard" && \
- ${master_sites} eq ${github.master_sites} && \
+ [lsearch -exact ${master_sites} ${github.master_sites}] != -1 && \
[llength ${distfiles}] > 0 && \
[llength [glob -nocomplain ${workpath}/*]] > 0} {
if {[file exists [glob ${workpath}/${github.author}-${github.project}-*]] && \
Modified: trunk/dports/graphics/MyPaint/Portfile
===================================================================
--- trunk/dports/graphics/MyPaint/Portfile 2014-12-14 23:02:33 UTC (rev 129505)
+++ trunk/dports/graphics/MyPaint/Portfile 2014-12-15 00:11:38 UTC (rev 129506)
@@ -150,7 +150,6 @@
port:py27-gobject3
post-extract {
- eval move [glob ${workpath}/mypaint-mypaint-*] ${workpath}/mypaint-${git.branch}
delete ${workpath}/mypaint-${git.branch}/brushlib
eval move [glob ${workpath}/mypaint-libmypaint-*] ${workpath}/mypaint-${git.branch}/brushlib
}
Modified: trunk/dports/sysutils/peco/Portfile
===================================================================
--- trunk/dports/sysutils/peco/Portfile 2014-12-14 23:02:33 UTC (rev 129505)
+++ trunk/dports/sysutils/peco/Portfile 2014-12-15 00:11:38 UTC (rev 129506)
@@ -60,7 +60,6 @@
# :
set gopath ${workpath}/GOPATH
post-extract {
- move [glob ${workpath}/peco-*] ${worksrcpath}
file mkdir ${gopath}/src/github.com/peco
ln -s ${worksrcpath} ${gopath}/src/github.com/peco/peco
file mkdir ${gopath}/src/github.com/jessevdk
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.macosforge.org/pipermail/macports-changes/attachments/20141214/5f03edfc/attachment.html>
More information about the macports-changes
mailing list