CUDA: Difference between revisions
imported>Hypnosis2839 m fix changed links |
imported>Luke No edit summary |
||
Line 85: | Line 85: | ||
* Even with the drivers correctly installed, some software, like Blender, may not see the CUDA GPU. Make sure your system configuration has the option <code>hardware.opengl.enable</code> enabled. | * Even with the drivers correctly installed, some software, like Blender, may not see the CUDA GPU. Make sure your system configuration has the option <code>hardware.opengl.enable</code> enabled. | ||
* By default, software packaged in source code form has CUDA support disabled, because of the unfree license. To solve this, you can enable builds with CUDA support with a nixpkgs wide configuration, or use binary packaged CUDA compatible software such as [https://github.com/edolstra/nix-warez/tree/master/blender blender-bin]. | * By default, software packaged in source code form has CUDA support disabled, because of the unfree license. To solve this, you can enable builds with CUDA support with a nixpkgs wide configuration, or use binary packaged CUDA compatible software such as [https://github.com/edolstra/nix-warez/tree/master/blender blender-bin]. | ||
== CUDA under WSL == | |||
This (surprisingly) works just fine using nixpkgs 23.05 provided that you prefix the <code>LD_LIBRARY_PATH</code> in your interactive environment with the WSL library directory. For nix shell this looks like: | |||
{{file|cuda-shell.nix|nix|<nowiki> | |||
shellHook = '' | |||
export CUDA_PATH=${pkgs.cudatoolkit} | |||
export LD_LIBRARY_PATH=/usr/lib/wsl/lib:${pkgs.linuxPackages.nvidia_x11}/lib:${pkgs.ncurses5}/lib | |||
export EXTRA_LDFLAGS="-L/lib -L${pkgs.linuxPackages.nvidia_x11}/lib" | |||
export EXTRA_CCFLAGS="-I/usr/include" | |||
''; | |||
</nowiki>}} | |||
== See also == | == See also == |