Closed lwl1112 closed 5 years ago
I don't think bamtools specifies the language version, so I'm not sure why it is being compiled as c++11. As far as I know it doesn't use c++11 features. What version of gcc are you using?
Unfortunately I don't have much time to support SGA these days so I suggest that you install through bioconda.
installed bioconda, and now I can use SGA. thank you.
No problem
after ./configure, I command 'make', and got the following errors:
sga-connect.o: In function
connectMain(int, char)': connect.cpp:(.text+0x1750): undefined reference toBamTools::BamReader::Open(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)' sga-filterBAM.o: In function
getErrorRate(BamTools::BamAlignment&)': filterBAM.cpp:(.text+0x870): undefined reference toBamTools::BamAlignment::FindTag(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, char*&, unsigned int const&, unsigned int&) const' filterBAM.cpp:(.text+0xa0b): undefined reference to
BamTools::BamAlignment::SetErrorString(std::cxx11::basic_string<char, std::char_traitsBamTools::BamAlignment::SetErrorString(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&) const' sga-filterBAM.o: In function
filterBAMMain(int, char)': filterBAM.cpp:(.text+0x1b94): undefined reference toBamTools::BamReader::Open(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)' filterBAM.cpp:(.text+0x1bc4): undefined reference to
_ZNK8BamTools9BamReader13GetHeaderTextB5cxx11Ev' filterBAM.cpp:(.text+0x1bd7): undefined reference toBamTools::BamWriter::Open(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, std::vector<BamTools::RefData, std::allocator<BamTools::RefData> > const&)' sga-rewrite-evidence-bam.o: In function
rewriteEvidenceBAMMain(int, char)': rewrite-evidence-bam.cpp:(.text+0x6a9): undefined reference toBamTools::BamReader::Open(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)' rewrite-evidence-bam.cpp:(.text+0x11dc): undefined reference to
_ZNK8BamTools9BamReader13GetHeaderTextB5cxx11Ev' rewrite-evidence-bam.cpp:(.text+0x11f4): undefined reference toBamTools::BamWriter::Open(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, std::vector<BamTools::RefData, std::allocator<BamTools::RefData> > const&)' sga-somatic-variant-filters.o: In function
getVariantCoverage(BamTools::BamReader, VCFRecord const&, ReadTable const)': somatic-variant-filters.cpp:(.text+0x3bf0): undefined reference toBamTools::BamReader::GetReferenceID(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&) const' sga-somatic-variant-filters.o: In function
somaticVariantFiltersMain(int, char*)': somatic-variant-filters.cpp:(.text+0x47ff): undefined reference toBamTools::BamReader::Open(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)' somatic-variant-filters.cpp:(.text+0x4851): undefined reference to
BamTools::BamReader::Open(std::__cxx11::basic_string<char, std::char_traitsGraphCompareAggregateResults::GraphCompareAggregateResults(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > const&, ReadTable const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)': GraphCompare.cpp:(.text+0x25fd): undefined reference to
BamTools::SamHeader::SamHeader(std::cxx11::basic_string<char, std::char_traitsmake[1]: [all-recursive] Error 1 make[1]: Leaving directory
make: [all] Error 2`
I guess the most recent bamtools is compiled with c++11, however, sga is using c++98. so my question is which version of bamtools should I choose and how to compile? can you explain in details (for example, do I need to edit cmakelist.txt when compiling bamtools so that the same compiler version is used as in SGA., and how to edit?, thanks) thank you very much.