[Nix-dev] Get depmod to Work

Shea Levy shea at shealevy.com
Fri Mar 18 19:18:12 CET 2011


On 3/18/11 2:13 PM, Eelco Dolstra wrote:
> Hi,
>
> On 03/18/2011 06:43 PM, Shea Levy wrote:
>
>> 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.
>
> You're not supposed to run "depmod" outside of the builder of 
> kernel-modules because it's impure (it ends up overwriting the depmod 
> files generated by the builder).
>
> Note that kernel-modules' builder does put a / at the end of $MODULE_DIR:
>
>
> https://svn.nixos.org/repos/nix/nixpkgs/trunk/pkgs/os-specific/linux/module-init-tools/aggregator.nix 
>
>
> If you want to add additional modules to the kernel configuration, you 
> should add them to the boot.extraModulePackages option and run 
> "nixos-rebuild switch".
>

Perhaps it's wrong to run it outside of the builder, but shouldn't it 
still work, or at least fail with a more graceful error message?



More information about the nix-dev mailing list