<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/094c4a7f8e2143782d45dfa0cc59a71223eb2225">https://github.com/macports/macports-base/commit/094c4a7f8e2143782d45dfa0cc59a71223eb2225</a></p>
<pre style="white-space: pre; background: #F8F8F8"><span style='display:block; white-space:pre;color:#808000;'>commit 094c4a7f8e2143782d45dfa0cc59a71223eb2225
</span>Author: Joshua Root <jmr@macports.org>
AuthorDate: Sat Mar 5 17:07:23 2022 +1100
<span style='display:block; white-space:pre;color:#404040;'> Update fallback compiler selections
</span>---
src/port1.0/portconfigure.tcl | 72 +++++++++++++++++++++++++++++++------------
1 file changed, 53 insertions(+), 19 deletions(-)
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/src/port1.0/portconfigure.tcl b/src/port1.0/portconfigure.tcl
</span><span style='display:block; white-space:pre;color:#808080;'>index 03162f36..30ea0d48 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/src/port1.0/portconfigure.tcl
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/src/port1.0/portconfigure.tcl
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -1170,18 +1170,30 @@ proc portconfigure::get_clang_compilers {} {
</span> source ${compiler_file}
} else {
ui_debug "clang_compilers.tcl not found in ports tree, using built-in selections"
<span style='display:block; white-space:pre;background:#ffe0e0;'>- # clang 9.0 and older build on 10.6+ (darwin 10)
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- # clang 7.0 and older build on 10.5+ (darwin 9)
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- # clang 3.4 and older build on 10.4+ (darwin 8)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # clang 11 and older build on 10.6+ (darwin 10)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # clang 7.0 and older build on 10.5+ (darwin 9)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # clang 3.4 and older build on 10.4+ (darwin 8)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # Clang 11 and newer only on Apple Silicon
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # Clang 9.0 and newer only on 11+ (Darwin 20)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {${os.major} >= 11} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ lappend compilers macports-clang-13 macports-clang-12
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ }
</span> if {${os.major} >= 10} {
<span style='display:block; white-space:pre;background:#ffe0e0;'>- lappend compilers macports-clang-9.0 \
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- macports-clang-8.0
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ lappend compilers macports-clang-11
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {[option build_arch] ne "arm64"} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ lappend compilers macports-clang-10 macports-clang-9.0
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {${os.major} < 20} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ lappend compilers macports-clang-8.0
</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:#ffe0e0;'>- if {${os.major} >= 9} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {${os.major} >= 9 && ${os.major} < 20} {
</span> lappend compilers macports-clang-7.0 \
<span style='display:block; white-space:pre;background:#ffe0e0;'>- macports-clang-6.0 \
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- macports-clang-5.0
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ macports-clang-6.0 \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ macports-clang-5.0
</span> }
if {${os.major} < 16} {
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -1199,18 +1211,30 @@ proc portconfigure::get_clang_compilers {} {
</span> }
# utility procedure: get GCC compilers based on os.major
proc portconfigure::get_gcc_compilers {} {
<span style='display:block; white-space:pre;background:#ffe0e0;'>- global os.major porturl
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ global os.major os.arch porturl
</span> set compilers ""
set compiler_file [getportresourcepath $porturl "port1.0/compilers/gcc_compilers.tcl"]
if {[file exists ${compiler_file}]} {
source ${compiler_file}
} else {
ui_debug "gcc_compilers.tcl not found in ports tree, using built-in selections"
<span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span> if {${os.major} >= 10} {
<span style='display:block; white-space:pre;background:#ffe0e0;'>- # see https://trac.macports.org/ticket/57135
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- lappend compilers macports-gcc-8
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ lappend compilers macports-gcc-11 macports-gcc-10
</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;'>+ if {${os.arch} ne "arm"} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {${os.major} >= 10} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ lappend compilers macports-gcc-9 macports-gcc-8
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {${os.major} < 20} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ lappend compilers macports-gcc-7 macports-gcc-6 macports-gcc-5
</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;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {${os.major} >= 11} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ lappend compilers macports-gcc-devel
</span> }
<span style='display:block; white-space:pre;background:#ffe0e0;'>- lappend compilers macports-gcc-7 macports-gcc-6 macports-gcc-5
</span> }
return ${compilers}
}
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -1592,17 +1616,27 @@ proc portconfigure::add_compiler_port_dependencies {compiler} {
</span> source ${dependencies_file}
} else {
ui_debug "gcc_dependencies.tcl not found in ports tree, using built-in data"
<span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # GCC version providing the primary runtime
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # Note settings here *must* match those in the lang/libgcc port and compilers PG
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {${os.major} < 10} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set gcc_main_version 7
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ } else {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set gcc_main_version 11
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span> # compiler links against libraries in libgcc\d* and/or libgcc-devel
if {[vercmp ${gcc_version} 4.6] < 0} {
<span style='display:block; white-space:pre;background:#ffe0e0;'>- set libgccs "path:lib/libgcc/libgcc_s.1.dylib:libgcc port:libgcc45"
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set libgccs "path:share/doc/libgcc/README:libgcc port:libgcc45"
</span> } elseif {[vercmp ${gcc_version} 7] < 0} {
<span style='display:block; white-space:pre;background:#ffe0e0;'>- set libgccs "path:lib/libgcc/libgcc_s.1.dylib:libgcc port:libgcc6"
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- } elseif {[vercmp ${gcc_version} 8] < 0} {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- set libgccs "path:lib/libgcc/libgcc_s.1.dylib:libgcc port:libgcc7"
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- } elseif {[vercmp ${gcc_version} 9] < 0} {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- set libgccs "path:lib/libgcc/libgcc_s.1.dylib:libgcc port:libgcc8"
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set libgccs "path:share/doc/libgcc/README:libgcc port:libgcc6"
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ } elseif {[vercmp ${gcc_version} ${gcc_main_version}] < 0} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set libgccs "path:share/doc/libgcc/README:libgcc port:libgcc${gcc_version}"
</span> } else {
<span style='display:block; white-space:pre;background:#ffe0e0;'>- set libgccs "path:lib/libgcc/libgcc_s.1.dylib:libgcc"
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # Using primary GCC version
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # Do not depend directly on primary runtime port, as implied by libgcc
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # and doing so prevents libgcc-devel being used as an alternative.
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set libgccs "path:share/doc/libgcc/README:libgcc"
</span> }
}
foreach libgcc_dep $libgccs {
</pre><pre style='margin:0'>
</pre>