[llvm-bugs] [Bug 39419] hello world example linker error

via llvm-bugs llvm-bugs at lists.llvm.org
Wed Oct 24 15:05:53 PDT 2018


https://bugs.llvm.org/show_bug.cgi?id=39419

Tim Northover <t.p.northover at gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         Resolution|---                         |INVALID
             Status|NEW                         |RESOLVED
                 CC|                            |t.p.northover at gmail.com

--- Comment #2 from Tim Northover <t.p.northover at gmail.com> ---
Yep, looks right to me. If you're linking a PIE executable (which your GCC
seems to default to and is reasonably sensible) then all your object files need
to be PIC. The way you do that on llc is via -relocation-model=pic.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20181024/baec3538/attachment.html>


More information about the llvm-bugs mailing list