Problem: various issues with interface generation

- didn't guard _library.h correctly, wasn't included properly
- _class header has to also pull in external API
- minor issues in generated headers
Merge pull request #43 from hintjens/master

Problem: various issues with interface generation