ParBLiSS / PaSGAL

Parallel Sequence to Graph Alignment
MIT License
35 stars 4 forks source link

build failure with tests #3

Open ekg opened 5 years ago

ekg commented 5 years ago

Strangely, I'm able to build the PaSGAL executable, but I'm getting a build failure that looks to be related to the tests:

-> % cmake -H. -Bbuild -DSIMD_SUPPORT=avx2 && cmake --build build -- -j 4                                                                                      
-- GNU C++ compiler supports AVX                                                                                                                               
-- Enabling AVX2...                                                                                                                              
-- Found OpenMP                                                                                                                                                
-- Protobuf libraries, header files and executables located                                                                                                    
-- Configuring done                                                                                                                                            
-- Generating done                                                                                                                                             
-- Build files have been written to: /home/erik/PaSGAL/build                                                                                                   
[ 29%] Built target gtest                                                                                                                                      
[ 29%] Built target vg_protobuf                                                                                                                                
[ 52%] Built target PaSGAL                                                                                                                                     
[ 52%] Built target gtest_main                                                                                                                                 
[ 58%] Building CXX object tests/CMakeFiles/test-local_alignment_uniform_len.dir/test_local_alignment_uniform_len.cpp.o                                        
[ 64%] Building CXX object tests/CMakeFiles/test-graph_load.dir/test_graph_load.cpp.o                                                                          
[ 70%] Building CXX object tests/CMakeFiles/test-pasgal_all.dir/test_pasgal_all.cpp.o                                                                          
[ 76%] Building CXX object tests/CMakeFiles/test-local_alignment.dir/test_local_alignment.cpp.o                                                                
In file included from /home/erik/PaSGAL/ext/gtest/googletest/include/gtest/gtest.h:63:0,                                                                       
                 from /home/erik/PaSGAL/tests/test_graph_load.cpp:7:                                                                                           
/home/erik/PaSGAL/ext/gtest/googletest/include/gtest/gtest-matchers.h:296:22: error: ‘IsSame’ is not a member of ‘testing::internal’                           
           !internal::IsSame<U, const U&>::value>::type* = nullptr)                                                                                            
                      ^~~~~~                                                                                                                                   
/home/erik/PaSGAL/ext/gtest/googletest/include/gtest/gtest-matchers.h:296:22: note: suggested alternative: ‘IsSpace’                                           
           !internal::IsSame<U, const U&>::value>::type* = nullptr)                                                                                            
                      ^~~~~~                                                                                                                                   
                      IsSpace                                                                                                                                  
....

This continues for a while. Any ideas?

There is a possibility that I've misconfigured things to get protobuf to work. From CMakeLists.txt:

set(PROTOBUF_INCLUDE_DIR "/home/erik/vg/include")
set(PROTOBUF_LIBRARY "/home/erik/vg/lib/libprotobuf.so")
set(PROTOBUF_PROTOC_EXECUTABLE "/home/erik/vg/bin/protoc")

I'm using protobuf from my vg repository. How would you suggest I build protobuf? If I still get the error when building it like you are then it might be something that you can reproduce.

As an aside, in vg we're talking about promoting the approach in GraphAligner of installing protobuf and its libraries with conda. Building it more complex than the rest of the system.

cjain7 commented 5 years ago

Protobuf path seems correct.. Seems like googletest is throwing some error, which could be due to a C++ compiler that doesn't provide C++11 support.

Just to be safer, I'd recommend manually informing Cmake what compiler to use... Again following the example in README, can you first delete the build directory to restart. Also, you don't need to edit the cmake files for configuring protobuf. While running cmake, you can specify following options:

-DPROTOBUF_DIR=/home/erik/vg/ -DCMAKE_CXX_COMPILER=<path to g++> -DCMAKE_C_COMPILER=<path to gcc>

Using PROTOBUF_DIR, cmake will find the relevant protobuf files.

Re: Conda Certaintly, it might make things easier. Let me check it out.