Debian Codegraph @

README

raw
1 This is a Perl interface to the HTS Library. See http://htslib.org
2
3 Bio::DB::HTS supports a wide range of install configurations, with two scripts - Build.PL and INSTALL.pl.
4
5 For a list of the ways it can be used, with examples in action see
6 https://github.com/Ensembl/Bio-DB-HTS/blob/master/scripts/build_options.sh
7 (link to scripts/build_options.sh in the Bio::DB::HTS GitHub repo at https://github.com/Ensembl/Bio-DB-HTS)
8
9 ## ONE-STEP INSTALLATION (INSTALL.pl)
10
11 In the root directory of this distribution you will find the script INSTALL.pl. Running this will download the latest released version of this module (from CPAN) and HTSlib (from GitHub) into a temporary directory, compile them, test and install Bio::DB::HTS. If you wish to install a version of Bio::DB::HTS downloaded (and possibly edited) from GitHub please use Build.PL as documented in the Multi-Step Installations section below.
12
13 Simply run:
14 ```
15 perl INSTALL.pl
16 ```
17
18 It will not install HTSlib at the system level - if desired this can be accomplished by changing into the downloaded htslib sub-directory and typing
19 ```
20 #These commands may need sudo...
21 #make and install the program
22 make install
23 #refresh the installed library listed
24 ldconfig
25 ```
26
27 When invoked, Bio::DB::HTS will try to use HTSlib from its downloaded location. If this is removed it requires htslib to be installed on the system, or LD_LIBRARY_PATH (DYLD_LIBRARY_PATH on Mac OSX) should contain the directory containing libhts.so.
28
29 Alternatively
30 ```
31 perl INSTALL.pl --static
32 ```
33 will install a version of Bio::DB::HTS. Be aware that this option depends on your system supporting it, and upgrades to HTSlib will require a rebuild of Bio::DB::HTS.
34
35 ## MULTI-STEP INSTALLATIONS (Build.PL)
36
37 You may require a more custom install e.g. a specific or customised version of HTSlib, HTSlib installed in a specific directory, or statically included, or Bio::DB::HTS installed in a specific location. Typically these will involve downloading, compiling and installing HTSlib first, followed by downloading compiling and installing Bio::DB:HTS.
38
39 You can see various examples of installing HTSlib and then Bio::DB::HTS using Build.PL by examining scripts/build_options.sh
40
41 ### TROUBLESHOOTING
42
43 If you encounter problems during compiling, you may need to edit
44 Build.PL so that extra_compiler_flags matches the CFLAGS and DFLAGS
45 settings in the HTSlib Makefile. Here are some common problems:
46
47 1. When building this module, you get an error like the following:
48 relocation R_X86_64_32 against `a local symbol' can not be used when
49 making a shared object; recompile with -fPIC
50
51 To fix this, edit the Makefile in the Samtools distribution by adding
52 "-fPIC" to the CFLAGS line. While you're at it, you may also wish to
53 get rid of a bunch of unused variable warnings that appears under
54 recent versions of gcc. The modified CFLAGS will look like this
55
56 CFLAGS= -g -Wall -Wno-unused -Wno-unused-result -O2 -fPIC #-m64 #-arch ppc
57
58 Then do "make clean; make" in the Samtools directory to recompile the
59 library. After this you should be able to build this module without
60 errors.
61
62 2. When building this module, you get an error about a missing math
63 library.
64
65 To fix this, follow the recipe in (1) except add -m64 to CFLAGS so it
66 looks like this:
67
68 CFLAGS= -g -Wall -O2 -fPIC #-m64 #-arch ppc
69
70 3. Remote file access over https is possible using libcurl when compiling HTSlib
71
72 autoconf
73 ./configure --enable-libcurl
74
75
76 4. "Failed to populate reference for id X" error message
77
78 This is probably an indication that the CRAM Reference archive is unavailable.
79
80 ## TESTING AND CONTRIBUTING
81
82 You can obtain the most recent development version of this module via
83 its GitHub site at https://github.com/Ensembl/Bio-DB-HTS. Please
84 feel free to submit bug reports, patches, etc. via GitHub.
85
86 ### AUTHOR
87
88 Rishi Nag <[email protected]>
89 based on Bio::DB::Sam by Lincoln Stein
90
91
92 ### COPYRIGHT
93
94 Copyright [2015-2018] EMBL-European Bioinformatics Institute
95
96 Licensed under the Apache License, Version 2.0 (the "License");
97 you may not use this file except in compliance with the License.
98 You may obtain a copy of the License at
99
100 http://www.apache.org/licenses/LICENSE-2.0
101
102 Unless required by applicable law or agreed to in writing, software
103 distributed under the License is distributed on an "AS IS" BASIS,
104 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
105 See the License for the specific language governing permissions and
106 limitations under the License.