pangenome / odgi

Optimized Dynamic Genome/Graph Implementation: understanding pangenome graphs
https://doi.org/10.1093/bioinformatics/btac308
MIT License
196 stars 40 forks source link

odgi compilation error #506

Closed subwaystation closed 1 year ago

subwaystation commented 1 year ago

odgi currently does not compile on my machine:

cmake -H. -Bbuild && cmake --build build -- -j 1
-- Could NOT find pybind11 (missing: pybind11_DIR)
-- Found OpenMP_C: -fopenmp (found version "4.5") 
-- Found OpenMP_CXX: -fopenmp (found version "4.5") 
-- 

-- Checking for module 'sdsl-lite'
--   Package 'sdsl-lite', required by 'virtual:world', not found
-- Checking for module 'libdivsufsort'
--   Package 'libdivsufsort', required by 'virtual:world', not found
-- Compiling odgi sources with PIC=ON
-- ODGI CMAKE_BUILD_TYPE: Release
-- ODGI CMAKE_CXX_FLAGS: -fopenmp -Ofast -march=native -pipe -msse4.2 -funroll-all-loops -fPIC
-- ODGI CMAKE_C_FLAGS: -fopenmp -Ofast -march=native -pipe -msse4.2 -funroll-all-loops -fPIC
-- Found OpenMP_C: -fopenmp (found version "4.5") 
-- Found OpenMP_CXX: -fopenmp (found version "4.5") 
-- pybind11 v2.6.2 dev1
-- Configuring done (0.5s)
-- Generating done (0.0s)
-- Build files have been written to: /home/heumos/odgi/build
[  0%] Performing build step for 'libbf-EXT'
[  4%] Building CXX object CMakeFiles/libbf_static.dir/src/bitvector.cpp.o
/home/heumos/odgi/deps/libbf/src/bitvector.cpp:13:1: error: ‘uint8_t’ does not name a type
   13 | uint8_t count_table[] = {
      | ^~~~~~~
/home/heumos/odgi/deps/libbf/src/bitvector.cpp:5:1: note: ‘uint8_t’ is defined in header ‘<cstdint>’; did you forget to ‘#include <cstdint>’?
    4 | #include <cassert>
  +++ |+#include <cstdint>
    5 | 
/home/heumos/odgi/deps/libbf/src/bitvector.cpp: In member function ‘bf::size_type bf::bitvector::count() const’:
/home/heumos/odgi/deps/libbf/src/bitvector.cpp:343:12: error: ‘count_table’ was not declared in this scope
  343 |       n += count_table[block & ((1u << 8) - 1)];
      |            ^~~~~~~~~~~
make[5]: *** [CMakeFiles/libbf_static.dir/build.make:76: CMakeFiles/libbf_static.dir/src/bitvector.cpp.o] Error 1
make[4]: *** [CMakeFiles/Makefile2:902: CMakeFiles/libbf_static.dir/all] Error 2
make[3]: *** [Makefile:146: all] Error 2
make[2]: *** [CMakeFiles/libbf-EXT.dir/build.make:86: libbf-EXT-prefix/src/libbf-EXT-stamp/libbf-EXT-build] Error 2
make[1]: *** [CMakeFiles/Makefile2:159: CMakeFiles/libbf-EXT.dir/all] Error 2
make: *** [Makefile:146: all] Error 2
gcc (GCC) 13.1.1 20230429
Copyright (C) 2023 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

I suspect the GCC version is the issue?

subwaystation commented 1 year ago

Fix in progress https://github.com/pangenome/odgi/pull/507.