Step 2: Check where your cuda installation is. For the installation from the repository it is /usr/lib/... and /usr/include. Otherwise, it will be /usr/local/cuda/ or /usr/local/cuda-<version>. You can check it with which nvcc or ldconfig -p | grep cuda
Refer the NVIDIA's CUDA Installation Guide page 32/33(_according to PDF reader page 36/37) for more details on how to install at the custom location for the CUDA libaries, and also what environment variables to set to make it work.
As per the documentation:
The Runfile can be extracted into the standalone Toolkit, Samples and
Driver Runfiles by using the --extract parameter. The Toolkit and Samples
standalone Runfiles can be further extracted by running:
$ ./runfile.run --tar mxvf
The Driver Runfile can be extracted by running:
$ ./runfile.run -x
For debian systems:
$ dpkg-deb -x package.deb output_dir
# Where package.deb is the downloaded debian package for cuda
# and output_dir is the directory where you want to extract the files.
As commented by the OP the installation guide page 34 ( PDF Reader Page 38) contains the necessary steps/references posted below for reference here:
How do I install the Toolkit in a different location?
The Runfile installation asks where you wish to install the Toolkit and the
Samples during an interactive install. If installing using a non-interactive
install, you can use the --toolkitpath and --samplespath parameters to
change the install location:
$ ./runfile.run --silent \
--toolkit --toolkitpath=/my/new/toolkit \
The RPM and Deb packages cannot be installed to a custom install location
directly using the package managers. See the "Install CUDA to a specific
directory using the Package Manager installation method" scenario in the
Advanced Setup section for more information.