graphia icon indicating copy to clipboard operation
graphia copied to clipboard

breakpad breaks build

Open nsajko opened this issue 3 years ago • 4 comments

With Git master Graphia, QT 6.3.1 and GCC 12.1.1 the build fails quickly like so:

[...]
-- Looking for pthread.h - found
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD - Success
-- Found Threads: TRUE  
-- Performing Test HAVE_STDATOMIC
-- Performing Test HAVE_STDATOMIC - Success
-- Found WrapAtomic: TRUE  
fatal: No names found, cannot describe anything.
-- Found OpenGL: /usr/lib/libOpenGL.so   
-- Found WrapOpenGL: TRUE  
-- Found XKB: /usr/lib/libxkbcommon.so (found suitable version "1.4.1", minimum required is "0.5.0") 
-- Found WrapVulkanHeaders: /usr/include  
fatal: No names found, cannot describe anything.
fatal: No names found, cannot describe anything.
fatal: No names found, cannot describe anything.
fatal: No names found, cannot describe anything.
fatal: No names found, cannot describe anything.
fatal: No names found, cannot describe anything.
fatal: No names found, cannot describe anything.
fatal: No names found, cannot describe anything.
fatal: No names found, cannot describe anything.
-- Configuring done
-- Generating done
-- Build files have been written to: /home/nsajko/tmp/graphia/build
[nsajko@aceramd graphia]$ cmake --build build
[  0%] Automatic MOC for target thirdparty_static
[  0%] Built target thirdparty_static_autogen
[  0%] Building CXX object source/thirdparty/CMakeFiles/thirdparty_static.dir/thirdparty_static_autogen/mocs_compilation.cpp.o
[  0%] Building CXX object source/thirdparty/CMakeFiles/thirdparty_static.dir/breakpad/src/client/minidump_file_writer.cc.o
[  1%] Building C object source/thirdparty/CMakeFiles/thirdparty_static.dir/breakpad/src/common/convert_UTF.c.o
[  1%] Building CXX object source/thirdparty/CMakeFiles/thirdparty_static.dir/breakpad/src/common/md5.cc.o
[  1%] Building CXX object source/thirdparty/CMakeFiles/thirdparty_static.dir/breakpad/src/common/string_conversion.cc.o
[  1%] Building CXX object source/thirdparty/CMakeFiles/thirdparty_static.dir/breakpad/src/client/linux/crash_generation/crash_generation_client.cc.o
[  1%] Building CXX object source/thirdparty/CMakeFiles/thirdparty_static.dir/breakpad/src/client/linux/dump_writer_common/thread_info.cc.o
[  1%] Building CXX object source/thirdparty/CMakeFiles/thirdparty_static.dir/breakpad/src/client/linux/dump_writer_common/ucontext_reader.cc.o
[  1%] Building CXX object source/thirdparty/CMakeFiles/thirdparty_static.dir/breakpad/src/client/linux/handler/exception_handler.cc.o
/home/nsajko/tmp/graphia/source/thirdparty/breakpad/src/client/linux/handler/exception_handler.cc: In function ‘void google_breakpad::{anonymous}::InstallAlternateStackLocked()’:
/home/nsajko/tmp/graphia/source/thirdparty/breakpad/src/client/linux/handler/exception_handler.cc:141:49: error: no matching function for call to ‘max(int, long int)’
  141 |   static const unsigned kSigStackSize = std::max(16384, SIGSTKSZ);
      |                                         ~~~~~~~~^~~~~~~~~~~~~~~~~
In file included from /usr/include/c++/12.1.1/string:50,
                 from /home/nsajko/tmp/graphia/source/thirdparty/breakpad/src/client/linux/handler/exception_handler.h:38,
                 from /home/nsajko/tmp/graphia/source/thirdparty/breakpad/src/client/linux/handler/exception_handler.cc:66:
/usr/include/c++/12.1.1/bits/stl_algobase.h:254:5: note: candidate: ‘template<class _Tp> constexpr const _Tp& std::max(const _Tp&, const _Tp&)’
  254 |     max(const _Tp& __a, const _Tp& __b)
      |     ^~~
