SpectrumIM / spectrum2

Spectrum 2 IM transports
https://spectrum.im
409 stars 91 forks source link

Build error on GCC 10 on OpenSuse. #507

Open Zombie-Ryushu opened 3 weeks ago

Zombie-Ryushu commented 3 weeks ago

[ 52s] /usr/include/google/protobuf/map_entry.h:150:15: note: mismatched types 'auto' and 'void' [ 52s] /usr/include/google/protobuf/map_entry.h:151:35: error: 'Read' is not a member of 'google::protobuf::internal::MapEntry<pbnetwork::Login_UserSettings_ValueEntry_DoNotUse, std::cxx11::basic_string, std::__cxx11::basic_string, (google::protobuf::internal::WireFormatLite::FieldType)9, (google::protobuf::internal::WireFormatLite::FieldType)9>::KeyTypeHandler {aka google::protobuf::internal::MapTypeHandler<(google::protobuf::internal::WireFormatLite::FieldType)9, std::cxx11::basic_string >}' [ 52s] ptr = KeyTypeHandler::Read(ptr, ctx, key); [ 52s] ~~~~^~~~~~~ [ 52s] /usr/include/google/protobuf/map_entry.h:154:36: error: use of 'auto google::protobuf::internal::MapEntry<Derived, Key, Value, kKeyFieldType, kValueFieldType>::mutable_value() [with Derived = pbnetwork::Login_UserSettings_ValueEntry_DoNotUse; Key = std::cxx11::basic_string; Value = std::cxx11::basic_string; google::protobuf::internal::WireFormatLite::FieldType kKeyFieldType = (google::protobuf::internal::WireFormatLite::FieldType)9; google::protobuf::internal::WireFormatLite::FieldType kValueFieldType = (google::protobuf::internal::WireFormatLite::FieldType)9]' before deduction of 'auto' [ 52s] auto* value = mutable_value(); [ 52s] ~~~~~^~ [ 52s] /usr/include/google/protobuf/map_entry.h:155:37: error: 'Read' is not a member of 'google::protobuf::internal::MapEntry<pbnetwork::Login_UserSettings_ValueEntry_DoNotUse, std::cxx11::basic_string, std::cxx11::basic_string, (google::protobuf::internal::WireFormatLite::FieldType)9, (google::protobuf::internal::WireFormatLite::FieldType)9>::ValueTypeHandler {aka google::protobuf::internal::MapTypeHandler<(google::protobuf::internal::WireFormatLite::FieldType)9, std::cxx11::basic_string >}' [ 52s] ptr = ValueTypeHandler::Read(ptr, ctx, value); [ 52s] ~~~~^~~~~~~ [ 52s] /usr/include/google/protobuf/map_entry.h: In instantiation of 'uint8_t google::protobuf::internal::MapEntry<Derived, Key, Value, kKeyFieldType, kValueFieldType>::_InternalSerialize(uint8_t, google::protobuf::io::EpsCopyOutputStream*) const [with Derived = pbnetwork::Login_UserSettings_ValueEntry_DoNotUse; Key = std::cxx11::basic_string; Value = std::cxx11::basic_string; google::protobuf::internal::WireFormatLite::FieldType kKeyFieldType = (google::protobuf::internal::WireFormatLite::FieldType)9; google::protobuf::internal::WireFormatLite::FieldType kValueFieldType = (google::protobuf::internal::WireFormatLite::FieldType)9; uint8_t = unsigned char]': [ 52s] /usr/include/google/protobuf/port_undef.inc:179:27: required from here [ 52s] /usr/include/google/protobuf/map_entry.h:181:32: error: 'Write' is not a member of 'google::protobuf::internal::MapEntry<pbnetwork::Login_UserSettings_ValueEntry_DoNotUse, std::__cxx11::basic_string, std::cxx11::basic_string, (google::protobuf::internal::WireFormatLite::FieldType)9, (google::protobuf::internal::WireFormatLite::FieldType)9>::KeyTypeHandler {aka google::protobuf::internal::MapTypeHandler<(google::protobuf::internal::WireFormatLite::FieldType)9, std::cxx11::basic_string >}' [ 52s] ptr = KeyTypeHandler::Write(kKeyFieldNumber, key(), ptr, stream); [ 52s] ~~~~~^~~~~~~~~ [ 52s] /usr/include/google/protobuf/map_entry.h:181:53: error: use of 'const auto& google::protobuf::internal::MapEntry<Derived, Key, Value, kKeyFieldType, kValueFieldType>::key() const [with Derived = pbnetwork::Login_UserSettings_ValueEntry_DoNotUse; Key = std::__cxx11::basic_string; Value = std::cxx11::basic_string; google::protobuf::internal::WireFormatLite::FieldType kKeyFieldType = (google::protobuf::internal::WireFormatLite::FieldType)9; google::protobuf::internal::WireFormatLite::FieldType kValueFieldType = (google::protobuf::internal::WireFormatLite::FieldType)9]' before deduction of 'auto' [ 52s] ptr = KeyTypeHandler::Write(kKeyFieldNumber, key(), ptr, stream); [ 52s] ~~~^~ [ 52s] /usr/include/google/protobuf/map_entry.h:182:35: error: 'Write' is not a member of 'google::protobuf::internal::MapEntry<pbnetwork::Login_UserSettings_ValueEntry_DoNotUse, std::cxx11::basic_string, std::__cxx11::basic_string, (google::protobuf::internal::WireFormatLite::FieldType)9, (google::protobuf::internal::WireFormatLite::FieldType)9>::ValueTypeHandler {aka google::protobuf::internal::MapTypeHandler<(google::protobuf::internal::WireFormatLite::FieldType)9, std::cxx11::basic_string >}' [ 52s] return ValueTypeHandler::Write(kValueFieldNumber, value(), ptr, stream); [ 52s] ~~~~~^~~~~~~~~~~ [ 52s] /usr/include/google/protobuf/map_entry.h:182:60: error: use of 'const auto& google::protobuf::internal::MapEntry<Derived, Key, Value, kKeyFieldType, kValueFieldType>::value() const [with Derived = pbnetwork::Login_UserSettings_ValueEntry_DoNotUse; Key = std::cxx11::basic_string; Value = std::__cxx11::basic_string; google::protobuf::internal::WireFormatLite::FieldType kKeyFieldType = (google::protobuf::internal::WireFormatLite::FieldType)9; google::protobuf::internal::WireFormatLite::FieldType kValueFieldType = (google::protobuf::internal::WireFormatLite::FieldType)9]' before deduction of 'auto' [ 52s] return ValueTypeHandler::Write(kValueFieldNumber, value(), ptr, stream); [ 52s] ~^~ [ 52s] make[2]: *** [plugin/cpp/CMakeFiles/transport-plugin.dir/build.make:146: plugin/cpp/CMakeFiles/transport-plugin.dir//__/include/transport/protocol.pb.cc.o] Error 1 [ 52s] make[1]: [CMakeFiles/Makefile2:516: plugin/cpp/CMakeFiles/transport-plugin.dir/all] Error 2 [ 52s] make: [Makefile:156: all] Error 2 [ 52s] error: Bad exit status from /var/tmp/rpm-tmp.gLEnBm (%build) [ 52s] [ 52s] [ 52s] RPM build errors: [ 52s] Bad exit status from /var/tmp/rpm-tmp.gLEnBm (%build) [ 52s] ### VM INTERACTION START ### [ 53s] Failed to write wtmp record, ignoring: Read-only file system

vitalyster commented 3 weeks ago

Not a spectrum issue, use compatible protobuf version?