LEXUGE / oceanix

OpenCore bootloader manager with Nix
GNU General Public License v3.0
32 stars 1 forks source link

Packaging other kexts #1

Open JJTech0130 opened 1 year ago

JJTech0130 commented 1 year ago

I see that README mentions the ability to package other kexts not included with oceanix, however, it's not entirely clear on the proper way to go about this. I'm not really that familiar with Nix, so I haven't been able to figure this out myself (other than just dropping the kext into the folder, which isn't ideal).

Any help would be greatly appreciated!

(For reference, the specific kexts I want to package are RealtekRTL8111 and CtlnaAHCIPort)

LEXUGE commented 1 year ago

In order to use the self-packaged kext in your own config, you have to first know how to reference a package in nix.

Other than that, if you only care about the latest version, the essential skeleton is like the one here https://github.com/LEXUGE/oceanix/blob/main/pkgs/kexts/intel-mausi/intel-mausi.nix

Basically it tells Nix to download the release file and checksum it. Then copy the kext into the output folder. Note that output folder structure has to be like Kexts/YourKext.kext.

You can read the nixpkgs guide to get a better idea.