Bowtie如何配置

簡(jiǎn)介

Bowtie是一個(gè)快速的,較為節(jié)省內(nèi)存的短序列拼接至模板基因組的工具。它在拼接35堿基長(zhǎng)度的序列時(shí),可以達(dá)到每小時(shí)2.5億次的拼接速度。Bowtie并不是一個(gè)簡(jiǎn)單的拼接工具,它不同于Blast等。它適合的工作是將小序列對(duì)比至大基因組上去。它最長(zhǎng)能讀取1024個(gè)堿基的片段。

配置流程

1.配置編譯環(huán)境

安裝相關(guān)依賴。

yum install gcc gcc-c++zlib-devel-y

2.獲取源碼

獲取“bowtie 1.2.3”源碼包。

cd/usr/local/src
wget https://github.com/BenLangmead/bowtie/archive/v1.2.3.zip

3.編譯和安裝

1)解壓并進(jìn)入源碼目錄。

unzip v1.2.3.zip
cd bowtie-1.2.3

2)修改Makefile文件。

vim Makefile

修改前。

BITS=32
ifeq(x86_64,$(shell uname-m))
BITS=64
endif
#msys will always be 32 bit so look at the cpu arch instead.
ifneq(,$(findstring AMD64,$(PRO CES SOR_ARCHITEW6432)))
ifeq(1,$(MINGW))
BITS=64
endif
endif
ifeq(1,$(LINUX))
ifeq(x86_64,$(shell uname-p))
BITS=64
endif
endif
ifeq(32,$(BITS))
$(error bowtie2 compilation requires a 64-bit platform)
endif
DEBUG_FLAGS=-O0-g3-m64
RELEASE_FLAGS=-O3-m64
NOASSERT_FLAGS=-DNDEBUG
FILE_FLAGS=-D_LARGEFILE_SOURCE-D_FILE_OFFSET_BITS=64-D_GNU_SOURCE

修改后。

BITS=32
ifeq(x86_64,$(shell uname-m))
BITS=64
endif
ifeq(aarch64,$(shell uname-m))
BITS=64
endif
#msys will always be 32 bit so look at the cpu arch instead.
ifneq(,$(findstring AMD64,$(PROCESSOR_ARCHITEW6432)))
ifeq(1,$(MINGW))
BITS=64
endif
endif
ifeq(1,$(LINUX))
ifeq(x86_64,$(shell uname-p))
BITS=64
endif
endif
ifeq(32,$(BITS))
$(error bowtie2 compilation requires a 64-bit platform)
endif
#DEBUG_FLAGS=-O0-g3-m64
#RELEASE_FLAGS=-O3-m64
#NOASSERT_FLAGS=-DNDEBUG
#FILE_FLAGS=-D_LARGEFILE_SOURCE-D_FILE_OFFSET_BITS=64-D_GNU_SOURCE
M64_FLAG:=-m64
ifeq(aarch64,$(shell uname-m))
M64_FLAG:=
endif

3)添加環(huán)境變量。

export NO_TBB=1
export POPCNT_CAPABILITY=0

4)編譯Bowtie。

make-j4

5)添加環(huán)境變量。

vim/etc/profile

將如下內(nèi)容寫入文件最后一行。

export PATH=/usr/local/src/bowtie-1.2.3:$PATH

保存并退出,然后執(zhí)行如下命令是環(huán)境變量生效。

source/etc/profile

4.運(yùn)行和驗(yàn)證

查看Bowtie版本信息。

bowtie--version

回顯類似如下信息表示Bowtie安裝成功。

/usr/local/src/bowtie-1.2.3/bowtie-align-s version 1.2.3
64-bit
...