ablab/spades

Break on AUR compile

muntean-alex opened this issue · 1 comments

Description of bug

Two relatively new Manjaro installs.
Using AUR to install, both halt on the same install.
AUR regularly points to SPAdes v. 3.15.4
Also tried with 3.15.5 which breaks at the same point

$ gcc --version
gcc (GCC) 13.2.1 20230801
[ 40%] Building C object ext/easel/CMakeFiles/easel.dir/esl_ssi.c.o
In member function ‘void btree::btree_node<Params>::set_child(int, btree::btree_node<Params>*) [with Params = btree::btree_map_params<omnigraph::impl::EdgeId, omnigraph::de::StrongWeakPtr<omnigraph::de::Histogram<omnigraph::de::PointT<float, float> > >, std::less<omnigraph::impl::EdgeId>, std::allocator<std::pair<const omnigraph::impl::EdgeId, omnigraph::de::StrongWeakPtr<omnigraph::de::Histogram<omnigraph::de::PointT<float, float> > > > >, 256>]’,
    inlined from ‘void btree::btree<Params>::rebalance_or_split(iterator*) [with Params = btree::btree_map_params<omnigraph::impl::EdgeId, omnigraph::de::StrongWeakPtr<omnigraph::de::Histogram<omnigraph::de::PointT<float, float> > >, std::less<omnigraph::impl::EdgeId>, std::allocator<std::pair<const omnigraph::impl::EdgeId, omnigraph::de::StrongWeakPtr<omnigraph::de::Histogram<omnigraph::de::PointT<float, float> > > > >, 256>]’ at /home/alexm/spades/src/SPAdes-3.15.4/ext/include/btree/btree.h:2151:24:
/home/alexm/spades/src/SPAdes-3.15.4/ext/include/btree/btree.h:577:23: warning: array subscript ‘btree::btree_node<btree::btree_map_params<omnigraph::impl::EdgeId, omnigraph::de::StrongWeakPtr<omnigraph::de::Histogram<omnigraph::de::PointT<float, float> > >, std::less<omnigraph::impl::EdgeId>, std::allocator<std::pair<const omnigraph::impl::EdgeId, omnigraph::de::StrongWeakPtr<omnigraph::de::Histogram<omnigraph::de::PointT<float, float> > > > >, 256> >[0]’ is partly outside array bounds of ‘unsigned char [384]’ [-Warray-bounds=]
  577 |     *mutable_child(i) = c;
      |     ~~~~~~~~~~~~~~~~~~^~~
In member function ‘_Tp* std::__new_allocator<_Tp>::allocate(size_type, const void*) [with _Tp = char]’,
    inlined from ‘btree::btree<Params>::node_type* btree::btree<Params>::new_internal_node(node_type*) [with Params = btree::btree_map_params<omnigraph::impl::EdgeId, omnigraph::de::StrongWeakPtr<omnigraph::de::Histogram<omnigraph::de::PointT<float, float> > >, std::less<omnigraph::impl::EdgeId>, std::allocator<std::pair<const omnigraph::impl::EdgeId, omnigraph::de::StrongWeakPtr<omnigraph::de::Histogram<omnigraph::de::PointT<float, float> > > > >, 256>]’ at /home/alexm/spades/src/SPAdes-3.15.4/ext/include/btree/btree.h:1281:47,
    inlined from ‘void btree::btree<Params>::rebalance_or_split(iterator*) [with Params = btree::btree_map_params<omnigraph::impl::EdgeId, omnigraph::de::StrongWeakPtr<omnigraph::de::Histogram<omnigraph::de::PointT<float, float> > >, std::less<omnigraph::impl::EdgeId>, std::allocator<std::pair<const omnigraph::impl::EdgeId, omnigraph::de::StrongWeakPtr<omnigraph::de::Histogram<omnigraph::de::PointT<float, float> > > > >, 256>]’ at /home/alexm/spades/src/SPAdes-3.15.4/ext/include/btree/btree.h:2150:33:
