Skip to content

Setting RUNPATH to lib directory #306

Open
@GertBurger

Description

@GertBurger

We vendor some 3rd party dependencies to reduce the number of system deps we have and to ensure consistency between installations.

Whilst evaluating this project as a basis for the python we'd like to ship we noticed that no RPATH or RUNPATH is set, which prevents loading of shared libraries from the most obvious location being the lib directory that is being shipped.

The only ticket I found that seems related is #227

I attempted to set the RUNPATH using pathelf but for some unknown reason it doesn't have any effect. Setting an RPATH worked but since it is deprecated and not really fit for our purpose we would rather not use it.

I'm not sure if it is possible to set a relocatable RUNPATH so setting a default one might not be possible. Being able to set one at all would be very useful.

My knowledge in this area is somewhat limited so I might be missing something obvious.

Thoughts?

P.S. the command was patchelf --set-rpath '/somepath/lib/' /somepath/bin/python3.9 where somepath is equivalent to the python directory in the release artifacts.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions