Compile with -fvisibility and make sure that the classes / structs are visible.