zd1 / telseq

A software for calculating telomere length
GNU General Public License v3.0
66 stars 26 forks source link

Error when installing #12

Closed danielecook closed 7 years ago

danielecook commented 7 years ago
make  all-recursive
make[1]: Entering directory `/tmp/telseq-20170307-25899-xl2asn/telseq-0.0.1/src'
Making all in Util
make[2]: Entering directory `/tmp/telseq-20170307-25899-xl2asn/telseq-0.0.1/src/Util'
make[2]: Nothing to be done for `all'.
make[2]: Leaving directory `/tmp/telseq-20170307-25899-xl2asn/telseq-0.0.1/src/Util'
Making all in Telseq
make[2]: Entering directory `/tmp/telseq-20170307-25899-xl2asn/telseq-0.0.1/src/Telseq'
/home/dec211/.linuxbrew/bin/g++-5 -Wall -Wextra -Wno-unknown-pragmas -g -O0 -std=c++11  -Wl,-rpath,/home/dec211/.linuxbrew/opt/bamtools/lib -L/home/dec211/.linuxbrew/opt/bamtools/lib -Wl,-rpath,/home/dec211/.linuxbrew/opt/bamtools/lib/bamtools -L/home/dec211/.linuxbrew/opt/bamtools/lib/bamtools  -L/home/dec211/.linuxbrew/lib -Wl,--dynamic-linker=/home/dec211/.linuxbrew/lib/ld.so -Wl,-rpath,/home/dec211/.linuxbrew/lib -Wl,-rpath=/home/dec211/.linuxbrew/opt/zlib/lib -Wl,-rpath=/home/dec211/.linuxbrew/opt/glibc/lib -Wl,-rpath=/home/dec211/.linuxbrew/opt/gmp/lib -Wl,-rpath=/home/dec211/.linuxbrew/opt/mpfr/lib -Wl,-rpath=/home/dec211/.linuxbrew/opt/libmpc/lib -Wl,-rpath=/home/dec211/.linuxbrew/opt/isl/lib -Wl,-rpath=/home/dec211/.linuxbrew/opt/gcc/lib -Wl,-rpath=/home/dec211/.linuxbrew/opt/bamtools/lib -o telseq telseq-telseq.o ../Util/libutil.a -lbamtools -lz
telseq-telseq.o: In function `scanBam()':
/tmp/telseq-20170307-25899-xl2asn/telseq-0.0.1/src/Telseq/telseq.cpp:165: undefined reference to `BamTools::BamReader::Open(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)'
/tmp/telseq-20170307-25899-xl2asn/telseq-0.0.1/src/Telseq/telseq.cpp:232: undefined reference to `BamTools::BamAlignment::HasTag(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&) const'
telseq-telseq.o: In function `bool BamTools::BamAlignment::GetTag<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >(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':
/home/dec211/.linuxbrew/opt/bamtools/include/bamtools/api/BamAlignment.h:517: undefined reference to `BamTools::BamAlignment::FindTag(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, char*&, unsigned int const&, unsigned int&) const'
collect2: error: ld returned 1 exit status
make[2]: *** [telseq] Error 1
make[2]: Leaving directory `/tmp/telseq-20170307-25899-xl2asn/telseq-0.0.1/src/Telseq'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/tmp/telseq-20170307-25899-xl2asn/telseq-0.0.1/src'
make: *** [all] Error 2
zd1 commented 7 years ago

Hi there, thanks for your interests in telseq. This looks like a problem with linking bamtools. Have you installed bamtools? and if so, have you run

./configure --with-bamtools=/path/to/bamtools

where /path/to/bamtools is the one that has "include" and "lib" subdirectories?

Zhihao

danielecook commented 7 years ago

Hey Zhihao - this actually works just fine:

checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking whether make supports nested variables... yes
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking whether gcc understands -c and -o together... yes
checking for style of include used by make... GNU
checking dependency style of gcc... gcc3
checking for g++... g++
checking whether we are using the GNU C++ compiler... yes
checking whether g++ accepts -g... yes
checking dependency style of g++... gcc3
checking for ranlib... ranlib
checking how to run the C++ preprocessor... g++ -E
checking for grep that handles long lines and -e... /bin/grep
checking for egrep... /bin/grep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking api/BamReader.h usability... yes
checking api/BamReader.h presence... yes
checking for api/BamReader.h... yes
checking that generated files are newer than configure... done
configure: creating ./config.status
config.status: creating Makefile
config.status: creating Util/Makefile
config.status: creating Telseq/Makefile
config.status: creating config.h
config.status: config.h is unchanged
config.status: executing depfiles commands

I also tried using the precompiled binary, and this is the error I get:

./telseq: /lib64/libc.so.6: version `GLIBC_2.15' not found (required by ./telseq)
./telseq: /lib64/libc.so.6: version `GLIBC_2.14' not found (required by ./telseq)
./telseq: /usr/lib64/libstdc++.so.6: version `GLIBCXX_3.4.14' not found (required by ./telseq)
zd1 commented 7 years ago

In this case, I would suggest upgrading libc on your system. For example, using the following

sudo apt-get update sudo apt-get install libc6

Best, Zhihao

danielecook commented 7 years ago

Thanks I'll see what I can do!