AUGUSTUS is a program that predicts genes in eukaryotic genomic sequences.1
2
3
4 ./augustus
./augustus: /lib64/libc.so.6: version `GLIBC_2.14' not found (required by ./augustus)
./augustus: /public/home/zpxu/bin/gcc-4.8.5/lib64/libstdc++.so.6: version `GLIBCXX_3.4.20' not found (required by ./augustus)
./augustus: /public/home/zpxu/bin/gcc-4.8.5/lib64/libstdc++.so.6: version `GLIBCXX_3.4.21' not found (required by ./augustus)
查看GLIBC版本:1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17strings /lib64/libc.so.6 | grep GLIBC
GLIBC_2.2.5
GLIBC_2.2.6
GLIBC_2.3
GLIBC_2.3.2
GLIBC_2.3.3
GLIBC_2.3.4
GLIBC_2.4
GLIBC_2.5
GLIBC_2.6
GLIBC_2.7
GLIBC_2.8
GLIBC_2.9
GLIBC_2.10
GLIBC_2.11
GLIBC_2.12
GLIBC_PRIVATE
发现最高版本是2.12但是系统需要2.14才可以,那么就自己编译安装吧。
1>下载GLIBC
1 | wget http://ftp.gnu.org/gnu/glibc/glibc-2.14.tar.gz |
2> glibc-2.14.tar.gz解压,并进入解压后目录,创建build目录,并且进入:
1 | tar -zxvf glibc-2.14.tar.gz && cd glibc-2.14 && mkdir build && cd build |
3>编译:
1 | ../configure --prefix=/opt/glibc-2.14 #你的安装目录 |
此时报错如下:1
2
3
4
5checking LD_LIBRARY_PATH variable... contains current directory
configure: error:
*** LD_LIBRARY_PATH shouldn't contain the current directory when
*** building glibc. Please change the environment variable
*** and run configure again.
报错意思简单明了:目录冲突;echo $LD_LIBRARY_PATH
但是次安装目录并不在我的环境变量.bashrc文件里啊。
打开configure文件,查找LD_LIBRARY_PATH,找到如下内容:
Test if LD_LIBRARY_PATH contains the notation for the current directory
since this would lead to problems installing/building glibc.
LD_LIBRARY_PATH contains the current directory if one of the following
is true:
- one of the terminals (“:” and “;”) is the first or last sign
- two terminals occur directly after each other
- the path contains an element with a dot in it
解释就是“LD_LIBRARY_PATH不能以终结符(”:” and “;”)作为开始和最后一个字符,且不能有2个终结符连在一起;因为在环境变量的最前和最后均有一个“:”,程序将此分隔符解释为当前目录了。
解决方法:
执行指令:vi ~/.bashrc
将LD_LIBRARY_PATH环境变量的开头和末尾的“:”去掉,保存。等正确编译完成后可以再次修改回原来。
执行指令:source ~/.bashrc
4> make
1 | make -j4 && make install |
make install 时报错如下:1
2
3
4/usr/bin/install: `include/limits.h' and `/glibc-2.14/include/limits.h' are the same file
make[1]: *** [/glibc-2.14/include/limits.h] Error 1
make[1]: Leaving directory `/glibc-2.14'
make: ***[install] Error 2
Google之发现解决办法如下:1
make install -k -i
通过k和i参数虽然可以强制安装,但经测试并不能真正解决问题,所以这最后一步的安装过程任然卡在这,目前也没有找到有效解决办法。这里先占个坑,等后面找到方法了再补充。
其中-j,-k和-i参数解释如下:1
2
3
4
5
6-j [jobs], --jobs[=jobs]
Specifies the number of jobs (commands) to run simultaneously. If there is more than one -j option, the last one is effective. If the -j option is given without an argument, make will not limit the number of jobs that can run simultaneously.
-i, --ignore-errors
Ignore all errors in commands executed to remake files.
-k, --keep-going
Continue as much as possible after an error. While the target that failed, and those that depend on it, cannot be remade, the other dependencies of these targets can be processed all the same.
5>添加环境变量
1 | export LD_LIBRARY_PATH=/opt/glibc-2.14/lib:$LD_LIBRARY_PATH |
PATH和LD_LIBRARY_PATH区别
PATH: 可执行程序的查找路径;
LD_LIBRARY_PATH: 动态库的查找路径;
再安装AUGUSTUS
上述关于GLIBC安装虽已失败告终,但AUGUSTUS的安装参考Installing Augustus with manual bamtools installation后得到解决。
1. 主要是无root权限下先安装依赖工具bam2hints 和 filterBam👇
首先安装 bamtools1
2
3
4
5
6git clone git://github.com/pezmaster31/bamtools.git
cd bamtools
mkdir build
cd build
cmake -DCMAKE_INSTALL_PREFIX=/your/path/to/bamtools ..
make
2.修改AUGUSTUS中部分MakeFile文件
首先修改augustus-3.2.3/auxprogs/bam2hints
目录下MakeFile文件内容:1
2
3
4
5
6
7
8
9
10
11
12Add:
BAMTOOLS = /your/path/to/bamtools
Replace:
INCLUDES = /usr/include/bamtools
By:
INCLUDES = $(BAMTOOLS)/include
Replace:
LIBS = -lbamtools -lz
By:
LIBS = $(BAMTOOLS)/lib/libbamtools.a -lz
再修改augustus-3.2.3/auxprogs/filterBam/src
目录下MakeFile文件内容:1
2
3
4
5
6
7
8
9
10
11
12
13
14
15Replace:
BAMTOOLS = /usr/include/bamtools
By:
BAMTOOLS = /your/path/to/bamtools
Replace:
INCLUDES = -I$(BAMTOOLS) -Iheaders -I./bamtools
By:
INCLUDES = -I$(BAMTOOLS)/include -Iheaders -I./bamtools
Replace:
LIBS = -lbamtools -lz
By:
LIBS = $(BAMTOOLS)/lib/libbamtools.a -lz
3. make
安装
最后回到主目录augustus-3.2.3
下make
即可安装成功,不需要make install
过程。