<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/ee1728b145b90b2c12d2d7645f8e7e735383b370">https://github.com/macports/macports-ports/commit/ee1728b145b90b2c12d2d7645f8e7e735383b370</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 ee1728b libtapi: fix < 10.7
</span>ee1728b is described below
<span style='display:block; white-space:pre;color:#808000;'>commit ee1728b145b90b2c12d2d7645f8e7e735383b370
</span>Author: Ken Cunningham <kencu@macports.org>
AuthorDate: Mon Jan 27 20:47:01 2020 -0800
<span style='display:block; white-space:pre;color:#404040;'> libtapi: fix < 10.7
</span><span style='display:block; white-space:pre;color:#404040;'>
</span><span style='display:block; white-space:pre;color:#404040;'> I had hoped to keep LTO enabled for this, but the older default
</span><span style='display:block; white-space:pre;color:#404040;'> ld64-127 on 10.6.8 refuses to build it with LTO on. It may be possible
</span><span style='display:block; white-space:pre;color:#404040;'> to fix that -- but I'm not sure how to do that at present.
</span><span style='display:block; white-space:pre;color:#404040;'>
</span><span style='display:block; white-space:pre;color:#404040;'> Disabling LTO works.
</span>---
devel/libtapi/Portfile | 27 +++++++++++++++++----------
1 file changed, 17 insertions(+), 10 deletions(-)
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/devel/libtapi/Portfile b/devel/libtapi/Portfile
</span><span style='display:block; white-space:pre;color:#808080;'>index c2ccb8c..629eb4f 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/devel/libtapi/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/devel/libtapi/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -64,16 +64,23 @@ if {[string match macports-clang-* ${configure.compiler}]} {
</span> depends_skip_archcheck-append cctools
configure.args-append -DCMAKE_LIBTOOL=${prefix}/bin/libtool
<span style='display:block; white-space:pre;background:#ffe0e0;'>- # libtool will error on llvm bitcode generated by a clang version
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- # newer than the libLTO.dylib cctools is built against
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- # making sure cctools is built against the newest llvm in use prevents this, but we can't
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- # always guarantee that will be the case
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- # we can instead set DYLD_LIBRARY_PATH to the libLTO.dylib that matches the building clang
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- # then libtool will use that libLTO.dylib instead, which matches the clang objects
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- set clangversion [lindex [split ${configure.compiler} -] 2]
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- build.env DYLD_LIBRARY_PATH=${prefix}/libexec/llvm-$clangversion/lib/
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {${os.platform} eq "darwin" && ${os.major} < 11} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # the default ld64-127 linker cannot build this with LTO at present in this configuration
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # if we could test the linker version, we might be able to enable it
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # if a newer linker than 127 is installed -- not sure where the cutoff is
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ configure.args-append -DLLVM_ENABLE_LTO=OFF
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ } else {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # libtool will error on llvm bitcode generated by a clang version
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # newer than the libLTO.dylib cctools is built against
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # making sure cctools is built against the newest llvm in use prevents this, but we can't
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # always guarantee that will be the case
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # we can instead set DYLD_LIBRARY_PATH to the libLTO.dylib that matches the building clang
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # then libtool will use that libLTO.dylib instead, which matches the clang objects
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set clangversion [lindex [split ${configure.compiler} -] 2]
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ build.env DYLD_LIBRARY_PATH=${prefix}/libexec/llvm-$clangversion/lib/
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ }
</span> }
if {${os.platform} eq "darwin" && ${os.major} < 11} {
</pre><pre style='margin:0'>
</pre>