Skip to content

No -R in MacOS X's ld #19

@DrMcCoy

Description

@DrMcCoy

Spawned off from here:

MacOS X's ld64-97.17 doesn't understand -R<dir>, thus -Wl,-R in BOOST_FIND_LIB() fails. Instead, it wants -rpath <dir>. That also works with GNU ld 2.21.0; however, I'm unsure about its portability.

The GNU ld manpage does seem to suggest that -R on a directory is only a compatibility option, and -rpath would be more correct:

For compatibility with other ELF linkers, if the -R option is followed by a
directory name, rather than a file name, it is treated as the -rpath option.

However, it also suggest that -rpath=<dir> (note the = instead of a space) would be correct, but that's also rejected by MacOS X's ld.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions