[Nix-dev] Get depmod to Work

Shea Levy shea at shealevy.com
Fri Mar 18 18:43:55 CET 2011


Currently, running `depmod` on a standard Nixos system will fail with:

Could not open 
/nix/store/...-kernel-modules/lib/modules2.6.XX.XX/modules.dep.temp for 
writing: No such file or directory.

That is, depmod is not putting a required directory separator between 
modules and 2.6.XX.XX. This results because bashrc.sh creates an 
/etc/bashrc that sets $MODULE_DIR to 
/nix/store/...-kernel-modules/lib/modules and module-dir.patch for 
module-init-tools simply concatenates $MODULE_DIR with the kernel 
version to get the directory name. This could be fixed by fixing 
bashrc.sh or by fixing module-dir.patch; I don't have time to go into 
the C right now but I've attached a patch that fixes bashrc.sh.

Cheers,
Shea Levy
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: fix-depmod.patch
Url: http://lists.science.uu.nl/pipermail/nix-dev/attachments/20110318/cc3664df/attachment.pl 


More information about the nix-dev mailing list