Extension hooks and skeleton of phongo, and basic bson implementation

Fixing unused variable compiler warnings.