#!/usr/bin/env python

# Generate the code
from pygccxml import parser
from pygccxml import declarations
from pyplusplus.module_builder import ctypes_module_builder_t, ctypes_decls_dependencies
shared_library_path = './lib.so'
header_file = './lib.c'
gccxml_cfg = parser.gccxml_configuration_t()
mb = ctypes_module_builder_t( [header_file], shared_library_path, gccxml_config=gccxml_cfg )
mb.global_ns.decl('cb_fun_t').include()
mb.build_code_creator(shared_library_path)
mb.write_module('api.py')

