Bug 239379 - devel/protobuf: pthread include fails, breaks net/mosh
Summary: devel/protobuf: pthread include fails, breaks net/mosh
Status: Closed DUPLICATE of bug 239038
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Some People
Assignee: Kubilay Kocak
Depends on:
Reported: 2019-07-22 10:36 UTC by Michael Büker
Modified: 2019-07-30 10:35 UTC (History)
2 users (show)

See Also:


Note You need to log in before you can comment on or make changes to this bug.
Description Michael Büker 2019-07-22 10:36:40 UTC
The root cause of bug #239038 appears to be that protobuf compilation (no longer?) includes pthread in the way that is needed for net/mosh to function. Compare the error message:

 [libprotobuf FATAL google/protobuf/generated_message_util.cc:809] CHECK failed: (scc->visit_status.load(std::memory_order_relaxed)) == (SCCInfoBase::kRunning):

to the one reported in https://stackoverflow.com/questions/52890529/fatalexception-thrown-by-protobuf-library-on-instantiation-of-message:

 [libprotobuf FATAL /myproj/protobuf/src/google/protobuf/generated_message_util.cc:785] CHECK failed: (scc->visit_status.load(std::memory_order_relaxed)) == (SCCInfoBase::kRunning):

In that stackoverflow discussion, the solution is to add "--no-as-needed" before "-pthread" to the linker flags for protobuf.

This suggests that a similar tweak to the protobuf build instructions in FreeBSD ports could also help. I am not sufficiently familiar with ports to try this myself.
Comment 1 Kubilay Kocak freebsd_committer freebsd_triage 2019-07-30 10:35:35 UTC
Since all the information, analysis and a patch is in bug 239038, which has now been re-triaged and re-assigned to the devel/protobuf maintainer, close this as a dupe

*** This bug has been marked as a duplicate of bug 239038 ***