/usr/include/c++/13.2.1/bits/new_allocator.h:147:55: note: object of size 384 allocated by ‘operator new’
  147 |         return static_cast<_Tp*>(_GLIBCXX_OPERATOR_NEW(__n * sizeof(_Tp)));
      |                                                       ^
In member function ‘void btree::btree_node<Params>::set_child(int, btree::btree_node<Params>*) [with Params = btree::btree_map_params<omnigraph::impl::EdgeId, omnigraph::de::StrongWeakPtr<omnigraph::de::Histogram<omnigraph::de::PointT<float, float> > >, std::less<omnigraph::impl::EdgeId>, std::allocator<std::pair<const omnigraph::impl::EdgeId, omnigraph::de::StrongWeakPtr<omnigraph::de::Histogram<omnigraph::de::PointT<float, float> > > > >, 256>]’,
    inlined from ‘void btree::btree<Params>::rebalance_or_split(iterator*) [with Params = btree::btree_map_params<omnigraph::impl::EdgeId, omnigraph::de::StrongWeakPtr<omnigraph::de::Histogram<omnigraph::de::PointT<float, float> > >, std::less<omnigraph::impl::EdgeId>, std::allocator<std::pair<const omnigraph::impl::EdgeId, omnigraph::de::StrongWeakPtr<omnigraph::de::Histogram<omnigraph::de::PointT<float, float> > > > >, 256>]’ at /home/alexm/spades/src/SPAdes-3.15.4/ext/include/btree/btree.h:2151:24:
/home/alexm/spades/src/SPAdes-3.15.4/ext/include/btree/btree.h:578:23: warning: array subscript ‘btree::btree_node<btree::btree_map_params<omnigraph::impl::EdgeId, omnigraph::de::StrongWeakPtr<omnigraph::de::Histogram<omnigraph::de::PointT<float, float> > >, std::less<omnigraph::impl::EdgeId>, std::allocator<std::pair<const omnigraph::impl::EdgeId, omnigraph::de::StrongWeakPtr<omnigraph::de::Histogram<omnigraph::de::PointT<float, float> > > > >, 256> >[0]’ is partly outside array bounds of ‘unsigned char [384]’ [-Warray-bounds=]
  578 |     c->fields_.parent = this;
      |     ~~~~~~~~~~~~~~~~~~^~~~~~
In member function ‘_Tp* std::__new_allocator<_Tp>::allocate(size_type, const void*) [with _Tp = char]’,
    inlined from ‘btree::btree<Params>::node_type* btree::btree<Params>::new_internal_node(node_type*) [with Params = btree::btree_map_params<omnigraph::impl::EdgeId, omnigraph::de::StrongWeakPtr<omnigraph::de::Histogram<omnigraph::de::PointT<float, float> > >, std::less<omnigraph::impl::EdgeId>, std::allocator<std::pair<const omnigraph::impl::EdgeId, omnigraph::de::StrongWeakPtr<omnigraph::de::Histogram<omnigraph::de::PointT<float, float> > > > >, 256>]’ at /home/alexm/spades/src/SPAdes-3.15.4/ext/include/btree/btree.h:1281:47,
    inlined from ‘void btree::btree<Params>::rebalance_or_split(iterator*) [with Params = btree::btree_map_params<omnigraph::impl::EdgeId, omnigraph::de::StrongWeakPtr<omnigraph::de::Histogram<omnigraph::de::PointT<float, float> > >, std::less<omnigraph::impl::EdgeId>, std::allocator<std::pair<const omnigraph::impl::EdgeId, omnigraph::de::StrongWeakPtr<omnigraph::de::Histogram<omnigraph::de::PointT<float, float> > > > >, 256>]’ at /home/alexm/spades/src/SPAdes-3.15.4/ext/include/btree/btree.h:2150:33:
/usr/include/c++/13.2.1/bits/new_allocator.h:147:55: note: object of size 384 allocated by ‘operator new’
  147 |         return static_cast<_Tp*>(_GLIBCXX_OPERATOR_NEW(__n * sizeof(_Tp)));
      |                                                       ^
