<pre style='margin:0'>
Ken (kencu) pushed a commit to branch master
in repository macports-ports.
</pre>
<p><a href="https://github.com/macports/macports-ports/commit/65ae07502eb013acf3a2a57b790097c487f3edb0">https://github.com/macports/macports-ports/commit/65ae07502eb013acf3a2a57b790097c487f3edb0</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 65ae07502eb icu: fix universal build on Darwin20+
</span>65ae07502eb is described below
<span style='display:block; white-space:pre;color:#808000;'>commit 65ae07502eb013acf3a2a57b790097c487f3edb0
</span>Author: Ken Cunningham <kencu@macports.org>
AuthorDate: Sat Apr 10 15:56:43 2021 -0700
<span style='display:block; white-space:pre;color:#404040;'> icu: fix universal build on Darwin20+
</span><span style='display:block; white-space:pre;color:#404040;'>
</span><span style='display:block; white-space:pre;color:#404040;'> prior to 10.14, universal means different library bit depths or endianness,
</span><span style='display:block; white-space:pre;color:#404040;'> so we had to build separately and lipo together using the muniversal PG
</span><span style='display:block; white-space:pre;color:#404040;'>
</span><span style='display:block; white-space:pre;color:#404040;'> We can't easily use the muniversal PG on darwin20+ as during the build,
</span><span style='display:block; white-space:pre;color:#404040;'> icu has to run binaries to generate data, and the Intel Mac cannot run the
</span><span style='display:block; white-space:pre;color:#404040;'> arm64 binaries generated by the muniversal PortGroup.
</span><span style='display:block; white-space:pre;color:#404040;'>
</span><span style='display:block; white-space:pre;color:#404040;'> However we don't need to use the muniversal PortGroup because the universal
</span><span style='display:block; white-space:pre;color:#404040;'> build on Darwin20+ has the same library bit depth and endianness on both
</span><span style='display:block; white-space:pre;color:#404040;'> Intel and arm64.
</span><span style='display:block; white-space:pre;color:#404040;'>
</span><span style='display:block; white-space:pre;color:#404040;'> Therefore we can build universal in one pass using clang's ability to generate both archs at once.
</span><span style='display:block; white-space:pre;color:#404040;'>
</span><span style='display:block; white-space:pre;color:#404040;'> closes: https://trac.macports.org/ticket/62548
</span><span style='display:block; white-space:pre;color:#404040;'>
</span><span style='display:block; white-space:pre;color:#404040;'> no revbump as
</span><span style='display:block; white-space:pre;color:#404040;'> 1. this should change no files on disk already installed
</span><span style='display:block; white-space:pre;color:#404040;'> 2. a new version of icu is coming shortly
</span>---
devel/icu/Portfile | 23 ++++++++++++++++++-----
1 file changed, 18 insertions(+), 5 deletions(-)
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/devel/icu/Portfile b/devel/icu/Portfile
</span><span style='display:block; white-space:pre;color:#808080;'>index 924ce1abf69..8847ba1322d 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/devel/icu/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/devel/icu/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -35,7 +35,23 @@ set docdir ${prefix}/share/doc/${name}
</span>
if {${subport} eq ${name} || ${subport} eq "${name}-lx"} {
<span style='display:block; white-space:pre;background:#ffe0e0;'>- PortGroup muniversal 1.0
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # prior to 10.14, universal means different library bit depths or endianness,
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # so we had to build separately and lipo together using the muniversal PG
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # We can't easily use the muniversal PG on darwin20+ (footnote 1), however we don't
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # need to use it because the universal build there has the same library bit
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # depth and endianness on both Intel and arm64. Therefore we can build universal in
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # one pass using clang's ability to generate both archs at once.
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set using_muniversal_PG false
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {${os.platform} eq "darwin" && ${os.major} < 18} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set using_muniversal_PG true
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ PortGroup muniversal 1.0
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # ICU needs to run binaries when building, to generate its data. (see footnote 1).
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ merger_must_run_binaries yes
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ }
</span>
distname ${my_name}-[string map {. _} ${version}]-src
extract.suffix .tgz
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -67,14 +83,11 @@ if {${subport} eq ${name} || ${subport} eq "${name}-lx"} {
</span>
configure.universal_args-delete --disable-dependency-tracking
<span style='display:block; white-space:pre;background:#ffe0e0;'>- # ICU needs to run binaries when building, to generate its data. (see footnote 1).
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- merger_must_run_binaries yes
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-
</span> build.type gnu
build.args VERBOSE=1
post-build {
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {[variant_exists universal] && [variant_isset universal]} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {[variant_exists universal] && [variant_isset universal] && ${using_muniversal_PG}} {
</span> set dirs {}
foreach arch ${universal_archs_to_use} {
lappend dirs ${worksrcpath}-${arch}
</pre><pre style='margin:0'>
</pre>