On October 19th, dev-libs/protobuf-3.6.1 became stable. I updated my system and some packages fail to build because /usr/bin/protoc outputs the following error when it's ran:
terminate called after throwing an instance of 'std::system_error'
what(): Unknown error -1
There's a bug report here: https://github.com/protocolbuffers/protobuf/issues/4958
I temporarily solved my problem by downgrading to dev-libs/protobuf-3.5.2
Steps to reproduce:
1. emerge dev-libs/protobuf-3.6.1
2. Run protoc
Found the problem.
protoc won't run if it's built with ld.gold. It works fine with ld.bfd
another bug report: https://github.com/protocolbuffers/protobuf/issues/5107
Please show 'emerge --info'.
*** This bug has been marked as a duplicate of bug 669194 ***