下载bwa对比软件:https://github.com/lh3/bwa
得到bwa-master.zip,然后进入保存该文件的目录,用命令unzip bwa-master.zip对其解压
rm -rf bwa-master.zip将zip文件删除,进入到bwa-master中,输入命令make
输入./bwa 可以查看帮助信息
配置bwa的环境变量:
① nano ~/.bash_profile #设置一些环境变量,设置完后按ctrl+x 、yes和tab
然后输入以下代码设置环境变量:
export PATH=$PATH: /where/to/install/bin
source ~/.bash_profile #在命令行输入,意思为保存文件
如果遇到 bash: ./xx: Permission denied 解决方法,即输入以下代码:
sudo chmod 777 ~/.bash_profile
② vim /etc/profile #另一种设置环境变量的方式
export PATH=/home/zach/bwa:$PATH #输入环境变量,ctrl+x
source /etc/profile #保存