FAQ¶
Installation issues¶
Why am I getting all of these zlib errors?¶
On certain operating systems (especially free Linux distributions) the complete zlib libraries are not installed. Bedtools depends upon zlib in order to decompress gzipped files.
- Building main bedtools binary.
obj/gzstream.o: In function gzstreambuf::open(char const*, int):
gzstream.C:(.text+0x2a5): undefined reference to gzopen64'
collect2: ld returned 1 exit status
make: *** [all] Error 1
If you see an error such as the above, it suggests you need to install the
zlib
and zlib1g-dev
libraries. This is typically straightforward using
package managers. For example, on Debian/Ubuntu this would be:
apt-get install zlib
apt-get install zlib1g-dev
and on Fedora/Centos this would be:
yum install zlib
yum install zlib1g-dev
Compiling with a specific zlib library¶
If you need to override the location of the zlib library used to compile bedtools, you can run make and specify the LIBS argument. For example:
make LIBS='/PATH/TO/ZLIB/lib/libz.a'
General questions¶
How do I know what version of bedtools I am using?¶
Use the –version option.
$ bedtools --version
bedtools v2.17.0
Issues with output¶
I know there are overlaps, but none are reported. What might be wrong?¶
There are two common causes of this problem. The first cause is non-obvious
differences in the way chromosomes are named in files being compared.
For example, “1” is not the same as “chr1” just as ” chr1” is not the same
as “chr1”. Secondly, users often copy files from a Windows machine to a UNIX
machine. This causes issues because Windows uses two bytes to represent
the end of a line (\r\n
) whereas the UNIX convention uses a single byte
(\n
). If your files don’t conform to the UNIX convention, you will have
problems. One can convert files from Windows to UNIX with
the following command:
perl -i -p -e 's/\r\n/\n/g;' file.windows > file.unix