samtools creating difficulties in installtion
2
0
Entering edit mode
8.3 years ago
ammarsabir15 ▴ 70

I tried to install samtools in ubuntu 15.10 (64bit) but it is causing following errors.

When I configured samtools it said that libncurses is missing.

Then I installed libncurses, but again the error was the same.

Then when I again tried to download libncurses then the terminal printed that libncurses is already present.

Below is given the commands I used along with their output:

sudo apt-get install libncurses5-dev libncursesw5-dev

and this is the output of above command


Output of above command

ammar@ammar-HP-15-Notebook-PC:~$ sudo apt-get install libncurses5-dev libncursesw5-dev

Reading package lists... Done

Building dependency tree

Reading state information... Done

libncurses5-dev is already the newest version.

libncursesw5-dev is already the newest version.

The following packages were automatically installed and are no longer required:

linux-headers-4.2.0-16 linux-headers-4.2.0-16-generic

linux-image-4.2.0-16-generic linux-image-extra-4.2.0-16-generic

linux-signed-image-4.2.0-16-generic

Use 'apt-get autoremove' to remove them.

0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded

                                  ----------

When i again changed the directory to samtools and given the command for configuring the same issue was there.

                                  ----------
                             ## Output of ./configure ##

ammar@ammar-HP-15-Notebook-PC:~$ cd samtools-1.3.1 ammar@ammar-HP-15-Notebook-PC:~/samtools-1.3.1$ ./configure

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 for special C compiler options needed for large files... no

checking for _FILE_OFFSET_BITS value needed for large files... no

checking location of HTSlib source tree... htslib-1.3.1

./configure: line 3086: AX_WITH_CURSES: command not found

configure: error: curses development files not found

The 'samtools tview' command uses the curses text user interface library. Building samtools with tview requires curses/ncurses/etc development files to be installed on the build machine; you may need to ensure a package such as libncurses5-dev (on Debian or Ubuntu Linux) or ncurses-devel (on RPM-based Linux distributions) is installed.

FAILED. Either configure --without-curses or resolve this error to build samtools successfully.

                                   ----------
                                   ----------

Anyone who knows please help.

next-gen sequencing snp • 6.9k views
ADD COMMENT
0
Entering edit mode

Unless you really want to use samtools tview, just ./configure --without-curses.

ADD REPLY
0
Entering edit mode

I don't know about tview what it is used for??.

Also this happens when I run with above command .

Below is given output of above command



ammar@ammar-HP-15-Notebook-PC:~/samtools-1.3.1$ ./configure --without-curses

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 for special C compiler options needed for large files... no

checking for _FILE_OFFSET_BITS value needed for large files... no

checking location of HTSlib source tree... htslib-1.3.1

checking for zlib.h... yes

checking for inflate in -lz... yes

configure: creating ./config.status

config.status: creating config.mk

config.status: creating config.h

config.status: config.h is unchanged

=== configuring in htslib-1.3.1 (/home/ammar/samtools-1.3.1/htslib-1.3.1)

configure: running /bin/bash ./configure --disable-option-checking '--prefix=/usr/local' '--without-curses' --cache-file=/dev/null --srcdir=.

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 for ranlib... ranlib

checking for special C compiler options needed for large files... no

checking for _FILE_OFFSET_BITS value needed for large files... no

checking how to run the C preprocessor... gcc -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 for stdlib.h... (cached) yes

checking for unistd.h... (cached) yes

checking for sys/param.h... yes

checking for getpagesize... yes

checking for working mmap... yes

checking for gmtime_r... yes

checking for zlib.h... yes

checking for inflate in -lz... yes

configure: creating ./config.status

config.status: creating config.mk

config.status: creating config.h

config.status: config.h is unchanged

----------

And after that when I gave make command then again it fails

Below is its output

----------

ammar@ammar-HP-15-Notebook-PC:~/samtools-1.3.1$ sudo make install

mkdir -p -m 755 /usr/local/bin /usr/local/share/man/man1

install -p samtools misc/ace2sam misc/maq2sam-long misc/maq2sam-short misc/md5fa misc/md5sum-lite misc/wgsim

misc/blast2sam.pl misc/bowtie2sam.pl misc/export2sam.pl misc/interpolate_sam.pl misc/novo2sam.pl misc/plot-bamstats

misc/psl2sam.pl misc/sam2vcf.pl misc/samtools.pl misc/seq_cache_populate.pl misc/soap2sam.pl misc/varfilter.py

misc/wgsim_eval.pl misc/zoom2sam.pl /usr/local/bin

install: cannot overwrite directory ‘/usr/local/bin/samtools’ with non-directory

Makefile:283: recipe for target 'install' failed

make: * [install] Error 1

----------

ADD REPLY
0
Entering edit mode

Interesting that /usr/local/bin/samtools is a directory, that's odd. You'll have to manually remove that and the make install again.

ADD REPLY
0
Entering edit mode

Thanks, by the grace of Allah I finally installed samtools but you have not told me the purpose of tview. I think it is for viewing bam files??

ADD REPLY
0
Entering edit mode

It's sort of like IGV, but on the command line and only for BAM files. Personally I use it maybe once a year, but maybe others use it more often. If you need it, then it's just a matter of figuring out where the header files for curses are getting installed on your system and telling configure that. I'm quite surprised that your sudo apt-get didn't result in everything automagically working, but perhaps this is some weird edge case.

ADD REPLY
0
Entering edit mode

actually i previously installed samtools version by running sudo apt-get samtools but the terminal installs version which was old i.e 0.01 etc but i needed latest version.May be it was due to that issue and mine issue is not the first one there are also same caseMakefile - samtools installation failed

ADD REPLY
1
Entering edit mode
8.3 years ago
lc574 ▴ 10

Did you run ./autoconf first?

ADD COMMENT
1
Entering edit mode
8.3 years ago

./configure: line 3086: AX_WITH_CURSES: command not found

This indicates that your unpacked samtools-1.3.1 directory has gotten broken somewhere along the way. Perhaps you ran autoconf therein but did not have the prerequisite autoconf-archive scripts available. (You don't need to run autoconf in a samtools release source directory yourself: it's already set up. Nonetheless, there are improvements that will be made to samtools's infrastructure to make this more robust.)

Delete that source directory, and start again with the release tarball freshly downloaded from github.com/samtools/samtools/releases (use the samtools-1.x.tar.bz2 download link).

ADD COMMENT

Login before adding your answer.

Traffic: 1637 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6