With Nsight EE you have several options:
Create a new project and copy the sources
You can use your shell or any file manager to copy source files to the project location. Make sure you manually refresh the project after you copied the files.
Creating a project in the same folder as your source files
In this post I will be using nbody CUDA Sample (note that Nsight also has a more native option to import CUDA samples, I will ignore that option here):
- Ran cuda-install-samples-6.0.sh to make a writable copy of samples in ~/dev/cuda/NVIDIA_CUDA-6.0_Samples
- In Nsight EE, go to File->New->CUDA C/C++ Project
On the first wizard page:
- Type in your project name (can be pretty much any string)
- Uncheck "Use default location" and select your root folder (~/dev/cuda/NVIDIA_CUDA-6.0_Samples/5_Simulations/nbody in my case)
- In the Project Type tree select Makefile Project/*Empty Project*
- Select CUDA Toolkit 5.5 in the Toolchains list.
- Complete the wizard
You will see newly created project with all your files in the Project Explorer view. Pressing Build will run make all
in your project location - you can customize this (among other things) in the project properties.
Note: Nsight will add several files to the root folder of your project.
Note: Some source editing features in Nsight may not work as reliably with Makefile projects as they do with the projects were Nsight maintains makefiles itself. Nsight does not know all compiler arguments passed from the custom makefile so it may not know all include paths or macro values.