add new gtests and fix linker issues for protocol buffers on Linux