Build fixes for Mac.

Usual suspects :
[chromium-style] Classes that are ref-counted should have destructors that are declared protected or private.
[chromium-style] Complex destructor has an inline body.
[chromium-style] Overriding method must have "virtual" keyword.