util/cb2replay.sh: Add C header and output compileable file

With this change, we define the helper functions that we make up, and
generate a C file that can be added directly to the coreboot tree.

Signed-off-by: Alexandru Gagniuc <mr.nuke.me@gmail.com>