2

I'm packaging a tool that includes some shared objects natively, and I think the right approach to add those objects to the rpath is to use the addAutoPatchelfSearchPath function to the installPhase of my Nix expression, but it's not picking up the .so libs as expected. I've tried setting the search path explicitly, relatively, etc. What would the correct usage be?

installPhase = ''
    mkdir -p $out
    addAutoPatchelfSearchPath $(pwd)
    cp -r $src $out
''
aionos242
  • 21
  • 1

1 Answers1

0

This is maybe a bit old, but in case someone still needs it, you should certainly use a path that is inside the $out directory (if you source it from the source file, since this will be deleted after build in has no chance to end up in a derivation):

addAutoPatchelfSearchPath $out/opt/Breitbandmessung

Note that the $out/lib folder is included by default.

tobiasBora
  • 3,376
  • 2
  • 23
  • 34