<pre style='margin:0'>
David Strubbe (dstrubbe) pushed a commit to branch master
in repository macports-ports.
</pre>
<p><a href="https://github.com/macports/macports-ports/commit/74f6c824bf28eb2dab3c060c4de82c87f69c2f1b">https://github.com/macports/macports-ports/commit/74f6c824bf28eb2dab3c060c4de82c87f69c2f1b</a></p>
<pre style="white-space: pre; background: #F8F8F8">The following commit(s) were added to refs/heads/master by this push:
<span style='display:block; white-space:pre;color:#404040;'> new 74f6c82 mpi portgroup: Improve enforce_variants for depspec; move checks to configure and archivefetch.
</span>74f6c82 is described below
<span style='display:block; white-space:pre;color:#808000;'>commit 74f6c824bf28eb2dab3c060c4de82c87f69c2f1b
</span>Author: David Strubbe <dstrubbe@macports.org>
AuthorDate: Wed Jul 25 13:34:11 2018 -0700
<span style='display:block; white-space:pre;color:#404040;'> mpi portgroup: Improve enforce_variants for depspec; move checks to configure and archivefetch.
</span><span style='display:block; white-space:pre;color:#404040;'>
</span><span style='display:block; white-space:pre;color:#404040;'> Use of mpi.enforce_variant could be done with a depspec rather than a port name (e.g. path:/opt/local/lib/libplumedKernel.dylib:plumed) but the resulting error messages were not clear; now it will give the name of an actual port in messages. The pre-fetch checks on dependencies should be done in pre-configure since only then are the dependencies guaranteed to be installed; a similar check should be done in pre-archivefetch for binaries. (Similar to https://trac.macports.org/ticket/548 [...]
</span>---
_resources/port1.0/group/mpi-1.0.tcl | 14 ++++++++++----
1 file changed, 10 insertions(+), 4 deletions(-)
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/_resources/port1.0/group/mpi-1.0.tcl b/_resources/port1.0/group/mpi-1.0.tcl
</span><span style='display:block; white-space:pre;color:#808080;'>index 3cff0cf..2bbeedf 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/_resources/port1.0/group/mpi-1.0.tcl
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/_resources/port1.0/group/mpi-1.0.tcl
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -161,7 +161,8 @@ proc mpi.enforce_variant {args} {
</span> proc mpi.action_enforce_variants {ports} {
global name
ui_debug "mpi.enforce_variant list: ${ports}"
<span style='display:block; white-space:pre;background:#ffe0e0;'>- foreach portname $ports {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ foreach depspec $ports {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set portname [_get_dep_port $depspec]
</span> if {![catch {set result [active_variants $portname "" ""]}]} {
set otmpi [mpi_active_variant_name $portname]
set mympi [mpi_variant_name]
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -179,13 +180,14 @@ proc mpi.action_enforce_variants {ports} {
</span>
compilers.action_enforce_c $portname
} else {
<span style='display:block; white-space:pre;background:#ffe0e0;'>- ui_error "Internal error: '$portname' is not an installed port."
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ ui_error "Internal error: '$portname' does not refer to an installed port."
</span> }
}
}
<span style='display:block; white-space:pre;background:#ffe0e0;'>-# only run this if mpi is chosen
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-pre-fetch {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+pre-configure {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # This does not needed to be done in pre-archivefetch because if the archive is already built,
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # we will not need to use the Fortran MPI compiler, and the incompatibility only matters at compile time.
</span> if {[fortran_variant_isset] && [mpi_variant_isset]} {
set gcc_name ""
regexp (gcc\[0-9\]*) ${mpi.name} gcc_name
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -320,3 +322,7 @@ pre-fetch {
</span> }
mpi.action_enforce_variants ${mpi.required_variants}
}
<span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+pre-archivefetch {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ mpi.action_enforce_variants ${mpi.required_variants}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+}
</span></pre><pre style='margin:0'>
</pre>