/usr/include/c++/12.1.1/bits/stl_algobase.h:254:5: note:   template argument deduction/substitution failed:
/home/nsajko/tmp/graphia/source/thirdparty/breakpad/src/client/linux/handler/exception_handler.cc:141:49: note:   deduced conflicting types for parameter ‘const _Tp’ (‘int’ and ‘long int’)
  141 |   static const unsigned kSigStackSize = std::max(16384, SIGSTKSZ);
      |                                         ~~~~~~~~^~~~~~~~~~~~~~~~~
/usr/include/c++/12.1.1/bits/stl_algobase.h:300:5: note: candidate: ‘template<class _Tp, class _Compare> constexpr const _Tp& std::max(const _Tp&, const _Tp&, _Compare)’
  300 |     max(const _Tp& __a, const _Tp& __b, _Compare __comp)
      |     ^~~
/usr/include/c++/12.1.1/bits/stl_algobase.h:300:5: note:   template argument deduction/substitution failed:
/home/nsajko/tmp/graphia/source/thirdparty/breakpad/src/client/linux/handler/exception_handler.cc:141:49: note:   deduced conflicting types for parameter ‘const _Tp’ (‘int’ and ‘long int’)
  141 |   static const unsigned kSigStackSize = std::max(16384, SIGSTKSZ);
      |                                         ~~~~~~~~^~~~~~~~~~~~~~~~~
In file included from /usr/include/c++/12.1.1/algorithm:61,
                 from /home/nsajko/tmp/graphia/source/thirdparty/breakpad/src/client/linux/handler/exception_handler.cc:86:
/usr/include/c++/12.1.1/bits/stl_algo.h:5746:5: note: candidate: ‘template<class _Tp> constexpr _Tp std::max(initializer_list<_Tp>)’
 5746 |     max(initializer_list<_Tp> __l)
      |     ^~~
/usr/include/c++/12.1.1/bits/stl_algo.h:5746:5: note:   template argument deduction/substitution failed:
/home/nsajko/tmp/graphia/source/thirdparty/breakpad/src/client/linux/handler/exception_handler.cc:141:49: note:   mismatched types ‘std::initializer_list<_Tp>’ and ‘int’
  141 |   static const unsigned kSigStackSize = std::max(16384, SIGSTKSZ);
      |                                         ~~~~~~~~^~~~~~~~~~~~~~~~~
/usr/include/c++/12.1.1/bits/stl_algo.h:5756:5: note: candidate: ‘template<class _Tp, class _Compare> constexpr _Tp std::max(initializer_list<_Tp>, _Compare)’
 5756 |     max(initializer_list<_Tp> __l, _Compare __comp)
      |     ^~~
/usr/include/c++/12.1.1/bits/stl_algo.h:5756:5: note:   template argument deduction/substitution failed:
/home/nsajko/tmp/graphia/source/thirdparty/breakpad/src/client/linux/handler/exception_handler.cc:141:49: note:   mismatched types ‘std::initializer_list<_Tp>’ and ‘int’
  141 |   static const unsigned kSigStackSize = std::max(16384, SIGSTKSZ);
      |                                         ~~~~~~~~^~~~~~~~~~~~~~~~~
make[2]: *** [source/thirdparty/CMakeFiles/thirdparty_static.dir/build.make:188: source/thirdparty/CMakeFiles/thirdparty_static.dir/breakpad/src/client/linux/handler/exception_handler.cc.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:288: source/thirdparty/CMakeFiles/thirdparty_static.dir/all] Error 2
make: *** [Makefile:136: all] Error 2
[nsajko@aceramd graphia]$

nsajko avatar Aug 04 '22 23:08 nsajko

A quick look at this commit's commit message seems to indicate it would fix the issue: https://chromium.googlesource.com/breakpad/breakpad/+/605c51ed96ad44b34c457bbca320e74e194c317e

nsajko avatar Aug 06 '22 23:08 nsajko

Hmm OK, will have a look when I get a chance. Our CI uses GCC 11 so is unaffected by this.

timangus avatar Aug 10 '22 09:08 timangus

According to the linked commit message, this is triggered by glibc > 2.33. So GCC version doesn't matter, I guess.

nsajko avatar Aug 11 '22 12:08 nsajko

Hmm, might be the installation then. CI uses Ubuntu 20.04.

timangus avatar Aug 11 '22 16:08 timangus

1cd209f probably fixes this...

timangus avatar Sep 16 '22 13:09 timangus

I'm assuming this is no longer a problem.

timangus avatar Oct 10 '22 12:10 timangus