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

gem-config: support rbnacl v6.0.0 #54262

Merged
merged 1 commit into from Jan 18, 2019
Merged

Conversation

smaximov
Copy link
Contributor

@smaximov smaximov commented Jan 18, 2019

Motivation for this change

With the v6.0.0 release of the rbnacl gem, it does not longer depend on rbnacl-libsodium gem (which is now deprecated (1)) to package the libsodium library and should use the one provided by the distribution; it raises an error if rbnacl-libsodium is detected (2). Unfortunately, default gem config patches rbnacl unconditionally (3), which means that newer versions of rbnacl fail at startup.

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS)
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nox --run "nox-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Determined the impact on package closure size (by running nix path-info -S before and after)
  • Assured whether relevant documentation is up to date
  • Fits CONTRIBUTING.md.

With the v6.0.0 release of the `rbnacl` gem, it does not longer depends
on `rbnacl-libsodium` gem (which is now deprecated ([1])) to package the
`libsodium` library and should use the one provided by the distribution;
it raises an error if `rbnacl-libsodium` is detected ([2]).
Unfortunately, default gem config patches `rbnacl` unconditionally ([3]),
which means that newer versions of `rbnacl` fail at startup.

[1]: RubyCrypto/rbnacl-libsodium#29
[2]: https://github.com/crypto-rb/rbnacl/blob/c176fc0bd8be74cf62c93a4b122e220ce4895348/lib/rbnacl.rb#L4-L8
[3]: https://github.com/NixOS/nixpkgs/blob/9fd099a6ae1690909ebf40145e4cdabd67179676/pkgs/development/ruby-modules/gem-config/default.nix#L300-L306
@zimbatm
Copy link
Member

zimbatm commented Jan 18, 2019

can we have some tests please?

@smaximov
Copy link
Contributor Author

@zimbatm is there any test for gem-config that I can use as a reference?

@zimbatm
Copy link
Member

zimbatm commented Jan 18, 2019

no, that's the problem, we have all the gem configs but they aren't tested. I am pretty sure some of them are breaking because of that.

Anyways, it's not a requirement. I just reacted because that gem config is getting more complicated than most.

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

Successfully merging this pull request may close these issues.

None yet

5 participants