Based on mwhite73 <marvin.white@gmail.com> implementation Linked to the api system Also fix Makefile to support standard c++ files This prevent nvcc use without device code Signed-off-by: Tanguy Pruvot <tanguy.pruvot@gmail.com>