In order to control the kernel-side GTP-U plane, a netlink based control interface between GTP-C in userspace and GTP-U in kernelspace was invented.
The encoding and decoding of these control messages is implemented in the libgtpnl (library for GTP netlink). The library is available from http://git.osmocom.org/libgtpnl/
The library uses GNU autotools, so the usual
autoreconf -fi && ./configure && make && make install
should be used to build + install it.