In file included from /home/alexm/spades/src/SPAdes-3.15.4/ext/src/llvm/Signals.cpp:14:
/home/alexm/spades/src/SPAdes-3.15.4/ext/include/llvm/Support/Signals.h:117:8: **error: variable or field ‘CleanupOnSignal’ declared void**
  117 |   void CleanupOnSignal(uintptr_t Context);
      |        ^~~~~~~~~~~~~~~
/home/alexm/spades/src/SPAdes-3.15.4/ext/include/llvm/Support/Signals.h:117:24: **error: ‘uintptr_t’ was not declared in this scope**
  117 |   void CleanupOnSignal(uintptr_t Context);
      |                        ^~~~~~~~~
/home/alexm/spades/src/SPAdes-3.15.4/ext/include/llvm/Support/Signals.h:18:1: note: ‘uintptr_t’ is defined in header ‘<cstdint>’; did you forget to ‘#include <cstdint>’?
   17 | #include <string>
  +++ |+#include <cstdint>
   18 | 
[ 40%] Building C object ext/easel/CMakeFiles/easel.dir/esl_stack.c.o
[ 40%] Building CXX object ext/llvm/CMakeFiles/llvm-support.dir/SmallVector.cpp.o
[ 41%] Building CXX object ext/llvm/CMakeFiles/llvm-support.dir/SourceMgr.cpp.o
[ 41%] Building C object ext/easel/CMakeFiles/easel.dir/esl_stats.c.o
[ 42%] Building C object ext/easel/CMakeFiles/easel.dir/esl_stopwatch.c.o
[ 42%] Building C object ext/easel/CMakeFiles/easel.dir/esl_stretchexp.c.o
[ 42%] Building C object ext/easel/CMakeFiles/easel.dir/esl_threads.c.o
In file included from /home/alexm/spades/src/SPAdes-3.15.4/ext/src/llvm/Signals.cpp:219:
/home/alexm/spades/src/SPAdes-3.15.4/ext/src/llvm/Signals.inc:347:44: **error: ‘void llvm::sys::CleanupOnSignal(uintptr_t)’ should have been declared inside ‘llvm::sys’**
  347 | void sys::CleanupOnSignal(uintptr_t Context) {
      |                                            ^
[ 42%] Building C object ext/easel/CMakeFiles/easel.dir/esl_tree.c.o
[ 42%] Building CXX object ext/llvm/CMakeFiles/llvm-support.dir/StringExtras.cpp.o
[ 42%] Building C object ext/easel/CMakeFiles/easel.dir/esl_vectorops.c.o
**make[2]: *** [ext/llvm/CMakeFiles/llvm-support.dir/build.make:440: ext/llvm/CMakeFiles/llvm-support.dir/Signals.cpp.o] Error 1**
make[2]: *** Waiting for unfinished jobs....
[ 43%] Building C object ext/easel/CMakeFiles/easel.dir/esl_vmx.c.o
[ 43%] Building C object ext/easel/CMakeFiles/easel.dir/esl_weibull.c.o
[ 43%] Building C object ext/easel/CMakeFiles/easel.dir/esl_workqueue.c.o
[ 43%] Building C object ext/easel/CMakeFiles/easel.dir/esl_wuss.c.o
[ 43%] Linking CXX static library libpaired_info.a
[ 43%] Built target paired_info
[ 43%] Linking C static library libeasel.a
[ 43%] Built target easel
[ 43%] Linking CXX static library libbinary_io.a
[ 43%] Built target binary_io
**make[1]: *** [CMakeFiles/Makefile2:1426: ext/llvm/CMakeFiles/llvm-support.dir/all] Error 2
make: *** [Makefile:166: all] Error 2
==> ERROR: A failure occurred in build().
    Aborting...**

spades.log

not available

params.txt

not available

SPAdes version

SPAdes v.3.15.4/5

Operating System

Linux chromebox 6.6.10-1-MANJARO

Python Version

Python 3.11.6

Method of SPAdes installation

AUR (manual)

No errors reported in spades.log

  • Yes
asl commented

Hello

You need to apply patches from #1157 to build with gcc 13. This will be a part of next SPAdes release