have a look at the information center (online or locally) and have a look at "building platform specific applications" and also the reference to bldapp script to build applications..
- the source is an xx.sqc file
- db2 connect to ccc
- db2 prep xx.sqc bindfile (bnd file created)
- db2 bind the file
- compile the created xx.c file
Best Regards, Guy Przytula