The dependency can be turned off as mentioned in this thread.
Hi,
I was trying to install samtools in my account on a linux cluster (x86_64 GNU/Linux). I downloaded the samtools tar.bz2 from http://www.htslib.org/download/ . After unzipping all the files, I cd into the directory and run 'make install'. However, I get an error:
[bsm@submit-3 samtools-1.4]$ make install
cd htslib-1.4 && make lib-static
make[1]: Entering directory /home/bsm/software/samtools-1.4/htslib-1.4'
gcc -g -Wall -O2 -I. -c -o cram/cram_io.o cram/cram_io.c
cram/cram_io.c:60:18: error: lzma.h: No such file or directory
cram/cram_io.c: In function ‘lzma_mem_deflate’:
cram/cram_io.c:865: warning: implicit declaration of function ‘lzma_stream_buffer_bound’
cram/cram_io.c:871: error: ‘LZMA_OK’ undeclared (first use in this function)
cram/cram_io.c:871: error: (Each undeclared identifier is reported only once
cram/cram_io.c:871: error: for each function it appears in.)
cram/cram_io.c:871: warning: implicit declaration of function ‘lzma_easy_buffer_encode’
cram/cram_io.c:871: error: ‘LZMA_CHECK_CRC32’ undeclared (first use in this function)
cram/cram_io.c: In function ‘lzma_mem_inflate’:
cram/cram_io.c:881: error: ‘lzma_stream’ undeclared (first use in this function)
cram/cram_io.c:881: error: expected ‘;’ before ‘strm’
cram/cram_io.c:887: error: ‘LZMA_OK’ undeclared (first use in this function)
cram/cram_io.c:887: warning: implicit declaration of function ‘lzma_stream_decoder’
cram/cram_io.c:887: error: ‘strm’ undeclared (first use in this function)
cram/cram_io.c:887: warning: implicit declaration of function ‘lzma_easy_decoder_memusage’
cram/cram_io.c:902: warning: implicit declaration of function ‘lzma_code’
cram/cram_io.c:902: error: ‘LZMA_RUN’ undeclared (first use in this function)
cram/cram_io.c:903: error: ‘LZMA_STREAM_END’ undeclared (first use in this function)
cram/cram_io.c:915: error: ‘LZMA_FINISH’ undeclared (first use in this function)
cram/cram_io.c:924: warning: implicit declaration of function ‘lzma_end’
make[1]: *** [cram/cram_io.o] Error 1
make[1]: Leaving directory/home/bsm/software/samtools-1.4/htslib-1.4'
make: * [htslib-1.4/libhts.a] Error 2
what do I need to do?
thanks!
--sorry for the bad formatting! I don't know how I should correct it :(
3 answers
You are missing the lzma headers, and you need to install the development package for lzma. On Debian and Ubuntu, it is called liblzma-devel. You probably have to ask your sys admin to install it for you.
sudo apt-get install build-essential sudo apt-get install samtools
Thanks all! The thread suggested by genomax2 worked!
Log in to answer this question.
In this thread scroll down and look up an answer that mentions issue #570. See if that fixes this issue.