backscrub icon indicating copy to clipboard operation
backscrub copied to clipboard

Compilation error on openSUSE Tumbleweed

Open oshikore opened this issue 2 years ago • 4 comments

backscrub used to build just fine on my system, and it does not any more. Since Tumbleweed is tumbling ahead, I can't really go back to the working state.

This is the end of the compilation, the full output is attached.

[ 11%] Building CXX object _deps/flatbuffers-build/CMakeFiles/flatbuffers.dir/src/idl_parser.cpp.o
In file included from /home/oscar/Apps/teams-cam/backscrub/build/flatbuffers/include/flatbuffers/base.h:217,
                 from /home/oscar/Apps/teams-cam/backscrub/build/flatbuffers/include/flatbuffers/idl.h:24,
                 from /home/oscar/Apps/teams-cam/backscrub/build/flatbuffers/src/idl_parser.cpp:23:
/usr/include/absl/strings/string_view.h:52:26: error: ‘string_view’ in namespace ‘std’ does not name a type
   52 | using string_view = std::string_view;
      |                          ^~~~~~~~~~~
/usr/include/absl/strings/string_view.h:52:21: note: ‘std::string_view’ is only available from C++17 onwards
   52 | using string_view = std::string_view;
      |                     ^~~
/usr/include/absl/strings/string_view.h:693:8: error: ‘string_view’ does not name a type
  693 | inline string_view ClippedSubstr(string_view s, size_t pos,
      |        ^~~~~~~~~~~
/usr/include/absl/strings/string_view.h:704:11: error: ‘string_view’ does not name a type
  704 | constexpr string_view NullSafeStringView(const char* p) {
      |           ^~~~~~~~~~~
/home/oscar/Apps/teams-cam/backscrub/build/flatbuffers/include/flatbuffers/base.h:219:23: error: ‘string_view’ in namespace ‘absl’ does not name a type
  219 |         typedef absl::string_view string_view;
      |                       ^~~~~~~~~~~
In file included from /home/oscar/Apps/teams-cam/backscrub/build/flatbuffers/include/flatbuffers/idl.h:25:
/home/oscar/Apps/teams-cam/backscrub/build/flatbuffers/include/flatbuffers/flatbuffers.h:561:16: error: ‘string_view’ in namespace ‘flatbuffers’ does not name a type
  561 |   flatbuffers::string_view string_view() const {
      |                ^~~~~~~~~~~
/home/oscar/Apps/teams-cam/backscrub/build/flatbuffers/include/flatbuffers/flatbuffers.h:1487:44: error: ‘flatbuffers::string_view’ has not been declared
 1487 |   Offset<String> CreateString(flatbuffers::string_view str) {
      |                                            ^~~~~~~~~~~
/home/oscar/Apps/teams-cam/backscrub/build/flatbuffers/include/flatbuffers/flatbuffers.h: In member function ‘flatbuffers::Offset<flatbuffers::String> flatbuffers::FlatBufferBuilder::CreateString(int)’:
/home/oscar/Apps/teams-cam/backscrub/build/flatbuffers/include/flatbuffers/flatbuffers.h:1488:29: error: request for member ‘data’ in ‘str’, which is of non-class type ‘int’
 1488 |     return CreateString(str.data(), str.size());
      |                             ^~~~
/home/oscar/Apps/teams-cam/backscrub/build/flatbuffers/include/flatbuffers/flatbuffers.h:1488:41: error: request for member ‘size’ in ‘str’, which is of non-class type ‘int’
 1488 |     return CreateString(str.data(), str.size());
      |                                         ^~~~
make[2]: *** [_deps/flatbuffers-build/CMakeFiles/flatbuffers.dir/build.make:76: _deps/flatbuffers-build/CMakeFiles/flatbuffers.dir/src/idl_parser.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:4023: _deps/flatbuffers-build/CMakeFiles/flatbuffers.dir/all] Error 2
make: *** [Makefile:156: all] Error 2
/home/oscar/Apps/teams-cam

buildlog.zip

oshikore avatar Jul 15 '22 15:07 oshikore

Which version of GCC are you using?

This looks like a problem with the 3rd-party flatbuffers library. Have a look at their bug tracker too if you can find any reports about similar issues.

BenBE avatar Jul 18 '22 16:07 BenBE

gcc version:

Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/usr/lib64/gcc/x86_64-suse-linux/12/lto-wrapper
OFFLOAD_TARGET_NAMES=nvptx-none:amdgcn-amdhsa
OFFLOAD_TARGET_DEFAULT=1
Target: x86_64-suse-linux
Configured with: ../configure --prefix=/usr --infodir=/usr/share/info --mandir=/usr/share/man --libdir=/usr/lib64 --libexecdir=/usr/lib64 --enable-languages=c,c++,objc,fortran,obj-c++,ada,go,d,jit --enable-offload-targets=nvptx-none,amdgcn-amdhsa, --enable-offload-defaulted --without-cuda-driver --enable-host-shared --enable-checking=release --disable-werror --with-gxx-include-dir=/usr/include/c++/12 --enable-ssp --disable-libssp --disable-libvtv --enable-cet=auto --disable-libcc1 --enable-plugin --with-bugurl=https://bugs.opensuse.org/ --with-pkgversion='SUSE Linux' --with-slibdir=/lib64 --with-system-zlib --enable-libstdcxx-allocator=new --disable-libstdcxx-pch --enable-libphobos --enable-version-specific-runtime-libs --with-gcc-major-version-only --enable-linker-build-id --enable-linux-futex --enable-gnu-indirect-function --program-suffix=-12 --without-system-libunwind --enable-multilib --with-arch-32=x86-64 --with-tune=generic --with-build-config=bootstrap-lto-lean --enable-link-mutex --build=x86_64-suse-linux --host=x86_64-suse-linux
Thread model: posix
Supported LTO compression algorithms: zlib zstd
gcc version 12.1.1 20220629 [revision 7811663964aa7e31c3939b859bbfa2e16919639f] (SUSE Linux) 

oshikore avatar Jul 19 '22 06:07 oshikore

I did a testbuild of flatbuffers. Version 2.0.6 fails with a very similar error.

master compiles without any issues.

oshikore avatar Jul 21 '22 17:07 oshikore

Okay, looks like we'll need to try to get this dependency updated somehow then …

BenBE avatar Jul 22 '22 13:07 BenBE

OK, the dependency chain we have currently: backscrub -> tensorflow/v2.8.0 -> flatbuffers/v1.12.0 (see <~TFLITE>/tools/cmake/modules/flatbuffers.cmake).

Shifting our dependency to tensorflow/v2.9.0 might fix, as that depends on flatbuffers/v2.0.5: @oshikore can you please test compile flatbuffers @ v2.0.5?

If we need to go newer, then our only option at present is to pull flatbuffers/master ourselves and convince TFLITE cmake not to, since tensorflow @ master depends on the known broken flatbuffers v2.0.6. I'll take a look at this just in case...

phlash avatar Aug 15 '22 09:08 phlash

Run cmake:

> cmake . -D FLATBUFFERS_CXX_FLAGS="-Wno-error"
fatal: not a git repository (or any parent up to mount point /)
Stopping at filesystem boundary (GIT_DISCOVERY_ACROSS_FILESYSTEM not set).
CMake Warning at CMake/Version.cmake:22 (message):
  git describe failed with exit code: 128
Call Stack (most recent call first):
  CMakeLists.txt:13 (include)


-- Proceeding with version: 2.0.5.0
-- extend CXX_FLAGS with -Wno-error
-- CMAKE_CXX_FLAGS:  -std=c++0x -Wall -pedantic -Werror -Wextra -Werror=shadow -faligned-new -Werror=implicit-fallthrough=2 -Wunused-result -Werror=unused-result -Wunused-parameter -Werror=unused-parameter -fsigned-char -Wno-error
-- `tests/monster_test.fbs`: add generation of C++ code with '--no-includes;--gen-compare'
-- `tests/monster_test.fbs`: add generation of binary (.bfbs) schema
-- `tests/namespace_test/namespace_test1.fbs`: add generation of C++ code with '--no-includes;--gen-compare;--gen-name-strings'
-- `tests/namespace_test/namespace_test2.fbs`: add generation of C++ code with '--no-includes;--gen-compare;--gen-name-strings'
-- `tests/union_vector/union_vector.fbs`: add generation of C++ code with '--no-includes;--gen-compare;--gen-name-strings'
-- `tests/optional_scalars.fbs`: add generation of C++ code with '--no-includes;--gen-compare'
-- `tests/native_type_test.fbs`: add generation of C++ code with ''
-- `tests/arrays_test.fbs`: add generation of C++ code with '--scoped-enums;--gen-compare'
-- `tests/arrays_test.fbs`: add generation of binary (.bfbs) schema
-- `tests/monster_test.fbs`: add generation of C++ embedded binary schema code with '--no-includes;--gen-compare'
-- `tests/monster_extra.fbs`: add generation of C++ code with '--no-includes;--gen-compare'
-- `samples/monster.fbs`: add generation of C++ code with '--no-includes;--gen-compare'
-- `samples/monster.fbs`: add generation of binary (.bfbs) schema
-- Configuring done
-- Generating done
-- Build files have been written to: /home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5

Run build:

> make
[  1%] Building CXX object CMakeFiles/flatbuffers.dir/src/idl_parser.cpp.o
In file included from /home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/base.h:237,
                 from /home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/src/idl_parser.cpp:23:
/usr/include/absl/strings/string_view.h:52:26: error: ‘string_view’ in namespace ‘std’ does not name a type
   52 | using string_view = std::string_view;
      |                          ^~~~~~~~~~~
/usr/include/absl/strings/string_view.h:52:21: note: ‘std::string_view’ is only available from C++17 onwards
   52 | using string_view = std::string_view;
      |                     ^~~
/usr/include/absl/strings/string_view.h:693:8: error: ‘string_view’ does not name a type
  693 | inline string_view ClippedSubstr(string_view s, size_t pos,
      |        ^~~~~~~~~~~
/usr/include/absl/strings/string_view.h:704:11: error: ‘string_view’ does not name a type
  704 | constexpr string_view NullSafeStringView(const char* p) {
      |           ^~~~~~~~~~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/base.h:239:23: error: ‘string_view’ in namespace ‘absl’ does not name a type
  239 |         typedef absl::string_view string_view;
      |                       ^~~~~~~~~~~
In file included from /home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:29,
                 from /home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffers.h:27,
                 from /home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/idl.h:26,
                 from /home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/src/idl_parser.cpp:24:
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/string.h:31:16: error: ‘string_view’ in namespace ‘flatbuffers’ does not name a type
   31 |   flatbuffers::string_view string_view() const {
      |                ^~~~~~~~~~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/string.h:57:28: error: ‘string_view’ in namespace ‘flatbuffers’ does not name a type
   57 | static inline flatbuffers::string_view GetStringView(const String *str) {
      |                            ^~~~~~~~~~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:494:44: error: ‘flatbuffers::string_view’ has not been declared
  494 |   Offset<String> CreateString(flatbuffers::string_view str) {
      |                                            ^~~~~~~~~~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:549:56: error: ‘string_view’ in namespace ‘flatbuffers’ does not name a type
  549 |   Offset<String> CreateSharedString(const flatbuffers::string_view str) {
      |                                                        ^~~~~~~~~~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h: In member function ‘flatbuffers::Offset<flatbuffers::String> flatbuffers::FlatBufferBuilder::CreateString(int)’:
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:495:29: error: request for member ‘data’ in ‘str’, which is of non-class type ‘int’
  495 |     return CreateString(str.data(), str.size());
      |                             ^~~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:495:41: error: request for member ‘size’ in ‘str’, which is of non-class type ‘int’
  495 |     return CreateString(str.data(), str.size());
      |                                         ^~~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h: In member function ‘flatbuffers::Offset<flatbuffers::String> flatbuffers::FlatBufferBuilder::CreateSharedString(int)’:
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:550:35: error: request for member ‘data’ in ‘str’, which is of non-class type ‘const int’
  550 |     return CreateSharedString(str.data(), str.size());
      |                                   ^~~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:550:47: error: request for member ‘size’ in ‘str’, which is of non-class type ‘const int’
  550 |     return CreateSharedString(str.data(), str.size());
      |                                               ^~~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/src/idl_parser.cpp: In member function ‘flatbuffers::CheckedError flatbuffers::Parser::ParseString(flatbuffers::Value&, bool)’:
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/src/idl_parser.cpp:1047:59: error: no matching function for call to ‘flatbuffers::FlatBufferBuilder::CreateSharedString(std::__cxx11::basic_string<char>&)’
 1047 |     val.constant = NumToString(builder_.CreateSharedString(s).o);
      |                                ~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:522:18: note: candidate: ‘flatbuffers::Offset<flatbuffers::String> flatbuffers::FlatBufferBuilder::CreateSharedString(const char*, size_t)’
  522 |   Offset<String> CreateSharedString(const char *str, size_t len) {
      |                  ^~~~~~~~~~~~~~~~~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:522:18: note:   candidate expects 2 arguments, 1 provided
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:549:18: note: candidate: ‘flatbuffers::Offset<flatbuffers::String> flatbuffers::FlatBufferBuilder::CreateSharedString(int)’
  549 |   Offset<String> CreateSharedString(const flatbuffers::string_view str) {
      |                  ^~~~~~~~~~~~~~~~~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:549:68: note:   no known conversion for argument 1 from ‘std::__cxx11::basic_string<char>’ to ‘int’
  549 |   Offset<String> CreateSharedString(const flatbuffers::string_view str) {
      |                                     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:580:18: note: candidate: ‘flatbuffers::Offset<flatbuffers::String> flatbuffers::FlatBufferBuilder::CreateSharedString(const flatbuffers::String*)’
  580 |   Offset<String> CreateSharedString(const String *str) {
      |                  ^~~~~~~~~~~~~~~~~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:580:51: note:   no known conversion for argument 1 from ‘std::__cxx11::basic_string<char>’ to ‘const flatbuffers::String*’
  580 |   Offset<String> CreateSharedString(const String *str) {
      |                                     ~~~~~~~~~~~~~~^~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/src/idl_parser.cpp: In member function ‘void flatbuffers::Parser::Serialize()’:
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/src/idl_parser.cpp:3542:58: error: no matching function for call to ‘flatbuffers::FlatBufferBuilder::CreateSharedString(std::string)’
 3542 |       const auto filename__ = builder_.CreateSharedString(
      |                               ~~~~~~~~~~~~~~~~~~~~~~~~~~~^
 3543 |           RelativeToRootPath(opts.project_root, f->first));
      |           ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:522:18: note: candidate: ‘flatbuffers::Offset<flatbuffers::String> flatbuffers::FlatBufferBuilder::CreateSharedString(const char*, size_t)’
  522 |   Offset<String> CreateSharedString(const char *str, size_t len) {
      |                  ^~~~~~~~~~~~~~~~~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:522:18: note:   candidate expects 2 arguments, 1 provided
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:549:18: note: candidate: ‘flatbuffers::Offset<flatbuffers::String> flatbuffers::FlatBufferBuilder::CreateSharedString(int)’
  549 |   Offset<String> CreateSharedString(const flatbuffers::string_view str) {
      |                  ^~~~~~~~~~~~~~~~~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:549:68: note:   no known conversion for argument 1 from ‘std::string’ {aka ‘std::__cxx11::basic_string<char>’} to ‘int’
  549 |   Offset<String> CreateSharedString(const flatbuffers::string_view str) {
      |                                     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:580:18: note: candidate: ‘flatbuffers::Offset<flatbuffers::String> flatbuffers::FlatBufferBuilder::CreateSharedString(const flatbuffers::String*)’
  580 |   Offset<String> CreateSharedString(const String *str) {
      |                  ^~~~~~~~~~~~~~~~~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:580:51: note:   no known conversion for argument 1 from ‘std::string’ {aka ‘std::__cxx11::basic_string<char>’} to ‘const flatbuffers::String*’
  580 |   Offset<String> CreateSharedString(const String *str) {
      |                                     ~~~~~~~~~~~~~~^~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/src/idl_parser.cpp:3545:61: error: no matching function for call to ‘flatbuffers::FlatBufferBuilder::CreateSharedString(std::string)’
 3545 |         included_files.push_back(builder_.CreateSharedString(
      |                                  ~~~~~~~~~~~~~~~~~~~~~~~~~~~^
 3546 |             RelativeToRootPath(opts.project_root, *i)));
      |             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~       
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:522:18: note: candidate: ‘flatbuffers::Offset<flatbuffers::String> flatbuffers::FlatBufferBuilder::CreateSharedString(const char*, size_t)’
  522 |   Offset<String> CreateSharedString(const char *str, size_t len) {
      |                  ^~~~~~~~~~~~~~~~~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:522:18: note:   candidate expects 2 arguments, 1 provided
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:549:18: note: candidate: ‘flatbuffers::Offset<flatbuffers::String> flatbuffers::FlatBufferBuilder::CreateSharedString(int)’
  549 |   Offset<String> CreateSharedString(const flatbuffers::string_view str) {
      |                  ^~~~~~~~~~~~~~~~~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:549:68: note:   no known conversion for argument 1 from ‘std::string’ {aka ‘std::__cxx11::basic_string<char>’} to ‘int’
  549 |   Offset<String> CreateSharedString(const flatbuffers::string_view str) {
      |                                     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:580:18: note: candidate: ‘flatbuffers::Offset<flatbuffers::String> flatbuffers::FlatBufferBuilder::CreateSharedString(const flatbuffers::String*)’
  580 |   Offset<String> CreateSharedString(const String *str) {
      |                  ^~~~~~~~~~~~~~~~~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:580:51: note:   no known conversion for argument 1 from ‘std::string’ {aka ‘std::__cxx11::basic_string<char>’} to ‘const flatbuffers::String*’
  580 |   Offset<String> CreateSharedString(const String *str) {
      |                                     ~~~~~~~~~~~~~~^~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/src/idl_parser.cpp: In member function ‘flatbuffers::Offset<reflection::Object> flatbuffers::StructDef::Serialize(flatbuffers::FlatBufferBuilder*, const flatbuffers::Parser&) const’:
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/src/idl_parser.cpp:3615:50: error: no matching function for call to ‘flatbuffers::FlatBufferBuilder::CreateSharedString(std::string&)’
 3615 |   const auto file__ = builder->CreateSharedString(decl_file_in_project);
      |                       ~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:522:18: note: candidate: ‘flatbuffers::Offset<flatbuffers::String> flatbuffers::FlatBufferBuilder::CreateSharedString(const char*, size_t)’
  522 |   Offset<String> CreateSharedString(const char *str, size_t len) {
      |                  ^~~~~~~~~~~~~~~~~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:522:18: note:   candidate expects 2 arguments, 1 provided
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:549:18: note: candidate: ‘flatbuffers::Offset<flatbuffers::String> flatbuffers::FlatBufferBuilder::CreateSharedString(int)’
  549 |   Offset<String> CreateSharedString(const flatbuffers::string_view str) {
      |                  ^~~~~~~~~~~~~~~~~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:549:68: note:   no known conversion for argument 1 from ‘std::string’ {aka ‘std::__cxx11::basic_string<char>’} to ‘int’
  549 |   Offset<String> CreateSharedString(const flatbuffers::string_view str) {
      |                                     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:580:18: note: candidate: ‘flatbuffers::Offset<flatbuffers::String> flatbuffers::FlatBufferBuilder::CreateSharedString(const flatbuffers::String*)’
  580 |   Offset<String> CreateSharedString(const String *str) {
      |                  ^~~~~~~~~~~~~~~~~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:580:51: note:   no known conversion for argument 1 from ‘std::string’ {aka ‘std::__cxx11::basic_string<char>’} to ‘const flatbuffers::String*’
  580 |   Offset<String> CreateSharedString(const String *str) {
      |                                     ~~~~~~~~~~~~~~^~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/src/idl_parser.cpp: In member function ‘flatbuffers::Offset<reflection::Service> flatbuffers::ServiceDef::Serialize(flatbuffers::FlatBufferBuilder*, const flatbuffers::Parser&) const’:
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/src/idl_parser.cpp:3746:50: error: no matching function for call to ‘flatbuffers::FlatBufferBuilder::CreateSharedString(std::string&)’
 3746 |   const auto file__ = builder->CreateSharedString(decl_file_in_project);
      |                       ~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:522:18: note: candidate: ‘flatbuffers::Offset<flatbuffers::String> flatbuffers::FlatBufferBuilder::CreateSharedString(const char*, size_t)’
  522 |   Offset<String> CreateSharedString(const char *str, size_t len) {
      |                  ^~~~~~~~~~~~~~~~~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:522:18: note:   candidate expects 2 arguments, 1 provided
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:549:18: note: candidate: ‘flatbuffers::Offset<flatbuffers::String> flatbuffers::FlatBufferBuilder::CreateSharedString(int)’
  549 |   Offset<String> CreateSharedString(const flatbuffers::string_view str) {
      |                  ^~~~~~~~~~~~~~~~~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:549:68: note:   no known conversion for argument 1 from ‘std::string’ {aka ‘std::__cxx11::basic_string<char>’} to ‘int’
  549 |   Offset<String> CreateSharedString(const flatbuffers::string_view str) {
      |                                     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:580:18: note: candidate: ‘flatbuffers::Offset<flatbuffers::String> flatbuffers::FlatBufferBuilder::CreateSharedString(const flatbuffers::String*)’
  580 |   Offset<String> CreateSharedString(const String *str) {
      |                  ^~~~~~~~~~~~~~~~~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:580:51: note:   no known conversion for argument 1 from ‘std::string’ {aka ‘std::__cxx11::basic_string<char>’} to ‘const flatbuffers::String*’
  580 |   Offset<String> CreateSharedString(const String *str) {
      |                                     ~~~~~~~~~~~~~~^~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/src/idl_parser.cpp: In member function ‘flatbuffers::Offset<reflection::Enum> flatbuffers::EnumDef::Serialize(flatbuffers::FlatBufferBuilder*, const flatbuffers::Parser&) const’:
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/src/idl_parser.cpp:3784:50: error: no matching function for call to ‘flatbuffers::FlatBufferBuilder::CreateSharedString(std::string&)’
 3784 |   const auto file__ = builder->CreateSharedString(decl_file_in_project);
      |                       ~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:522:18: note: candidate: ‘flatbuffers::Offset<flatbuffers::String> flatbuffers::FlatBufferBuilder::CreateSharedString(const char*, size_t)’
  522 |   Offset<String> CreateSharedString(const char *str, size_t len) {
      |                  ^~~~~~~~~~~~~~~~~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:522:18: note:   candidate expects 2 arguments, 1 provided
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:549:18: note: candidate: ‘flatbuffers::Offset<flatbuffers::String> flatbuffers::FlatBufferBuilder::CreateSharedString(int)’
  549 |   Offset<String> CreateSharedString(const flatbuffers::string_view str) {
      |                  ^~~~~~~~~~~~~~~~~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:549:68: note:   no known conversion for argument 1 from ‘std::string’ {aka ‘std::__cxx11::basic_string<char>’} to ‘int’
  549 |   Offset<String> CreateSharedString(const flatbuffers::string_view str) {
      |                                     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:580:18: note: candidate: ‘flatbuffers::Offset<flatbuffers::String> flatbuffers::FlatBufferBuilder::CreateSharedString(const flatbuffers::String*)’
  580 |   Offset<String> CreateSharedString(const String *str) {
      |                  ^~~~~~~~~~~~~~~~~~
/home/oscar/Apps/teams-cam/testing/flatbuffers-2.0.5/include/flatbuffers/flatbuffer_builder.h:580:51: note:   no known conversion for argument 1 from ‘std::string’ {aka ‘std::__cxx11::basic_string<char>’} to ‘const flatbuffers::String*’
  580 |   Offset<String> CreateSharedString(const String *str) {
      |                                     ~~~~~~~~~~~~~~^~~
make[2]: *** [CMakeFiles/flatbuffers.dir/build.make:76: CMakeFiles/flatbuffers.dir/src/idl_parser.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:96: CMakeFiles/flatbuffers.dir/all] Error 2
make: *** [Makefile:146: all] Error 2

oshikore avatar Aug 15 '22 09:08 oshikore

As I suspected, the earlier tag isn't useful, so we'll need to force a specific checkout beyond the last tagged release. I have a PR (#147) that contains the CMake changes for us.

Unfortunately trying to use the latest HEAD from flatbuffers fails to complete configuration against the remainder of Tensorflow. ~~By application of bisection, I have determined that the newest commit hash that seems not to break Tensorflow is: 20aad0c41e1252b04c72111c3eb221280a9c2009 on April 6th.~~ Unfortunately this commit causes a compile error within Tensorflow, so more bisecting required..

phlash avatar Aug 16 '22 16:08 phlash

Hmmn. Tensorflow v2.8.0 as we are currently using does not compile against flatbuffers v2.0.6, so we must upgrade Tensorflow before we can upgrade flatbuffers... unfortunately the latest Tensorflow (v2.9.1) only supports flatbuffers v2.0.5 (trying v2.0.6 or anything later fails to build Tensorflow).

This looks like an issue that needs to be taken downstream, as we cannot fix Tensorflow :disappointed: Apologies.

phlash avatar Aug 16 '22 18:08 phlash

@phlash thanks for the effort in any case. I'll keep an eye on the project, I hope tensorflow will get sorted out eventually.

oshikore avatar Aug 18 '22 12:08 oshikore