protocolbuffers / protobuf

Protocol Buffers - Google's data interchange format
http://protobuf.dev
Other
65.01k stars 15.41k forks source link

Building protobuf 27.0 with emcc yields errors #16424

Closed adokhugi closed 1 month ago

adokhugi commented 4 months ago

What version of protobuf and what language are you using? Version: 27.0 Language: C++

What operating system (Linux, Windows, ...) and version? Windows 11

What runtime / compiler are you using (e.g., python version or gcc version) emcc

What did you do? Steps to reproduce the behavior:

  1. git clone
  2. emcmake cmake
  3. emmake make

What did you expect to see It should have built protobuf without errors.

What did you see instead? [ 52%] Building CXX object CMakeFiles/protoc-gen-upb.dir/upb_generator/common.cc.o [ 52%] Building CXX object CMakeFiles/protoc-gen-upb.dir/upb_generator/file_layout.cc.o [ 52%] Building CXX object CMakeFiles/protoc-gen-upb.dir/upb_generator/mangle.cc.o [ 52%] Building CXX object CMakeFiles/protoc-gen-upb.dir/upb_generator/names.cc.o [ 52%] Building CXX object CMakeFiles/protoc-gen-upb.dir/upb_generator/protoc-gen-upb.cc.o [ 52%] Building C object CMakeFiles/protoc-gen-upb.dir/upb_generator/cmake/google/protobuf/compiler/plugin.upb_minitable.c.o [ 52%] Linking CXX executable protoc-gen-upb.js wasm-ld: error: CMakeFiles/protoc-gen-upb.dir/upb_generator/common.cc.o: undefined symbol: absl::lts_20240116::string_view::rfind(char, unsigned long) const wasm-ld: error: CMakeFiles/protoc-gen-upb.dir/upb_generator/common.cc.o: undefined symbol: absl::lts_20240116::StrReplaceAll(absl::lts_20240116::string_view, std::initializer_list<std::2::pair<absl::lts_20240116::string_view, absl::lts_20240116::string_view>>) wasm-ld: error: CMakeFiles/protoc-gen-upb.dir/upb_generator/common.cc.o: undefined symbol: absl::lts_20240116::string_view::find_first_not_of(char, unsigned long) const wasm-ld: error: CMakeFiles/protoc-gen-upb.dir/upb_generator/common.cc.o: undefined symbol: absl::lts_20240116::StrReplaceAll(absl::lts_20240116::string_view, std::initializer_list<std::__2::pair<absl::lts_20240116::string_view, absl::lts_20240116::string_view>>) wasm-ld: error: CMakeFiles/protoc-gen-upb.dir/upb_generator/common.cc.o: undefined symbol: absl::lts_20240116::substitute_internal::SubstituteAndAppendArray(std::2::basic_string<char, std::2::char_traits, std::__2::allocator>, absl::lts_20240116::string_view, absl::lts_20240116::string_view const, unsigned long) wasm-ld: error: CMakeFiles/protoc-gen-upb.dir/upb_generator/common.cc.o: undefined symbol: absl::lts_20240116::substitute_internal::SubstituteAndAppendArray(std::2::basic_string<char, std::2::char_traits, std::__2::allocator>, absl::lts_20240116::string_view, absl::lts_20240116::string_view const, unsigned long) wasm-ld: error: CMakeFiles/protoc-gen-upb.dir/upb_generator/common.cc.o: undefined symbol: absl::lts_20240116::substitute_internal::SubstituteAndAppendArray(std::2::basic_string<char, std::2::char_traits, std::__2::allocator>, absl::lts_20240116::string_view, absl::lts_20240116::string_view const, unsigned long) wasm-ld: error: CMakeFiles/protoc-gen-upb.dir/upb_generator/common.cc.o: undefined symbol: absl::lts_20240116::StrReplaceAll(absl::lts_20240116::string_view, std::initializer_list<std::2::pair<absl::lts_20240116::string_view, absl::lts_20240116::string_view>>) wasm-ld: error: CMakeFiles/protoc-gen-upb.dir/upb_generator/protoc-gen-upb.cc.o: undefined symbol: absl::lts_20240116::log_internal::LogMessage::operator<<(absl::lts_20240116::string_view) wasm-ld: error: CMakeFiles/protoc-gen-upb.dir/upb_generator/protoc-gen-upb.cc.o: undefined symbol: void absl::lts_20240116::log_internal::LogMessage::CopyToEncodedBuffer<(absl::lts_20240116::log_internal::LogMessage::StringType)0>(absl::lts_20240116::string_view) wasm-ld: error: CMakeFiles/protoc-gen-upb.dir/upb_generator/protoc-gen-upb.cc.o: undefined symbol: absl::lts_20240116::string_view::find(char, unsigned long) const wasm-ld: error: CMakeFiles/protoc-gen-upb.dir/upb_generator/protoc-gen-upb.cc.o: undefined symbol: absl::lts_20240116::ByChar::Find(absl::lts_20240116::string_view, unsigned long) const wasm-ld: error: CMakeFiles/protoc-gen-upb.dir/upb_generator/protoc-gen-upb.cc.o: undefined symbol: void absl::lts_20240116::log_internal::LogMessage::CopyToEncodedBuffer<(absl::lts_20240116::log_internal::LogMessage::StringType)0>(absl::lts_20240116::string_view) wasm-ld: error: CMakeFiles/protoc-gen-upb.dir/upb_generator/protoc-gen-upb.cc.o: undefined symbol: void absl::lts_20240116::log_internal::LogMessage::CopyToEncodedBuffer<(absl::lts_20240116::log_internal::LogMessage::StringType)0>(absl::lts_20240116::string_view) wasm-ld: error: CMakeFiles/protoc-gen-upb.dir/upb_generator/protoc-gen-upb.cc.o: undefined symbol: void absl::lts_20240116::log_internal::LogMessage::CopyToEncodedBuffer<(absl::lts_20240116::log_internal::LogMessage::StringType)0>(absl::lts_20240116::string_view) wasm-ld: error: CMakeFiles/protoc-gen-upb.dir/upb_generator/protoc-gen-upb.cc.o: undefined symbol: void absl::lts_20240116::log_internal::LogMessage::CopyToEncodedBuffer<(absl::lts_20240116::log_internal::LogMessage::StringType)0>(absl::lts_20240116::string_view) wasm-ld: error: CMakeFiles/protoc-gen-upb.dir/upb_generator/protoc-gen-upb.cc.o: undefined symbol: absl::lts_20240116::CEscape(absl::lts_20240116::string_view) wasm-ld: error: CMakeFiles/protoc-gen-upb.dir/upb_generator/common.cc.o: undefined symbol: absl::lts_20240116::substitute_internal::SubstituteAndAppendArray(std::2::basic_string<char, std::__2::char_traits, std::2::allocator>, absl::lts_20240116::string_view, absl::lts_20240116::string_view const, unsigned long) wasm-ld: error: CMakeFiles/protoc-gen-upb.dir/upb_generator/names.cc.o: undefined symbol: absl::lts_20240116::log_internal::LogMessageFatal::LogMessageFatal(char const, int, absl::lts_20240116::string_view) wasm-ld: error: CMakeFiles/protoc-gen-upb.dir/upb_generator/common.cc.o: undefined symbol: absl::lts_20240116::substitute_internal::SubstituteAndAppendArray(std::2::basic_string<char, std::__2::char_traits, std::2::allocator>, absl::lts_20240116::string_view, absl::lts_20240116::string_view const*, unsigned long) wasm-ld: error: too many errors emitted, stopping now (use -error-limit=0 to see all errors)

