1
0

default.nix 586 B

123456789101112131415161718192021222324
  1. { buildEnv, bundlerEnv, ruby_2_5, defaultGemConfig, fetchpatch }:
  2. let
  3. fix-yajl = fetchpatch {
  4. url = "https://github.com/chef/ffi-yajl/commit/ba84d91986c2d149f0a05132401e8ad9d17dab6c.diff";
  5. sha256 = "0vfmdxgpcd0v2y4r5k27lnydqh3hb0zg8f24hlrddi4p7xi93815";
  6. };
  7. gems = bundlerEnv rec {
  8. name = "chef";
  9. ruby = ruby_2_5;
  10. gemdir = ./.;
  11. gemConfig = defaultGemConfig // {
  12. ffi-yajl = attrs: {
  13. dontBuild = false;
  14. patches = (attrs.patches or []) ++ [ fix-yajl ];
  15. };
  16. };
  17. };
  18. in
  19. buildEnv {
  20. name = "chef-packages";
  21. paths = [ gems ];
  22. }