<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/43f6c6038861428f10bf07b236464273e9c0e206">https://github.com/macports/macports-ports/commit/43f6c6038861428f10bf07b236464273e9c0e206</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 43f6c60 ld64-latest: build 450.3
</span>43f6c60 is described below
<span style='display:block; white-space:pre;color:#808000;'>commit 43f6c6038861428f10bf07b236464273e9c0e206
</span>Author: Ken Cunningham <kencu@macports.org>
AuthorDate: Wed Jan 22 17:09:46 2020 -0800
<span style='display:block; white-space:pre;color:#404040;'> ld64-latest: build 450.3
</span><span style='display:block; white-space:pre;color:#404040;'>
</span><span style='display:block; white-space:pre;color:#404040;'> * add man pages if ld64-latest is installed
</span><span style='display:block; white-space:pre;color:#404040;'> * add build fixes for older systems
</span><span style='display:block; white-space:pre;color:#404040;'> * clarify compiler blacklisting for some older ld64 versions
</span><span style='display:block; white-space:pre;color:#404040;'> * add new ld64_274 subport
</span><span style='display:block; white-space:pre;color:#404040;'> * default systems that can't build libtapi with Xcode to ld64_274
</span><span style='display:block; white-space:pre;color:#404040;'> * add support for tests (universal tests TBA)
</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/57587
</span><span style='display:block; white-space:pre;color:#404040;'> closes: https://trac.macports.org/ticket/53784
</span>---
devel/ld64/Portfile | 126 ++++++++++++---
devel/ld64/files/Makefile-450 | 107 +++++++++++++
devel/ld64/files/dyld-655-availability.diff | 27 ++++
devel/ld64/files/ld64-409-Options-strndup.diff | 37 +++++
.../files/ld64-409-add-missing-machine-defs.diff | 23 +++
.../ld64/files/ld64-409-lto-file-llvm-3.4-fix.diff | 14 ++
.../ld64-409-options-disable-i386-warning.diff | 15 ++
.../ld64/files/ld64-409-snapshot-no-mkpath-np.diff | 169 +++++++++++++++++++++
.../ld64-450-move-baseplatform-def-to-header.diff | 50 ++++++
9 files changed, 549 insertions(+), 19 deletions(-)
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/devel/ld64/Portfile b/devel/ld64/Portfile
</span><span style='display:block; white-space:pre;color:#808080;'>index 2122a8b..8a58c16 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/devel/ld64/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/devel/ld64/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -6,8 +6,8 @@ PortGroup compiler_blacklist_versions 1.0
</span> name ld64
epoch 2
version 3
<span style='display:block; white-space:pre;background:#ffe0e0;'>-revision 1
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-set dyld_version 421.2
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+revision 2
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+set dyld_version 655.1.1
</span> categories devel
platforms darwin
maintainers {jeremyhu @jeremyhu} {kencu @kencu}
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -20,9 +20,9 @@ description ld64 is the new mach-o linker
</span> long_description ld64 combines several object files and libraries, \
resolves references, and produces an ouput file.
<span style='display:block; white-space:pre;background:#ffe0e0;'>-checksums dyld-421.2.tar.gz \
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- rmd160 8985a77c70b6018f456634f89142670834489a4d \
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- sha256 e922c4e78af8f7af14dd158f1db986f8eb260403e7a0dc67fa35279d2cfdceb7 \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+checksums dyld-655.1.1.tar.gz \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ rmd160 eef3ce30381e5fa23152c637e3bde2d8cf4cde0b \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ sha256 8ca6e3cf0263d3f69dfa65e0846e2bed051b0cff92e796352ad178e7e4c92f1d \
</span> ld64-97-standalone-libunwind-headers.patch \
rmd160 f6da71e097aa61b1055b3fdc12cd39aafed5f492 \
sha256 370d02757ea628b5dd145c099e42fc4eb88cc09cf459a59e32d14bbc9b4a105e \
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -37,8 +37,11 @@ checksums dyld-421.2.tar.gz \
</span> sha256 8ef36729b643201081ab45ebd8586ede8f9968bc17614b679a940faa82875ca6 \
ld64-274.2.tar.gz \
rmd160 16e57faf2b1d3f3808fb8e4b167cf23a14f106b0 \
<span style='display:block; white-space:pre;background:#ffe0e0;'>- sha256 175d89c419e99d49a7a5f7e4196d3cef4c9e19cc17a425c332e86df6b516f7d7
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ sha256 175d89c419e99d49a7a5f7e4196d3cef4c9e19cc17a425c332e86df6b516f7d7 \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ ld64-450.3.tar.gz \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ rmd160 4d263cff143228e021c438d3c2d1800ff367c895 \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ sha256 140619e676e099581771dbad98277850ff731cd23938bed95b4d7171616acca1 \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ size 729639
</span>
subport ld64-97 {
# Xcode 3.2.6
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -48,6 +51,7 @@ subport ld64-97 {
</span> set makefile "Makefile-97"
set ld64_ver 97
<span style='display:block; white-space:pre;background:#e0ffe0;'>+ # the fallbacks on all current systems (10.6+ at least) are not set up to build this
</span> compiler.blacklist-append *clang*
patchfiles-append \
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -76,6 +80,9 @@ subport ld64-127 {
</span> version 127.2
revision 14
<span style='display:block; white-space:pre;background:#e0ffe0;'>+ # multiple errors with macports clang versions newer than 3.7
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ compiler.blacklist-append {macports-clang-[5-9].0} macports-clang-devel
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span> set makefile "Makefile-127"
set ld64_ver 127
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -111,6 +118,9 @@ subport ld64-236 {
</span> # < 100 is a guess. Xcode 4.1 might work, so I'm leaving it as an option unless someone reports a failure.
compiler.blacklist-append *gcc* {clang < 100}
<span style='display:block; white-space:pre;background:#e0ffe0;'>+ # multiple errors with macports clang versions newer than 5.0
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ compiler.blacklist-append {macports-clang-[6-9].0} macports-clang-devel
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span> set makefile "Makefile-133"
set ld64_ver 236
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -138,17 +148,17 @@ subport ld64-236 {
</span> }
}
<span style='display:block; white-space:pre;background:#ffe0e0;'>-subport ld64-latest {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+subport ld64-274 {
</span> # Xcode 8.2.1
version 274.2
<span style='display:block; white-space:pre;background:#ffe0e0;'>- revision 2
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ revision 0
</span>
# https://trac.macports.org/ticket/43737
# https://trac.macports.org/ticket/50130
compiler.blacklist-append *gcc* {clang < 300}
set makefile "Makefile-274"
<span style='display:block; white-space:pre;background:#ffe0e0;'>- set ld64_ver latest
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set ld64_ver 274
</span>
patchfiles-append \
ld64-version.patch \
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -171,6 +181,43 @@ subport ld64-latest {
</span> supported_archs i386 x86_64
}
<span style='display:block; white-space:pre;background:#e0ffe0;'>+subport ld64-latest {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # Xcode 10.2
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ version 450.3
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set makefile "Makefile-450"
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ revision 0
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # https://trac.macports.org/ticket/43737
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # https://trac.macports.org/ticket/50130
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # clang 700.1.81 (10.10) fails with error: use of undeclared identifier '__builtin_mul_overflow'
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ compiler.blacklist-append *gcc* {clang < 701}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set ld64_ver latest
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ patchfiles-append \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ ld64-version.patch \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ ld64-133-no-CrashReporterClient.h.patch \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ ld64-136-i386-badAddress.patch \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ ld64-ppc-9610466.patch \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ ld64-409-snapshot-no-mkpath-np.diff \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ ld64-409-lto-file-llvm-3.4-fix.diff \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ ld64-409-Options-strndup.diff \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ ld64-409-add-missing-machine-defs.diff \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ ld64-409-options-disable-i386-warning.diff \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ ld64-450-move-baseplatform-def-to-header.diff \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ depends_lib-append port:libcxx port:libtapi
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ configure.cxx_stdlib libc++
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ configure.cxxflags-append -std=c++11
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # silence some warnings
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ configure.cxxflags-append -Wno-deprecated-declarations
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ configure.cxxflags-append -Wno-parentheses-equality
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ supported_archs i386 x86_64
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span> subport ld64-xcode {
version 2
}
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -184,21 +231,27 @@ if {${subport} eq ${name}} {
</span> # avoid cyclic macports-clang dep on 10.6/libc++
configure.cxx_stdlib
<span style='display:block; white-space:pre;background:#ffe0e0;'>- variant ld64_97 conflicts ld64_127 ld64_236 ld64_xcode description {Use ld64-97 as the default linker (last version that works on Tiger)} {}
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- variant ld64_127 conflicts ld64_97 ld64_236 ld64_xcode description {Use ld64-127 as the default linker (last version that supports ppc and works on Leopard)} {}
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- variant ld64_236 conflicts ld64_97 ld64_127 ld64_xcode description {Use ld64-236 as the default linker (last version that builds against OS X's libstdc++)} {}
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- variant ld64_xcode conflicts ld64_97 ld64_127 ld64_236 description {Use ld64-xcode as the default linker (version provided by the selected Xcode.app toolchain)} {}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ variant ld64_97 conflicts ld64_127 ld64_236 ld64_274 ld64_xcode description {Use ld64-97 as the default linker (last version that works on Tiger)} {}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ variant ld64_127 conflicts ld64_97 ld64_236 ld64_274 ld64_xcode description {Use ld64-127 as the default linker (last version that supports ppc and works on Leopard)} {}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ variant ld64_236 conflicts ld64_97 ld64_127 ld64_274 ld64_xcode description {Use ld64-236 as the default linker (last version that builds against OS X's libstdc++)} {}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ variant ld64_274 conflicts ld64_97 ld64_127 ld64_236 ld64_xcode description {Use ld64-274 as the default linker (last version that builds without libtapi support)} {}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ variant ld64_xcode conflicts ld64_97 ld64_127 ld64_236 ld64_274 description {Use ld64-xcode as the default linker (version provided by the selected Xcode.app toolchain)} {}
</span>
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {![variant_isset ld64_97] && ![variant_isset ld64_127]} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {![variant_isset ld64_97] && ![variant_isset ld64_127] && ![variant_isset ld64_236] && ![variant_isset ld64_274] && ![variant_isset ld64_xcode]} {
</span> if {${os.major} < 9} {
default_variants +ld64_97
} elseif {${os.major} < 11} {
<span style='display:block; white-space:pre;background:#e0ffe0;'>+ # os versions < 11 can't build newer ld64 versions with their stock xcode compilers
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # so need to call in clang-9.0 and that has a runtime dep on ld64 (circular)
</span> default_variants +ld64_127
<span style='display:block; white-space:pre;background:#e0ffe0;'>+ } elseif {${os.major} < 16} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # os versions < 16 can't build libtapi or newer ld64 versions with their stock xcode compilers
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # so need to call in clang-9.0 and that has a runtime dep on ld64 (circular)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ default_variants +ld64_274
</span> }
}
<span style='display:block; white-space:pre;background:#ffe0e0;'>- if {[vercmp $xcodeversion 9.0] >= 0} {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- # only ld64_xcode speaks tapi at present
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {[vercmp $xcodeversion 11.0] >= 0} {
</span> default_variants +ld64_xcode
}
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -208,6 +261,8 @@ if {${subport} eq ${name}} {
</span> set ld64_ver 127
} elseif {[variant_isset ld64_236]} {
set ld64_ver 236
<span style='display:block; white-space:pre;background:#e0ffe0;'>+ } elseif {[variant_isset ld64_274]} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ set ld64_ver 274
</span> } elseif {[variant_isset ld64_xcode]} {
set ld64_ver xcode
} else {
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -369,7 +424,8 @@ if {${subport} eq ${name}} {
</span> }
}
<span style='display:block; white-space:pre;background:#ffe0e0;'>- system "cd ${workpath}/dyld-${dyld_version} && patch -p0 < ${filespath}/dyld-421-no-blocks.patch"
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # what is in this patch might be done as reinplaces, as above.
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ system "cd ${workpath}/dyld-${dyld_version} && patch -p0 < ${filespath}/dyld-655-availability.diff"
</span> }
configure {
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -424,7 +480,18 @@ if {${subport} eq ${name}} {
</span> file rename ${destroot}${prefix}/bin/rebase ${destroot}${prefix}/bin/rebase-${ld64_ver}
file rename ${destroot}${prefix}/bin/unwinddump ${destroot}${prefix}/bin/unwinddump-${ld64_ver}
<span style='display:block; white-space:pre;background:#ffe0e0;'>- delete {*}[glob ${destroot}${prefix}/share/man/man1/*]
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # we can only install one set of man pages from one subport without file collisions
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # so install only the latest man pages, good for most installations
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {![string match ${subport} "${name}-latest"]} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ delete {*}[glob ${destroot}${prefix}/share/man/man1/*]
</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;'>+ # this is not presently working as we need to account for the name.1 -> name-${ld64_ver}.1 syntax
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # fs-traverse path ${destroot}${prefix}/share/man/man1 {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # if {[file isfile ${path}]} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # file rename ${path} ${path}-${ld64_ver}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # }
</span>
if {${llvm_version} != ""} {
system "install_name_tool -change ${prefix}/libexec/llvm-${llvm_version}/lib/libLTO.dylib \
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -435,4 +502,25 @@ if {${subport} eq ${name}} {
</span> }
}
<span style='display:block; white-space:pre;background:#e0ffe0;'>+# this should be in base
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+if {"${configure.sdkroot}" eq ""} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ configure.sdkroot "/"
</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;'>+# for a universal build, we need to run the tests for each arch and clean between
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+if {![variant_isset universal]} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ test.run yes
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ test.dir ${workpath}/ld64-${version}/unit-tests/test-cases
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ test.cmd perl ../bin/make-recursive.pl \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ CXX="${configure.cxx} -arch ${configure.build_arch}" \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ CC="${configure.cc} -arch ${configure.build_arch}" \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ BUILT_PRODUCTS_DIR="${workpath}/ld64-${version}" \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ LD_SYSROOT="${configure.sdkroot}" \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ LD="${workpath}/ld64-${version}/ld" \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ OSX_SDK="${configure.sdkroot}" \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ ARCH="${configure.build_arch}" \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ | perl ../bin/result-filter.pl
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ test.target
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span> livecheck.type none
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/devel/ld64/files/Makefile-450 b/devel/ld64/files/Makefile-450
</span>new file mode 100644
<span style='display:block; white-space:pre;color:#808080;'>index 0000000..3f63f00
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>--- /dev/null
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/devel/ld64/files/Makefile-450
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -0,0 +1,107 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ifdef LLVM_CONFIG
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+LLVM_CPPFLAGS := -I$(shell $(LLVM_CONFIG) --includedir) -DLTO_SUPPORT
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+LLVM_LDFLAGS := -L$(shell $(LLVM_CONFIG) --libdir) -Wl,-rpath,$(shell $(LLVM_CONFIG) --libdir) -lLTO
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+endif
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+CPPFLAGS = $(LLVM_CPPFLAGS) -Isrc/abstraction -Isrc/ld -Isrc/ld/parsers $(OTHER_CPPFLAGS)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+CFLAGS = -Os $(OTHER_CFLAGS)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+CXXFLAGS = -Os $(OTHER_CXXFLAGS)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+LDFLAGS = $(OTHER_LDFLAGS)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ifndef RANLIB
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+RANLIB = ranlib
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+endif
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ifndef AR
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+AR = ar
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+endif
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ifndef PREFIX
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+PREFIX = /usr
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+endif
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+# libprunetrie.a
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+all : src/ld/configure.h ObjectDump dyldinfo ld machocheck rebase unwinddump
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+src/ld/Snapshot.o : src/ld/compile_stubs.h
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+src/ld/compile_stubs.h : compile_stubs
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ echo "static const char *compile_stubs = " > $@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ cat $^ | sed s/\"/\\\\\"/g | sed s/^/\"/ | sed s/$$/\\\\n\"/ >> $@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ echo ";" >> $@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+src/ld/configure.h : src/create_configure
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ DERIVED_SOURCES_DIR=src/ld DERIVED_FILE_DIR=src/ld $^ > $@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ObjectDump : src/ld/debugline.o
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ObjectDump : src/ld/parsers/macho_relocatable_file.o
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ObjectDump : src/ld/parsers/lto_file.o
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ObjectDump : src/other/ObjectDump.o
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ $(CXX) $(LLVM_LDFLAGS) $(LDFLAGS) $^ -o $@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+dyldinfo : src/other/dyldinfo.o
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ $(CXX) $(LDFLAGS) -Wl,-exported_symbol,__mh_execute_header $^ -o $@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ld : src/ld/debugline.o
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ld : src/ld/ld.o
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ld : src/ld/InputFiles.o
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ld : src/ld/Options.o
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ld : src/ld/OutputFile.o
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ld : src/ld/Resolver.o
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ld : src/ld/Snapshot.o
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ld : src/ld/SymbolTable.o
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ld : src/ld/parsers/archive_file.o
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ld : src/ld/parsers/lto_file.o
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ld : src/ld/parsers/macho_dylib_file.o
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ld : src/ld/parsers/macho_relocatable_file.o
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ld : src/ld/parsers/opaque_section_file.o
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ld : src/ld/parsers/textstub_dylib_file.o
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ld : src/ld/passes/bitcode_bundle.o
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ld : src/ld/passes/branch_island.o
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ld : src/ld/passes/branch_shim.o
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ld : src/ld/passes/code_dedup.o
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ld : src/ld/passes/compact_unwind.o
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ld : src/ld/passes/dtrace_dof.o
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ld : src/ld/passes/dylibs.o
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ld : src/ld/passes/got.o
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ld : src/ld/passes/huge.o
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ld : src/ld/passes/objc.o
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ld : src/ld/passes/order.o
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ld : src/ld/passes/tlvp.o
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ld : src/ld/passes/stubs/stubs.o
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ld : src/ld/passes/thread_starts.o
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ $(CXX) $(LLVM_LDFLAGS) $(LDFLAGS) $(OTHER_LDFLAGS_LD64) -Wl,-exported_symbol,__mh_execute_header $^ -lxar -ltapi -o $@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+machocheck : src/other/machochecker.o
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ $(CXX) $(LDFLAGS) $^ -o $@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+rebase : src/other/rebase.o
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ $(CXX) $(LDFLAGS) -Wl,-exported_symbol,__mh_execute_header $^ -o $@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+unwinddump : src/other/unwinddump.o
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ $(CXX) $(LDFLAGS) -Wl,-exported_symbol,__mh_execute_header $^ -o $@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+src/other/PruneTrie.o : src/ld/configure.h
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+libprunetrie.a : src/other/PruneTrie.o
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ $(AR) cru $@ $^
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ $(RANLIB) $@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+install : all
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ install -d -m 755 $(DESTDIR)$(PREFIX)/bin
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ install -d -m 755 $(DESTDIR)$(PREFIX)/lib
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ install -d -m 755 $(DESTDIR)$(PREFIX)/include/mach-o
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ install -d -m 755 $(DESTDIR)$(PREFIX)/share/man/man1
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ install -m 755 ObjectDump $(DESTDIR)$(PREFIX)/bin
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ install -m 755 dyldinfo $(DESTDIR)$(PREFIX)/bin
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ install -m 755 ld $(DESTDIR)$(PREFIX)/bin
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ install -m 755 machocheck $(DESTDIR)$(PREFIX)/bin
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ install -m 755 rebase $(DESTDIR)$(PREFIX)/bin
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ install -m 755 unwinddump $(DESTDIR)$(PREFIX)/bin
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #install -m 644 src/other/prune_trie.h $(DESTDIR)$(PREFIX)/include/mach-o
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #install -m 644 libprunetrie.a $(DESTDIR)$(PREFIX)/lib
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ install -m 644 doc/man/man1/dyldinfo.1 $(DESTDIR)$(PREFIX)/share/man/man1
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ install -m 644 doc/man/man1/ld.1 $(DESTDIR)$(PREFIX)/share/man/man1
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ install -m 644 doc/man/man1/ld64.1 $(DESTDIR)$(PREFIX)/share/man/man1
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ install -m 644 doc/man/man1/rebase.1 $(DESTDIR)$(PREFIX)/share/man/man1
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ install -m 644 doc/man/man1/unwinddump.1 $(DESTDIR)$(PREFIX)/share/man/man1
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;color:#808080;'>diff --git a/devel/ld64/files/dyld-655-availability.diff b/devel/ld64/files/dyld-655-availability.diff
</span>new file mode 100644
<span style='display:block; white-space:pre;color:#808080;'>index 0000000..0238447
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>--- /dev/null
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/devel/ld64/files/dyld-655-availability.diff
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -0,0 +1,27 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+--- include/mach-o/dyld.h.orig 2020-01-26 11:37:27.000000000 -0800
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++++ include/mach-o/dyld.h 2020-01-26 11:37:39.000000000 -0800
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -35,6 +35,24 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ extern "C" {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #endif
</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;'>++#undef __OSX_AVAILABLE_STARTING
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#define __OSX_AVAILABLE_STARTING(...)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#undef __OSX_AVAILABLE_BUT_DEPRECATED
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#define __OSX_AVAILABLE_BUT_DEPRECATED(...)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#undef __OSX_AVAILABLE_BUT_DEPRECATED_MSG
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#define __OSX_AVAILABLE_BUT_DEPRECATED_MSG(...)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#undef __API_AVAILABLE
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#define __API_AVAILABLE(...)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#undef __API_UNAVAILABLE
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#define __API_UNAVAILABLE(...)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#undef __OSX_DEPRECATED
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#define __OSX_DEPRECATED(...)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#ifndef AVAILABLE_MAC_OS_X_VERSION_10_10_AND_LATER
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++# define AVAILABLE_MAC_OS_X_VERSION_10_10_AND_LATER __attribute__((unavailable))
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#endif
</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;'>+ * The following functions allow you to iterate through all loaded images.
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ * This is not a thread safe operation. Another thread can add or remove
</span><span style='display:block; white-space:pre;color:#808080;'>diff --git a/devel/ld64/files/ld64-409-Options-strndup.diff b/devel/ld64/files/ld64-409-Options-strndup.diff
</span>new file mode 100644
<span style='display:block; white-space:pre;color:#808080;'>index 0000000..6e15225
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>--- /dev/null
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/devel/ld64/files/ld64-409-Options-strndup.diff
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -0,0 +1,37 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+diff --git src/ld/Options.cpp.orig src/ld/Options.cpp
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+index 3fea3a0..63a9919 100644
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+--- src/ld/Options.cpp.orig
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++++ src/ld/Options.cpp
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -49,6 +49,32 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ // from FunctionNameDemangle.h
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ extern "C" size_t fnd_get_demangled_name(const char *mangledName, char *outputBuffer, size_t length);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#ifndef strnlen
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++size_t
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++strnlen (const char *s, size_t len)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++{
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ size_t i;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ for(i = 0; i < len && s[i]; i++)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ ;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ return i;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#endif
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#ifndef strndup
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++char *
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++strndup (const char *old, size_t sz)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++{
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ size_t len = strnlen (old, sz);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ char *t = (char *)malloc(len + 1);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ if (t != NULL) {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ memcpy (t, old, len);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ t[len] = '\0';
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ return t;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#endif
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ // upward dependency on lto::version()
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ namespace lto {
</span><span style='display:block; white-space:pre;color:#808080;'>diff --git a/devel/ld64/files/ld64-409-add-missing-machine-defs.diff b/devel/ld64/files/ld64-409-add-missing-machine-defs.diff
</span>new file mode 100644
<span style='display:block; white-space:pre;color:#808080;'>index 0000000..3a41bb4
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>--- /dev/null
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/devel/ld64/files/ld64-409-add-missing-machine-defs.diff
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -0,0 +1,23 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+diff --git src/ld/Options.h src/ld/Options.h
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+index 67ac22e..0788980 100644
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+--- src/ld/Options.h
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++++ src/ld/Options.h
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -38,6 +38,18 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #include "Snapshot.h"
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #include "MachOFileAbstraction.hpp"
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#ifndef CPU_SUBTYPE_ARM64_E
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++# define CPU_SUBTYPE_ARM64_E 2
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#endif
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#ifndef CPU_ARCH_ABI64_32
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++# define CPU_ARCH_ABI64_32 0x2000000
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#endif
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#ifndef CPU_TYPE_ARM64_32
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++# define CPU_TYPE_ARM64_32 ((cpu_type_t) (CPU_TYPE_ARM | CPU_ARCH_ABI64_32))
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#endif
</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;'>+ extern void throwf (const char* format, ...) __attribute__ ((noreturn,format(printf, 1, 2)));
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ extern void warning(const char* format, ...) __attribute__((format(printf, 1, 2)));
</span><span style='display:block; white-space:pre;color:#808080;'>diff --git a/devel/ld64/files/ld64-409-lto-file-llvm-3.4-fix.diff b/devel/ld64/files/ld64-409-lto-file-llvm-3.4-fix.diff
</span>new file mode 100644
<span style='display:block; white-space:pre;color:#808080;'>index 0000000..4d13e66
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>--- /dev/null
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/devel/ld64/files/ld64-409-lto-file-llvm-3.4-fix.diff
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -0,0 +1,14 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+--- ./src/ld/parsers/lto_file.cpp.orig 2020-01-26 12:28:10.000000000 -0800
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++++ ./src/ld/parsers/lto_file.cpp 2020-01-26 12:28:38.000000000 -0800
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -1681,7 +1681,11 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ //
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ unsigned int runtime_api_version()
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#if LTO_API_VERSION >= 17
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ return ::lto_api_version();
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#else
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ return LTO_API_VERSION;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#endif
</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;color:#808080;'>diff --git a/devel/ld64/files/ld64-409-options-disable-i386-warning.diff b/devel/ld64/files/ld64-409-options-disable-i386-warning.diff
</span>new file mode 100644
<span style='display:block; white-space:pre;color:#808080;'>index 0000000..3c349c6
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>--- /dev/null
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/devel/ld64/files/ld64-409-options-disable-i386-warning.diff
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -0,0 +1,15 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+--- src/ld/Options.cpp.orig 2020-01-28 09:10:14.000000000 -0800
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++++ src/ld/Options.cpp 2020-01-28 09:15:46.000000000 -0800
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -5897,8 +5897,10 @@
</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;'>+- if ( !internalSDK )
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+- warning("The i386 architecture is deprecated for macOS (remove from the Xcode build setting: ARCHS)");
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++// this warning generates unnecessary errors in configure stages -- disable for MacPorts as we
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++// intend to use this linker on older systems where i386 is still used
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++// if ( !internalSDK )
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++// warning("The i386 architecture is deprecated for macOS (remove from the Xcode build setting: ARCHS)");
</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;color:#808080;'>diff --git a/devel/ld64/files/ld64-409-snapshot-no-mkpath-np.diff b/devel/ld64/files/ld64-409-snapshot-no-mkpath-np.diff
</span>new file mode 100644
<span style='display:block; white-space:pre;color:#808080;'>index 0000000..4da55ca
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>--- /dev/null
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/devel/ld64/files/ld64-409-snapshot-no-mkpath-np.diff
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -0,0 +1,169 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+--- ./src/ld/Snapshot.cpp.orig 2020-01-26 11:39:26.000000000 -0800
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++++ ./src/ld/Snapshot.cpp 2020-01-26 11:40:12.000000000 -0800
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -23,6 +23,166 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #include "compile_stubs.h"
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++int
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++_mkpath_np(const char *path, mode_t omode, const char ** firstdir)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++{
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ char *apath = NULL;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ unsigned int depth = 0;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ mode_t chmod_mode = 0;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ int retval = 0;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ int old_errno = errno;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ struct stat sbuf;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ /* Try the trivial case first. */
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ if (0 == mkdir(path, omode)) {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ if (firstdir) {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ *firstdir = strdup(path);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ goto mkpath_exit;
</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;'>++ /* Anything other than an ENOENT, EEXIST, or EISDIR indicates an
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ * error that we need to send back to the caller. ENOENT indicates
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ * that we need to try a lower level.
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ */
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ switch (errno) {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ case ENOENT:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ break;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ case EEXIST:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ if (stat(path, &sbuf) == 0) {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ if (S_ISDIR(sbuf.st_mode)) {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ retval = EEXIST;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ } else {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ retval = ENOTDIR;
</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;'>++ retval = EIO;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ goto mkpath_exit;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ case EISDIR: /* <rdar://problem/10288022> */
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ retval = EEXIST;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ goto mkpath_exit;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ default:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ retval = errno;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ goto mkpath_exit;
</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;'>++ apath = strdup(path);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ if (apath == NULL) {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ retval = ENOMEM;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ goto mkpath_exit;
</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;'>++ while (1) {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ /* Increase our depth and try making that directory */
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ char *s = strrchr(apath, '/');
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ if (!s) {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ /* We should never hit this under normal circumstances,
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ * but it can occur due to really unfortunate timing
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ */
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ retval = ENOENT;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ goto mkpath_exit;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ *s = '\0';
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ depth++;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ if (0 == mkdir(apath, S_IRWXU | S_IRWXG | S_IRWXO)) {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ /* Found our starting point */
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ /* POSIX 1003.2:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ * For each dir operand that does not name an existing
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ * directory, effects equivalent to those cased by the
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ * following command shall occcur:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ *
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ * mkdir -p -m $(umask -S),u+wx $(dirname dir) &&
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ * mkdir [-m mode] dir
</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;'>++ struct stat dirstat;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ if (-1 == stat(apath, &dirstat)) {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ /* Really unfortunate timing ... */
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ retval = ENOENT;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ goto mkpath_exit;
</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 ((dirstat.st_mode & (S_IWUSR | S_IXUSR)) != (S_IWUSR | S_IXUSR)) {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ chmod_mode = dirstat.st_mode | S_IWUSR | S_IXUSR;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ if (-1 == chmod(apath, chmod_mode)) {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ /* Really unfortunate timing ... */
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ retval = ENOENT;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ goto mkpath_exit;
</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 (firstdir) {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ *firstdir = strdup(apath);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ break;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ } else if (errno == EEXIST) {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ /* Some other process won the race in creating this directory
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ * before we did. We will use this as our starting point.
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ * See: <rdar://problem/10279893>
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ */
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ if (stat(apath, &sbuf) == 0 &&
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ S_ISDIR(sbuf.st_mode)) {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ if (firstdir) {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ *firstdir = strdup(apath);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ }
</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;'>++ retval = ENOTDIR;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ goto mkpath_exit;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ } else if (errno != ENOENT) {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ retval = errno;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ goto mkpath_exit;
</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;'>++ while (depth > 1) {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ /* Decrease our depth and make that directory */
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ char *s = strrchr(apath, '\0');
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ *s = '/';
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ depth--;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ if (-1 == mkdir(apath, S_IRWXU | S_IRWXG | S_IRWXO)) {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ /* This handles "." and ".." added to the new section of path */
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ if (errno == EEXIST)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ continue;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ retval = errno;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ goto mkpath_exit;
</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 (chmod_mode) {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ if (-1 == chmod(apath, chmod_mode)) {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ /* Really unfortunate timing ... */
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ retval = ENOENT;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ goto mkpath_exit;
</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;'>++
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ if (-1 == mkdir(path, omode)) {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ retval = errno;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ if (errno == EEXIST &&
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ stat(path, &sbuf) == 0 &&
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ !S_ISDIR(sbuf.st_mode)) {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ retval = ENOTDIR;
</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;'>++mkpath_exit:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ free(apath);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ errno = old_errno;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ return retval;
</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;'>++int mkpath_np(const char *path, mode_t omode) {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ return _mkpath_np(path, omode, NULL);
</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;'>+ //#define STORE_PID_IN_SNAPSHOT 1
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ // Well known snapshot file/directory names. These appear in the root of the snapshot.
</span><span style='display:block; white-space:pre;color:#808080;'>diff --git a/devel/ld64/files/ld64-450-move-baseplatform-def-to-header.diff b/devel/ld64/files/ld64-450-move-baseplatform-def-to-header.diff
</span>new file mode 100644
<span style='display:block; white-space:pre;color:#808080;'>index 0000000..6fc7263
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>--- /dev/null
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/devel/ld64/files/ld64-450-move-baseplatform-def-to-header.diff
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -0,0 +1,50 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+diff --git src/ld/ld.cpp src/ld/ld.cpp
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+index 763bbd6..87c58a5 100644
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+--- src/ld/ld.cpp
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++++ src/ld/ld.cpp
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -89,20 +89,6 @@ extern "C" double log2 ( double );
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #include "parsers/lto_file.h"
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #include "parsers/opaque_section_file.h"
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+-const ld::Platform ld::basePlatform(const ld::Platform& platform) {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+- switch(platform) {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+- case ld::kPlatform_iOSMac:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+- case ld::kPlatform_iOSSimulator:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+- return ld::kPlatform_iOS;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+- case ld::kPlatform_watchOSSimulator:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+- return kPlatform_watchOS;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+- case ld::kPlatform_tvOSSimulator:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+- return ld::kPlatform_tvOS;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+- default:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+- return platform;
</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;'>+ const ld::VersionSet ld::File::_platforms;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ struct PerformanceStatistics {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+diff --git src/ld/ld.hpp src/ld/ld.hpp
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+index c8bf3f6..83bd5cf 100644
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+--- src/ld/ld.hpp
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++++ src/ld/ld.hpp
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -58,6 +58,20 @@ enum Platform {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ kPlatform_watchOSSimulator=9
</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;'>++static const Platform basePlatform(const ld::Platform& platform) {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ switch(platform) {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ case ld::kPlatform_iOSMac:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ case ld::kPlatform_iOSSimulator:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ return ld::kPlatform_iOS;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ case ld::kPlatform_watchOSSimulator:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ return kPlatform_watchOS;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ case ld::kPlatform_tvOSSimulator:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ return ld::kPlatform_tvOS;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ default:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ return platform;
</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;'>+ const ld::Platform basePlatform(const ld::Platform& platform);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ typedef std::set<Platform> PlatformSet;
</span></pre><pre style='margin:0'>
</pre>