<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 - Clang: The "x86_64-unknown-elf" target does not define __ELF__"
   href="https://bugs.llvm.org/show_bug.cgi?id=47036">47036</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>Clang: The "x86_64-unknown-elf" target does not define __ELF__
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>clang
          </td>
        </tr>

        <tr>
          <th>Version</th>
          <td>10.0
          </td>
        </tr>

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

        <tr>
          <th>OS</th>
          <td>other
          </td>
        </tr>

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

        <tr>
          <th>Severity</th>
          <td>normal
          </td>
        </tr>

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

        <tr>
          <th>Component</th>
          <td>-New Bugs
          </td>
        </tr>

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

        <tr>
          <th>Reporter</th>
          <td>kaeptmblaubaer1000@gmail.com
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>htmldeveloper@gmail.com, llvm-bugs@lists.llvm.org, neeilans@live.com, richard-llvm@metafoo.co.uk
          </td>
        </tr></table>
      <p>
        <div>
        <pre>kb1000 <<a href="mailto:kaeptmblaubaer1000@gmail.com">kaeptmblaubaer1000@gmail.com</a>>

Do., 6. Aug., 22:17 (vor 17 Stunden)

an Visual
Minimal reproduction:
clang -E -dM -target x86_64-unknown-elf -x c /dev/null
vs.
clang -E -dM -target x86_64-unknown-linux-elf -x c /dev/null

While you won't see __ELF__ for the first command, you will see it for the
second command.
Please note that I only verified this against clang 10.0.1.
I originally noticed this while trying to compile the Firework Kernel
(<a href="https://github.com/Firework-OS/Kernel">https://github.com/Firework-OS/Kernel</a>) on Termux, which uses libc++, which in
turn complains if it does not detect the object file format.</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>