Fix some used-but-not-defined warnings, and some format-string warnings about needing to cast T* to void* for the %p specifier.  No bug, r=themaid