Cuda and library

How I can make a new library from anything program implemented on CUDA?
for example we have a program only doubled every cell of the array. the program called doubled.cu.
so the idea is:

include <doubled.lib>
main ()
init array
doubled (array)
exit

can you help me, please?
thank you