shaod2 commented 4 months ago

Can you confirm the version? I don't think v27 is released yet

adokhugi commented 4 months ago

I cloned the github repo on April 5th, 2024. Somewhere the number 27 appeared. In any case it is more recent than the latest official release.

Am Fr., 5. Apr. 2024 um 17:37 Uhr schrieb Dennis Shao < @.***>:

Can you confirm the version? I don't think v27 is released yet

— Reply to this email directly, view it on GitHub https://github.com/protocolbuffers/protobuf/issues/16424#issuecomment-2040115022, or unsubscribe https://github.com/notifications/unsubscribe-auth/ALYK4YFKWQS3NN54S2BALUTY33ANBAVCNFSM6AAAAABFYUQXE2VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDANBQGEYTKMBSGI . You are receiving this because you authored the thread.Message ID: @.***>

-- Dipl.-Ing. Dr. Claus D. Volko, BSc http://www.cdvolko.net/

github-actions[bot] commented 1 month ago

We triage inactive PRs and issues in order to make it easier to find active work. If this issue should remain active or becomes active again, please add a comment.

This issue is labeled inactive because the last activity was over 90 days ago.

github-actions[bot] commented 1 month ago

We triage inactive PRs and issues in order to make it easier to find active work. If this issue should remain active or becomes active again, please reopen it.

This issue was closed and archived because there has been no new activity in the 14 days since the inactive label was added.