Added extern "C" to functions declarations to be able to call them from C#.