Nixpkgs/Patching Nixpkgs: Difference between revisions
Hustlerone (talk | contribs) nixpkgs-unstable'.src leads you back to nixpkgs-unstable. Might as well just use nixpkgs-unstable. |
Hustlerone (talk | contribs) oops |
||
| Line 44: | Line 44: | ||
]; | ]; | ||
}).src; | }).src; | ||
lib = nixpkgs-unstable'.lib; | |||
pkgs-unstable = import nixpkgs-unstable' { | pkgs-unstable-patched = import nixpkgs-unstable' { | ||
system = "x86_64-linux"; | system = "x86_64-linux"; | ||
}; | }; | ||
| Line 52: | Line 52: | ||
In the above example we create a derivation with the patch applied, called <code>nixpkgs-unstable'</code>. Pay attention we take the <code>src</code> attribute to get back the top-level (unpatched) nixpkgs. We can then access <code>lib</code> functions normally. We then import that new | In the above example we create a derivation with the patch applied, called <code>nixpkgs-unstable'</code>. Pay attention we take the <code>src</code> attribute to get back the top-level (unpatched) nixpkgs. We can then access <code>lib</code> functions normally. We then import that new | ||
derivation which we assign to <code>pkgs-unstable</code>. Now we can use <code>pkgs-unstable</code> to access the | derivation which we assign to <code>pkgs-unstable-patched</code>. Now we can use <code>pkgs-unstable-patched</code> to access the | ||
Ghidra 11.2 package, as well as any other packages normally available in nixpkgs. | Ghidra 11.2 package, as well as any other packages normally available in nixpkgs. | ||