Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to change all nix packages' RUNPATH to RPATH? #16767

Closed
amosbird opened this issue Jul 7, 2016 · 5 comments
Closed

How to change all nix packages' RUNPATH to RPATH? #16767

amosbird opened this issue Jul 7, 2016 · 5 comments

Comments

@amosbird
Copy link
Contributor

amosbird commented Jul 7, 2016

I have customized toolchains that rely on LD_LIBRARY_PATH while I still want to use binaries from nix-env like cmake and ninja.

LSB Version: :base-4.0-amd64:base-4.0-noarch:core-4.0-amd64:core-4.0-noarch:printing-4.0-amd64:printing-4.0-noarch
Distributor ID: CentOS
Description: CentOS release 6.7 (Final)
Release: 6.7
Codename: Final

nix-env (Nix) 1.11.2

@vcunat
Copy link
Member

vcunat commented Jul 7, 2016

That should be achieved by dropping our patch for it: https://github.com/NixOS/nixpkgs/blob/master/pkgs/development/tools/misc/binutils/default.nix#L21

Note that you'll have to build basically everything from scratch by yourself, if you take the simple direct approach.

@amosbird
Copy link
Contributor Author

amosbird commented Jul 8, 2016

@vcunat I was trying to do that but failed. It keeps giving me warnings about package conflicts. Could you give me some help build everything from scratch? Could we have an option in nix-env which lets user choose if they want rpath or not?

@vcunat
Copy link
Member

vcunat commented Jul 8, 2016

I don't think adding the option would help the conflicts (whatever those are exactly).

@amosbird
Copy link
Contributor Author

amosbird commented Jul 8, 2016

@vcunat I've cloned the nixpkgs repo and dropped the newdtags patch. After installing a brand new nix-env toolset, removing all the nix store and profiles, I did nix-env -f /path/to/my/nixpkgs -i binutils. It was compiling for a long time and finally gave me a confliction. What should I do?

@amosbird
Copy link
Contributor Author

@vcunat this dtags patch seems to have no effects on whether RPATH or RUNPATH being used. I've tried dropping the patch or setting link_info.new_dtags = FALSE;. All the nixpkgs still have RUNPATH being set instead of RPATH.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants