[PATCH] [mach-o] wire up a dylib's install-name in more places

Tim Northover t.p.northover at gmail.com
Tue Jul 1 01:24:56 PDT 2014


Hi Nick,

On 30 June 2014 22:20, kledzik at apple.com <kledzik at apple.com> wrote:
> One other thing to fix: If a dylib is built and there is no -install_name on the command line, whatever path is passed to -o should be used as the install name.

I'll work on that today. I'd like to get us defaulting to "a.out"
first so the two interact reasonably well together.

> Also what case of multiple yaml docs in one test case file is not working (and leading you to use Inputs/ files)/

It's the need to independently control which files appear in
individual lld RUN lines. If the single .yaml file contains a symbol
as both N_UNDF and not, we can't ensure that the .dylib we create gets
used to resolve it: both .o versions will be part of the second RUN
line making use of that .dylib as well.

> LC_ID_DYLIB traditionally goes after the LC_SEGMENT commands. So, just move this code up in the function.

Sounds reasonable, on the principle of least surprise and efficiency.
Though I do hope no tools actually depend on that.

I've committed it with that change as r212093. I'll be happy to change
the test if you know of any more cunning way to put it into a single
file.

Cheers.

Tim.



More information about the llvm-commits mailing list