<pre style='margin:0'>
Chris Jones (cjones051073) pushed a commit to branch master
in repository macports-ports.
</pre>
<p><a href="https://github.com/macports/macports-ports/commit/ef749e5b8ea7877920cc428717d1bad26a69c975">https://github.com/macports/macports-ports/commit/ef749e5b8ea7877920cc428717d1bad26a69c975</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 ef749e5 gcc{9,10}: Better test for cctools active llvm variant
</span>ef749e5 is described below
<span style='display:block; white-space:pre;color:#808000;'>commit ef749e5b8ea7877920cc428717d1bad26a69c975
</span>Author: Chris Jones <jonesc@macports.org>
AuthorDate: Sun May 5 10:02:03 2019 +0100
<span style='display:block; white-space:pre;color:#404040;'> gcc{9,10}: Better test for cctools active llvm variant
</span>---
lang/gcc10/Portfile | 37 ++++++++++++++++++++++++++-----------
lang/gcc9/Portfile | 37 ++++++++++++++++++++++++++-----------
2 files changed, 52 insertions(+), 22 deletions(-)
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/lang/gcc10/Portfile b/lang/gcc10/Portfile
</span><span style='display:block; white-space:pre;color:#808080;'>index 84e1753..071447e 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/lang/gcc10/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/lang/gcc10/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -3,6 +3,7 @@
</span> PortSystem 1.0
PortGroup select 1.0
PortGroup compiler_blacklist_versions 1.0
<span style='display:block; white-space:pre;background:#e0ffe0;'>+PortGroup active_variants 1.1
</span>
epoch 3
name gcc10
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -95,17 +96,31 @@ configure.env-append \
</span> OTOOL=${prefix}/bin/otool \
OTOOL64=${prefix}/bin/otool
<span style='display:block; white-space:pre;background:#ffe0e0;'>-# Make sure the MP clang version used by cctool's 'as' is available at
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-# build time and used. Versions here must match those in cctools port.
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-if { ${os.major} == 12 || ${os.major} == 13 } {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- depends_build-append port:clang-3.7
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- configure.compiler macports-clang-3.7
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-} elseif { ${os.major} == 10 || ${os.major} == 11 } {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- depends_build-append port:clang-3.4
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- configure.compiler macports-clang-3.4
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-} elseif { ${os.major} >= 14 } {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- depends_build-append port:clang-7.0
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- configure.compiler macports-clang-7.0
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+# Make sure the MP clang version used by cctool's 'as' is available at build time and used.
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+if { ${os.major} > 10 } {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {![catch {set installed [lindex [registry_active cctools] 0]}]} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # cctools already installed, so figure out from registry what variant to use
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # list here must have all possible variants from cctools in it
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ foreach {llvm_v llvm_v_nodot} {3.4 34 3.7 37 3.9 39 4.0 40 5.0 50 6.0 60 7.0 70 8.0 80 devel dev} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {[active_variants cctools llvm${llvm_v_nodot} ""]} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ depends_build-append port:clang-${llvm_v}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ configure.compiler macports-clang-${llvm_v}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ break
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ } else {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # cctools is not yet installed, so have to play 'guess the default variant' :(
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # Logic here needs to match that used in cctools port.
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if { ${os.major} <= 11 } {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set llvm_v 3.4
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ } elseif { ${os.major} <= 13 } {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set llvm_v 3.7
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ } else {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set llvm_v 7.0
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ depends_build-append port:clang-${llvm_v}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ configure.compiler macports-clang-${llvm_v}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ }
</span> }
pre-configure {
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/lang/gcc9/Portfile b/lang/gcc9/Portfile
</span><span style='display:block; white-space:pre;color:#808080;'>index 22278fa..451b012 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/lang/gcc9/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/lang/gcc9/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -3,6 +3,7 @@
</span> PortSystem 1.0
PortGroup select 1.0
PortGroup compiler_blacklist_versions 1.0
<span style='display:block; white-space:pre;background:#e0ffe0;'>+PortGroup active_variants 1.1
</span>
epoch 2
name gcc9
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -100,17 +101,31 @@ configure.env-append \
</span> OTOOL=${prefix}/bin/otool \
OTOOL64=${prefix}/bin/otool
<span style='display:block; white-space:pre;background:#ffe0e0;'>-# Make sure the MP clang version used by cctool's 'as' is available at
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-# build time and used. Versions here must match those in cctools port.
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-if { ${os.major} == 12 || ${os.major} == 13 } {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- depends_build-append port:clang-3.7
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- configure.compiler macports-clang-3.7
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-} elseif { ${os.major} == 10 || ${os.major} == 11 } {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- depends_build-append port:clang-3.4
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- configure.compiler macports-clang-3.4
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-} elseif { ${os.major} >= 14 } {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- depends_build-append port:clang-7.0
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- configure.compiler macports-clang-7.0
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+# Make sure the MP clang version used by cctool's 'as' is available at build time and used.
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+if { ${os.major} > 10 } {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {![catch {set installed [lindex [registry_active cctools] 0]}]} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # cctools already installed, so figure out from registry what variant to use
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # list here must have all possible variants from cctools in it
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ foreach {llvm_v llvm_v_nodot} {3.4 34 3.7 37 3.9 39 4.0 40 5.0 50 6.0 60 7.0 70 8.0 80 devel dev} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {[active_variants cctools llvm${llvm_v_nodot} ""]} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ depends_build-append port:clang-${llvm_v}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ configure.compiler macports-clang-${llvm_v}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ break
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ } else {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # cctools is not yet installed, so have to play 'guess the default variant' :(
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # Logic here needs to match that used in cctools port.
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if { ${os.major} <= 11 } {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set llvm_v 3.4
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ } elseif { ${os.major} <= 13 } {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set llvm_v 3.7
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ } else {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set llvm_v 7.0
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ depends_build-append port:clang-${llvm_v}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ configure.compiler macports-clang-${llvm_v}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ }
</span> }
pre-configure {
</pre><pre style='margin:0'>
</pre>