move libtcc interface and helper functions to libtcc.c