any_proto linked multiple times with -c opt
It appears that the generated code (and in particular, the initialization code) for any_proto is being linked into our executables multiple times. These then fail to start:
-----------------------------------------------------------------------------
[libprotobuf ERROR external/com_google_protobuf/src/google/protobuf/descriptor_database.cc:58] File already exists in database: google/protobuf/any.proto
[libprotobuf FATAL external/com_google_protobuf/src/google/protobuf/descriptor.cc:1394] CHECK failed: generated_database_->Add(encoded_file_descriptor, size):
terminate called after throwing an instance of 'google::protobuf::FatalException'
what(): CHECK failed: generated_database_->Add(encoded_file_descriptor, size):
This only happens when we compile with -c opt. -c dbg and the default configuration all work.
I don't know if this is our problem, a Bazel problem, or a protobuf problem. Our issue, with more details: https://github.com/google/kythe/issues/2834
Just updated to 0.15.1. I'm not sure how long this has been a problem; I tried downgrading to 0.13.0 and it was still broken.
Fixed by updating to protobuf 3.6.0. Further details in https://github.com/google/kythe/commit/27addcb0b06688d3b080486d57cab0459e9f0f06