4

I am new to Debian and I want to install the NVIDIA CUDA toolkit, so I typed:

apt install nvidia-cuda-toolkit

but it did not work, I found out I need to add a source in /etc/apt/sources.list which contains this CUDA package.

However, as for now there are only a few lines in /etc/apt/sources.list referring to a university, which I chose during installation.

I do not know how to find out which source I need to add.

Is there a Debian database, where I can submit the program I need and which in turn gives me a list of sources containing it?

einpoklum
  • 9,515
sharkant
  • 3,710

1 Answers1

7

The nvidia-cuda-toolkit package is a non-free software , edit your /etc/apt/sources.list by adding the non-free component :

apt edit-sources

Then edit your sources , there is an example:

deb http://deb.debian.org/debian stretch main contrib non-free

save and run:

apt update
apt install nvidia-cuda-toolkit 

Component

main consists of DFSG-compliant packages, which do not rely on software outside this area to operate. These are the only packages considered part of the Debian distribution.

contrib packages contain DFSG-compliant software, but have dependencies not in main (possibly packaged for Debian in non-free).

non-free contains software that does not comply with the DFSG.

GAD3R
  • 66,769
  • 1
    thank you very much, could anybody comment on what the "stretch main contrib non-free"-part means? – sharkant Jul 24 '17 at 18:46