This is an archive of the discontinued LLVM Phabricator instance.

[macho] -rpath support
ClosedPublic

Authored by Jean-Daniel on Dec 18 2014, 10:54 AM.

Details

Summary

Work on adding -rpath support to the mach-o linker.
This patch is based on the ld64 behavior for the command line option validation.

It includes a basic test to check that the LC_RPATH load commands are properly generated when that option is used.

It also add LC_RPATH support to the binary reader, but I don't know how to test it though.

Diff Detail

Repository
rL LLVM

Event Timeline

Jean-Daniel retitled this revision from to [macho] -rpath support.
Jean-Daniel updated this object.
Jean-Daniel edited the test plan for this revision. (Show Details)
Jean-Daniel added a reviewer: kledzik.
Jean-Daniel set the repository for this revision to rL LLVM.
Jean-Daniel added a project: lld.
Jean-Daniel added a subscriber: Unknown Object (MLST).
kledzik edited edge metadata.Dec 18 2014, 12:00 PM

LGTM.

The static linker does not need to interpret LC_RPATH in linked dylibs, so there is no need to write a test case that it can.

This revision was automatically updated to reflect the committed changes.