<html>
    <head>
      <base href="https://bugs.llvm.org/">
    </head>
    <body><table border="1" cellspacing="0" cellpadding="8">
        <tr>
          <th>Bug ID</th>
          <td><a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - ld64.lld.darwinnew-linked binaries don't run on macOS 10.13"
   href="https://bugs.llvm.org/show_bug.cgi?id=48395">48395</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>ld64.lld.darwinnew-linked binaries don't run on macOS 10.13
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>lld
          </td>
        </tr>

        <tr>
          <th>Version</th>
          <td>unspecified
          </td>
        </tr>

        <tr>
          <th>Hardware</th>
          <td>PC
          </td>
        </tr>

        <tr>
          <th>OS</th>
          <td>Linux
          </td>
        </tr>

        <tr>
          <th>Status</th>
          <td>NEW
          </td>
        </tr>

        <tr>
          <th>Severity</th>
          <td>enhancement
          </td>
        </tr>

        <tr>
          <th>Priority</th>
          <td>P
          </td>
        </tr>

        <tr>
          <th>Component</th>
          <td>MachO
          </td>
        </tr>

        <tr>
          <th>Assignee</th>
          <td>unassignedbugs@nondot.org
          </td>
        </tr>

        <tr>
          <th>Reporter</th>
          <td>nicolasweber@gmx.de
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>llvm-bugs@lists.llvm.org
          </td>
        </tr></table>
      <p>
        <div>
        <pre>Repro:
1. Download
<a href="https://drive.google.com/file/d/1Gjrg4bQCv3uD9Ucqt4ZtroHrz5v0iCJX/view?resourcekey=0-f53UMW57gtrPlSis2sTjKg">https://drive.google.com/file/d/1Gjrg4bQCv3uD9Ucqt4ZtroHrz5v0iCJX/view?resourcekey=0-f53UMW57gtrPlSis2sTjKg</a>
and unzip it

2. ~/src/llvm-project/out/gn/bin/ld64.lld.darwinnew @response.txt

3. ./base_unittests --gtest_filter='*Exception*'

on macOS 10.14+, that starts fine (the test fails, but that's issue 48389).

On macOS 10.13, it fails with:

```
dyld: Symbol not found: __objc_empty_cache
  Referenced from: /b/s/w/ir/out/gnmac/./base_unittests
  Expected in:
/System/Library/Frameworks/CoreFoundation.framework/Versions/A/CoreFoundation
 in /b/s/w/ir/out/gnmac/./base_unittests
```

(It works fine with ld64.)


MacOSX.sdk/System/Library/Frameworks/CoreFoundation.framework/CoreFoundation.tbd
has a re-export of MacOSX.sdk/usr/lib/libobjc.tbd, so maybe that symbol moved
between dylibs in 10.14, or dyld got more forgiving with incorrect two-level
namespaces or something.</pre>
        </div>
      </p>


      <hr>
      <span>You are receiving this mail because:</span>

      <ul>
          <li>You are on the CC list for the bug.</li>
      </ul>
    </body>
</html>