New Package That Manipulates Udev

I want to build a derivation that makes udev changes. Is there something additional I need to consider in such a case? Does it involve:

https://github.com/NixOS/nixpkgs/blob/0bfd0187dafe3f597355e6be16b7b9a5f4b90376/nixos/modules/services/hardware/udev.nix

somehow?

(BTW, the package in question is midisport-firmware.)

I had a look and the consensus seems to be to add udev rules to $out/lib/udev/rules.d/ and then add the package to services.udev.packages = [ my-package ]; either directly in configuration.nix or through a module. Below is a couple of example packages that do this.

1 Like

Thanks very much!

Let me chew on that a bit and try it. Iā€™ll report my results back here.

OK, I havenā€™t had a chance to try this yet because thereā€™s also a firmware component that must be built. The package depends up fxload, which is available. I just need to get a better understanding about how that works in a NixOS context.

Was there ever a solution to this? Iā€™d like to use my m-audio uno interface under nixos.

Yes, see the solution above: New Package That Manipulates Udev - #2 by Shou

1 Like

ah. I donā€™t really understand how to apply that to making midisport-firmware available in nixos. I was hoping for a nixos setting perhaps. Iā€™ll have to circle back to this when I have time to delve into what udev is and so forth.

You are probably better off opening a new thread than necrobumping a solved one, then.