apt uses dpkg as back-end to install many apps, and for dpkg there is a /var/lib/dpkg/info directory , where there's many *.info files; these contain information on each and every file that came with a package.
Thus you can do grep -i --color 'nvcc' /var/lib/dpkg/info/*.list . That may generate a pretty large list, however, so to narrow it down we can use which utility.
which locates a particular binary/executable file. For instance,
xieerqi:$ grep $(which gnome-terminal) /var/lib/dpkg/info>
/var/lib/dpkg/info/gnome-terminal.list:/usr/bin/gnome-terminal.wrapper
/var/lib/dpkg/info/gnome-terminal.list:/usr/bin/gnome-terminal
This tells grep to take full path to gnome-terminal executable, and find which package has installed it. In this case the package was gnome-terminal.
A not so obvious case would be nm-tool
xieerqi:$ grep $(which nm-tool) /var/lib/dpkg/info/*.list
/var/lib/dpkg/info/network-manager.list:/usr/bin/nm-tool
We thus know, it belongs to network-manager package