NCO官网写到:
If pre-built executables do not satisfy you (e.g., are out-of-date)
and you want the latest, greatest features, then the first steps to
build (i.e., compile, for the most part) NCO from source code are to
install the pre-requisites: ANTLR version 2.7.7
直接源码编译安装antlr-2.7.7时,编译报错,查阅资料发现为c++库函数bug(https://gist.github.com/kwilcox/6514735)
在解压后的目录中,执行:
$ sed -i "13a #include <strings.h>" lib/cpp/antlr/CharScanner.hpp
$ sed -i "14a #include <cstdio>" lib/cpp/antlr/CharScanner.hpp
添加两个头文件即可成功编译安装