cabbage icon indicating copy to clipboard operation
cabbage copied to clipboard

local system libs

Open cocreature opened this issue 9 years ago • 3 comments

Sometimes you want to depend on a system library that is not yet on nixpkgs. That would require writing a .nix file for it, but I am not sure how to pass that lib to cabbage after having done that.

cocreature avatar Jun 04 '15 07:06 cocreature

Yeah, I lucked out in that there is already support for OS X frameworks. I'm pretty new to Nix, but I think this would be referred to as adding an impurity. What I'm not clear on yet is exactly how to plumb it through to the build environment of the package that needs it.

acowley avatar Jun 04 '15 15:06 acowley

I don't think you need an impurity for that. The lib could still be managed by nix and not by your system. You just need a way to build system libs from a .nix file.

cocreature avatar Jun 04 '15 16:06 cocreature

Oh, sorry, I misunderstood. I thought you wanted to avoid writing the Nix file and just wanted to pull in a .a from somewhere. Okay, right, this is definitely solveable. It just has to get pulled into the generated shell.nix, and passed on through like anything else. It will require a tweak to the way systemDeps are handled, but I think it will fit in that mechanism.

acowley avatar Jun 04 '15 16:06 acowley