Infer version 0.8.1安装(14.04 LTS)

一、安装附属项

参考资源:https://github.com/facebook/infer/blob/master/INSTALL.md#pre-compiled-versions

编写shell文件:
gedit ~/Desktop/install.sh
添加如下代码到install.sh

sudo apt-get update
sudo apt-get upgrade
sudo apt-get install -y \
  autoconf \
  automake \
  build-essential \
  git \
  libgmp-dev \
  libmpc-dev \
  libmpfr-dev \
  m4 \
  openjdk-7-jdk \
  python-software-properties \
  unzip \
  zlib1g-dev

为文件添加可执行权限
sudo chmod +x ~/Desktop/install.sh
运行
~/Desktop/install.sh

二、下载最新release版Infer 0.8.1

下载链接:https://github.com/facebook/infer/releases/tag/v0.8.1
infer-linux64-v0.8.1.tar.xz

运行如下命令:

tar xf infer-linux64-v0.8.1.tar.xz
cd infer-linux64-v0.8.1/
./build-infer.sh
export PATH=`pwd`/infer/bin:$PATH

遇到如下问题:

checking for OCaml findlib package atdgen version 1.6.0... not found
configure: error: missing dependency: atdgen.

If you are using opam, please run

  opam update
  opam pin add --yes --no-action infer .
  opam install --deps-only infer

按照提示解决即可。

三、Hello World测试

测试例子链接:http://fbinfer.com/docs/hello-world.html

  • 1
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值