<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 - Wildcard in linker script matches non-SHF_ALLOC sections causing error"
   href="https://bugs.llvm.org/show_bug.cgi?id=44452">44452</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>Wildcard in linker script matches non-SHF_ALLOC sections causing error
          </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>ELF
          </td>
        </tr>

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

        <tr>
          <th>Reporter</th>
          <td>john.brawn@arm.com
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>llvm-bugs@lists.llvm.org, peter.smith@linaro.org
          </td>
        </tr></table>
      <p>
        <div>
        <pre>If you have the following linker script:
  SECTIONS
  {
    ALL 0x1000 : { *(*) }
  }

and try to link pretty much anything using it you get the errors

ld.lld: error: section type mismatch for .rela.plt
<span class="quote">>>> <internal>:(.rela.plt): SHT_RELA
>>> output section ALL: SHT_PROGBITS</span >

ld.lld: error: section type mismatch for .rela.dyn
<span class="quote">>>> <internal>:(.rela.dyn): SHT_RELA
>>> output section ALL: SHT_PROGBITS</span >

ld.lld: error: section type mismatch for .symtab
<span class="quote">>>> <internal>:(.symtab): SHT_SYMTAB
>>> output section ALL: SHT_PROGBITS</span >

ld.lld: error: section type mismatch for .symtab_shndx
<span class="quote">>>> <internal>:(.symtab_shndx): SHT_SYMTAB_SHNDX
>>> output section ALL: SHT_PROGBITS</span >

ld.lld: error: section type mismatch for .shstrtab
<span class="quote">>>> <internal>:(.shstrtab): SHT_STRTAB
>>> output section ALL: SHT_PROGBITS</span >

ld.lld: error: section type mismatch for .strtab
<span class="quote">>>> <internal>:(.strtab): SHT_STRTAB
>>> output section ALL: SHT_PROGBITS</span >

GNU ld doesn't match such sections for this same linker script, and instead
generates separate output sections for them.</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>