// tracecmd.i %module ctracecmd %include "typemaps.i" %include "constraints.i" %nodefaultctor record; %nodefaultdtor record; %apply Pointer NONNULL { struct tracecmd_input *handle }; %apply Pointer NONNULL { struct pevent *pevent }; %apply Pointer NONNULL { struct format_field * }; %apply unsigned long long *OUTPUT {unsigned long long *} %apply int *OUTPUT {int *} %{ #include "trace-cmd.h" %} %ignore trace_seq_vprintf; /* SWIG can't grok these, define them to nothing */ #define __trace #define __attribute__(x) #define __thread %include "trace-cmd.h" %include "parse-events.h"